Sequential circuit latchs and Flip-Flops.

msa29cse 144 views 77 slides May 06, 2024
Slide 1
Slide 1 of 77
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10
Slide 11
11
Slide 12
12
Slide 13
13
Slide 14
14
Slide 15
15
Slide 16
16
Slide 17
17
Slide 18
18
Slide 19
19
Slide 20
20
Slide 21
21
Slide 22
22
Slide 23
23
Slide 24
24
Slide 25
25
Slide 26
26
Slide 27
27
Slide 28
28
Slide 29
29
Slide 30
30
Slide 31
31
Slide 32
32
Slide 33
33
Slide 34
34
Slide 35
35
Slide 36
36
Slide 37
37
Slide 38
38
Slide 39
39
Slide 40
40
Slide 41
41
Slide 42
42
Slide 43
43
Slide 44
44
Slide 45
45
Slide 46
46
Slide 47
47
Slide 48
48
Slide 49
49
Slide 50
50
Slide 51
51
Slide 52
52
Slide 53
53
Slide 54
54
Slide 55
55
Slide 56
56
Slide 57
57
Slide 58
58
Slide 59
59
Slide 60
60
Slide 61
61
Slide 62
62
Slide 63
63
Slide 64
64
Slide 65
65
Slide 66
66
Slide 67
67
Slide 68
68
Slide 69
69
Slide 70
70
Slide 71
71
Slide 72
72
Slide 73
73
Slide 74
74
Slide 75
75
Slide 76
76
Slide 77
77

About This Presentation

This a presentation slide for sequential circuit latchs and flipflops


Slide Content

Sequential Circuit
Latches and Flip-Flops

Contents
►Sequential circuit
►Triggering of sequential circuit
►SR latch
►Gated SR latch
►J-K flip-flop
►D flip-flop
►T flip-flop
►Preset Clear JK flip-flop

Sequential Circuit
►Output depends on present input and past history of the system
►Temporary storage device and it has two stable state.
►Two type of sequential circuit :
a) Asynchronous : Output changes any time
b) Synchronous : Output changes with clock
►Level sensitive (Latch)
►Edge triggered (Flip-Flop)
Combinational
Circuit
Memory
Inputs Outputs
clock
Figure: Block diagram of a sequential circuit

Difference Between level
& Edge Triggering
►The state of a flip flop is switched by a momentary change in the input signal. This
momentary change is called trigger.
►There are two type of trigger possible. a)level Tigger b) edge trigger
0
1
0
1
Positive Level
Negative Level
Figure: Level trigger

►Two type of edge trigger.
a) positive edge
b) negative edge
►Positive edge means 0 to 1 transition
►Negative edge means 1 to 0 transition
►Can implement edge trigger by using capacitive coupling (RC circuit is inserted in clock) and
Master Slave flip-flop

Edge Triggering of Flip-Flops
0
1
Positive
Edge
Negative
Edge
0
1
Figure: Edge trigger
Negative
Edge
Positive
Edge

Observation of NOR Gate
A B Y
0 0 1
0 1 0
1 0 0
1 1 0
A
B
Y
Whenever an input is ‘1’ the output Y is ‘0’
Figure: NOR GATE
Truth Table of NOR Gate

Set-Reset(S-R) Latch (NOR)
S R Q
1 0 1(set)
Characteristics Table of SR Latch
Figure: S-R Latch
Let S=1, R=0
1
ABY
00 1
01 0
10 0
11 0
Truth Table of NOR gate
0
0
0
1
1

Set-Reset(S-R) Latch (NOR)
SR Q
1 0 1(set)
Characteristics Table of SR Latch
Figure: S-R Latch
Previously Q=1, Q’=0
0
ABY
00 1
01 0
10 0
11 0
Truth Table of NOR gate
0
0
0
1
1
0 01(hold)
0
1

Set-Reset(S-R) Latch (NOR)
SR Q
1 0 1(set)
Characteristics Table of SR Latch
Figure: S-R Latch
Previously Q=1, Q’=0
1
ABY
00 1
01 0
10 0
11 0
Truth Table of NOR gate
0
0
0
1
1
0 01(hold)
0
0
0 10(reset)
1

Set-Reset(S-R) Latch (NOR)
SR Q
10 1 (Set)
Characteristics Table of SR Latch
Figure: S-R Latch
Previously Q=0, Q’=1
0
ABY
00 1
01 0
10 0
11 0
Truth Table of NOR gate
1
1
0
0
0
00 1 (Hold)
01 0 (Reset)
00 0 (Hold)
0
1

