Professional Documents
Culture Documents
T he complexity of a chip
Scale of integration: SSI 1 - 10 gates MSI 10 - 100 gates LSI 100 - 1000 gates VLSI > 1000 gates
Encoder s - Decoder s
Main function of encoder and decoder The purpose is to reduce the number of wires required for interconnection.
Decoders
Decoder logic circuit that activates an output that corresponds to a binary number on the input (set of inputs). May not use all of the possible input codes
ENABLE inputs The 74ALS138 decoder BCD to decimal decoders (the 7442) BCD to decimal decoder/driver (the 7445) Decoder applications
Example
74138 Decoder
BCD-to-7-SEGMENT
7-segment configuration- to form the decimal characters 0 -9 and sometimes the hex characters A F. BCD-to-7-segment decoder/driver is used to take 4-bit BCD input and provide the outputs that will pass current through the appropriate segment to display the decimal digit.
BCD-to-7-SEGMENT
(a) BCD-to-7segment decoder/driver driving a common-anode 7-segment LED display; (b) segment patterns for all possible input codes.
Encoder
The opposite of this decoding process is called encoding and is performed by a logic circuit called an encoder. Encoder has a number of input lines, only one of which is activated at a given time, and produces an N-bit output code depending on which input is activated. An 8-line-to-3-line encoder accepts 8 input lines and produces a 3-bit output code corresponding to the activated input.
Encoder
Following through the logic, verify that a LOW at any input will produce the output binary code corresponding to that input.
Note that A0 is not internally connected (A1A7=1111111, then Q2Q1Q0=000 Only one input should be low. Example: If A3 = A5 =0, and all other are High, then Q Q Q =011 (=3 ), NOT ACCEPTABLE
Encoder
Priority Encoders Include the necessary logic to ensure that when 2 or more inputs are activated, the output code will correspond to the HIGHEST-NUMBERED input. Example: A3, and A5 are LOW, the output code will be 101(5). When A6, A2, and A0 are all LOW, the output code is 110(6). The 74148, 74LS148, and 74HC148 are all
Nine active low inputs representing decimal 1 thru 9 Output: inverted BCD code corresponding to the highest numbered activated input. Outputs can be converted to normal BCD by putting each through an inverter. No A0. When all inputs are high, it corresponds to decimal 0
Switch Encoder
Four-input multiplexer: (a) using sum of products logic; (b) using tristate buffers.
Multiplexer s
Main function of multiplexer and demultiplexer The purpose is to reduce the number of wires required for interconnection by making the signals to time-share the link.
Demultiplexer
E=0, Select input S2S1S0 will select one data input E=1, multiplexer is disable
Multiplexer A pplications
1. 2. 3. 4. Data routing Parallel-to-serial conversion Operation Sequencing Logic Function Generation
1-Line-to-8-Line Demultiplexer
Magnitude Comparator
Cascading Inputs Expanding the comparison operation to more than 4 bits by cascading two or more 4-bit comparators. When 2 comparators are to be cascaded, the outputs of the lower-order comparator are connected to the corresponding inputs of higher-order comparator.
Tr y this....
Whats the output, if 74ALS138 .
E 0 = 0 E 0 = E 0 = 0 A0 = A0 = 0 A0 = 0 , ; ,
E0 = E 0 = 0E 0 = 0 A0 = A0 = 0A0 = 0 , ; ,
Figure 1
Try this....
Determine the states of the 74147 decimal-to-BCD priority encoder outputs when A 0, A 0, A 0are LOW and the other are HIGH.
Basic Adders
Half-Adder
Simple Binary Addition 0+0=0 0+1=1 1+0=1 1 + 1 = 10 Zero plus zero equals zero Zero plus one equals one One plus zero equals one One plus one equals zero with a carry of one
Half-Adder
Full-Adder