Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

Lecture Notes On Logic Circuits

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 15

+5

V
5
T ime
+5
V
5
1 0 1
T ime
Logic Circuits and Switching Theory

Module 1
Review on Digital Circuits
Introduction
Digital computers have made possible many scientific, industrial, and
commercial advances that would have been unattainable otherwise. Our
space program would have been impossible without real time, continuous
computer monitoring, and many business enterprises function efficiently only
with the aid of automatic data processing.
Logic Design vs. Computer Design
Logic design deals with the basic concepts and tools used to design
digital hardware consisting of logic circuits.
Computer design deals with additional concepts and tools used to design
computers and other complex digital hardware.
Numerical Representations
Almost all the fields of endeavor are dealing with quantities.
Quantities are measured, monitored, recorded, manipulated arithmetically,
observed, and utilized in most physical systems.
There is a need to represent these quantities/values efficiently and
accurately.
Ways to represent numerical values
Analog representation represented by a voltage, current, or meter
movement proportional to the value of that quantity.
Digital representation represented not by continuously variable indicators
but by symbols called digits.
Analog Examples:
Automobile speedometer
deflection of the needle is proportional to the speed of the
auto.
Mercury thermometer
height of the column of mercury is proportional to the room
temperature.
Audio microphone
output voltage is generated in proportion to the amplitude of
the sound waves that impinge on the microphone.
Analog AC-powered wall clock
time of the day changes continuously as the needle reading
changes continuously.
Analog Signal Characteristics
Having a continuous range of values and can be associated with
continuous physical phenomena.
Continuous signal - smooth connected, an unbroken series of consecutive
values with no instantaneous changes.



Digital Example
Digital watch
provides time of the day in the form of digital digits that represents
hours and minutes (and sometimes seconds). The watch reading
changes in discrete steps of one per minute (or per second).
Digital signal
Typically has two discrete values (or states) and are appropriate for any
phenomena involving counting or integer numbers.
Discrete signal - separated into distinct segments or pieces, a series of
discontinuous values.





Major differences:
Analog and Digital quantities:
Analog continuously variable defined values
Digital vary only by discrete steps
Analog Digital
Continuously variable Discrete steps
Amplification Switching
Voltages Numbers
No ambiguity in reading the value of a digital quantity
Value of analog quantity is often open to interpretation, thus we always
round to a convenient level of precision.
Points to Ponder:
Real life is full of analog signals.
Analog systems: slight error in input, large error in output.
General purpose computers: digital
Sensors & actuators - interface circuits are often analog.
Digital systems: more accurate, reliable and deal better with
degraded signals.
Digital signals - easier to process, used as an approximation to real
analog signals.
Binary digital systems - has only two discrete values that make
digital systems easier to decode.
Two discrete values:
1. High voltage, high current flowing, ON, TRUE, YES, "1"
2. Low voltage, low current flowing, OFF, FALSE, NO, "0"
Digital logic levels
Voltage that represents a defined digital state in an
electronic circuit.
Logic LOW (or logic 0)
lower of two voltages (usually 0V) in a digital system with
two logic levels.
Logic HIGH (or logic 1)
higher of two voltages (traditionally 5V, but in some systems
a specific value such as 1.8V, 2.5V or 3.3V) in a digital system with
two logic levels.
Digital logic levels








Digital System
Devices designed to manipulate logical information or physical
quantities that are represented in digital form. Most often electronic, but they
can also be mechanical, magnetic, or pneumatic.
Analog system
Devices that manipulate physical quantities that are represented in
analog form.
Advantages of digital techniques
Reproducibility of results
Easier to design
Flexibility and functionality
Programmability
Speed
Economy
Steadily advancing technology
Storage is easy
Limitations of Digital Techniques
The real world is analog most physical quantities are analog in
nature.
Processing digitized signals takes time.
Digital Conversion:
when dealing with analog inputs and outputs:
Convert the real-world analog inputs to digital form.
Process (or operate on) the digital information
Convert the digital outputs back to real-world analog form.
Block diagram








Digital Circuit
Inherently binary in nature, but several types of representations of numerical
data are in use.
The representation of an unsigned integer can be done in binary, octal,
decimal or hexadecimal.
For display purposes, each decimal digit is often represented by a four-bit
binary number in a system called binary coded decimal (BCD).
Digital Representation









