Differenze tra le versioni di "No more secrets Part 5: Mux Demux"
(Creata pagina con '== The MUX (or Selector) == The Multiplexor (also called Mux or Selector by closer friends) is a circuit which has n control inputs, 2^n data inputs and une output. The cont...') |
m (→The Demux) |
||
Riga 55: | Riga 55: | ||
== The Demux == | == The Demux == | ||
+ | |||
+ | A demultiplexer is the opposite of a mux. It takes one data input and n control inputs and 2^n output lines. | ||
+ | The input is copied on the output line addressed by the control input. | ||
+ | |||
+ | A demux is conceptually similar to a railroad switching system, this time the one that the trains | ||
+ | use entering a station. A train coming from a railroad is router to a specific track to | ||
+ | approach a specific platform where people can get on and off. | ||
+ | |||
+ | [[File:railswitch2.jpg]] | ||
+ | |||
+ | Unfortunately it needs 14 nand gates to create a two control inputs demux circuits, two more than those available on out breadboard. | ||
+ | However, It is possible to build two 1 control bit demuxes. | ||
+ | |||
+ | This is the circuit: | ||
+ | [[File:demux.jpg]] | ||
+ | |||
+ | This is the table to set up the jumpers on the breadboard: | ||
+ | <pre> | ||
+ | c0: AAD | ||
+ | in0: BD | ||
+ | c1: FFI | ||
+ | in1: GH | ||
+ | A: B | ||
+ | B: CC | ||
+ | C: out00 | ||
+ | D: EE | ||
+ | E: out01 | ||
+ | F: G | ||
+ | G: HH | ||
+ | H: out10 | ||
+ | I: JJ | ||
+ | J: out11 | ||
+ | </pre> |
Versione delle 17:22, 10 giu 2014
The MUX (or Selector)
The Multiplexor (also called Mux or Selector by closer friends) is a circuit which has n control inputs, 2^n data inputs and une output.
The control input decides which data input is copied into the output all the other inputs are simply ignored.
In my mind a Mux is similar to a track switch on a railroad. More specifically the switching system for the trains leaving a station. There are plenty of platforms in the station and the switches must be set up for the departing train to guarantee the routing to the railroad to the next station
The truth table for a mux having two control inputs is the following
in1 in0 dt0 dt1 dt2 dt3 out 0 0 0 x x x 0 0 0 1 x x x 1 0 1 x 0 x x 0 0 1 x 1 x x 1 1 0 x x 0 x 0 1 0 x x 1 x 1 1 1 x x x 0 0 1 1 x x x 1 1
(where x means for any value of this input, both 0 and 1)
The circuit is the following:
ANd this is the file for the jumpers:
in0: AACF in1: HHJ dt0: B dt1: C dt2: E dt3: F A: BE B: D C: D D: I E: G F: G G: J H: I I: K J: K K: out
For each configuration of in0 and in1 the corresponding input will be copied to the output. To test this circuit, plug in a led to the output gate (K) and set both in0 and in1 to 0, now the led is turned on and off by setting on and off in0. In other words, in0 is copied on out. Any input on dt1, dt2 or dt3 does not change the value of out. Now if you set in0 to 1, in1 is copied to out. Now the value at dt0 dt1 and dt3 is irrelevant, while the led turns on and off when the input at dt1 changes. Similarly when in0 and in1 are 1 0, dt2 is copied and when in0 and in1 are 1, 1 is the turn of dt3.
The Demux
A demultiplexer is the opposite of a mux. It takes one data input and n control inputs and 2^n output lines. The input is copied on the output line addressed by the control input.
A demux is conceptually similar to a railroad switching system, this time the one that the trains use entering a station. A train coming from a railroad is router to a specific track to approach a specific platform where people can get on and off.
Unfortunately it needs 14 nand gates to create a two control inputs demux circuits, two more than those available on out breadboard. However, It is possible to build two 1 control bit demuxes.
This is the circuit: File:Demux.jpg
This is the table to set up the jumpers on the breadboard:
c0: AAD in0: BD c1: FFI in1: GH A: B B: CC C: out00 D: EE E: out01 F: G G: HH H: out10 I: JJ J: out11