SlideShare a Scribd company logo
1 of 37
Functions of Combinational
Logic
• Basic Adders
– Important in computers and many types of
digital systems to process numerical data
– Basic adder operations are fundamental to
the study of digital systems

IS 151 Digital Circuitry

1
The Half Adder
• Basic rules of binary addition
–0+0=0
–0+1=1
–1+0=1
– 1 + 1 = 10

• A half-adder accepts 2 binary digits on its
inputs and produces two binary digits on
its outputs – a sum bit and a carry bit
IS 151 Digital Circuitry

2
The Half Adder
• Logic symbol for the half-adder

• Truth table for the half adder
A

B

Cout

Sum

0

0

0

0

0

1

0

1

1

0

0

1

1

1

1

0
IS 151 Digital Circuitry

3
The Half Adder
• Derive expressions for the Sum and Cout
as functions of inputs A and B
• From the truth table:
– Cout is a 1 only when both A and B are 1s:
Cout = AB
– Sum is a 1 only if A and B are not equal:
Sum = A B

IS 151 Digital Circuitry

4
The Half Adder
• Half-adder logic diagram

IS 151 Digital Circuitry

5
The Full Adder
• Accepts 3 inputs including an input carry
and generates a sum output and an
output carry
• Difference between half and full-adder
– the full adder has three inputs (including an
input carry) while a half adder has only two
inputs (without the input carry)

IS 151 Digital Circuitry

6
The Full Adder
Logic symbol for a full adder

IS 151 Digital Circuitry

7
The Full Adder
• Full adder truth table
A

B

Cin

Cout

Sum

0

0

0

0

0

0

0

1

0

1

0

1

0

0

1

0

1

1

1

0

1

0

0

0

1

1

0

1

1

0

1

1

0

1

0

1

1

1

1

1

IS 151 Digital Circuitry

8
The Full Adder
• Derive expressions for the Sum and Cout
as functions of inputs A, B and Cin from the
truth table
• Alternatively, using knowledge from the
half adder:
– Sum = inputs exclusively-ORed
• Sum = (A

B) Cin

– Cout = inputs ANDed
• AB + (A B)Cin
IS 151 Digital Circuitry

9
The Full Adder
• From the truth table:
– Sum = A’B’C + A’BC’+ AB’C’ + ABC
–
= A’B’C + ABC + A’BC’ + AB’C’
–
= C(A’B’ + AB) + C’(A’B + AB’)
–
= C(AexB)’ + C’(AexB)
–
= CexAexB
–
= AexBexC

IS 151 Digital Circuitry

10
The Full Adder
• Also from the truth table:
– Carry out = A’BC + AB’C ABC’ + ABC
–
= C(A’B + AB’) + AB(C’ + C)
–
= C(AexB) + AB
–
= AB + (AexB)C

IS 151 Digital Circuitry

11
The Full Adder
• Logic circuit for full-adder

IS 151 Digital Circuitry

12
The Full Adder - Exercise
• Determine an alternative method for
implementing the full-adder
– Write SoP expressions from the truth table for
Sum and Cout
– Map the expressions on K-maps and write
simplified expressions if any
– Implement/draw the circuit diagram for the
full-adder

IS 151 Digital Circuitry

13
Parallel Binary Adders
• A single full adder is capable of adding two 1- bit
numbers and an input carry
• To add binary numbers with more than one bit,
additional full-adders must be used.
• Example, for a 2-bit number, 2 full adders are
used, 4-bit numbers, 4 full-adders are used, etc.
• The carry output of each adder is connected to
the carry input of the next higher-order adder

IS 151 Digital Circuitry

14
Parallel Binary Adders
• Block diagram of a basic 2-bit parallel
adder
General format, addition of
two 2-bit numbers

A2

B2

A1

B1

A

B Cin

A

B Cin

A2A1
+ B2B1
Σ3Σ2Σ1

Cout

(MSB) Σ3

Σ

Σ2

Cout

Σ

Σ1 (LSB)

IS 151 Digital Circuitry

15
Parallel Binary Adders
• Block diagram of a basic 4-bit parallel
adder
A4

B4

A3

B3

A2

B2

A1

B1

A

B Cin

A

B Cin

A

B Cin

A

B Cin

(MSB)

(LSB)

Cout

Σ

Cout

Σ

Cout

Σ

Cout

Σ

C4

Σ4

Σ3

IS 151 Digital Circuitry

Σ2

Σ1

16
Comparators
• Basic function – to compare the magnitudes
of two binary quantities to determine the
relationship of those quantities
• Comparators determine whether two
numbers are equal or not

IS 151 Digital Circuitry

17
Comparators
• Basic comparator operations
The input bits are equal

The input bits are not equal

The input bits are equal

IS 151 Digital Circuitry

18
Comparators
• To compare binary numbers containing 2
bits each, an additional Ex-OR gate is
required

IS 151 Digital Circuitry

19
Comparators
• The two LSBs of the two numbers are compared
by gate G1, and the MSBs are compared by gate
G2
– Binary number A = A1A0
– Binary number B = B1B0

• If the two numbers are equal, their
corresponding bits are the same, and the output
of each Ex-OR gate is a 0
• The 0s are inverted using the inverter, producing
1s
• The 1s are ANDed, producing a 1, which
indicates equality
IS 151 Digital Circuitry

