Você está na página 1de 24

Combinational Logic Design

Lecture 13
Topics

 Multiplexer
 Demultiplexer

2 EC381/Digital Systems I Fall 2014


Multiplexer (or Mux)

 Selects one of a set of inputs to pass


on to output
 Binary control code, n lines
 Choose one from 2n inputs
 For n‐inputs, we need ceil( log2(n) )
select inputs.

3 EC381/Digital Systems I
Two Input Mux

Selector

S=0  Y=I0
S=1  Y=I1

Y=S’ I0 +SI1

4 EC381/Digital Systems I
Mux 2 to 1

5 EC381/Digital Systems I
Two Input Mux

6 EC381/Digital Systems I
Two Input Mux

7 EC381/Digital Systems I
4-to-1 Line Multiplexer

MUX1.circ

8 EC381/Digital Systems I
4-to-1 Line Multiplexer

9 EC381/Digital Systems I
4-to-1 Line Multiplexer

x0

x1
f

x2

x3

10 EC381/Digital Systems I
Multiplexer Tree
 We can build large Multiplexers from smaller Multiplexers
 Example
 4 input MUX using 2 input MUX

11 EC381/Digital Systems I
 Example
 16 input MUX using 4 input MUX

12 EC381/Digital Systems I
13 EC381/Digital Systems I Fall 2013
Muxes as General-purpose Logic

 2n:1 multiplexer implements any function of n


variables
1. With the variables used as control inputs and
2. Data inputs tied to 0 or 1
3. In essence, a lookup table
 Example: F(A,B,C) = m0 + m2 + m6 + m7
= A'B'C' + A'BC' + ABC' + ABC

14 EC381/Digital Systems I Fall 2013


Muxes as General-purpose Logic

 2n:1 multiplexer implements any function of n


variables
1. With the variables used as control inputs and
2. Data inputs tied to 0 or 1
3. In essence, a lookup table
1 0
 Example: F(A,B,C) = m0 + m2 + m6 + m7 0 1
1 2
= A'B'C' + A'BC' + ABC' + ABC 0 3
0 4 8:1 MUX F
0 5
1 6
1 7
S2 S1 S0

A B C

15 EC381/Digital Systems I Fall 2013


Multiplexers as General-purpose Logic
(cont’d)
 2n-1:1 mux can implement any function of n variables
 With n-1 variables used as control inputs and
 Data inputs tied to the last variable or its complement
 Example:
 F(A,B,C) = m0 + m2 + m6 + m7
= A'B'C' + A'BC' + ABC' + ABC

16 EC381/Digital Systems I Fall 2013


Multiplexers as General-purpose Logic
(cont’d)
 2n-1:1 mux can implement any function of n variables
 With n-1 variables used as control inputs and
 Data inputs tied to the last variable or its complement
 Example:
 F(A,B,C) = m0 + m2 + m6 + m7
= A'B'C' + A'BC' + ABC' + ABC

1 0
0 1 A B C F
1 2 0 0 0 1 C'
0 3 0 0 1 0 C' 0
0 4 8:1 MUX 0 1 0 1 C' 1 4:1 MUX F
C'
0 5 0 1 1 0 0 2
F
1 6 1 0 0 0 0 1 3 S1 S0
1 7 1 0 1 0
S2 S1 S0 1 1 0 1 1 A B
1 1 1 1

A B C
17 EC381/Digital Systems I Fall 2013
Multiplexers as General-purpose Logic
 Example

x2

x2

x2

X2 ’

18 EC381/Digital Systems I Fall 2013


Multiplexers as General-purpose Logic
 Example

x2

x2

x2

X2 ’

19 EC381/Digital Systems I Fall 2013


Multiplexers as General-purpose Logic-
Example
 F(a,b,c)=Σm(3,5,6,7)
 Design F using 2 to 1 Multiplexer and external gates

20 EC381/Digital Systems I Fall 2013


F1=bc

F2=b+c

F1

 F=a’F1+aF2
 =a’(bc)+a(b+c) F2

21 EC381/Digital Systems I Fall 2013


Multiplexers built using decoders and tri‐state
buffers

22 EC381/Digital Systems I Fall 2013


Demultiplexer

23 EC381/Digital Systems I Fall 2013


Demultiplexer is a decoder with enable
 1 to 4 Demultiplexer ( Takes one input E)
 Out to one of 2n possible outputs
 2 to 4 decoder with enable E (2 inputs S0,S1)

24
EC381/Digital Systems I