|
|
Suppose we have a multiplexor with 4 data inputs and 2 control signals
The inputs are numbered as follows:
The control signals is a binary number used to select the corresponding numbered input
Example: control signals = 00
The control signals = 00 will make output z = input i0
Example: control signals = 01
The control signals = 01 will make output z = input i1
Watch the behaior in the DEMO: /home/cs355001/demo/circuits/mux
I will construct a 4x1 mux (4 inputs to 1 output) - it's easy to generalize
Start with the input data signals and control signals:
Prepare to form all possible combinations of the control signals:
Let input i0 pass only when control signals are equal to: c1=0, c0=0:
Let input i1 pass only when control signals are equal to: c1=0, c0=1:
Let input i2 pass only when control signals are equal to: c1=1, c0=0:
Let input i3 pass only when control signals are equal to: c1=1, c0=1:
Exactly one of the inputs will be active - collate with an OR gate:
DEMO: /home/cs355001/demo/circuits/mux+lights
The EDiSim circuit program for the previous circuit is:
Switch aa i3 '3' ZERO; // Data inputs Switch ba i2 '2' ZERO; Switch ca i1 '1' ZERO; Switch da i0 '0' ZERO; Switch gb c1 '4' ZERO; // Control inputs Switch gc c0 '5' ZERO; Not fb c1 not_c1; Not fb c0 not_c0; And dc i0 not_c1 not_c0 out_0; And ec i1 not_c1 c0 out_1; And bc i2 c1 not_c0 out_2; And ac i3 c1 c0 out_3; Or cd out_3 out_2 out_1 out_0 z; Probe ce z; // Probes to show users |
DEMO: /home/cs355001/demo/circuits/mux