Set-Reset(S-R) Latch (NOR)
SR Q
10 1 (Set)
Characteristics Table of SR Latch
Figure: S-R Latch
Previously Q=0, Q’=1
1
ABY
00 1
01 0
10 0
11 0
Truth Table of NOR gate
1
1
1
0
0
00 1 (Hold)
01 0 (Reset)
00 0 (Hold)
11 Invalid
0
0
0

Set-Reset(S-R) Latch (NOR)
SR Q
10 1 (Set)
Characteristics Table of SR Latch
00 (Hold)
01 0 (Reset)
11 Invalid
Block diagram of SR Latch
Q
R
S
time
time
time
Timing diagram of a SR LATCH

Gated Set-Reset(S-R) Latch (NOR)
0
0
0
ESR Q
010(Hold)
000 (Hold)
001 (Hold)
011(Hold)
1
R
S
ESR Q
110(SET)
100 (Hold)
101 (RESET)
111(INVALID)
ABY
00 0
01 0
10 0
11 1
Truth Table of AND gate
Characteristics Table
Gated S-R Latch

Characteristics of S-R Flip-Flop
Q(t)SRQ(t+1)
0 00
0 01
0 10
0 11
1 00
1 01
1 10
1 11
0 (Hold)
0 (reset)
1 (Set)
(Invalid)
1 (Hold)
0 (reset)
1 (Set)
(Invalid)
x 1
1 x 1
Q(t)
S
R 00 01 11 10
0


1
Characteristics equation:
Q(t+1)=S+ R’Q(t)
Characteristics Table:

SRQ
00Hold
010 (Reset)
101 (SET)
11Invalid
S-R Flip-Flop
Characteristics

Characteristics Table
Gated Set-Reset(S-R) Latch (NOR)
E
Gated S-R Latch
R
S
E
Q
time
time
time
time
Timing diagram of a Gated SR LATCH

J-K Flip-Flop

Figure: Logic Diagram of J-K Flip-Flop

•Modified version of S-R
Flip-Flop.

•Enable is replaced with
clock.

•Invalid Condition is
removed

JK Flip Flop
1
0
Q
0
Q
Q
1
0
1
Q
Q
Figure: Logic Diagram of J-K Flip-Flop

J-K Flip-Flop (SET condition)
let Q’=1
SRQ
00Hold
010 (Reset)
101 (SET)
11Invalid
1
0 0
1
Q = 1
0
1
1
0
Truth Table of SR Flip Flop
Figure: Logic Diagram of J-K Flip-Flop

J-K Flip-Flop (HOLD condition)
previously Q=1 Q’=0
0 0
1
0
0
1
0
1
0
0
0
SRQ
00Hold
010 (Reset)
101 (SET)
11Invalid
1
0
1
0
Truth Table of SR Flip Flop
Figure: Logic Diagram of J-K Flip-Flop

J-K Flip-Flop (RESET condition)
previously Q=1 Q’=0
0
1
1
0
1
0
1
0
0
0
SRQ
00Hold
010 (Reset)
101 (SET)
11Invalid
1
0
1
1
0
Truth Table of SR Flip Flop
Figure: Logic Diagram of J-K Flip-Flop

J-K Flip-Flop (Toggle condition)
previously Q=0 Q’=1
0
1
0
1
0
1
0
1
0
1
SRQ
00Hold
010 (Reset)
101 (SET)
11Invalid
0
1
1
1
0
Truth Table of SR Flip Flop
Figure: Logic Diagram of J-K Flip-Flop

Characteristics of J-K Flip-Flop
Q(t)JKQ(t+1)
0 00
0 01
0 10
0 11
1 00
1 01
1 10
1 11
0 (Hold)
0 (reset)
1 (Set)
1 (Toggle)
1 (Hold)
0 (reset)
1 (Set)
0 (Toggle)
1 1
1 1
Q(t)
J
K 00 01 11 10
0


1
Characteristics equation:
Q(t+1)=JK+ K’Q(t)
Characteristics Table:

JKQ
00Hold
010 (Reset)
101 (SET)
11Toggle
JK Flip Flop Characteristics