20
Comparators
• If the corresponding sets of bits are not equal,
i.e. A0≠B0, or A1≠B1, a 1 occurs on that Ex-OR
gate output (G1 or G2)
• In order to produce a single output indicating an
equality or inequality of two numbers, two
inverters and an AND gate are used
• When the two inputs are not equal, a 1,0 or 0,1
appears on the inputs of the AND gate,
producing a 0, indicating inequality
IS 151 Digital Circuitry

21
Comparators - Examples
• Determine whether A and B are equal (or
not) by following the logic levels through
the circuit
– a) A0 = 1, B0 = 0 and A1 = 1, B1 = 0
– b) A0 = 1, B0 = 1 and A1 = 1, B1 = 0

IS 151 Digital Circuitry

22
4-bit Comparators
• To determine if two numbers are equal
• If not, determine which one is greater or
less than the other
• Numbers
– A = A3A2A1A0
– B = B3B2B1B0

IS 151 Digital Circuitry

23
4-bit Comparators
• Determine the inequality by examining
highest-order bit in each other
– If A3 = 1 and B3 = 0; A > B
– If A3 = 0 and B3 = 1; A < B
– If A3 = B3, examine the next lower bit position
for an inequality (i.e. A2 with B2)

IS 151 Digital Circuitry

24
4-bit Comparators
• The three observations are valid for each
bit position in the numbers
• Check for an inequality in a bit position,
starting with the highest order bits
• When such an inequality is found, the
relationship of the two numbers is
established, and any other inequalities in
lower-order bit positions are ignored
IS 151 Digital Circuitry

25
Comparators - Example
• Implement a circuit to compare the relationship
between A and B
A

B

A>B

A=B

A<B

0

0

0

1

0

0

1

0

0

1

1

0

1

0

0

1

1

0

1

For A > B (G): G = AB’
For A = B (E): E = A’B’ + AB
For A < B (L): L = A’B

0

IS 151 Digital Circuitry

26
Decoders
• Function – to detect the presence of a
specified combination of bits (code) on
inputs and to indicate the presence of that
code by a specified output level
• n-input lines (to handle n bits)
• 1 to 2n output lines to indicate the
presence of 1 or more n-bit combinations

IS 151 Digital Circuitry

27
Decoders
• Example: determine when a binary 1001 occurs on the
inputs of a digital circuit
• Use AND gate; make sure that all of the inputs to the AND
gate are HIGH when the binary number 1001 occurs

IS 151 Digital Circuitry

28
Decoders
• Exercise: develop the logic required to
detect the binary code 10010 and produce
an active-LOW output (0)

IS 151 Digital Circuitry

29
Decoders - Application
• BCD-to-Decimal decoder
– Converts each BCD code into one of 10 possible decimal
digits
Decimal
Digit

BCD Code
A3 A2 A1 A0

BCD Decoding Function

0

0

0

0

0

A3’ A2’ A1’ A0’

1

0

0

0

1

2

0

0

1

0

3

0

0

1

1

4

0

1

0

0

5

0

1

0

1

6

0

1

1

0

7

0

1

1

1

8

1

0

0

0

9

1

0

0

1

IS 151 Digital Circuitry

30
Encoders
• A combinational logic circuit that performs
a reverse decoder function
• Accepts an active level on one of its inputs
(e.g. a decimal or octal digit) and converts
it to a coded output, e.g. BCD or binary

IS 151 Digital Circuitry

31
Encoders
• The Decimal-to-BCD Encoder (10-line-to-4-line encoder)
– Ten inputs (one for each decimal digit)
– Four outputs corresponding to the BCD code
• Logic symbol for a decimal-to-BCD encoder

Decimal
Input

DEC/BCD
0
1
2
3
1
4
2
5
4
6
8
7
8
9

BCD
Output

IS 151 Digital Circuitry

32
Encoders
• From the BCD/Decimal table, determine
the relationship between each BCD bit and
the decimal digits in order to analyse the
logic.
– Example
–
–
–
–

A3 = 8 + 9
A2 = 4 + 5 + 6 + 7
A1 = 2 + 3 + 6 + 7
A0 = 1 + 3 + 5 + 7 + 9

IS 151 Digital Circuitry

33
Encoders
• Example: if input line 9 is HIGH (assume
all others are LOW), it will produce a HIGH
on A3 and A0, and a LOW on A1and A2 –
which is 1001, meaning decimal 9.

IS 151 Digital Circuitry

34
Encoders - Exercise
• Implement the
logic circuit for the
10-line-to-4-line
encoder using the
logic expressions
for the BCD
codes A3 to A0
and inputs 0 to 9

IS 151 Digital Circuitry

35
Logic Functions Exercise
(Lab 3)
• Design and test a circuit to implement the
function of the full adder (refer to lecture)

IS 151 Digital Circuitry

36
• End of Lecture

IS 151 Digital Circuitry

37

More Related Content

What's hot

Arm organization and implementation
Arm organization and implementationArm organization and implementation
Arm organization and implementationShubham Singh
 
Floating point arithmetic operations (1)
Floating point arithmetic operations (1)Floating point arithmetic operations (1)
Floating point arithmetic operations (1)cs19club
 
