Sei sulla pagina 1di 18

COUNTERS

• Counter is used to provide timing and control signals


(gating).
• Basic element of counter is Flip-Flop
• A Mod –N counter divides clock frequency by a factor N
• Synchronous counters are faster than asynchronous
counters. Here all flip-flops are responds to same clock
(edge/level). Synchronous counters are called as parallel
counters.
• In asynchronous counter one flip-flop output drives the
clock of another flip-flop. Here as the clock signal
passage is similar to ripple ,they are called as Ripple
counters.
Counters
• Synchronous Asynchronous

Propagation delay = n*Tff +Tgate

Propagation delay= Tff +Tgate


Ring Counter , JHONSON Counter
• Both Ring Counter and Johnson counter belongs to
synchronous counter. The basic element is D-FF. They
are also called as shift counters

• In Ring Counter (synchronous counter ) the True output


of one flip flop is connected as D input of Next Flip-
flop. The First FF’s D- input is given By Last FF output.
The modulus of Ring Counter with N-FF is N

• .If the Last Flip-flop complementary output


is connected to the D input of First Flip- Flop then it is
called as Twisted Ring or JHONSON counter. The
Modulus with N-FFs is 2N
Synchronous counter Design
• State Diagram of the counter
• State Table of the counter
• Excitation Table of given Flip-flop
• Replace each next state using the
excitation table and obtain the expression
for the each given Flip-flop input/s.
MOD -6 Synchronous counter using D-FF
(JHONSON Counter)
• State Diagram

ABC ABC ABC


000 001 011

ABC ABC
ABC
100 111
110
State Table
PS NS
ABC An Bn Cn
000 0 0 1 Excitation Table Of
001 0 1 1 D- FF is Qn = D
010 * * *
011 1 1 1 AB
100 0 0 0 C 00 01 11 10
Ø 1
101 * * * 0
110 1 0 0
1 1 1 Ø
111 1 1 0
An =Da= ε(3,6,7) + ε Ø(2,5) = B
AB Db = B Dc = C
00 01 11 10
C Ø 1 Ø
0
1 1 1 Ø 1 1 Ø
1
Db = C Dc = A’

Dc C Db B Da

A’
Asynchronous counters
• All the Flip flops are T-FF and they are
operating in Toggle mode( T=1).
• External clock is applied to LSB Flip Flop.
• The Clock of one flip-flop is driven by the
TRUE output of the previous one (Up-
counting).
• With N-flip Flops the modulus of the
counter is 2N.
Operation
• Only FF A responds to the clock
• FF B must wait for FF A to change before
it can toggle
• FF C must wait for B, and so on
• Delay of 5 to 20 ns, can be trouble some
• Called Ripple Counter: FF responds one
after another in a rippling effect.
• Frequency division – each FF will have
an output frequency of ½ the input. The
output frequency of the last FF of any
counter will be the clock frequency
divided by the MOD of the counter.

Ex:MOD-16 counter, last FF will have a


freq =1/16 of the input clock, also called
a divide by 16 counter.
Four-bit asynchronous (ripple) counter.
# of states
=16

MOD-16
Ripple
Counter
Counter waveforms showing frequency division by 2 for each FF
Divide by
A by 2
B by 4
C by 8
D by 16
Asynchronous (ripple) down counter

Counting
down rather
than up simply
requires
cascading the
clocks using
the inverted
outputs

MOD-8 asynchronous (ripple) down counter


Asyn Counter MOD < 2 N

• Get the binary pattern of the modulus


Ex: MOD -6 , the Binary pattern QcQbQa=110
• Choose the flip-flop outputs which are 1
for that count (modulus), here Qc,Qb
• Connect them to the inputs of Nand gate
and the output of the Nand gate is
connected to asynchronous clear control
line of each filp-flop.
Counters with MOD Number <2N

MOD-6
asynchronous
counter
produced by
clearing a
MOD-8 counter
when a count of
six (110)
occurs.
Counters with MOD Number <2N
(a) State transition diagram for the MOD-6
ripple counter.
(b) LEDs are often used to display the
states of a counter.

Count of 5
1 0 1
ON OFF ON

• At 1 kHz, LED’s switch on and off


rapidly, they appear ON all the time
with half the normal brightness
• State 110 will not be visible, because
it lasts for few nanoseconds as the
counter recycles to 000
Counters with MOD Number <2N
a) MOD-14 ripple
counter;
At D,
freq=30/14
=2.14kHz

b) MOD-10
(decade)
ripple counter.
At D,
freq=1/10
=0.1MHz
• Mod number:
For N FF’s, the number of states = 2N
ex: N=4, then Mod=16
ex: how many FF’s are needed to
have a count of 1000?
2N >1000,  N=10 (will count till
1024)
(N log 2 = 3 N=9.96==10)

Potrebbero piacerti anche