Number Systems
Decimal Numbering System
Uses ten (10) as a base, also called base-10 system.
It uses ten digit symbols: 0, 1, 2, 3, 4, 5, 6, 7, 8, and 9.
Each number position represents a weighting factor (positional value
system) which is a power of the base ten. (1, 10, 100, 1000, etc.)
Why do we use 10 digits, anyway?
Digit is derived from the Latin word for finger
Decimal: Example
4175.8610 can be computed as:
=(4 x 103) + (1 * 102) + (7 * 101) + (5 * 100) + (8 * 10-1) + (6 * 10-2)
7,392.42 is equal to:
= (7 * 103) + (3 * 102) + (9 * 101) + (2 * 100) + (4 * 10-1) + (2 * 10-2)
Octal Numbering System
A base-eight numbering system with eight digits of 0,1,2,3,4,5,6,7.
Decimal Octal
-------- ------
0 0
1 1
7 7
8 10
9 11
For example to count in octal the digits combine after reaching a
count of 7
1,..7,10,11,12,,17,20,21,,75,76,77,100
For two octal digits the largest number is 77 so the two octal digits
end after at 77.
To find the decimal number equal to an octal number:
(127.4)8
= (1* 82) +(2 * 81) + (7 * 80) +
(4 * 8-1 )
= (87.5)10
(4536)8
= (4x83) + (5x82) + (3x81) + (6x80)
= (1362)10
Summary: Octal
In the octal system, a number with digits XYZ can be written as:
XYZ8
= (X x 82) + (Y x 81) + ( Z x 80)
Sixty fours Eights Ones
32768 4096 512 64 8 1











Hexadecimal Numbering System
Has a base-16
There are 16 digits in this system: 0, 1..9, and A, B, C, D, E, F)
Hexadecimal Decimal
----------- -------
0 0
1 1
..
9 9
A 10
B 11
..
E 14
F 15
To count in hexadecimal: 0..F,10,11,19,1A,1B,..,1E,1F,20,
21,.99,9A,,9F,A0,A1..,FE,FF,100
For two hexadecimal digits the largest number is FF so the two
hexadecimal digits end after at FF.
To find the decimal number equal to a hexadecimal number:
(B65F)16
= (11 * 163)+ (6 * 162)+ (5 * 161)+ (5 * 160)
= (46,687)10
Try this
(BCF) 16
(FA.CE) 16
XYZ16 = X x 162 + Y x 161 + Z x 160
256s 16s 1s
1048576 65536 4096 256 16 1



Binary Numbering System
Uses two (2) as a base, made of binary digits (bits): 0 and 1; useful
to represent switch positions (open or closed).
Leftmost bit position is called Most Significant Bit (MSB).
Right most bit position is called Least Significant Bit (LSB).

Conversion of Integer from
Decimal to other Bases
For each digit position:
1. Divide decimal number by the base.
2. The remainder is the lowest-order digit
3. Repeat first two steps until no divisor remains.
4.
Example: (13)10 = _____ 2





Operations on Numbers
Binary Addition
Multiplication of Binary numbers
Complements
Common use of complement: subtraction operation.
Perform subtraction through the addition operation.
Two types of complements for each r system:
rs complement ( radix complement )
(r-1)s complement ( diminished radix complement)

(r-1)s Complements
(r-1)s complement for a number N with n digits in base-r numbering system
is defined as: (rn-1 ) N
Example #1: Find the 9s complement of 12389:
= (105 -1 ) - 12389
= 99999 -12389 = 87610
Example #2: Find the 9s complement of 1234:
= (104 -1) 1234 = 9999 -1234
= 8765
Example #3: Find the 1s complement of 1011001:
= (27 1 ) 101 1001
= 111 1111 101 1001 = 010 0110

Notice that the 1s complement of binary numbers is formed by changing
1s to 0s and 0s to 1s
Example: 1s complement of 0001111 is 1110000.

(rs complement)
(rs) complement for number N in base r with n digits is defined as rn N
Also, rs complement= ( r-1)s complement +1

