Professional Documents
Culture Documents
7 ChapterSeven
7 ChapterSeven
7 ChapterSeven
FLIP-FLOPS AND
REGISTERS
Objectives
Sequential circuits
Registers
Calculator
104
Memory
S
Q S Q
SR
Latch
R Q
R Q
Mode 1:
S=R=0. Q*=Q. The next state Q* is equal to the present state Q. So,
there is no change of state.
Mode 2:
S=1, R=0. Q* = 1, representing set operation.
Mode 3:
S=0, R=1. Q*=0, representing reset operation.
S R Q Q Mode
0 0 Q Q Hold
0 1 0 1 Re set
1 0 1 0 Set
1 1 0 0 Pr ohibited(invalid)
Example 1:
Assume that the initial state Q=0. Determine the Q waveform for the
SR latch.
S
R
Initialstate
Q=0 Output Q changes states
immediately when S or R
changes
7.3 SR Flip-Flop
CLK S R Q Q Mode
0 0 Q Q Hold
0 1 0 1 Re set
1 0 1 0 Set
1 1 0 0 Pr ohibited (invalid )
Example 1:
Assume that the initial state Q=0. Determine the Q waveform for the
SR flip-flop.
CLK 1 2 3 4 5 6 7 8
7.4 D Flip-Flop
The D flip-flop has only a single data input D and a clock input CLK.
The SR flip-flop can be converted to a D flip-flop by adding an inverter.
Data is transferred from the input D to the output Q on the 0 → 1
transition of the clock pulse.
SET SET
S Q D Q CLK D Q
0 0
R CLR
Q CLR
Q 1 1
Example 1:
Assume that Q=0 initially. Determine the Q waveform for the D flip-
flop.
CLK 1 2 3 4
7.5 D Latch
E D Q
D Q
0 x Nochange
E Q 1 0 0
1 1 1
Example 1:
Assume that Q=0 initially. Determine the Q waveform for the D flip-
flop.
1 2 3 4
789
456 Encoder Decoder
123
0
Gnd
S9 DISP1
74147
I9 abcdefg.
S8 I8 74LS48
I7 A3 A3 g
I6 A2 A2 f
I5 A1 A1 e
S7 I4 A0 A0 d
I3 c
I2 b
I1 a
S6
test
RBI RBO
S5
S4
S3
S2
S1
S0
109
789 4-Bit
456 Encoder Storage Decoder
123 Register
0
9
4321
4321
D0 Q0
D1 Q1
D2 Q2
D3 Q3
5V Load CP
+V
TP1
R2
1k
9
4321 4321
D Q
_
CP Q
D Q
_
CP Q
D Q
_
CP Q
D Q
_
CP Q
V1
5V Load
+V
R1
1k
110
SET
D Q
CLR
Q
1 1 D
SET
Q
2 2
3 MSB
3 A CLR
Q
4 4 B
5 Enkoder Dekoder
SET
D Q
5 C
6 LSB
6 D
Q
7 7
CLR
8 8 SET
D Q
9 9
0 CLR
Q
Gnd
S9
74147
I9 abcdefg.
S8 I8 74LS48
I7 A3 A3 g
I6 A2 D0 Q0 A2 f
I5 A1 D1 Q1 A1 e
S7 I4 A0 D2 Q2 A0 d
I3 c
I2 D3 Q3 b
I1 a
CP
S6
test
RBI RBO
S5
S4
S3
S2
S1
S0
111
3. Load Register A = 2.
• Load A = 1 and Load B = 0.
• Press 2.
Output of OR gate = 1. A clock transition 0 → 1 will transfer the
number 2 into register A.
Number 2 is displayed.
4. Load Register B = 3.
• Load B = 1 and Load A = 0.
• Press 3.
Output of OR gate = 1. A clock transition 0 → 1 will transfer the
number 3 into register B.
7 8 9 a
4 5 6 Control 4 Bit f b
Encoder g
1 2 3 Load Adder Decoder
e c
0 d
Add/
Register
Subtract
B
Control
112
SET
D Q A1
B1
L CLR
Q
Σ1 A a
SET
D Q A2 b
Σ2 B c
B2
L CLR
Q 7 Segment d
SET
4 Bit Adder Σ3 C Decoder e
D Q A3
f
B3 Σ4 D g
L CLR
Q
D
SET
Q A4
8
B4
L CLR
Q
1 Register A
2 1 Y
3 2
4 3 A MSB
7 8 9 4 B Add/Subtract
5 Load A Control
4 5 6 6 5 C LSB
1 2 3 6 D Load B
7
0 8 7
9 8
Z Control Load
0 9
SET
D Q
x
L CLR
Q
SET
D Q
L CLR
Q
SET
D Q
L CLR
Q
SET
D Q
L CLR
Q
Register B
113
114
Exercises
Q=0
Mode
CLK 1 2 3 4 5 6 7 8
Q=0
Mode
3. Assume that Q=0 initially. Determine the Q waveform for the D flip-
flop.
CLK 1 2 3 4 5 6 7 8
Q=0
Mode