DCF Module - 4
DCF Module - 4
D CLK Q Q’_________________
1 1 0 SET (stores a 1)
0 01 RESET (stores a 0)
The flip-flop as a storage element
When a 1 is on D, Q When a 0 is on D, Q
becomes a 1 at becomes a 0 at
triggering edge of CLK triggering edge of CLK
or remains a 1 if already or remains a 0 if already
in the SET state in the RESET state
Type of register
When signal = 1,
● SHIFT
When signal = 0,
LOAD
4-bit parallel in/serial out shift register (PISO)
When signal = 0,
● LOAD
G1 – G3
enabled
4-bit parallel in/serial out shift register (PISO)
When signal = 1,
● SHIFT
G4 – G6
enabled
Example : Show the data input waveform for 4-bit register with parallel input
and clock shift/load waveform…4-bit parallel in/serial out shift register (PISO)
Parallel In, Parallel Out Shift Register (PIPO)
Timing
Diagram
Working
● The counter is initially reset to 00
Counter Q2 Q1 Q0 Counter Q2 Q1 Q0
State State
0 0 0 0 4 1 0 0
1 0 0 1 5 1 0 1
2 0 1 0 6 1 1 0
3 0 1 1 7 1 1 1
2 bit down counter
Working
● The counter is initially reset to 00
1 0 0 0 0 0
2 0 0 0 1 1
3 0 0 1 0 2
4 0 0 1 1 3
5 0 1 0 0 4
6 0 1 0 1 5
7 0 1 1 0 6
8 0 1 1 1 7
9 1 0 0 0 8
10 1 0 0 1 9
11 Counter Resets its Outputs back to Zero
Logic Diagram of a Mod-10 Counter
MOD-6 Asynchronous Up
Counter
● MOD 6 asynchronous counter will require 3 flip
flops and will count from 000 to 101
Connection
● Connect a shift register in standard SISO format.
● Connect Q of last FF to the D input of first FF. (that is
give positive feedback)
● Take output from all FFs.
3 – bit ring counter
3 bit Ring Counter – State Diagram
RING Counter
0 0 1 1 1
0 1 0 2 2
1 0 0 3 4
0 0 1 1 1
0 1 0 2 2
1 0 0 3 4
Ring Counter or circulating register
Working
● Assume that initially Q2 and Q1 are 0 and Q0 is 1.
● This 1 will shift to right for each clock pulse resulting
the 010. for the next clock output is 100.
● For the third clock it is again 001. and the sequence
repeats.
Ring Counter
State Diagram
● A counter is first described by a state diagram, which is shows the
sequence of states through which the counter advances when it is
clocked
T flip-flop Excitation Table
States Input
Present Next T
0 0 0
0 1 1
1 0 1
1 1 0
JK flip-flop
JK flip-flop
("X" is "don't care")
States Inputs
Present Next J K
0 0 0 X
0 1 1 X
1 0 X 1
1 1 X 0
Synchronous Counters
● In Synchronous Counter, the external clock signal
is connected to the clock input of EVERY individual
flip-flop within the counter so that all of the flip-
flops are clocked together simultaneously (in
parallel) at the same time giving a fixed time
relationship.
● In other words, changes in the output occur in
“synchronisation” with the clock signal.
● The result of this synchronization is that all the
individual output bits changing state at exactly the
same time in response to the common clock
signal with no ripple effect and therefore, no
propagation delay.
3 bit Up counter
● A 3 bit up counter requires 3 flip flops.
● The counting sequence is 000, 001, 010, 011, 100, 101, 110, 111
0 0 0 0 0 1 0 0 1
0 0 1 0 1 0 0 1 1
0 1 0 0 1 1 0 0 1
0 1 1 1 0 0 1 1 1
1 0 0 1 0 1 0 0 1
1 0 1 1 1 0 0 1 1
1 1 0 1 1 1 0 0 1
1 1 1 0 0 0 1 1 1
Simplified Expression from Truth Table
K-MAP FOR T1
K-MAP FOR T2
Simplified Expression from Truth Table
K-MAP FOR T3
LOGIC DIAGRAM
4 BIT UP COUNTER USING JKFF
Present State Next State
Q4 Q3 Q2 Q1 Q4 Q3 Q2 Q1 J4 K4 J3 K3 J2 K2 J1 K1
0 0 0 0 0 0 0 0 1 0 x o x 0 x 1 x
1 0 0 0 1 0 0 1 0 0 x 0 x 1 x x 1
2 0 0 1 0 0 0 1 1 0 x 0 x x 0 1 x
3 0 0 1 1 0 1 0 0 0 x 1 x x 1 x 1
4 0 1 0 0 0 1 0 1 0 x x 0 0 x 1 x
5 0 1 0 1 0 1 1 0 0 x x 0 1 x x 1
6 0 1 1 0 0 1 1 1 0 x x 0 x 0 1 x
7 0 1 1 1 1 0 0 0 1 x x 1 x 1 x 1
8 1 0 0 0 1 0 0 1 x 0 o x 0 x 1 x
9 1 0 0 1 1 0 1 0 x 0 o x 1 x x 1
10 1 0 1 0 1 0 1 1 x 0 o x x 0 1 x
11 1 0 1 1 1 1 0 0 x 0 1 x x 1 x 1
12 1 1 0 0 1 1 0 1 x 0 x 0 0 x 1 x
13 1 1 0 1 1 1 1 0 x 0 x 0 1 x x 1
14 1 1 1 0 1 1 1 1 x 0 x 0 x 0 1 x
15 1 1 1 1 0 0 0 0 x 1 x 1 x 1 x 1
MOD 6 Counter
● In a mod-6 counter you are using a 3-bit counter that actually has 8
states. However, when the counter reaches the seventh state (Q2 =
1, Q1 = 1, Q0 = 0), you force the counter to return to the state (Q2 =
0, Q1 = 0, Q0 = 0)...
● For this you use an NAND gate, whose output is connected with the
CLEAR inputs of the flip-flops.
Mod 6 Counter – State Diagram
MOD 6 COUNTER
CIRCUIT EXCITATION TABLE
PRESENT STATE NEXT STATE T3 T2 T1
0 0 0 0 0 1 0 0 1
0 0 1 0 1 0 0 1 1
0 1 0 0 1 1 0 0 1
0 1 1 1 0 0 1 1 1
1 0 0 1 0 1 0 0 1
1 0 1 0 0 0 1 0 1
1 1 0 x x x x x x
1 1 1 x x x x x x
Simplified Expression from Truth Table
K-MAP FOR T1
K-MAP FOR T2
Simplified Expression from Truth Table
K-MAP FOR T3
3 bit down counter
3 bit up down counter