Example #1: Find the 10s complement of 2389:
=9999 - 2389 = 7610 + 1 = 7611
Example #2: Find the 2s complement of 10 1100:
= 11 1111 - 10 1100 = 01 0011 + 1
= 010100

Subtraction with complements
(Unsigned Numbers)
Use the following algorithms:
1. Add M to rs complement of N

2. If M>=N, then subtract the sum to rn to form the result.

3. if M<N place a negative sign - in front of rs complement of the result

Do the operation: 3250 - 72532

M = 03250
10s complement of N = + 27468
------------
30718
Since N is > M the result is:
- (10s complement 30718) =-69282

Perform the operation using 2s complement: 1010100 - 1000011
Solution:
X = 1010100 = 101 0100 (copy)
- Y = 1000011 =+ 011 1101 (2s)
1 001 0001
- 1 000 0000
001 0001


Signed Binary Numbers
01001 can be considered unsigned binary = 9 or signed binary = +9
But, 11001 can be considered unsigned binary = 25 or signed binary = -9
Signed numbers uses 0 for + and 1 for - , this system is called
Signed-
magnitude convention
All negative numbers have 1 in leftmost bit
Signed magnitude is mostly used in ordinary arithmetic.
The 1s complement is mostly used in logical operations.
The 2s complement is mostly used in computer arithmetic.

Binary Coded Decimal (BCD)
Uses 4 bits to encode one decimal digit
Example: (4321)10
= 0100 0011 0010 0001
Invalid digits: 1010, 1011,1100,1101,
1110,and 1111.

Character Representation
ASCII American Standard Code for Information Interchange
128 characters (7 bits required)
Contains:
Control characters (non-printing)
Printing characters (letters, digits, punctuation)


Error-Detecting Code
To detect the error in data communication, an 8th bit is added to ASCII
character to indicate its parity.
Parity bit - extra bit included with a message to make the total number of 1s
either even or odd
The 8-bit characters included parity bits (with even parity) are transmitted to
their destination. If the parity of received
character is not even it means at least one bits has been changed.

Binary Storage and Registers
Register - group if binary cells that are responsible for storing and holding
the binary information.
Register transfer operation is transferring binary operation from one set of
registers to another set of registers.
Digital logic circuits process the binary information stored in the registers.

Boolean Algebra

Invented by George Boole in 1854
Considered as the backbone of computer circuit
analysis and design
It is a branch of mathematics that is directly
applicable to digital design.
It is a set of elements, a set of operators that act
on these elements, and a set of axioms or
postulates that govern the actions of these
operators on these elements.

Theorems and Postulates
The postulates are basic axioms of the algebraic
structure and need no proof.
Basic Identity (a) x+ 0 = x (b) x. 1 = x
Commutative
Property
(a) x + y = y + x (b) xy = yx
Distributive
Property
(a) x(y+z) = xy+xz (b) x+yz = (x+y )
(x+z)
Basic Identity (a) x+ x = 1 (b) xx = 0
Postulates of Boolean Algebra

The theorems must be proven from the
postulates
Theorem 1. Identity x + x = x xx = x
Theorem 2. Identity x+ 1= 1 x.0 = 0
Theorem 3. Involution (x) = x
Theorem 4.
Associative
x+(y+z) = (x+y) + z x(yz) = (xy)z
Theorem 5. De
Morgans
(x+y) = x.y (xy) = x + y
Theorem 6.
Absorption
x + xy = x x(x+y) = x

Operations with Boolean Algebra
Complementation ()
To complement a variable is to reverse its
value
Represented by placing a bar over the
variable or by the () symbol after the variable.

Addition (+)
Boolean Addition is equivalent to logical
OR.
The (+) plus symbol is used to indicate
the addition or ORing
Multiplication (.)
Boolean multiplication is equivalent to a
logical AND operation

Truth Table
It lists every possible combination of inputs and the
output corresponding to each combination of inputs.
Given a function N inputs, the possible combinations will
then be equal to 2N.
Example: using a truth table prove that x (x+y) = x.

x y x+y x(x+y)
0 0 0 0
0 1 1 0
1 0 1 1
1 1 1 1


Boolean Functions
It is defined using an equal sign and an
expression comprise of binary variables,
two binary operators OR and AND, the
unary operator NOT and the parentheses.
It may also be represented by a truth
table, showing all the possible 1s and 0s
combination of the N binary variable

