How to Set Up a State Table for a 2-bit Gray Code Counter?

Join the discussion
Registration is free. Ask a follow-up in this thread, or start your own.
1 reply · 3K views
gomezfx
Messages
20
Reaction score
0

Homework Statement


A counter has two state outputs y1 (the more significant bit) and y2 (the less significant bit) and a control input x. When x = 0, the states of the counter’s flip-flops do not change. When x = 1, the states of the counter’s flip-flops cycle through the codes of a 2-bit Gray code sequence (00 – 01 – 11 – 10) on successive clock pulses.


Homework Equations





The Attempt at a Solution



I am having trouble setting up the state table. The gray code part is what's confusing me I think. Does anyone mind looking at my state table to verify if it's right. Also, how am I supposed to know what the outputs for y1 and y2 yield?

hw.png
 
Physics news on Phys.org
Your state table is OK. y1 and y2 just output the current state of the counter, so y1=a and y2 = b