Computer architecture register transfer languages rtl
Computer architecture register transfer languages rtlComputer architecture register transfer languages rtl
Computer architecture register transfer languages rtlMazin Alwaaly
 
Computer architecture
Computer architectureComputer architecture
Computer architectureZuhaib Zaroon
 
Microprocessor fundamentals
Microprocessor fundamentalsMicroprocessor fundamentals
Microprocessor fundamentalsJLoknathDora
 
Mod 10 synchronous counter updated
Mod 10 synchronous counter updatedMod 10 synchronous counter updated
Mod 10 synchronous counter updatedDANISHAMIN950
 
Interrupt of 8085
Interrupt of 8085Interrupt of 8085
Interrupt of 8085Nitin Ahire
 
Control Unit Design
Control Unit DesignControl Unit Design
Control Unit DesignVinit Raut
 
Types of system
Types of system Types of system
Types of system mihir jain
 
multiplexers and demultiplexers
 multiplexers and demultiplexers multiplexers and demultiplexers
multiplexers and demultiplexersUnsa Shakir
 
Pipeline hazard
Pipeline hazardPipeline hazard
Pipeline hazardAJAL A J
 
Unit 2 processor&amp;memory-organisation
Unit 2 processor&amp;memory-organisationUnit 2 processor&amp;memory-organisation
Unit 2 processor&amp;memory-organisationPavithra S
 
Quine Mc Clusky (Tabular) method
Quine Mc Clusky (Tabular) methodQuine Mc Clusky (Tabular) method
Quine Mc Clusky (Tabular) methodSyed Saeed
 
Datapath Design of Computer Architecture
Datapath Design of Computer ArchitectureDatapath Design of Computer Architecture
Datapath Design of Computer ArchitectureAbu Zaman
 
Logic Gates
Logic GatesLogic Gates
Logic Gatesstudent
 
Digital Electronics - Counters
Digital Electronics - CountersDigital Electronics - Counters
Digital Electronics - CountersJayakrishnan J
 

What's hot (20)

Arm organization and implementation
Arm organization and implementationArm organization and implementation
Arm organization and implementation
 
Floating point arithmetic operations (1)
Floating point arithmetic operations (1)Floating point arithmetic operations (1)
Floating point arithmetic operations (1)
 
Computer architecture register transfer languages rtl
Computer architecture register transfer languages rtlComputer architecture register transfer languages rtl
Computer architecture register transfer languages rtl
 
Computer architecture
Computer architectureComputer architecture
Computer architecture
 
Microprocessor fundamentals
Microprocessor fundamentalsMicroprocessor fundamentals
Microprocessor fundamentals
 
Mod 10 synchronous counter updated
Mod 10 synchronous counter updatedMod 10 synchronous counter updated
Mod 10 synchronous counter updated
 
Unit I.fundamental of Programmable DSP
Unit I.fundamental of Programmable DSPUnit I.fundamental of Programmable DSP
Unit I.fundamental of Programmable DSP
 
Interrupt of 8085
Interrupt of 8085Interrupt of 8085
Interrupt of 8085
 
Control Unit Design
Control Unit DesignControl Unit Design
Control Unit Design
 
Types of system
Types of system Types of system
Types of system
 
multiplexers and demultiplexers
 multiplexers and demultiplexers multiplexers and demultiplexers
multiplexers and demultiplexers
 
Pipeline hazard
Pipeline hazardPipeline hazard
Pipeline hazard
 
Meley & moore
Meley & mooreMeley & moore
Meley & moore
 
Sequential circuits
Sequential circuitsSequential circuits
Sequential circuits
 
Unit 2 processor&amp;memory-organisation
Unit 2 processor&amp;memory-organisationUnit 2 processor&amp;memory-organisation
Unit 2 processor&amp;memory-organisation
 
Quine Mc Clusky (Tabular) method
Quine Mc Clusky (Tabular) methodQuine Mc Clusky (Tabular) method
Quine Mc Clusky (Tabular) method
 
Datapath Design of Computer Architecture
Datapath Design of Computer ArchitectureDatapath Design of Computer Architecture
Datapath Design of Computer Architecture
 
Fulll Adder
Fulll AdderFulll Adder
Fulll Adder
 
Logic Gates
Logic GatesLogic Gates
Logic Gates
 
Digital Electronics - Counters
Digital Electronics - CountersDigital Electronics - Counters
Digital Electronics - Counters
 

Viewers also liked

IS 151 Lecture 2
IS 151 Lecture 2IS 151 Lecture 2
IS 151 Lecture 2wajanga
 
IS 151 Lecture 11
IS 151 Lecture 11IS 151 Lecture 11
IS 151 Lecture 11wajanga
 
02 combinational logic
02 combinational logic02 combinational logic
02 combinational logicZainab Noor
 
Comparison among Different Adders
Comparison among Different Adders Comparison among Different Adders
Comparison among Different Adders iosrjce
 
3Sem-Logic Design Notes-Unit4-Design and Analysis of Combinational Logic
 3Sem-Logic Design Notes-Unit4-Design and Analysis of Combinational Logic 3Sem-Logic Design Notes-Unit4-Design and Analysis of Combinational Logic
3Sem-Logic Design Notes-Unit4-Design and Analysis of Combinational LogicDr. Shivananda Koteshwar
 
