Download presentation
Presentation is loading. Please wait.
1
Digital Logic Circuits
Winter 2012 COMP 2130 Intro Computer Systems Computing Science Thompson Rivers University
2
Digitial Logic Circuits
Course Contents Part I – Review Mumber Systems Boolean Logic Digital Logic Circuits Part II – C Programming Language Part III – Introduction to Computer Systems Not the replacement of IPv6; Inter-transition mechanism; But if IPv6 would fail TRU-COMP2130 Digitial Logic Circuits
3
Unit Learning Objectives
Find a Boolean expression corresponding to circuit. Find a circuit corresponding to a Boolean expression. Find a Boolean expression corresponding to an i/o table. Create an i/o table corresponding to given requirements. Design AND, OR, and NOT gates using NOR gates. Understand how multiplexers and decoders work. TRU-COMP2130 Digitial Logic Circuits
4
Digitial Logic Circuits
Unit Contents Gates Input/Output Table for a Circuit Boolean Expression Corresponding to a Circuit Circuit Corresponding to a Boolean Expression Finding a Circuit Corresponding to a Given Input/Output Table Simplifying Combinational Circuits NAND and NOR Gates Combinatorial Circuits Sequential Circuits TRU-COMP2130 Digitial Logic Circuits
5
Digitial Logic Circuits
Analogy between the operations of switching devices and the operations of logical connectives P Q Switches in series P Q P Q 1 ? P Q Switches in parallel P Q P Q 1 ? TRU-COMP2130 Digitial Logic Circuits
6
Digitial Logic Circuits
Gates AND (conjunction) OR (disjuction) NOT (negation) TRU-COMP2130 Digitial Logic Circuits
7
Input/Output Table for a Circuit
P = 1 an Q = 0, then R = ??? I/O table ??? P = 0, Q = 1, and R = 1. Then S = ??? I/O table ??? TRU-COMP2130 Digitial Logic Circuits
8
Digitial Logic Circuits
I/O tables for circuits??? TRU-COMP2130 Digitial Logic Circuits
9
Boolean Expression for a Circuit
TRU-COMP2130 Digitial Logic Circuits
10
Circuit Corresponding to a Boolean Expression
(~P Q) ~Q ((P Q) (R S)) T TRU-COMP2130 Digitial Logic Circuits
11
Finding a Circuit Corresponding to a Given I/O Table
How to find a circuit that corresponds to the above I/O table? Input Output P Q R S 1 TRU-COMP2130 Digitial Logic Circuits
12
Digitial Logic Circuits
Input Output P Q R S 1 For the 1st, the 2nd and the 3rd rows, P Q R P ~Q R P ~Q ~R Then ??? TRU-COMP2130 Digitial Logic Circuits
13
Digitial Logic Circuits
For the 1st, the 2nd and the 3rd rows, P Q R P ~Q R P ~Q ~R All the other cases will produce 0. Therefore, S = (P Q R) (P ~Q R) (P ~Q ~R) This is a disjunction of conjunctions (called disjunctive normal form). This boolean expression might be simplified by using equivalences. How to find a circuit that corresponds to the above boolean expression? = (P R Q) (P R ~Q) (P ~Q ~R) = ((P R) (Q ~Q )) (P ~Q ~R) = ((P R) T) (P ~Q ~R) = (P R) (P ~Q ~R) = P (R (~Q ~R)) = P (R ~Q) TRU-COMP1380 Digitial Logic Circuits
14
Digitial Logic Circuits
1 bit full adder = ??? S = (P Q Cin) (P ~Q ~Cin) (~P Q ~ Cin) (~P ~Q Cin) Cout = ... Corresponding circuit ??? Input Output P Q Cin S Cout 1 TRU-COMP2130 Digitial Logic Circuits
15
Digitial Logic Circuits
2-to-1 multiplexer When C = 0; A is selected, and when C = 1, B is selected. Corresponding i/o table? S = ??? A B C S Input Output A B C S 1 TRU-COMP1380 Digitial Logic Circuits
16
Simplifying Combinational Circuits
Any good idea? Convert to a boolean expression, and then Simplify the boolean expression by using equivalences R = ((P ~Q) (P Q)) Q = ... by distributive law = ... TRU-COMP2130 Digitial Logic Circuits
17
Digitial Logic Circuits
NAND and NOR Gates AND and NAND gates NAND = NOT (AND) OR and NOR gates NOR = NOT (OR) TRU-COMP2130 Digitial Logic Circuits
18
NOT AND OR XOR NAND NOR TRU-COMP2130 Digital Logic
19
Can you make NAND, NOR and XOR, by using AND, OR and NOT?
A B = (~A B) + (A ~B) Can you make AND by using OR and NOT? (Using DeMorgan’s Law) A B = ~(~A + ~B) Can you make OR by using AND and NOT? A + B = ~(~A ~B) TRU-COMP2130 Digital Logic
20
Can you make AND, OR and NOT, by using NOR?
~A = A NOR A A + B = (A NOR B) NOR (A NOR B) A B = (A NOR A) NOR (B NOR B) Can you make AND, OR and NOT, by using NAND? Digital circuits can be, and frequently are, implemented solely with NOR gates or solely with NAND gates. TRU-COMP2130 Digital Logic
21
Combinational Circuits
A combinational circuit is an interconnected set of gates whose output at any time is a function only of the input at that time. E.g., a boolean function of three variables? F(A,B,C) = ~A B ~C + ~A B C + A B ~C = (A+B+C)(A+B+~C)(~A+B+C)(~A+B+~C)(~A+~B+~C) The second form is easier to implement. TRU-COMP2130 Digital Logic
22
Multiplexer (E.g., to control signal and data routing)
Two + four inputs, one output 0 0 => value from input D0 is selected from D0, D1, D2, D3 0 1 => value from input D1 is selected 1 0 => value from input D2 is selected 1 1 => value from input D3 is selected Decoder (E.g., address decoding) Two inputs, four outputs 0 0 => output D0 selected 0 1 => output D1 selected 1 0 => output D2 selected 1 1 => output D3 selected TRU-COMP2130 Digital Logic
23
TRU-COMP2130 Digital Logic
24
Adder A B Cin S Cout 1 ... 1 bit full adder 4 bit adder TRU-COMP2130
1 ... Adder 1 bit full adder 4 bit adder TRU-COMP2130 Digital Logic
25
Sequential Circuits Combinational circuits implement the essential functions of a digital computer. However, they provide no memory or state information. The current output of a sequential circuit depends not only on the current input but also on the past history of inputs TRU-COMP2130 Digital Logic
26
Flip-flop Register Counter ... The simplest form of sequential circuit
The S-R latch: 1 bit memory > Q = 1 > Q = 0 > no change Register Counter ... TRU-COMP2130 Digital Logic
27
Programmable Logic Devices
TRU-COMP2130 Digital Logic
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.