Algebraic Manipulation
A Boolean function may be transformed
from an algebraic expression into a logic
diagram composed of AND, OR and NOT.
There is an AND gate for each term in the
expression, and an OR gate is used to
combined two or more terms.

Complement of a Function
The function F and F are complementary
if:
they depend on the same set of input
variables
for every combination of values of the input
variables, the values of F and F are inverses
to each other.

The complement of a function may be derived
algebraically using De Morgans theorem.

Canonical Forms
A binary variable may appear either in its normal
form (x) or in its complemented form (x).
Combining x and y with the AND operator, the
following 4 combinations will result: xy, xy, xy
and xy.

Minterm or Standard Products
Obtained from an AND terms of the N
variables
It is represented by the symbol mj
where j
denotes the decimal equivalent of the binary
value
Maxterm or Standard Sums
Obtained from an OR term of the N variables
It is represented by the symbol Mj
where j
denotes the decimal equivalent of the binary
value

Sum of Minterms
The ORing of terms which result in
a 1-value of the function. Ex.

Boolean Function:
F1=xyz + xyz + xyz
=m1 + m4 +m5
or F1=(1, 4, 5)

Complement of the Function
F1=xyz + xyz + xyz + xyz + xyz
= m0, m2, m3, m6, m7

or F1 =(0, 2, 3, 6, 7)
x y z F1
0 0 0 0
0 0 1 1
0 1 0 0
0 1 1 0
1 0 0 1
1 0 1 1
1 1 0 0
1 1 1 0

Product of Maxterms
The ANDing of terms which
each result in a 0-value of the
function
Ex. Express the Boolean
function F= AB + AC as a
product of maxterms

F= (M0,M1, M2,M3,M5)
F=(A + B +C) (A+B+C)
(A+B+C) (A+B+C) (A+B+C)
A B C F
0 0 0 0
0 0 1 0
0 1 0 0
0 1 1 0
1 0 0 1
1 0 1 0
1 1 0 1
1 1 1 1


Standard Forms:
Two types of Standard Form
Sum of Products
A Boolean expression containing AND terms of one or more
literals each.
The sum denotes the ORing of the AND terms.
Ex. F1= y + xyz + xz
Product of Sums
A Boolean expression containing OR terms of one or more
literals each.
The sum denotes the ANDing of the OR terms.
Ex. F2=y (x+z) (x+y+z) (x+y+z+w)

Binary Logic and Gates
Integrated Circuits
Circuits implemented using transistors and
interconnections (semiconductor devices).
Logic Gate basic circuit

Karnaugh Map
Proposed by Veitch and modified by
Karnaugh
A diagram made up of squares, each
squares represents one minterm
The map presents a visual diagram of all
possible ways a function may be
expressed in a standard form.

Pairs
Group of two 1s that are vertically or horizontally
adjacent.
It is customary to encircle a pair of adjacent 1s
for easy identification.
If one variable changes its value, that variable
can be eliminated. (The variable and its
complement will be eliminated.)
If more than one group exists on a map, you can
OR the simplified product to get the simplified
Boolean equation.

Quads
A group of four 1s that are end to end or in
the form of square.
Two variables and their complements can
be dropped.

Octets
A group of eight adjacent 1s.
It eliminates three variables and their
complements.

Overlapping Groups
When you encircle groups, you are
allowed to use the same 1 more than
once.
Always overlap groups when possible
to get the largest groups you can.

Rolling the Map
Group the 1s just like by imagining rolling
the map so that the left side touches the
right side or the upper touches the lower
side.
Draw half-circles around each group.

Redundant Groups
A group whose 1s are completely
overlapping by other groups.
The inner pair in (a) are completely
overlapped by the outside pairs, and can
be eliminated to get the simpler map as
shown in (b).

Dont-Care Conditions
Represented by x in the truth table, its
because they can be treated as 0s or 1s,
whichever leads to a simpler circuit.
In K-map, treat xs as 1s and try to form
the largest groups to include with the real
1s.
The remaining xs will be treated as 0s


Combinational Circuit
A combinational circuit consists of logic gates whose outputs at any time are
determined directly from the present combination of inputs without regard to
previous inputs. A combinational circuit performs a specific information-
processing operation fully specified logically by a set of Boolean function.