Copy of 7.digital basicsa
Copy of 7.digital basicsaCopy of 7.digital basicsa
Copy of 7.digital basicsaChethan Nt
 
9.sequential+circuits part+1
9.sequential+circuits part+1 9.sequential+circuits part+1
9.sequential+circuits part+1 liran1018
 
IS 151 - Lecture 3
IS 151 - Lecture 3IS 151 - Lecture 3
IS 151 - Lecture 3wajanga
 
Lecture11 combinational logic dynamics
Lecture11 combinational logic dynamicsLecture11 combinational logic dynamics
Lecture11 combinational logic dynamicsvidhya DS
 
different logic full adders
different logic full addersdifferent logic full adders
different logic full addersGuna Sekhar
 
Pass Transistor Logic
Pass Transistor LogicPass Transistor Logic
Pass Transistor LogicDiwaker Pant
 
CMOS Topic 6 -_designing_combinational_logic_circuits
CMOS Topic 6 -_designing_combinational_logic_circuitsCMOS Topic 6 -_designing_combinational_logic_circuits
CMOS Topic 6 -_designing_combinational_logic_circuitsIkhwan_Fakrudin
 
Introduction to VLSI
Introduction to VLSI Introduction to VLSI
Introduction to VLSI illpa
 

Viewers also liked (16)

IS 151 Lecture 2
IS 151 Lecture 2IS 151 Lecture 2
IS 151 Lecture 2
 
IS 151 Lecture 11
IS 151 Lecture 11IS 151 Lecture 11
IS 151 Lecture 11
 
02 combinational logic
02 combinational logic02 combinational logic
02 combinational logic
 
Comparison among Different Adders
Comparison among Different Adders Comparison among Different Adders
Comparison among Different Adders
 
vlsi
vlsivlsi
vlsi
 
3Sem-Logic Design Notes-Unit4-Design and Analysis of Combinational Logic
 3Sem-Logic Design Notes-Unit4-Design and Analysis of Combinational Logic 3Sem-Logic Design Notes-Unit4-Design and Analysis of Combinational Logic
3Sem-Logic Design Notes-Unit4-Design and Analysis of Combinational Logic
 
Copy of 7.digital basicsa
Copy of 7.digital basicsaCopy of 7.digital basicsa
Copy of 7.digital basicsa
 
9.sequential+circuits part+1
9.sequential+circuits part+1 9.sequential+circuits part+1
9.sequential+circuits part+1
 
IS 151 - Lecture 3
IS 151 - Lecture 3IS 151 - Lecture 3
IS 151 - Lecture 3
 
Lecture11 combinational logic dynamics
Lecture11 combinational logic dynamicsLecture11 combinational logic dynamics
Lecture11 combinational logic dynamics
 
different logic full adders
different logic full addersdifferent logic full adders
different logic full adders
 
Pass Transistor Logic
Pass Transistor LogicPass Transistor Logic
Pass Transistor Logic
 
Analog vlsi
Analog vlsiAnalog vlsi
Analog vlsi
 
CMOS Topic 6 -_designing_combinational_logic_circuits
CMOS Topic 6 -_designing_combinational_logic_circuitsCMOS Topic 6 -_designing_combinational_logic_circuits
CMOS Topic 6 -_designing_combinational_logic_circuits
 
Introduction to VLSI
Introduction to VLSI Introduction to VLSI
Introduction to VLSI
 
Pass transistor logic
Pass transistor logicPass transistor logic
Pass transistor logic
 

Similar to IS 151 Lecture 9

FYBSC IT Digital Electronics Unit III Chapter II Arithmetic Circuits
FYBSC IT Digital Electronics Unit III Chapter II Arithmetic CircuitsFYBSC IT Digital Electronics Unit III Chapter II Arithmetic Circuits
FYBSC IT Digital Electronics Unit III Chapter II Arithmetic CircuitsArti Parab Academics
 
18CSC203J_COA_Unit 2 final.pptx
18CSC203J_COA_Unit 2 final.pptx18CSC203J_COA_Unit 2 final.pptx
18CSC203J_COA_Unit 2 final.pptxtakix43466
 
Comparators_and_Code_Convertersv.pptx.ppt
Comparators_and_Code_Convertersv.pptx.pptComparators_and_Code_Convertersv.pptx.ppt
Comparators_and_Code_Convertersv.pptx.pptHardikGupta400524
 
DLD Lecture No 20 Look Ahead Carry Generator, Binary Subtractors and BCD Add...
DLD Lecture No 20 Look Ahead Carry Generator, Binary Subtractors and  BCD Add...DLD Lecture No 20 Look Ahead Carry Generator, Binary Subtractors and  BCD Add...
DLD Lecture No 20 Look Ahead Carry Generator, Binary Subtractors and BCD Add...SaveraAyub2
 
Chapter 5: Cominational Logic with MSI and LSI
Chapter 5: Cominational Logic with MSI and LSIChapter 5: Cominational Logic with MSI and LSI
Chapter 5: Cominational Logic with MSI and LSIEr. Nawaraj Bhandari
 
DLD Lecture No 19 Binary adders.pptx
DLD Lecture No 19  Binary adders.pptxDLD Lecture No 19  Binary adders.pptx
DLD Lecture No 19 Binary adders.pptxSaveraAyub2
 
