in Digital Logic recategorized by
3,293 views
24 votes
24 votes
Design a $3$-bit counter using D-flip flops such that not more than one flip-flop changes state between any two consecutive states.
in Digital Logic recategorized by
by
3.3k views

2 Comments

Can we use Johnson Counter here??
1
1
Yes.
1
1

4 Answers

33 votes
33 votes
Best answer

State diagram will be as  (remember concept of $\textsf{GRAY}$ code) 

State table and $3$-bit synchronous counter with D FFs, will be as 

$\begin{array}{c|c|c}
\text{Present State}&\text{Next State}&\text{FF Inputs}\\\hline
ABC&\bar A \bar B \bar C & D_AD_BD_C\\\hline
001&011&011\\000&001&001\\010&110&110\\011&010&010\\100&000&000\\101&100&100\\110&111&111\\
\end{array}$

 

edited by

4 Comments

why from 000 state to 001 state we can also go from 000 to 100 or 010??
2
2

@Arjun Sir @Deepak Poonia Sir why are we only going to only one state , many more states are possible. For example from 000 we can go to any state except 111 which holds true acording to the question.

0
0

You can create any Counting/State Sequence here as long as any two consecutive states differ in exactly one bit position.

For eg, we can create Counter whose state sequence is:

$000 \rightarrow 010 \rightarrow 011 \rightarrow 001 \rightarrow  101 \rightarrow 111 \rightarrow 110 \rightarrow 100 \rightarrow 000 \dots  $

This state sequence also obeys all the given conditions. The Counter for this sequence is another correct answer.

Similarly, more sequences are possible.

2
2
6 votes
6 votes

We count in Gray Code :

5 votes
5 votes
  Present  state       Next state  
Q2 Q1 Q0 D2 D1 D0 Q2 Q1 Q0
0 0 0 0 0 1 0 0 1
0 0 1 0 1 1 0 1 1
0 1 1 0 1 0 0 1 0
0 1 0 1 1 0 1 1 0
1 1 0 1 1 1 1 1 1
1 1 1 1 0 1 1 0 1
1 0 1 1 0 0 1 0 0
1 0 0 0 0 0 0 0 0

D2=Q1Q0'+Q2Q0

D1=Q2'Q1+Q1Q0'

D0=Q2'Q1'+Q2Q1

2 Comments

I am getting

D2= Q1Q0' + Q2Q0

D1= Q2'Q0 + Q1Q0'

D0= Q2'Q1' + Q2Q1. Could you please check?
0
0
how to get Do,D1,D2 coloum pllzzz explain
1
1
3 votes
3 votes

Consider $Q_{A},Q_{B},Q_{C}$ as the $3$ bits, $Q_{A}$ being MSB. The trend taken is that of the $3$-bit gray code. Solve for $D_{a}, D_{b}, D_{c}$  each as a function of $Q_{A},Q_{B},Q_{C}.$ $$\begin{array}{lll|ll}\hline  Q_{A} & Q_{B} & Q_{C} & Q_{A_{n}} = D_{A} & Q_{B_{n}}= D_{B} & Q_{C_{n}}= D_{C}   \\\hline  0&0&0 & 0& 0& 1 \\\hline 0& 0& 1 & 0& 1& 1  \\\hline 0& 1& 1 & 0& 1& 0 \\\hline 0& 1& 0 & 1& 1& 0 \\\hline 1& 1& 0 & 1& 1& 1 \\\hline 1& 1& 1 & 1& 0& 1 \\\hline 1& 0& 1 & 1& 0& 0  \\\hline 1& 0& 0 & 0& 0& 0 \\\hline \end{array}$$

edited by
by

2 Comments

i believe the K-MAP's in the answer are wrong

this is a same question https://gateoverflow.in/17408/gate1992-04-c

with same table but with different K-MAP's drawn in answer

0
0

I guess, the answer is different from the answer of question https://gateoverflow.in/17408/gate1992-04-c because we are also trying to avoid hazards which may cause more than one state change during transition from one state to other, seems more appropriate.

0
0

Related questions