Combinational Circuit
Consists of input variables, logic gates and
output variables.
The logic gates accept signals from the
inputs and generate signals to the outputs. inputs and generate signals to the
outputs.

Design Procedure
The design of combinational circuits starts from the
verbal outline of the problem and ends in a logic circuit
diagram or a set of Boolean functions from which the
logic diagram can be easily obtained. The procedure
involves the following steps: involves the following steps:
1. The problem is stated.
2. The number of available input variables and required output variables
is determined.
3. The input and output variables are assigned letter symbols.
4. The truth table that defines the required relationships between inputs
and output is derived.
5. The simplified Boolean function for each output is obtained.
6. The logic diagram is drawn.

Arithmetic
Arithmetic circuits are the ones which
perform arithmetic operations like addition,
subtraction, multiplication, division, parity
calculation. calculation.

Adders
Adders are the basic building blocks of all
arithmetic circuits; adders add two binary
numbers and give out sum and carry as
output. Basically we have two types of output. Basically we have two types
of
adders.
Half Adder.
Full Adder.

Half Adder
Use a combinational circuit that performs
addition on two bits
Boolean Equation: SUM= X XOR Y
CARRY = XY CARRY = XY

Truth Table

X Y SUM CARRY
0 0 0 0
0 1 1 0
1 0 1 0
1 1 0 1











Full-Adders
Uses a combinational circuit that performs
the addition on three bits.
It consists of three inputs and two outputs.
Boolean Equation: Boolean Equation:
SUM= A XOR B XOR C
CARRY= AB + AC + BC

Truth Table
X Y Z SUM CARRY
0 0 0 0 0
0 0 1 1 0
0 1 0 1 0
0 1 0 1 0
0 1 1 0 1
1 0 0 1 0
1 0 1 0 1
1 1 0 0 1
1 1 1 1 1


























4-bit Carry Ripple Adder
Adds two 4-bit numbers: X = X3 X2 X1 X0, Y = Y3 Y2 Y1 Y0
producing the sum S = S3 S2 S1 S0 , C-out = C4 from the most
significant position j=3



BCD Adder
BCD addition is the same as binary addition with
a bit of variation: whenever a sum is greater than
1001, it is not a valid BCD number, so we add
0110 to it, to do the correction. This will produce
a carry, which is added to the next BCD position. a carry, which is added to
the next BCD position.
Add the two 4-bit BCD code inputs.
Determine if the sum of this addition is greater than
1001; if yes, then add 0110 to this sum and generate
a carry to the next decimal position.
















Subtracters
Subtracter circuits take two binary
numbers as input and subtract one binary
number input from the other binary
number input. Similar to adders, it gives number input. Similar to adders, it
gives
out two outputs, difference and borrow
(carry-in the case of Adder). There are two
types of subtracters.

Half-Subtracters
A combinational circuit that performs subtraction on two
bits and produces their difference.
Boolean Equation:
Difference= AB + AB = A XOR B
Borrow= AB
where Difference is an output where Difference is an output
variable that holds the difference.
Borrow a variable that holds the binary
signal that informs the next stage that 1 has been
borrowed.
A- minuend bit
B- subtrahend

Truth Table and K-map
X Y Borrow Difference
0 0 0 0
0 1 1 1
1 0 0 1
1 1 0 0















Block and Logic Diagram




Full Subtracter
A full subtracter is a combinational circuit that performs
subtraction involving three bits, namely minuend, subtrahend,
and borrow-in. The logic symbol and truth table are shown
below.
Truth Table
X Y Bin Diff Bout
0 0 0 0 0
0 0 1 1 1
0 1 0 1 1
0 1 1 0 1
1 0 0 1 0
1 0 1 0 0
1 1 0 0 0
1 1 1 1 1





































Analysis of a Combinational Circuit
The analysis of a combinational circuit
starts with the given logic diagram and
culminates with the set of Boolean
functions, or truth table, or a verbal functions, or truth table, or a verbal
explanation of the circuit operation.
To obtain the output Boolean functions
from a logic diagram, proceed as follows:

