Like this presentation? Why not share!

# Chap 3

## on Feb 22, 2012

• 3,640 views

### Views

Total Views
3,640
Views on SlideShare
3,640
Embed Views
0

Likes
1
144
0

No embeds

### Report content

• Comment goes here.
Are you sure you want to
• Look over examples 3-11 – 3-13, 3-17, 3-18
• Explain using TT with opposite polarity don’t cared.
• NAND AND NOR

## Chap 3Presentation Transcript

• Lecture No. 3
• Computer Logic Design
• Logic Gates
• Logic Gates
• Logic Gates
• Basic building blocks of the digital circuits
• Control flow of information
• Represent Logical Operations (Functions)
• Fundamental Gates
• AND, OR, NOT
• Characteristics
• Operation of the gate (what it does)
• Function/truth table
• Timing diagram
• Application example
• AND Gate
• AND Gate
• Standard logical symbol (ANSI/IEEE Standard 91-1984)
• Where F is the output and A,B,C……,N are the inputs of the gate
• Performs logical multiplication
• The output is HIGH only when all the inputs are HIGH
• AND Gate
• The logical operation of a gate can be expressed with a table that lists all input combinations with the corresponding outputs, known as truth table
• Truth table for a two input AND gate
Input Output A B F 0 0 0 0 1 0 1 0 0 1 1 1
• AND Gate
• Timing Diagram - a graph that accurately displays the relationship of two or more waveforms with respect to each other on a time basis
• Graphical representation of AND gate operation
• AND Gate
• Application example of AND gate
• Device (Stop-watch) enable/disable switch
• When the input B is set to HIGH (enabled), the clock signal is applied to the counter
• OR Gate
• Standard logical symbol
• The output is HIGH when one or more inputs are HIGH
• OR Gate
• Truth table for a two input OR gate
Input Output A B F 0 0 0 0 1 1 1 0 1 1 1 1
• OR Gate
• Timing diagram of the OR-Gate
• OR Gate
• OR gate application example
• Car door alarm system
• When all the doors are closed, 0000 is applied to the input of the OR gate
• When one or more doors are open, the output of OR gate is 1, which activates the alarm
• NOT Gate
• The standard logical symbol
• Performs the inversion or complementation
• Changes one logic level to the opposite logic level
• The bubble shows the negation
• NOT Gate
• Truth table for a NOT Gate
Input Output A F 0 1 1 0
• NOT Gate
• Timing diagram of NOT-Gate
• NOT Gate
• NOT gate application example
• 1’s complement
• NAND Gate
• Contraction of NOT-AND
• Standard logic symbol
• Output is LOW only when all inputs are HIGH
• Bubble indicates ACTIVE LOW output
• Output level is opposite to that of the AND gate
E
• NAND Gate
• The truth table for a two input NAND gate
Input Middle Output Output A B E F 0 0 0 1 0 1 0 1 1 0 0 1 1 1 1 0
• NAND Gate
• Timing diagram of NAND gate
• NAND Gate
• NAND gate application example
• Device Failure Alarm System
• When all the fans are working, the input to the NAND gate is 111 and the output is 0
• If any one of the fan stops working, the output of the NAND gate becomes 1, which activates the alarm
• NAND Gate as Negative-OR
• The truth table for a two input NAND gate looks awfully similar to an OR gate with the inputs inverted.
Input NAND Output A B F 0 0 1 0 1 1 1 0 1 1 1 0 Input OR Output A B F 1 1 1 1 0 1 0 1 1 0 0 0
• NAND Gate as Negative-OR Bubble signifies ACTIVE LOW INPUT
• NAND Gate as a Universal Gate
• NAND gate can be used to perform all the fundamental gate operations (NOT, AND, OR)
• Universal NAND gate
• NAND as NOT Gate Join all the input pins of the NAND gate together Input Output A B F 0 0 1 0 1 1 1 0 1 1 1 0
• NAND as AND Gate
• Using NAND gate to perform the AND gate operation
• Remember NAND is NOT-AND. What if we inverse this one more level? NOT-(NOT-AND) = AND
• Accomplished by applying a NOT operation (implemented through NAND gate) to the output of the NAND gate
• NAND as OR Gate
• Using NAND gate to perform the OR gate operation
• Can we form NOR gate as well?
• NOR Gate
• Contraction of NOT-OR
• The standard logic symbol
• Produces a LOW output when one or more of its input is HIGH
• Bubble indicates ACTIVE LOW output
• The output logic is opposite to that of the OR gate
• NOR Gate
• Truth table for a two input NOR gate
Input Output A B F 0 0 1 0 1 0 1 0 0 1 1 0
• NOR Gate
• Timing diagram of a NOR gate
• NOR Gate
• Application as Washing Machine Controller
• If the machine lid is open or the water in the tub is below certain level or the machine is overloaded (weight of water and clothes in the tub is above certain limit), the output of corresponding sensor is set to 1, producing a 0 at the NOR gate output that switches the machine off
• NOR Gate as Negative-AND
• The truth table for a two input NOR gate looks awfully similar to an AND gate with the inputs inverted.
Input NOR Output A B F 0 0 1 0 1 0 1 0 0 1 1 0 Input AND Output A B F 1 1 1 1 0 0 0 1 0 0 0 0
• NOR Gate as Negative-AND Bubble signifies ACTIVE LOW INPUT
• NOR Gate as a Universal Gate
• NOR gate can be used to perform all the fundamental gate operations (NOT, AND, OR)
• Universal NOR gate
• NOR as NOT Gate Join all the input pins of the NOR gate together Input Output A B F 0 0 1 0 1 0 1 0 0 1 1 0
• NOR as OR Gate
• Using NOR gate to perform the OR gate operation
• Remember NOR is NOT-OR. What if we inverse this one more level? NOT-(NOT-OR) = OR
• Accomplished by applying a NOT operation (implemented through NOR gate) to the output of the NOR gate
• NOR as AND Gate
• Using NOR gate to perform the AND gate operation
• Can we form NAND gate as well?
• Review
• The output of a logic gate is used to activate an alarm whenever at least one of its inputs is LOW. Name the gate?
• Name the following gate?
• Name the following gate?
• XOR Gate
• Exclusive OR (XOR for short)
• Standard logic symbol
• This gate has only two inputs
• Logical expression
• The output is HIGH only when the two the inputs are at opposite logic level
• XOR Gate
• The truth table for XOR Gate
Input Output A B F 0 0 0 0 1 1 1 0 1 1 1 0
• XOR Gate
• Timing diagram of XOR gate
• XOR Gate
• Application example of XOR gate
• Detecting odd parity
• Applying 0011 at the input A, B, C and D respectively generates 0 at the output of XOR gate 1, XOR gate 2 and XOR gate 3, indicating that number of 1s are not odd
• Applying 1011at the input generates a 1 at the output of XOR gate 3 indicating odd number of 1s
• XNOR Gate
• Exclusive-NOR (XNOR for short)
• Standard logic symbol
• This gate has only two inputs
• Logical expression
• The output is LOW only when the two inputs are at opposite logic level
• XNOR Gate
• Truth table for XNOR gate
Input Output A B F 0 0 1 0 1 0 1 0 0 1 1 1
• XNOR Gate
• Timing diagram of XNOR gate
• XNOR Gate
• Application example of XNOR gate
• Detecting even parity
• Applying 1011 at the input A, B, C and D respectively generates 1 at the output of XOR gate 1, a 0 at the output of XOR gate 2 and a 0 at the output of XNOR gate 3, indicating that the number of 1s in the input sequence are not even
• Applying 0011 generates 1 at the XNOR gate output, indicating even number of 1s
• Summary of logic gates
• Fundamental logic gates
• AND
• OR
• NOT
• Universal gates
• NAND
• NOR
• Other gates
• XOR
• XNOR
• Standard logic symbol
• Logical/Boolean expression
• Truth table
• Application example