10) encoder prac 10
TRANSCRIPT
-
7/28/2019 10) Encoder Prac 10
1/8
Logic Design & Switching Circuits EncodersInstitute of Industrial Electronics
Engineering
Lab Session 10
ENCODERS
OBJECTIVE
To Verify the characteristics of Encoders.
APPARATUS
Power Supply
Resistors
LEDs
Jumper wires
DIP switches
4 bit Encoder (74LS148)
THEORY:An Encoder is a combinational logic circuit that essentially performs a REVERSE
decoder function. An Encoder accepts an active level on one of its inputs representinga digit, such as a decimal or octal digit, and converts it to a coded output, such as BCDor binary. Encoders can also be devised to encode various symbols and alphabeticcharacters. The process of converting from familiar symbols or numbers to a codedFormat is called Encoding.An encoder can be a device used to change a signal (such as a bit-stream) or data intoa code. The code serves any of a number of purposes such as compressinginformation for transmission or storage, encrypting or adding redundancies to the inputcode, or translating from one code to another. This is usually done by means of aprogrammed algorithm, especially if any part is digital, while most analog encoding isdone with analog circuitry.
Single bit 4 to 2 Encoder
An encoder has 2n input lines and n output lines. The output lines generate abinary code corresponding to the input value. For example a single bit 4-to-2Encoder takes in 4 bits and outputs 2 bits. It is assumed that there are only 4 typesof input signals these are: 0001, 0010, 0100, 1000.
Decimal to Binary Encoder
This type of Encoder has 10 Inputs. One for each decimal digit. And four outputscorresponding to the BCD code. As Shown Below.
-
7/28/2019 10) Encoder Prac 10
2/8
22
-
7/28/2019 10) Encoder Prac 10
3/8
Logic Design & Switching Circuits EncodersInstitute of Industrial Electronics
Engineering
This is the basic 10 to 4 line Encoder. The BCD code i.e. from MSB LSB (8421) is
listed in below Table. From this we can examine the relationship between each BCD andDecimal Digits in order to analyze the Logic. The 74LS147 Encoder is Used for theDecimal to Binary Encoder.
Basic Logic Diagram of Decimal to Binary Encoder is As Follows. A 0-Digit input is notneeded because the BCD outputs are all Low when there is no High Input.
8 line-to-2-line Priority Encoder:The 74LS148 Encodes Eight Data lines to three-line (4-2-1) binary (octal). By
providing cascading circuitry (Enable Input EI and Enable Output EO) Octal Expansion isallowed without needing external circuitry. The 74LS148 8-input priority Encoder acceptsdata from eight active LOW output and provides a binary representation on the threeactive LOW outputs. A priority is assigned to each input so that when two or more inputsare simultaneously active, the input with the highest priority is represented on the Output,
with input Line 7I having the highest priority.
-
7/28/2019 10) Encoder Prac 10
4/8
Logic Design & Switching Circuits EncodersInstitute of Industrial Electronics
Engineering
The two different Logic Symbols of 74LS148 is Shown Below:
The pin configuration of74148 is Shown Below:
The 74LS148 can be expended to 16-to-4 line Encoder by connecting the EO of higherorder encoder to the EI of Lower order encoder and Negative-ORing the correspondingoutputs. The EO is used as the fourth and most significant bit. This particularconfiguration produces active High outputs for the 4-bit binary number.
-
7/28/2019 10) Encoder Prac 10
5/8
22
-
7/28/2019 10) Encoder Prac 10
6/8
Logic Design & Switching Circuits EncodersInstitute of Industrial Electronics
Engineering
The Function Table of Encoder 74LS148 is:
INPUTS OUTPUTS
EI D7 D6 D5 D4 D3 D2 D1 D0 GS A2 A1 A0 EO
0 1 1 1 1 1 1 1 0 0 0 0 0 1
0 1 1 1 1 1 1 0 1 0 0 0 1 1
0 1 1 1 1 1 0 1 1 0 0 1 0 1
0 1 1 1 1 0 1 1 1 0 0 1 1 10 1 1 1 0 1 1 1 1 0 1 0 0 1
0 1 1 0 1 1 1 1 1 0 1 0 1 1
0 1 0 1 1 1 1 1 1 0 1 1 0 1
0 0 1 1 1 1 1 1 1 0 1 1 1 1Where,
1 = HIGH Voltage Level0 = LOW Voltage Level
Circuit Diagram:
U5
74LS148N
A09
A17
A2 6
GS14
D313
D41
D52
D212
D111
D010
D74
D63
EI5
EO15
GND8
VCC16
0
0
65
4
3210
28
-
7/28/2019 10) Encoder Prac 10
7/8
Logic Design & Switching Circuits EncodersInstitute of Industrial Electronics
Engineering
PROCEDURE:
Construct the circuit as shown below.
Now close the dip switch and power on the voltage source.
Observe the status of the LED.
Now open the dip switch and observe the status of the LED.
Also try to obtain output waveform by connecting Oscilloscope probes across
the resistor and quickly switching on & off the dip switch.
SIMULATION RESULTS:
-
7/28/2019 10) Encoder Prac 10
8/8
Logic Design & Switching Circuits EncodersInstitute of Industrial Electronics
Engineering
OBSERVATIONS:
We observe that the output comes in following the Truth Table given below:
INPUTS OUTPUTS
EI D7 D6 D5 D4 D3 D2 D1 D0 GS A2 A1 A0 EO
0 1 1 1 1 1 1 1 0 0 0 0 0 1
0 1 1 1 1 1 1 0 1 0 0 0 1 1
0 1 1 1 1 1 0 1 1 0 0 1 0 1
0 1 1 1 1 0 1 1 1 0 0 1 1 1
0 1 1 1 0 1 1 1 1 0 1 0 0 1
0 1 1 0 1 1 1 1 1 0 1 0 1 1
0 1 0 1 1 1 1 1 1 0 1 1 0 1
0 0 1 1 1 1 1 1 1 0 1 1 1 1Where,
1 = HIGH Voltage Level0 = LOW Voltage Level
CONCLUSION:The Encoders are very useful circuits to convert decimal inputs to Binary output and
is used in Keypad circuits.