J-K Flip Flop
JK Q
10 (Set)
Characteristics table of J-K Flip Flop
00 (Hold)
01 (Reset)
11 Toggle
Block diagram of J-K Flip Flop
K
J
clk
Q
time
time
time
time
Timing diagram of a Gated JK Flip-Flop

D Flip-Flop
J
K
D
Figure: Logic Diagram of D Flip-Flop

D Flip-Flop
D
K




J
Q




Q
Block diagram of D Flip Flop
JK Q
10(Set)
Characteristics table
of J-K Flip-Flop
00 (Hold)
01 (Reset)
11Toggle
D Q
0 0
1 1
0
1
0
1 0
1
1
1
0
0 1
0
Characteristics table of D
Flip-Flop
J-K
Flip Flop
clk
N.B. INPUT AND OUTPUT SAME SO ACTS AS A BUFFER
CIRCUIT

Characteristics of D Flip Flop
Q(t)DQ(t+1)
0 0
0 1
1 0
1 1
0
1
0
1
1
1
Q(t)
D
0 1
0


1
Characteristics equation:
Q(t+1)=D
Characteristics Table:

DQ
00
11
D Flip Flop Characteristics

D Flip-Flop
D Q
0 0
1 1
Characteristics table of D Flip-Flop
D




Q




Q
Block diagram of D Flip Flop
D
Flip Flop
clk
D
clk
Q
time
time
time
Timing diagram of a Gated D Flip-Flop

T Flip-Flop
T
Figure: Logic Diagram of T Flip-Flop

T Flip-Flop
T
K




J
Q




Q
Block diagram of T Flip Flop
JK Q
10(Set)
Characteristics table
of J-K Flip-Flop
00 (Hold)
01 (Reset)
11Toggle
T Q
0HOLD
1 Toggle
1
1
Toggle
Characteristics table of T
Flip-Flop
J-K
Flip Flop
clk
1
0
0
0
Hold

Characteristics of T Flip Flop
Q(t)T Q(t+1)
0 0
0 1
1 0
1 1
0 (HOLD)
1
(TOGGLE)
1 (HOLD)
0
(TOGGLE)
1
1
Q(t)
T
0 1
0


1
Characteristics equation:
Q(t+1) = T Q(t)’ + T’ Q(t)
Characteristics Table:

T Q
0 HOLD
1 TOGGLE
D Flip Flop Characteristics

T Flip-Flop
T




Q




Q
Block diagram of T Flip Flop
T
Flip Flop
clk
time
time
T Q
0HOLD
1 Toggle
Characteristics table of T
Flip-Flop

The
End

Green University of Bangladesh
Department of Electrical & Electronic Engineering
Sequential Circuit

Triggering of Flip-flop
Combinational
Circuit
Memory
Clock Pulse
Input Output
State
Latch/Flipflop
Control Input

Triggering of Flip-flop
❑Edge Trigger
❑Level Trigger

Triggering of Flip-flop
❑Level Trigger ❑Edge Trigger
The flip flop is triggered only during the
high-level or the low level of the clock pulse.
Positive level triggering
Negative level triggering
In edge triggering, the flip flop changes its state during
the positive edge or negative edge of the clock pulse.
Positive edge triggering
Negative edge triggering

Triggering of Flip-flop

Clocked SR Flip-flop
SR Flip flop with Clock
Nand Latch

Clocked SR Flip-flop(cont’d)



This whole Circuit is SR Flip-Flop

Clocked SR Flip-flop(cont’d)



Clk S R Q Q’State

No
Change
No
Change
Memory



0 XX
S’+ 1= 1
=R’+ 1=1
S* R*

Clocked SR Flip-flop(cont’d)



Clk S R Q Q’ State

No
Change
No
Change
Memory



0 XX
S’+0=S’
=R’+0=R’
S* R*
100
=1
=1
Memory

Clocked SR Flip-flop(cont’d)



Clk S R Q Q’ State

No
Change
No
Change
Memory



0 XX
S’+0=S’
=R’+0=R’
S* R*
100
=1
=0
Memory
10101

Clocked SR Flip-flop(cont’d)



Clk S R Q Q’ State

No
Change
No
Change
Memory



0 XX
S’+0=S’
=R’+0=R’
S* R*
100
=0
=1
Memory
10101
11 0 1 0

Clocked SR Flip-flop(cont’d)



Clk S R Q Q’ State

No
Change
No
Change
Memory




