decoders and encoders sections 3-5, 3-6 mano & kime

30
Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

Post on 21-Dec-2015

255 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

Decoders and Encoders

Sections 3-5, 3-6 Mano & Kime

Page 2: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

Decoders and Encoders

• Binary Decoders

• Binary Encoders

• Priority Encoders

Page 3: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

Decoders

Page 4: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime
Page 5: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

3-to-8 Line Decoder

Page 6: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

A 2-to-4-Line Decoder

Page 7: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

Implementing a Binary Adder Using a Decoder

S(X,Y,Z) = m(1,2,4,7)

C(X,Y,Z) = m(3,5,6,7)

Page 8: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

Decoder Networks

Page 9: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

4-input tree decoder

Page 10: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime
Page 11: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

Decoder uses

Page 12: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

Decoder uses

Page 13: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime
Page 14: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

Decoders and Encoders

• Binary Decoders

• Binary Encoders

• Priority Encoders

Page 15: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

Binary encoders

Page 16: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

A0 = D1 + D3 + D5 + D7

A1 = D2 + D3 + D6 + D7

A2 = D4 + D5 + D6 + D7

Page 17: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime
Page 18: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

Uses of binary encoders

Page 19: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

Decoders and Encoders

• Binary Decoders

• Binary Encoders

• Priority Encoders

Page 20: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime
Page 21: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

Maps of Priority Encoder

Page 22: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

Logic Diagram of a4-Input Priority Encoder

Page 23: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

Uses of priority encoders

Page 24: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

VHDL Example:8-input priority encoder

Page 25: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

entity pencoder is

port (

x: in STD_LOGIC_VECTOR (7 downto 0);

E: in STD_LOGIC;

y: out STD_LOGIC_VECTOR (2 downto 0);

A: out STD_LOGIC

);

end pencoder;

Page 26: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime

architecture pencoder_arch of pencoder isbegin pe: process(x,E) variable k: integer; begin y <= "000"; A <= '0'; if E = '1' then for j in 0 to 7 loop if x(j) = '1' then

y <= conv_std_logic_vector(j,3); A <= '1'; end if; end loop; end if; end process pe;end pencoder_arch;

Page 27: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime
Page 28: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime
Page 29: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime
Page 30: Decoders and Encoders Sections 3-5, 3-6 Mano & Kime