Professional Documents
Culture Documents
R (Reset)
Q
0
Q
R=0
1
S=1
Q
0
B
S (Set)
A B B
B
A=0
Keep state
Unstable
condition
R (Reset)
Q
0
Q
R=0
1
S=1
Q
0
B
S (Set)
A B B
B
A=0
Cross-coupled NAND
R
Q
Q
Q
S
Hold State
R=S=0
R=1, S=1
5
Forbidden I/Ps
4) The D-Latch
R
R1
R-S
Clk
D
Q
Latch Q
S1
0
Q=1,
D=0, S=0, R=1
Clk=1
Q=0, Q 1
Clk=0 R1,S1=0 (hold state)
Clocked Latch
(level-sensitive clock latch)
see terminology defined
later.
clk
positiv
e edge
positiv
e edge
otherwi
0 or 1
se
6
Keep
Keep
previou previou
s state s state
4) The T-Latch
clk
positiv
e edge
positiv
e edge
otherwi
0 or 1
se
Keep
Keep
previou previou
s state s state
Q 10
10
R
CLK
J
8
R-S
1
Q
01
01
Keep state
R-S, D, J-K, T, etc., though the examples are given for the R-S latch.
Transparent Latch: O/P responds to latch I/Ps without any enable or clock signal.
R
Symbol:
R
S
Q
Q
Clock:
Fixed frequency alternating 1 and 0 signal
ii) Clocked or Level-Sensitive Latch:
R
O/P responds to I/Ps only when enb or
Q
clock is at a pre-determined level (high
Clock
or low In this example, it is High)
or
enb
10
Symbol:
R
S
Q
Q
or
CLK
(high enable)
R
S
CLK
Q
Q
(low enable)
CLK
CLK
Clock:
O/P resp. period for
a low-enable/clock
level sensitive latch
11
O/P response
period for a
positive
edgetriggered
FF.
O/P response
period for a
negative
edge-triggered
FF
O/P response
period for a
HIGH-enable/clock
level-sensitive
latch
D
CLK
If negative edge-triggered
TSetup
THold
D
CLK
Negative edge arrival
If D-Latch is high-level sensitive: Tsetup and Thold have to be around the negative edge
of clock (more specifically, when the clock begins to go low), similar to negative edge-triggered.
If D-Latch is low-level sensitive: Tsetup and Thold have to be around the positive
12
edge of clock, similar to positive edge-triggered.
0
S
R-S
Latch
Qm
Qm
1
P
0
1
0
1 Q
Qs
R-S
S
Qs
CLK
J-K
M-S
13
Q
Q
HoldsD when
clock goes low
D
R
D
Holds D when
clock goes low
Q responds to
internal S signal;
Q responds to
internal R signal.
CLK
D
R
Clk=0
Q
Q
D
14
Q =D
D=1=S
Q=1, Q 0
Q D
D 0R
Clk=0
Clk=1
0
Assume D=1
15
Q(t)\SR 00
0
0
1
1
01
0
0
11
x
x
Q+ = Q( t+ )
0
Hold
1
0
Reset
0
1
Set
1
x
Forbidden
x
10
1
1
Q+= S+ R Q
(Characteristic equation)
16
Excitation Table
Reversed Truth Table
What the inputs to FFs should be for given output
transitions (Q Q+)
Q
0
0
1
1
17
Q+
0
1
0
1
R
x
0
1
0
S
0
1
0
x
J
0
1
x
x
K
x
x
1
0
T
0
1
1
0
D
0
1
0
1
Logic
This should
behave like a
D-FF.
Q
Q
CLK
D
Q 0
O/P function = J
0
J=D
Q
D
Function = K
K= D
CLK
D-FF
Q
Q
D J-K
Example 2:
KQ
D
0
1
0
1
JQ
00
01
11
10
J
0
0
0
0
1
1
1
1
K
0
0
1
1
0
0
1
1
Q
0
1
0
1
0
1
0
1
Q+
0
1
0
0
1
1
1
0
TT for J-K
J-K FF/Latch
Q
J
CLK
19
Logic
CLK
Function is D JQ K Q
K
Q
Q
Q
Q
100
E
A
000
No external I/Ps
D
011
Counter O/P
Logic
Next State
bits
001
010
FFs
n
CLK
Input
Present State
111
001
110
010
101
011
100
C
0
0
0
0
1
1
1
1
21
Q
0
0
1
1
Q+
0
1
0
1
R
x
0
1
0
S
0
1
0
x
J
0
1
x
x
K
x
x
1
0
T
0
1
1
0
D
0
1
0
1
B
0
0
1
1
0
0
1
1
A
0
1
0
1
0
1
0
1
Output
Next State
C+ B+ A+
0 0
1
0 1
0
0 1
1
1 0
0
1 0
1
1 1
0
1 1
1
0 0
0
Toggle Flip-Flop
Inputs
TC TB TA
0
0
1
0
1
1
0
0
1
1
1
1
0
0
1
0
1
1
0
0
1
1
1
1
(b) State Transition Table (What next state
will be given the
current state.)
From excitation table for FF inputs, get K-map for the FF inputs.
CB
00 01 11 10
A
0
1
1
1
1
1
1
1
1
1
TA=1
CB
00 01 11 10
A
0 0 0 0
0
1
0 1 1 0
TC=AB
CB
A
00 01 11 10
0
1
0
1
0
1
0
1
0
1
TB=A
Obtain logic expr. for FF I/Ps (as functions of current state bits A,
B, C, --- A=QA, B=QB, C=QC) and realize the counter
22
000
110
010
101
011
State Transition
Diagram
Next
State
+
C B+
0 1
x x
0 1
1 0
x x
1 1
0 0
x x
A+
0
x
1
1
x
0
0
x
JC
0
x
0
1
x
x
x
x
C
0
0
0
0
1
1
1
1
Remapped Next
State
KC JB KB
x
1 x
x
x x
x
x 0
x
x 1
x
x x
0
1 x
1
x 1
x
x x
B
0
0
1
1
0
0
1
1
A
0
1
0
1
0
1
0
1
Next State
C+ B+ A+
0 1
0
x x
x
0 1
1
1 0
1
x x
x
1 1
0
0 0
0
x x
x
Q Q+ J K
0 0
0 x
0 1
1 x
1 0
x 1
1 1
x 0
Q JQ K Q
J-K Flip-Flop Excitation Table
KC A
JB 1
KB A C
KA C
J A BC
CB
00
A
0 0
1 x
A
CB
0
1
11 10
0
1
x
x
x
x
00
01
11
10
1
x
x
x
x
x
x
1
CB
00
A
0 0
1 x
24
01
01
1
x
CB
A 00
JC
A
JB
11 10
0
x
x
x
JA
x
x
0
1
CB
0
1
01
x
x
11
10
1
x
x
0
KC
00
01
11
10
x
x
0
1
1
x
x
x
CB
00
A
0 x
1 x
01
x
0
KB
11 10
x
x
x
1
KA
J
Q
CLK
K
Q
A
Count
signal
C
KB
A
C
J
Q
CLK
K
Q
B
KB
JA
J
Q
CLK
K
Q
JA
Registers
26
Registers
A flip-flop stores one bit of information
When a set of n flip-flops is used to store n bits of data, we refer
to these flip-flops as a register
Common register usages include
Holding a data value output from an arithmetic circuit
Holding a count value in a counter circuit
A common clock signal is typically used for
each flip-flop in a register
27
Shift register
A register that provides the ability
to shift its
contents by a single bit
May be to the right or left (or
possibly both)
28
29
31
Counters
Special purpose arithmetic circuits used for
the purpose of counting
Design circuits that can increment or decrement a
count by 1
Counter circuits server many purposes
Count occurrences of certain events
Generate timing intervals for controlling various
tasks in a digital system
Track elapsed time between events
Often (but not always) built with T flip-flops
because the toggle feature is naturally suited
for implementing the counting operation
32
33
34
35
36
37