combinational-circuit (1).ppt
combinational-circuit (1).pptcombinational-circuit (1).ppt
combinational-circuit (1).pptThanmayiKumar
 
Arithmetic Microoperation.pdf
Arithmetic Microoperation.pdfArithmetic Microoperation.pdf
Arithmetic Microoperation.pdfHarshitJ4
 
I semester Unit 4 combinational circuits.pptx
I semester Unit 4 combinational circuits.pptxI semester Unit 4 combinational circuits.pptx
I semester Unit 4 combinational circuits.pptxMayank Pandey
 
Lecture6 Chapter4- Design Magnitude Comparator Circuit, Introduction to Decod...
Lecture6 Chapter4- Design Magnitude Comparator Circuit, Introduction to Decod...Lecture6 Chapter4- Design Magnitude Comparator Circuit, Introduction to Decod...
Lecture6 Chapter4- Design Magnitude Comparator Circuit, Introduction to Decod...UmerKhan147799
 
Digital Electronics (EC8392) UNIT-II -PPT-S.SESHA VIDHYA/ ASP/ECE
Digital Electronics (EC8392) UNIT-II -PPT-S.SESHA VIDHYA/ ASP/ECEDigital Electronics (EC8392) UNIT-II -PPT-S.SESHA VIDHYA/ ASP/ECE
Digital Electronics (EC8392) UNIT-II -PPT-S.SESHA VIDHYA/ ASP/ECESeshaVidhyaS
 
Combinational and sequential logic
Combinational and sequential logicCombinational and sequential logic
Combinational and sequential logicDeepak John
 
Unit 4 combinational circuit
Unit 4 combinational circuitUnit 4 combinational circuit
Unit 4 combinational circuitKalai Selvi
 

Similar to IS 151 Lecture 9 (20)

Digital Logic Design
Digital Logic Design Digital Logic Design
Digital Logic Design
 
FYBSC IT Digital Electronics Unit III Chapter II Arithmetic Circuits
FYBSC IT Digital Electronics Unit III Chapter II Arithmetic CircuitsFYBSC IT Digital Electronics Unit III Chapter II Arithmetic Circuits
FYBSC IT Digital Electronics Unit III Chapter II Arithmetic Circuits
 
18CSC203J_COA_Unit 2 final.pptx
18CSC203J_COA_Unit 2 final.pptx18CSC203J_COA_Unit 2 final.pptx
18CSC203J_COA_Unit 2 final.pptx
 
Comparators_and_Code_Convertersv.pptx.ppt
Comparators_and_Code_Convertersv.pptx.pptComparators_and_Code_Convertersv.pptx.ppt
Comparators_and_Code_Convertersv.pptx.ppt
 
DLD Lecture No 20 Look Ahead Carry Generator, Binary Subtractors and BCD Add...
DLD Lecture No 20 Look Ahead Carry Generator, Binary Subtractors and  BCD Add...DLD Lecture No 20 Look Ahead Carry Generator, Binary Subtractors and  BCD Add...
DLD Lecture No 20 Look Ahead Carry Generator, Binary Subtractors and BCD Add...
 
Chapter 5: Cominational Logic with MSI and LSI
Chapter 5: Cominational Logic with MSI and LSIChapter 5: Cominational Logic with MSI and LSI
Chapter 5: Cominational Logic with MSI and LSI
 
combinational-circuit (1).ppt
combinational-circuit (1).pptcombinational-circuit (1).ppt
combinational-circuit (1).ppt
 
DLD Chapter-4.pdf
DLD Chapter-4.pdfDLD Chapter-4.pdf
DLD Chapter-4.pdf
 
DLD Lecture No 19 Binary adders.pptx
DLD Lecture No 19  Binary adders.pptxDLD Lecture No 19  Binary adders.pptx
DLD Lecture No 19 Binary adders.pptx
 
combinational-circuit (1).ppt
combinational-circuit (1).pptcombinational-circuit (1).ppt
combinational-circuit (1).ppt
 
Arithmetic Microoperation.pdf
Arithmetic Microoperation.pdfArithmetic Microoperation.pdf
Arithmetic Microoperation.pdf
 
I semester Unit 4 combinational circuits.pptx
I semester Unit 4 combinational circuits.pptxI semester Unit 4 combinational circuits.pptx
I semester Unit 4 combinational circuits.pptx
 
Lecture6 Chapter4- Design Magnitude Comparator Circuit, Introduction to Decod...
Lecture6 Chapter4- Design Magnitude Comparator Circuit, Introduction to Decod...Lecture6 Chapter4- Design Magnitude Comparator Circuit, Introduction to Decod...
Lecture6 Chapter4- Design Magnitude Comparator Circuit, Introduction to Decod...
 
Combinational circuit
Combinational circuitCombinational circuit
Combinational circuit
 
Digital Electronics (EC8392) UNIT-II -PPT-S.SESHA VIDHYA/ ASP/ECE
Digital Electronics (EC8392) UNIT-II -PPT-S.SESHA VIDHYA/ ASP/ECEDigital Electronics (EC8392) UNIT-II -PPT-S.SESHA VIDHYA/ ASP/ECE
Digital Electronics (EC8392) UNIT-II -PPT-S.SESHA VIDHYA/ ASP/ECE
 
COA(Unit_3.pptx)
COA(Unit_3.pptx)COA(Unit_3.pptx)
COA(Unit_3.pptx)
 
