Hardware Reference
In-Depth Information
Lösung zu Aufgabe 1.8
a)Berechnungsbaum b)Signalflussplan
( )
∧
x
1
&
x
2
x
3
( )
( )
∧
∧
&
( )
∧
( )
&
∧
x
1
x
2
x
3
x
1
x
2
x
3
Für die gleichberechtigten UND-Verknüpfungen ist für den Berechnungsbaum
eine Abarbeitung von links nach rechts unterstellt. Im Signalflussplan sind die
gleichberechtigten UND-Verknüpfungen und die anschließenden Negationen
jeweils zu NAND-Gattern mit drei Eingängen zusammengefasst.
c) Siehe Web-Projekt P1.2/LsgSchaltungAusdruck.vhdl:
--
Vereinbarungen der Entwurfseinheit
signal x: std_logic_vector(
3
downto
1
) ;
signal y: std_logic;
--
nebenläufige Anweisungen der Entwurfseinheit
y <=
not
(x(
1
)
and
x(
2
)
and not
x(
3
))
and
not
(
not
x(
1
)
and not
x(
2
)
and not
x(
3
))
after
2 ns
;
Lösung zu Aufgabe 1.9
--
b) Testrahmen
entity
Test_S2B
is end entity
;
architecture
t1
of
Test_S2B
is
signal
x:std_logic_vector(
4
downto
1
);
signal
y:std_logic;
begin
TObj:
entity
work.S2B(stk)
port map
(x1=>x(1), x2=>x(2),
x3=>x(3), x4=>x(4), y=>y);
process
begin
wait for
5 ns
; x<=
"0000"
;
wait for
5 ns
; x<=
"0001"
;
wait for
5 ns
; x<=
"0011"
;
wait for
5 ns
; x<=
"0111"
;
wait
;
end process
;
end architecture
;
--
a) Strukturbeschreibung
entity
S2B
is
port
(x1,x2,x3,x4:
in
std_logic;
y:
out
std_logic);
end entity
;
architecture
stk
of
S2B
is
signal
z:std_logic;
begin
G1:
entity
work.Gxx(fkt)
port map
(a=>x1, b=>x2,
c=>x3, d=>z);
G2:
entity
work.Gxx(fkt)
port map
(a=>z, b=>x3,
c=>x4, d=>y);
end architecture
;
)
WEB-Projekt:P1.2/LsgGxx.vhdl