0 XX
S’+0=S’
=R’+0=R’
S* R*
100
=0
=0
Memory
10101
11 0 1 0
11 1 1 1
invalid

Truth Table for Clocked SR Flipflop(cont’d)

Clk S R Q Q’ State

No
Change
No
Change
Memory




0 XX
100
Memory
10101
11 0 1 0
11 1 1 1
invalid
❑Circuit
❑Truth Table

Truth Table for Clocked SR Flipflop(cont’d)

Clk S R Qn+1
Qn

Qn




0X X
100
101 0
11 0
1
11 1X
❑Characteristic Table ❑Truth Table
QnS R Qn+1

0 0 0 0
0 0 1 0
0 1 0 1
0 1 1 X
1 0 0 1
1 0 1 0
1 1 0 1
1 1 1 X

Truth Table for Clocked SR Flipflop(cont’d)

❑Characteristic Table ❑Excitation Table

❑Truth Table for SR flipflop
D flip-flop

❑Truth Table for SR flipflop
D flip-flop
❑Truth Table for D flip-flop

D flip-flop

D flip-flop

Synchronous Counter

Definition
A synchronous counter , in contrast to an
asynchronous counter , is one whose output bits
change state simultaneously, with no ripple.

The only way we can build such a counter circuit from J-K flip-flops
is to connect all the clock inputs together, so that each and every
flip-flop receives the exact same clock pulse at the exact same time

Now, the question is, what do we do with the J and K inputs? We know that we still have to
maintain the same divide-by-two frequency pattern in order to count in a binary sequence, and
that this pattern is best achieved utilizing the "toggle" mode of the flip-flop, so the fact that the
J and K inputs must both be (at times) "high" is clear. However, if we simply connect all the J
and K inputs to the positive rail of the power supply as we did in the asynchronous circuit, this
would clearly not work because all the flip-flops would toggle at the same time: with each and
every clock pulse!

How To Design Synchronous Counter

Design a MOD-4 synchronous up-counter,
using JK FF.
STEP 1: No of FF=2
STEP 2: Excitation Table

Design a MOD-4 synchronous up-counter,
using JK FF.
Step 3:

Step 4: Obtain the simplified function using K-Map
B
A
B
B
B
A
A
A

Step 5: Draw the circuit diagram.

Design a MOD-8 synchronous up-counter,
using JK FF.

Step2: State transition diagram & State
Table

Step 3: Expand the present state-next state table to form the transition
table.
Excitation Table

Step 4: Use Karnaugh maps to identify the present state
logic functions for each of the inputs.
QB QA
QC
QB QA
QC

QC
QB QA

Circuit Implementation

How To Design Synchronous Counter
that count Random number
Design a Synchronous Counter to Count 4,7,3,0 and 2 respectively using
JKFlip Flop negative trigered by showing:
i. Flip Flop Used
ii. State Transition Diagram
iii. Exitation Table / Present state, next State
iv. Karnough Map & perform Simplified Function
v. The Synchronous Counter

n = 3 bit = 3 Flip Flop

Synchronous Counter to Count 4,7,3,0 and 2 respectively

Step 4: Karnough Map and
Simplified Function
K Map for JA
0 0 1X3 X
2 0
4 15X 7 X6 X
BA
C4=100
5=101
7=111
6=110
C B A
JA= C=QC

Step 4: Karnough Map and
Simplified Function
K Map for KA
0 X1X3 1
2 X
4 X5X 7 06 X
BA
C0=000
1=001
3=011
2=010
C B A
KA= C=QC

Step 4: Karnough Map and
Simplified Function
K Map for JB
0 1 1X3 X
2 X
4 15X 7 X6 X
BA
C
JB=1

Step 4: Karnough Map and
Simplified Function
K Map for KB
0 X1X3 1
2 1
4 X5X 7 06 X
BA
C0=000
1=001
3=011
2=010
C B A
KB= C=QC

Step 4: Karnough Map and
Simplified Function
K Map for Jc
0 0 1X3 0
2 1
4 X5X 7 X6 X
BA
C2=010
6=110
C B A
Jc= BA=QBQA

Step 4: Karnough Map and
Simplified Function
K Map for Kc
0 X1X3 X
2 X
4 05X 7 16 X
BA
C
2=010
3=011
7=111
6=110

C B A
Kc= B=QB

Circuit Implementation
CB
A
Tags