Combinational and sequential logic
Combinational and sequential logicCombinational and sequential logic
Combinational and sequential logic
 
Unit 4 combinational circuit
Unit 4 combinational circuitUnit 4 combinational circuit
Unit 4 combinational circuit
 
Logic gates
Logic gatesLogic gates
Logic gates
 
UNIT-3 Complete PPT.pptx
UNIT-3 Complete PPT.pptxUNIT-3 Complete PPT.pptx
UNIT-3 Complete PPT.pptx
 

More from wajanga

IS 151 Lecture 3
IS 151 Lecture 3IS 151 Lecture 3
IS 151 Lecture 3wajanga
 
IS 151 Lecture 1
IS 151 Lecture 1IS 151 Lecture 1
IS 151 Lecture 1wajanga
 
IS 151 Outline 2014
IS 151 Outline 2014IS 151 Outline 2014
IS 151 Outline 2014wajanga
 
IS 139 Assignment 3
IS 139 Assignment 3IS 139 Assignment 3
IS 139 Assignment 3wajanga
 
IS 139 Lecture 7
IS 139 Lecture 7IS 139 Lecture 7
IS 139 Lecture 7wajanga
 
IS 139 Lecture 6
IS 139 Lecture 6IS 139 Lecture 6
IS 139 Lecture 6wajanga
 
IS 139 Assignment 2
IS 139 Assignment 2IS 139 Assignment 2
IS 139 Assignment 2wajanga
 
IS 139 Lecture 5
IS 139 Lecture 5IS 139 Lecture 5
IS 139 Lecture 5wajanga
 
IS 139 Lecture 4
IS 139 Lecture 4IS 139 Lecture 4
IS 139 Lecture 4wajanga
 
IS 139 Assignment 1
IS 139 Assignment 1IS 139 Assignment 1
IS 139 Assignment 1wajanga
 
IS 139 Lecture 3
IS 139 Lecture 3IS 139 Lecture 3
IS 139 Lecture 3wajanga
 
IS 139 Lecture 1
IS 139 Lecture 1IS 139 Lecture 1
IS 139 Lecture 1wajanga
 
IS 139 Lecture 2
IS 139 Lecture 2IS 139 Lecture 2
IS 139 Lecture 2wajanga
 
IS 151 Lecture 10
IS 151 Lecture 10IS 151 Lecture 10
IS 151 Lecture 10wajanga
 
IS 151 Lecture 8
IS 151 Lecture 8IS 151 Lecture 8
IS 151 Lecture 8wajanga
 
IS 151 Lecture 7
IS 151 Lecture 7IS 151 Lecture 7
IS 151 Lecture 7wajanga
 
IS 151 Lecture 6
IS 151 Lecture 6IS 151 Lecture 6
IS 151 Lecture 6wajanga
 
IS 151 Lecture 6
IS 151 Lecture 6IS 151 Lecture 6
IS 151 Lecture 6wajanga
 
IS 151 Lecture 5
IS 151 Lecture 5IS 151 Lecture 5
IS 151 Lecture 5wajanga
 
IS 151 lecture 4
IS 151   lecture 4IS 151   lecture 4
IS 151 lecture 4wajanga
 

More from wajanga (20)

IS 151 Lecture 3
IS 151 Lecture 3IS 151 Lecture 3
IS 151 Lecture 3
 
IS 151 Lecture 1
IS 151 Lecture 1IS 151 Lecture 1
IS 151 Lecture 1
 
IS 151 Outline 2014
IS 151 Outline 2014IS 151 Outline 2014
IS 151 Outline 2014
 
IS 139 Assignment 3
IS 139 Assignment 3IS 139 Assignment 3
IS 139 Assignment 3
 
IS 139 Lecture 7
IS 139 Lecture 7IS 139 Lecture 7
IS 139 Lecture 7
 
IS 139 Lecture 6
IS 139 Lecture 6IS 139 Lecture 6
IS 139 Lecture 6
 
IS 139 Assignment 2
IS 139 Assignment 2IS 139 Assignment 2
IS 139 Assignment 2
 
IS 139 Lecture 5
IS 139 Lecture 5IS 139 Lecture 5
IS 139 Lecture 5
 
IS 139 Lecture 4
IS 139 Lecture 4IS 139 Lecture 4
IS 139 Lecture 4
 
IS 139 Assignment 1
IS 139 Assignment 1IS 139 Assignment 1
IS 139 Assignment 1
 
IS 139 Lecture 3
IS 139 Lecture 3IS 139 Lecture 3
IS 139 Lecture 3
 
IS 139 Lecture 1
IS 139 Lecture 1IS 139 Lecture 1
IS 139 Lecture 1
 
IS 139 Lecture 2
IS 139 Lecture 2IS 139 Lecture 2
IS 139 Lecture 2
 
IS 151 Lecture 10
IS 151 Lecture 10IS 151 Lecture 10
IS 151 Lecture 10
 
IS 151 Lecture 8
IS 151 Lecture 8IS 151 Lecture 8
IS 151 Lecture 8
 
IS 151 Lecture 7
IS 151 Lecture 7IS 151 Lecture 7
IS 151 Lecture 7
 
IS 151 Lecture 6
IS 151 Lecture 6IS 151 Lecture 6
IS 151 Lecture 6
 