Label with arbitrary symbols all gate outputs that are
a function of the input variables. Obtain the Boolean
functions for each gate.
Label with other arbitrary symbols those gates which
are a function of input variables and / or previously
labeled gates. Find the Boolean functions for these labeled gates. Find the
Boolean functions for these
gates.
Repeat the process outlined in step 2 until the outputs
of the circuit are labeled.
By repeated substitution of previously defined
functions, obtain the output Boolean functions in
terms on input variables only.


MSI and PLD Components

Parallel Binary Subtracter
Parallel binary subtracter can be implemented
by cascading several full-subtracters.
Implementation and associated problems are
those of a parallel binary adder, seen before in
parallel binary adder section. parallel binary adder section.
The next slide is the block level representation of
a 4-bit parallel binary subtracter, which subtracts
4-bit Y3Y2Y1Y0 from 4-bit X3X2X1X0. It has 4-
bit difference output D3D2D1D0 with borrow
output Bout.

Block diagram of a 4-bit parallel
binary subtracter
















Serial Binary Subtracter
A serial subtracter can be obtained by
converting the serial adder using the 2's
complement system. The subtrahend is
stored in the Y register and must be 2's
complemented before it is added to the complemented before it is added to
the
minuend stored in the X register.
The circuit for a 4-bit serial subtracter
using full-adder is shown in the figure
below.




Decoders
A decoder is a combinational circuit that converts binary
information from n input lines to a maximum of 2n unique
output lines. If the n bit decoded information has unused
or dont care combinations, the decoder output will have
fewer than 2n outputs.
A decoder is a multipleinput, multipleoutput logic circuit
that converts coded inputs into coded outputs, where the
A decoder is a multipleinput, multipleoutput logic circuit
that converts coded inputs into coded outputs, where the
input and output codes are different; e.g. nto2n, BCD
decoders.
Decoding is necessary in applications such as data
multiplexing, 7 segment display and memory address
decoding. Figure below shows the pseudo block of a
decoder.

Basic Binary Decoder
And AND gate can be used as the basic decoding
element, because its output is HIGH only when all its
inputs are HIGH. For example, if the input binary
number is 0110, then, to make all the inputs to the
AND gate HIGH, the two outer bits must be inverted AND gate HIGH, the
two outer bits must be inverted
using two inverters as shown in figure below.



Binary n-to-2n Decoders
A binary decoder has n inputs and 2n
outputs. Only one output is active at any
one time, corresponding to the input value.
Figure below shows a representation of
Binary nto2n
decoder Binary nto2n
decoder



Example - 2-to-4 Binary Decoder
A 2 to 4 decoder consists of two inputs and
four outputs, truth table and symbols of which
is shown below.
X Y F0 F1 F2 F3
0 0 1 0 0 0
0 1 0 1 0 0
1 0 0 0 1 0
1 1 0 0 0 1
Truth Table


3-to-8 Binary Decoder
A 3 to 8 decoder consists of three inputs and
eight outputs, truth table and symbols of which is
shown below.
Truth Table
X Y Z F0 F1 F2 F3 F4 F5 F6 F7
0 0 0 1 0 0 0 0 0 0 0
0 0 1 0 1 0 0 0 0 0 0
0 1 0 0 0 1 0 0 0 0 0
0 1 1 0 0 0 1 0 0 0 0
1 0 0 0 0 0 0 1 0 0 0
1 0 1 0 0 0 0 0 1 0 0
1 1 0 0 0 0 0 0 0 1 0
1 1 1 0 0 0 0 0 0 0 1





Implementing Functions Using
Decoders
Any nvariable logic function, in canonical sumof
minterms form can be implemented using a single nto
2n decoder to generate the minterms, and an OR gate to
form the sum.
The output lines of the decoder corresponding to the minterms of
the function are used as inputs to the or gate. the function are used as inputs
to the or gate.
Any combinational circuit with n inputs and m outputs
can be implemented with an nto2n
decoder with m OR
gates.
Suitable when a circuit has many outputs, and each
output function is expressed with few minterms.


















Encoders
An encoder is a combinational circuit that
performs the inverse operation of a decoder. If a
device output code has fewer bits than the input
code has, the device is usually called an
encoder. e.g. 2nton, priority encoders. encoder. e.g. 2nton, priority
encoders.
The simplest encoder is a 2nton binary
encoder, where it has only one of 2n inputs = 1
and the output is the nbit binary number
corresponding to the active input.


