Chapter 6
Chapter 6
1
Chapter outline
• Sequential Circuit Model
• Classification of Sequential Circuits
• Analysis of Sequential Circuits
• State table, state diagram, state equations and flip-
flop input functions
• State reduction and assignment
• Design Procedure of Sequential Circuits
• Design of counters
2
Sequential Circuit Model
Mealy Machine
• Output based on state and present input
Q(t+1)
Flip
Comb.
next Flops Q(t)
Logic
state
present Y(t)
X(t)
Comb.
state
present Logic
input
clk
3
Moore Machine
Q(t+1) Y(t)
Flip Comb.
Comb.
next Flops Q(t) Logic
Logic
state
X(t) present
state
present
input
clk
4
Mealy Model
Mealy versus Moore
Inputs
Input Output Outputs
Logic Logic
Combina- Memory Combina-
tional Element tional
Moore Model
5
Analysis of Sequential Circuits
• The behaviour of a sequential circuit is determined from the inputs, the
outputs and the states of its flip-flops. Both the output and the next
state are a function of the inputs and the present state. The suggested
analysis procedure of a sequential circuit is set out in Figure 6 below.
• We start with the logic schematic from which we can derive excitation
equations for each flip-flop input. Then, to obtain next-state equations,
we insert the excitation equations into the characteristic equations. The
output equations can be derived from the schematic, and once we have
our output and next-state equations, we can generate the next-state and
output tables as well as state diagrams. When we reach this stage, we
use either the table or the state diagram to develop a timing diagram
which can be verified through simulation.
• Now let's look at some examples, using these procedures to analyse a
sequential circuit.
6
Figure 6. Analysis procedure of sequential circuits.
7
Analysis of Sequential Circuits
Flip Flop State
Behavior of clocked sequential circuit can be determined from inputs,
outputs and FF state
x D0
Q1 Q0
Q
D
Q’
y
Q
D Q1
Q0 D1 Q’
Clk
y(t) = x(t)Q1(t)Q0(t)
Q0(t+1) = D0(t) = x(t)Q1(t)
Q1(t+1) = D1(t) = x(t) + Q0(t)
8
Output and State Equations
Next state dependent on previous state.
x D0
Q1 Q0
Q
D
Q’
y
Q
D Q1
Q0 D1 Q’
Clk
Output equation
y(t) = x(t)Q1(t)Q0(t)
Q0(t+1) = D0(t) = x(t)Q1(t)
State equations
Q1(t+1) = D1(t) = x(t) + Q0(t)
9
State Table
• Sequence of outputs, inputs, and flip flop states
enumerated in state table
• Present state indicates current value of flip flops
• Next state indicates state after next rising clock edge
• Output is output value on current clock edge
11
State Diagram
• Circles indicate current state
• Arrows point to next state
• For x/y, x is input and y is output
Present Next State Output
State x=0 x=1 x=0 x=1
00 00 10 0 0
10 10 0 0
01 00 11 0 0
10 10 11 0 1
11 1/1
0/0 0/0
0/0 1/0
00 01 10 11
1/0
1/0 0/0
12
State Diagram
1/1
0/0 0/0
0/0 1/0
s0 s1 s2 s3
1/0
1/0 0/0
13
Flip Flop Input Equations
Boolean expressions which indicate the input to the flip flops.
x D0
Q1 Q0
Q
D
Q’
y
Q
D Q1
Q0 D1 Q’
Clk
DQ0 = xQ1
DQ1 = x + Q0
14
Analysis with D Flip-Flops
• Identify flip flop input equations
• Identify output equation
16
Design procedure of Sequential
Circuits
• The design of a synchronous sequential circuit starts from a set of specifications
and culminates in a logic diagram or a list of Boolean functions from which a
logic diagram can be obtained. In contrast to a combinational logic, which is
fully specified by a truth table, a sequential circuit requires a state table for its
specification. The first step in the design of sequential circuits is to obtain a
state table or an equivalence representation, such as a state diagram.
17
Cont’d
18
Designing Finite State Machines
• Specify the problem with words
-(e.g. Design a circuit that detects three consecutive
1 inputs)
• Assign binary values to states
• Develop a state table
• Use K-maps to simplify expressions
-Flip flop input equations and output equations
• Create appropriate logic diagram
-Should include combinational logic and flip flops
19
Design of Counters
• A sequential circuit that goes through a prescribed sequence of states upon
the application of input pulses is called a counter. The input pulses, called
count pulses, may be clock pulses. In a counter, the sequence of states may
follow a binary count or any other sequence of states. Counters are found
in almost all equipment containing digital logic. They are used for counting
the number of occurrences of an event and are useful for generating timing
sequences to control operations in a digital system.
20