IS 151 Lecture 6
IS 151 Lecture 6IS 151 Lecture 6
IS 151 Lecture 6
 
IS 151 Lecture 5
IS 151 Lecture 5IS 151 Lecture 5
IS 151 Lecture 5
 
IS 151 lecture 4
IS 151   lecture 4IS 151   lecture 4
IS 151 lecture 4
 

Recently uploaded

Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slidevu2urc
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsRoshan Dwivedi
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxKatpro Technologies
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024The Digital Insurer
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Enterprise Knowledge
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 

Recently uploaded (20)

Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 

IS 151 Lecture 9

  • 1. Functions of Combinational Logic • Basic Adders – Important in computers and many types of digital systems to process numerical data – Basic adder operations are fundamental to the study of digital systems IS 151 Digital Circuitry 1
  • 2. The Half Adder • Basic rules of binary addition –0+0=0 –0+1=1 –1+0=1 – 1 + 1 = 10 • A half-adder accepts 2 binary digits on its inputs and produces two binary digits on its outputs – a sum bit and a carry bit IS 151 Digital Circuitry 2
  • 3. The Half Adder • Logic symbol for the half-adder • Truth table for the half adder A B Cout Sum 0 0 0 0 0 1 0 1 1 0 0 1 1 1 1 0 IS 151 Digital Circuitry 3
  • 4. The Half Adder • Derive expressions for the Sum and Cout as functions of inputs A and B • From the truth table: – Cout is a 1 only when both A and B are 1s: Cout = AB – Sum is a 1 only if A and B are not equal: Sum = A B IS 151 Digital Circuitry 4
  • 5. The Half Adder • Half-adder logic diagram IS 151 Digital Circuitry 5
  • 6. The Full Adder • Accepts 3 inputs including an input carry and generates a sum output and an output carry • Difference between half and full-adder – the full adder has three inputs (including an input carry) while a half adder has only two inputs (without the input carry) IS 151 Digital Circuitry 6
  • 7. The Full Adder Logic symbol for a full adder IS 151 Digital Circuitry 7
  • 8. The Full Adder • Full adder truth table A B Cin Cout Sum 0 0 0 0 0 0 0 1 0 1 0 1 0 0 1 0 1 1 1 0 1 0 0 0 1 1 0 1 1 0 1 1 0 1 0 1 1 1 1 1 IS 151 Digital Circuitry 8
  • 9. The Full Adder • Derive expressions for the Sum and Cout as functions of inputs A, B and Cin from the truth table • Alternatively, using knowledge from the half adder: – Sum = inputs exclusively-ORed • Sum = (A B) Cin – Cout = inputs ANDed • AB + (A B)Cin IS 151 Digital Circuitry 9
  • 10. The Full Adder • From the truth table: – Sum = A’B’C + A’BC’+ AB’C’ + ABC – = A’B’C + ABC + A’BC’ + AB’C’ – = C(A’B’ + AB) + C’(A’B + AB’) – = C(AexB)’ + C’(AexB) – = CexAexB – = AexBexC IS 151 Digital Circuitry 10
  • 11. The Full Adder • Also from the truth table: – Carry out = A’BC + AB’C ABC’ + ABC – = C(A’B + AB’) + AB(C’ + C) – = C(AexB) + AB – = AB + (AexB)C IS 151 Digital Circuitry 11
  • 12. The Full Adder • Logic circuit for full-adder IS 151 Digital Circuitry 12
  • 13. The Full Adder - Exercise • Determine an alternative method for implementing the full-adder – Write SoP expressions from the truth table for Sum and Cout – Map the expressions on K-maps and write simplified expressions if any – Implement/draw the circuit diagram for the full-adder IS 151 Digital Circuitry 13
  • 14. Parallel Binary Adders • A single full adder is capable of adding two 1- bit numbers and an input carry • To add binary numbers with more than one bit, additional full-adders must be used. • Example, for a 2-bit number, 2 full adders are used, 4-bit numbers, 4 full-adders are used, etc. • The carry output of each adder is connected to the carry input of the next higher-order adder IS 151 Digital Circuitry 14
  • 15. Parallel Binary Adders • Block diagram of a basic 2-bit parallel adder General format, addition of two 2-bit numbers A2 B2 A1 B1 A B Cin A B Cin A2A1 + B2B1 Σ3Σ2Σ1 Cout (MSB) Σ3 Σ Σ2 Cout Σ Σ1 (LSB) IS 151 Digital Circuitry 15
  • 16. Parallel Binary Adders • Block diagram of a basic 4-bit parallel adder A4 B4 A3 B3 A2 B2 A1 B1 A B Cin A B Cin A B Cin A B Cin (MSB) (LSB) Cout Σ Cout Σ Cout Σ Cout Σ C4 Σ4 Σ3 IS 151 Digital Circuitry Σ2 Σ1 16
  • 17. Comparators • Basic function – to compare the magnitudes of two binary quantities to determine the relationship of those quantities • Comparators determine whether two numbers are equal or not IS 151 Digital Circuitry 17
  • 18. Comparators • Basic comparator operations The input bits are equal The input bits are not equal The input bits are equal IS 151 Digital Circuitry 18
  • 19. Comparators • To compare binary numbers containing 2 bits each, an additional Ex-OR gate is required IS 151 Digital Circuitry 19
  • 20. Comparators • The two LSBs of the two numbers are compared by gate G1, and the MSBs are compared by gate G2 – Binary number A = A1A0 – Binary number B = B1B0 • If the two numbers are equal, their corresponding bits are the same, and the output of each Ex-OR gate is a 0 • The 0s are inverted using the inverter, producing 1s • The 1s are ANDed, producing a 1, which indicates equality IS 151 Digital Circuitry 20
  • 21. Comparators • If the corresponding sets of bits are not equal, i.e. A0≠B0, or A1≠B1, a 1 occurs on that Ex-OR gate output (G1 or G2) • In order to produce a single output indicating an equality or inequality of two numbers, two inverters and an AND gate are used • When the two inputs are not equal, a 1,0 or 0,1 appears on the inputs of the AND gate, producing a 0, indicating inequality IS 151 Digital Circuitry 21
  • 22. Comparators - Examples • Determine whether A and B are equal (or not) by following the logic levels through the circuit – a) A0 = 1, B0 = 0 and A1 = 1, B1 = 0 – b) A0 = 1, B0 = 1 and A1 = 1, B1 = 0 IS 151 Digital Circuitry 22
  • 23. 4-bit Comparators • To determine if two numbers are equal • If not, determine which one is greater or less than the other • Numbers – A = A3A2A1A0 – B = B3B2B1B0 IS 151 Digital Circuitry 23
  • 24. 4-bit Comparators • Determine the inequality by examining highest-order bit in each other – If A3 = 1 and B3 = 0; A > B – If A3 = 0 and B3 = 1; A < B – If A3 = B3, examine the next lower bit position for an inequality (i.e. A2 with B2) IS 151 Digital Circuitry 24
  • 25. 4-bit Comparators • The three observations are valid for each bit position in the numbers • Check for an inequality in a bit position, starting with the highest order bits • When such an inequality is found, the relationship of the two numbers is established, and any other inequalities in lower-order bit positions are ignored IS 151 Digital Circuitry 25
  • 26. Comparators - Example • Implement a circuit to compare the relationship between A and B A B A>B A=B A<B 0 0 0 1 0 0 1 0 0 1 1 0 1 0 0 1 1 0 1 For A > B (G): G = AB’ For A = B (E): E = A’B’ + AB For A < B (L): L = A’B 0 IS 151 Digital Circuitry 26
  • 27. Decoders • Function – to detect the presence of a specified combination of bits (code) on inputs and to indicate the presence of that code by a specified output level • n-input lines (to handle n bits) • 1 to 2n output lines to indicate the presence of 1 or more n-bit combinations IS 151 Digital Circuitry 27
  • 28. Decoders • Example: determine when a binary 1001 occurs on the inputs of a digital circuit • Use AND gate; make sure that all of the inputs to the AND gate are HIGH when the binary number 1001 occurs IS 151 Digital Circuitry 28
  • 29. Decoders • Exercise: develop the logic required to detect the binary code 10010 and produce an active-LOW output (0) IS 151 Digital Circuitry 29
  • 30. Decoders - Application • BCD-to-Decimal decoder – Converts each BCD code into one of 10 possible decimal digits Decimal Digit BCD Code A3 A2 A1 A0 BCD Decoding Function 0 0 0 0 0 A3’ A2’ A1’ A0’ 1 0 0 0 1 2 0 0 1 0 3 0 0 1 1 4 0 1 0 0 5 0 1 0 1 6 0 1 1 0 7 0 1 1 1 8 1 0 0 0 9 1 0 0 1 IS 151 Digital Circuitry 30
  • 31. Encoders • A combinational logic circuit that performs a reverse decoder function • Accepts an active level on one of its inputs (e.g. a decimal or octal digit) and converts it to a coded output, e.g. BCD or binary IS 151 Digital Circuitry 31
  • 32. Encoders • The Decimal-to-BCD Encoder (10-line-to-4-line encoder) – Ten inputs (one for each decimal digit) – Four outputs corresponding to the BCD code • Logic symbol for a decimal-to-BCD encoder Decimal Input DEC/BCD 0 1 2 3 1 4 2 5 4 6 8 7 8 9 BCD Output IS 151 Digital Circuitry 32
  • 33. Encoders • From the BCD/Decimal table, determine the relationship between each BCD bit and the decimal digits in order to analyse the logic. – Example – – – – A3 = 8 + 9 A2 = 4 + 5 + 6 + 7 A1 = 2 + 3 + 6 + 7 A0 = 1 + 3 + 5 + 7 + 9 IS 151 Digital Circuitry 33
  • 34. Encoders • Example: if input line 9 is HIGH (assume all others are LOW), it will produce a HIGH on A3 and A0, and a LOW on A1and A2 – which is 1001, meaning decimal 9. IS 151 Digital Circuitry 34
  • 35. Encoders - Exercise • Implement the logic circuit for the 10-line-to-4-line encoder using the logic expressions for the BCD codes A3 to A0 and inputs 0 to 9 IS 151 Digital Circuitry 35
  • 36. Logic Functions Exercise (Lab 3) • Design and test a circuit to implement the function of the full adder (refer to lecture) IS 151 Digital Circuitry 36
  • 37. • End of Lecture IS 151 Digital Circuitry 37