Example - Octal-to-Binary
Encoder
OctaltoBinary take 8 inputs and provides
3 outputs, thus doing the opposite of what
the 3to8 decoder does. At any one time,
only one input line has a value of 1. The only one input line has a value of 1.
The
figure below shows the truth table of an
Octaltobinary encoder.

Truth Table
I0 I1 I2 I3 I4 I5 I6 I7 Y2 Y1 Y0
1 0 0 0 0 0 0 0 0 0 0
0 1 0 0 0 0 0 0 0 0 1
0 0 1 0 0 0 0 0 0 1 0
0 0 1 0 0 0 0 0 0 1 0
0 0 0 1 0 0 0 0 0 1 1
0 0 0 0 1 0 0 0 1 0 0
0 0 0 0 0 1 0 0 1 0 1
0 0 0 0 0 0 1 0 1 1 0
0 0 0 0 0 0 0 1 1 1 1

































DecimaltoBinary take
10 inputs and provides
4 outputs, thus doing
the opposite of what
the 4to10 decoder
does. At any one time, does. At any one time,
only one input line has
a value of 1. The figure
on the right shows the
truth table of a
Decimaltobinary
encoder.

I0 I1 I2 I3 I4 I5 I6 I7 I8 I9 Y3 Y2 Y1 Y0
1 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 0 0 0 0 0 0 0 0 0 0 0 1
0 0 1 0 0 0 0 0 0 0 0 0 1 0
0 0 0 1 0 0 0 0 0 0 0 0 1 1
0 0 0 1 0 0 0 0 0 0 0 0 1 1
0 0 0 0 1 0 0 0 0 0 0 1 0 0
0 0 0 0 0 1 0 0 0 0 0 1 0 1
0 0 0 0 0 0 1 0 0 0 0 1 1 0
0 0 0 0 0 0 0 1 0 0 0 1 1 1
0 0 0 0 0 0 0 0 1 0 1 0 0 0
0 0 0 0 0 0 0 0 0 1 1 0 0 1


From the above truth table , we can derive
the functions Y3, Y2, Y1 and Y0 as given
below.
Y3 = I8 + I9 Y3 = I8 + I9
Y2 = I4 + I5 + I6 + I7
Y1 = I2 + I3 + I6 + I7
Y0 = I1 + I3 + I5 + I7 + I9

Priority Encoder
If we look carefully at the Encoder circuits that we got,
we see the following limitations. If more than two inputs
are active simultaneously, the output is unpredictable or
rather it is not what we expect it to be.
This ambiguity is resolved if priority is established so that
only one input is encoded, no matter how many inputs only one input is
encoded, no matter how many inputs
are active at a given point of time.
The priority encoder includes a priority function. The
operation of the priority encoder is such that if two or
more inputs are active at the same time, the input having
the highest priority will take precedence.

Example 4 to 3 Priority
Encoder
The truth table of a 4input priority encoder is as
shown below. The input D3 has the highest
priority, D2 has next highest priority, D0 has the
lowest priority. This means output Y2 and Y1 are
0 only when none of the inputs D1, D2, D3 are 0 only when none of the
inputs D1, D2, D3 are
high and only D0 is high.
A 4 to 3 encoder consists of four inputs and
three outputs, truth table and symbols of which
is shown below.

Truth Table
D3 D2 D1 D0 Y2 Y1 Y0
0 0 0 0 0 0 0
0 0 0 1 0 0 1
0 0 1 x 0 1 0
0 0 1 x 0 1 0
0 1 x x 0 1 1
1 x x x 1 0 0


Multiplexer
Digital multiplexer is a combinational
circuit that selects binary information from
one of many input lines and directs it to a
single output line. The selection of a
particular input line is controlled by a set of particular input line is controlled
by a set of
selection lines.
The block diagram of MUX with n data
sources of b bits wide and s bits wide
select line is shown in below figure.

Larger Multiplexers
Larger multiplexers can be constructed
from smaller ones. An 8to1 multiplexer
can be constructed from smaller
multiplexers as shown below. multiplexers as shown below.

You might also like