- A multi-way switch or many-to-one switch
is a device that allow you to make
a selection from many input value:
The above figure shows the logical function of a many-to-one switch in
2 different state.
In the left figure, the switch directs the top-most input
to the output, and in the second, it directs the 3rd input to
the output.
- You are familiar with a multi-way switch, you find them in many
common devices.
One example is the switch in a boom box that let you select
from CD, radio, and cassete.
- The many-to-one switch in computer is called a
multiplexor or mux.
Schematically (functionally), a multiplexor looks like this:
- The multiplexor can be constructed using a simple 2 staged technique.
- Here is (again) the circuit diagram for a
4x1 multiplexor
(4x1 means it switches
4 inputs to
1 output):
- The following circuit diagram shows what will happen when
the
control signals are 11 (= 3decimal))
(the mux will switch the
input i3 to the
output):
- Notice that three of the and gates will receive at least one
input that is equal to ZERO (red line).
These and-gates will output ZERO.
- Notice that the top-most and gates will receive all 1's
from the control-inputs.
The top-most and-gate will operate as a "pass-through"
for the input signal i3
- The output of the top-most and-gate is equal to the input value
i3
- Looking at the Or-gate, you will notice that all but one input
is ZERO (because all but one and-gates in the first stage will
output ZERO).
- The or-gate will thus also operate as a "pass-through"
for the input signal i3
- The other cases of control signals are similar.
For example, if the control signals are (0,0),
then the top-most 3 and-gates will receive at least one
input signal that is ZERO and will output ZERO.
The bottom and-gate will operate as a "pass-through"
for the input signal i0
The or-gate will now operate as a "pass-through"
for the input signal i0
- You can see the circuit in action with EDiSim yourself:
click here
Run the mux circuit as:
/home/cs355001/bin/cs355sim /home/cs355001/demo/circuits/mux
|
In this circuit,
I adding some probes to show the
output values of the
AND gates to
show you how this
circuit works:
/home/cs355001/bin/cs355sim /home/cs355001/demo/circuits/mux+lights
|
Notice only the
select input will
pass through its
AND-gate.
All the
outputs of the
non-selected AND-gates
are equal to ZERO.