Unit 4 All
Unit 4 All
Syllabus Unit IV
Sequential Logic:
• Introduction: Sequential Circuits. Difference between combinational
circuits and sequential circuits
• Flip- flop: SR, JK, D, T; Preset & Clear, Master and Slave Flip Flops
their truth tables and excitation tables, Conversion from one type to
another type of Flip Flop.
• Application of Flip-flops: Bounce Elimination Switch, registers,
counters.
• Registers: Buffer register; shift register;
• Counters: Asynchronous counter. Synchronous counter, ring
counters, BCD Counter, Johnson Counter, Modulus of the counter
(IC 7490), Pseudo Random Binary Sequence Generator, Sequence
generator and detector
Books to Refer
Text Books:
Chapter 12 from
Chapter 13 from
Reference Book:
PR = Preset
CLR = Clear
CLK = Clock
J K Q Q’ Mode
0 0 Q Q’ Hold
1 0 1 0 Sets JK contains an internal
Active Low SR latch.
0 1 0 1 Resets
1 1 Q’ Q Toggle
Review: Truth Table for NAND
2 Inputs: 3 Inputs:
A B X A B C X
0 0 1 0 0 0 1
0 1 1 0 0 1 1
1 0 1 0 1 0 1
1 1 0 0 1 1 1
1 0 0 1
1 0 1 1
1 1 0 1
1 1 1 0
Mode of Operation: Hold
Hold: no change in Q.
J K Q Q’ Orig. Q Orig. Q’
0 0 0 1 0 1
Mode of Operation: Set
Set: Q = 1.
J K Q Q’ Orig. Q Orig. Q’
1 0 1 0 0 1
Mode of Operation: Reset
Reset: Q = 0.
J K Q Q’ Orig. Q Orig. Q’
0 1 0 1 1 0
Mode of Operation: Toggle
Toggle: Q = Q’.
J K Q Q’ Orig. Q Orig. Q’
1 1 1 0 0 1
Mode of Operation: Toggle again
Toggle: Q = Q’.
J K Q Q’ Orig. Q Orig. Q’
1 1 0 1 1 0
Overview: During a time period
Characteristic Equation
Q J K Q(t + 1)
0 0 0 0
0 0 1 0
0 1 0 1
0 1 1 1
1 0 0 1
1 0 1 0
1 1 0 1 Characteristic Equation:
1 1 1 0
Q(t+1) = J.Q’+ K’.Q
If only one slide to remember…
Characteristic Equation:
J K Q Q’ Mode
0 0 Q Q’ Hold SR Latch:
1 0 1 0 Sets
A ‘0’ at the set or the
0 1 0 1 Resets
reset will either set or
1 1 Q’ Q Toggle reset the value of Q.
Race Around Condition
Master Slave Flip Flop
Input Output waveform of Mater Slave flip flop
D-Type Flip Flop
• If we use only middle two rows of the truth table
of S-R or J-K Flip flop, we obtain D- tyoe of Flip
flop
J K Q
0 0 Q
1 0 1
0 1 0
1 1 Q’
D Q
0 0
1 1
T Type Flip Flop
• In J K Flip Flop , if J=K, the resulting Flip flop is
referred to as a T- type Flip Flop.
P J K Q
r
0 0 Q
1 0 1
0 1 0
1 1 Q’
Clk
D Q
0 Q
1 Q’
Cr
Preset & Clear
• When the power is switched on the state of the
circuit is uncertain.(i.e. 0 or 1)
• In many application it is desired to initially set
or reset the Flip Flop to initial state.
• This is accomplished by using direct or
asynchronous inputs referred to as preset(Pr)
and clear(Cr) inputs.
• These inputs may be applied at any time
between clock pulses and are not in synchronism
with
SR flip-flop with Preset & Clear
Preset(Pr)
Clk Cr Pr Q
CLK
1 1 1 Qn+1 Normal FF
0 0 1 0 Clear
0 1 0 1 Preset
Clear (Cr)
S R Qn+1 S R Qn Qn+1
0 0 Qn 0 0 0 0
0 1 0 0 0 1 1
1 0 1
0 1 0 0
1 1 ?
0 1 1 0
SR excitation table 1 0 0 1
1 0 1 1
Qn Qn+1 S R
1 1 0 ?
0 0 0 X
1 1 1 ?
0 1 1 0
1 0 0 1
1 1 X 0
J K Flip Flop
JK truth table Next state table
J K Qn+1
J K Qn Qn+1
0 0 Qn
0 1 0 0 0 0 0
1 0 1 0 0 1 1
1 1 Qn’ 0 1 0 0
0 1 1 0
JK excitation table 1 0 0 1
1 0 1 1
Qn Qn+1 J K
1 1 0 1
0 0 0 X
1 1 1 0
0 1 1 X
1 0 X 1
1 1 X 0
D Flip Flop
D truth table Next state table
D Qn+1 D Qn Qn+1
0 0 0 0 0
1 1 0 1 0
1 0 1
1 1 1
D excitation table
Qn Qn+1 D
0 0 0
0 1 1
1 0 0
1 1 1
T Flip Flop
T truth table Next state table
T Qn+1 T Qn Qn+1
0 Qn 0 0 0
1 Qn’ 0 1 1
1 0 1
1 1 0
T excitation table
Qn Qn+1 T
0 0 0
0 1 1
1 0 1
1 1 0
Conversion from one Flip Flop to Another
Conversion of Flip Flops
• SR to JK
• SR to D
• SR to T
• JK to D
• JK to T
• D to T
• T to D
• JK to SR
• T to SR
• D to JK
T Flip-Flop to D Flip-Flop
Input Present Next State Flip- Flop
State input
D Qn Qn+1 T
0 0 0 0
0 1 0 1
1 0 1 1
1 1 1 0
1 1 0
T = D Q’ + D’ Q
D
D’
T
D Flip Flop to JK Flip Flop
Input Input Present Next Flip
State State Flop
input
J K Qn Qn+1 D
0 0 0 0 0
0 0 1 1 1
0 1 0 0 0
0 1 1 0 0
1 0 0 1 1
1 0 1 1 1
1 1 0 1 1
1 1 1 0 0
D Flip-flop to JK Flip Flop
Q
0 1 Q 0 1
JK
JK D Q+
0 0 1 0 0 1
0 0 0 0 0 0 0 0
01 1 0 01 1 0 1 1
11 1 1 11 1 1
10 10
D = J Q’ + K’ Q
Q
J
D
K
Q’
T Flip Flop to JK Flip Flop
Excitation Table of T FF
Inpu Inpu Prese Next Flip
t t nt State Flop
State input Qn Qn+1 T
J K Qn Qn+1 T 0 0 0
0 0 0 0 0 0 1 1
0 0 1 1 0 1 0 1
0 1 0 0 0 1 1 0
0 1 1 0 1
1 0 0 1 1
1 0 1 1 0
1 1 0 1 1
1 1 1 0 1
T Flip-flop to JK Flip Flop
Q Q+
Q 0 1
0 1 JK Q+
JK
JK
T Q+
0 0 0 0 0 0
0 Q
0 0 1 0 0 1 0
0 0 Q
01 1 1 01 1 1 01
1 1 Q’
11 1 0 11 1 0 10
Q’
10 10 11
T = J Q’ + K Q
Q
J
T
K
Q’
JK Flip Flop to T Flip Flop
Input Present Next State Flip Flop Flip Flop
State Input Input
T Qn Qn+1 JA KA
0 0 0 0 X
0 1 1 X 0
1 0 1 1 X
1 1 0 X 1
Qn Qn+1 J K
0 0 0 X
0 1 1 X
1 0 X 1
1 1 X 0
Implement T Flip-flop by JK Flip-flop
Q
T 0 1 Q J K
Q+
0 0 1 0 0 X
1 1 0 0 1 X
01 X 1
10 X 0
11
Q Q
T 0 1 T 0 1
0 X 0 X 0
0
1 1 X 1 X 1
J=T K=T
Sequential Logic:
• Shift Register
i. Serial In Serial Out (SISO)
ii. Serial In Parallel Out (SIPO)
iii. Parallel In Serial Out (PISO)
iv. Parallel In Parallel Out (PIPO)
v. Bidirectional Shift Register
vi. Universal Shift Register
Buffer Register
• D Q • D Q • D Q
• Q • Q • Q
10110
10110
10110
Regis
ters
D Q D Q D Q
Q Q Q
Regis
Input D Q D Q D Q Output
Q Q Q
Regis
Input D Q D Q D Q
Q Q Q
Regis
PISO Flip-Flop Shift Register ters
1.62
D Q D Q
D Q
Q Q
Q
Regis
D Q D Q D Q
Q Q Q
• Types of Counter
1. Synchronous Counter
2. Asynchronous Counter
Differences
Asynchronous Counter Synchronous Counter
• Output of the first flip flop • No connection between output
drives the clock for the next of first flip flop and clock input
flip flop. of the next flip flop.
• All the flip flops are not • All the flip flops are clocked
clocked simultaneously. simultaneously.
• Logic circuit is very simple. • Logic circuit is complex.
• These counters are slow • These counters are fast.
because of propagation delay.
Ripple/Asynchronous Counter
4 Bit asynchronous down counter
Asynchronous Up/ Down Counter
Truth Table
Input Input Input Outp
ut
Y=Q’ for down
M Q Q’ Y counting
0 0 0 0
0 0 1 1
Y=Q for up counting
0 for1 0 0
0 1 1 1
1 K0
Map Equation0for Y=M’Q’+MQ
0
1 0
UP/DOWN’ = Y1 0
1 1 0 1
1 1 1 1
3 bit Synchronous Up/Down Counter
Counter has 8 states i.e N=8
2n >= N
n = no. of Flip Flop= 3
Control Input for Flip-flop
input M QC QB QA QC+1 QB+1 QA+1 J C KC J B KB J A KA
0 0 0 0 0 0 1 0 X 0 X 1 X
0 0 0 1 0 1 0 0 X 1 X X 1
0 0 1 0 0 1 1 0 X X 0 1 X
0 0 1 1 1 0 0 1 X X 1 X 1
0 1 0 0 1 0 1 X 0 0 X 1 X
0 1 0 1 1 1 0 X 0 1 X X 1
0 1 1 0 1 1 1 X 0 X 0 1 X
0 1 1 1 0 0 0 X 1 X 1 X 1
1 1 1 1 1 1 0 X 0 1 X 1 X
1 1 1 0 1 0 1 X 0 X 0 X 1
1 1 0 1 1 0 0 X 0 X 1 1 X
1 1 0 0 0 1 1 X 1 0 X X 1
1 0 1 1 0 1 0 0 X 1 X 1 X
1 0 1 0 0 0 1 0 X X 0 X 1
1 0 0 1 0 0 0 0 X X 1 1 X
1 0 0 0 1 1 1 1 X 1 X X 1
Logical diagram of 3 bit Synchronous Counter
Decade Binary Counter/Modulo N counter
• IC 7490 is a decade binary counter
Internal Diagram of IC 7490
Function table 7490
0 0 0 0 0 0
1 0 0 0 1 0
2 0 0 1 0 0
3 0 0 1 1 0
4 0 1 0 0 0
5 0 1 0 1 0
6 0 1 1 0 1
7 0 1 1 1 1
8 1 0 0 0 1
9 1 0 0 1 1
Design MOD 6 counter using IC 7490.
Logical Diagram for Mod 6 Counter
Divide by 20 counters using IC 7490
• Logical Method :-
7490(1) 7490(2)
Logical Diagram for Mod 20 counter
Ring Counter
• A ring counter takes the serial output of the last Flip-Flop of
a shift register and provides it to the serial input of the first
Flip-Flop.
Timing Sequence of 4 bit Ring Counter
Johnson Counter / Twisting Ring / Switch
Tail Counter