Starting from:

$30

CS2100 Tutorial 9-Sequential Circuits Solved

LumiNUS Discussion Questions: 

 
 

 
0
1

C/0
A/1

D/1
B/0

B/1
D/0

C/0
D/0
D1. The state table on the right describes the state transition of a circuit with 4 states A, B, C and D, an input x, and an output z. For example, if the circuit is in state A and its input x is 0, then it moves into state C and generates the output 0 for z.

 

(a)    Complete the state diagram below. The label of the arc indicates input/output,  hence 1/1 means x=1 and z=1. 

                                        x/z 


(b)   Assuming that the circuit starts in state A, find the output sequence and state sequence for the input sequence x = 100010 (read from left to right). (x = 100010 means that initially x is 1, then in the next clock x is 0, and so on.)


D2. Match the following state diagrams to the 4 flip-flops: JK flip-flop, D flip-flop, RS flipflop, and T flip-flop. Don’t-care value is indicated by “x”.

(a)                                                                                                                                        (b)  

 

 

(b)                                                                                                                                       (d)  

 

Tutorial Questions 

1.      A four-state sequential circuit below consists of a T flip-flop and a D flip-flop. Analyze the circuit.  

 

 

(a)    Complete the state table and hence draw the state diagram.  

(b)   Assuming that the circuit is initially at state 0, what is the final state and the outputs generated after 3 clock cycles?  

A state is called a sink if once the circuit enters this state, it never moves out of that state.  

(c)    How many sinks are there for this circuit?  

(d)   Which is likely to be an unused state in this circuit?

 

 

Present state 

A                  B 
Output p 
Flip-flop inputs 
Next state 

A+              B+ 
TA 
DB 


 
 
 
                 


 
 
 
                 


 
 
 
                 


 
 
 
                 
 
 
 
 
                                                                                                         

             

 

2.       Given the state transition diagram on the right with states AB and input x, implement the circuit using JK flip-flops and the fewest number of logic gates.

Fill in the state table below and draw the circuit. You do not need to follow the simplest SOP expression in your implementation as that might not give you a circuit with the fewest logic gates.

 

Present state A 
 


Input x 
Next  state 

    A+       B+ 
Flip-flop A 
Flip-flop 

JB 


KB 
     JA       KA 
0
0
0
            
            
 
 
0
0
1
            
            
 
 
0
1
0
            
            
 
 
0
1
1
            
            
 
 
1
0
0
            
            
 
 
1
0
1
            
            
 
 
1
1
0
            
            
 
 
1
1
1
            
            
 
 
             

      State 3 is unused. Can you complete the following state diagram with the unused state?

 

 

 

 A circuit is self-correcting if for some reason the circuit enters into any unused (invalid) state, it is able to transit to a valid state after a finite number of transitions. Is your circuit self-correcting, and why?

             

3.      [AY2018/19 Semester 2 exam] 

A sequential circuit goes through the following states, whose state values are shown in decimal:

 

 

 

The states are represented by 4-bit values ABCD. Implement the sequential circuit using a D flip-flop for A, T flip-flops for B and C, and a JK flip-flop for D.

 

(a)    Write out the simplified SOP expressions for all the flip-flop inputs.

 

(b)   Implement your circuit according to your simplified SOP expressions obtained in part (a). Complete the given state diagram, by indicating the next state for each of the five unused states.

 

(c)    Is your circuit self-correcting? Why?  

 

 

 

 

 

 

 

 

             

Question 4 may be skipped if there is not enough time.

 

4.      Pokemone Theme Park offers locker rental to its visitors. Visitors may purchase two types of token: Pokemoney $1 (P$1) and Pokemoney $2 (P$2). A locker’s rental costs P$3. When a visitor deposits P$3 into the locker’s token slot, its door will open.

 Design a sequential circuit with states AB for the locker’s door using D flip-flops. The circuit consists of 4 states representing the amount a visitor has deposited: 0, 1, 2 and 3 (or, in binary, AB = 00, 01, 10 and 11). The visitor can deposit only one token at a time.  When the circuit reaches the final state 3, it remains in state 3 even if the visitor continues to put tokens into the slot. When the circuit is in state 2 and the visitor deposits a P$2 token, the circuit goes into state 3.

 The partial state diagram is shown below. The inputs x and y represent the P$1 and P$2 tokens respectively. The label on each arrow represents xy.  

(a)    Draw and write the missing arrows and labels.

 

 

(b)   Write the simplified SOP expressions for the flip-flop inputs DA and DB.  

 

More products