Presentation is loading. Please wait.

Presentation is loading. Please wait.

QUIZ What Circuit is this ?. Entity (The Object) -- Entity informs about the circuit’s interface -- signals entity my_circuit is port (L0, L1, L2, L3.

Similar presentations


Presentation on theme: "QUIZ What Circuit is this ?. Entity (The Object) -- Entity informs about the circuit’s interface -- signals entity my_circuit is port (L0, L1, L2, L3."— Presentation transcript:

1 QUIZ What Circuit is this ?

2 Entity (The Object) -- Entity informs about the circuit’s interface -- signals entity my_circuit is port (L0, L1, L2, L3 in bit; A, B in bit; F out bit ); end my_circuit ;

3 ARCHITECTURE (The Method) Architecture describes what is the circuit doing. Many Different ways to the describe a circuit.

4 Boolean Signal Flow architecture equation of my_circuit is begin F <= (not A) and (not B) and L0 or (not A) and B and L1 or A and (not B) and L2 or A and B and L3; end equation;

5 Programmer’s View architecture behaviour of my_circuit is begin process(A, B) is begin if A = ‘0’ and B=‘0’ then F <= L0 ; elsif A = ‘0’ and B=‘1’ then F <= L1 ; elsif A = ‘1’ and B=‘0’ then F <= L2 ; else F <= L3 ; end if; end process; end behaviour;

6 C Programmer’ View architecture looks_like_C of my_circuit is signal sel: bit_vector(1 downto 0); begin sel <= ‘A’ & ‘B’; -- runs concurrently with the process below process(sel) is begin case sel is when "00" => F <= L0; when "01" => F <= L1; when "10" => F <= L2; when others => F <= L3; end case; end process; end looks_like_C;

7 Designer’s way. Very specific! architecture simple of my_circuit is begin with A&B select F <= L0 when "00", L1 when "01", L2 when "10", L3 when "11"; end simple;

8 Designer’s, more flexible way architecture flexible of my_circuit is begin F <= L1 when A&B = “00”, L2 when A&B = “01”, L3 when A&B = “10”, L4 when A&B = “11”; end flexible;

9 The Answer is 4:1 Multiplexer


Download ppt "QUIZ What Circuit is this ?. Entity (The Object) -- Entity informs about the circuit’s interface -- signals entity my_circuit is port (L0, L1, L2, L3."

Similar presentations


Ads by Google