Beruflich Dokumente
Kultur Dokumente
CHAPTER 1:
Sequential Logic - advanced
2
Ø Number representations
Ø Boolean Algebra
Ø Logic gate
Ø Karnaugh map
Ø Combinational Circuit
(Arithmetic circuits, Decoder/Encoder, Mux/Demux…)
Ø Sequential Circuit
(Latches, Flip-flops, Counters)
3
4
In this lecture:
Ø Latchs and Flip-flops - Basic components of Memory
• State Minimization
• State Encoding
In this lecture:
Ø Latchs and Flip-flops - Basic components of Memory
• State Minimization
• State Encoding
Sequential components
Ø Sequential components contain memory elements
Clock signal
Gated SR latch
Control signal C activates the latch.
11
Flip-Flops (FF)
Ø Latches are level-sensitive since they respond to input
changes during clock width à It is difficult to work.
Ø Flip-Flops respond to input changes only during the
change in clock signal.
Ø They are easy to work with though more expensive than
latches.
Ø Two styles of flip-flops are available.
1. master-slave (MS)
2. edge-triggered (ET)
13
Note:
Low-to-high delay is 4.0ns.
High-to-low delay is 3.0ns
14
Master-slave D-FF
In a MS flip-flop, D is
sampled and stored at the
rising edge of the Clk
signal
15
Flip-flop types
18
Graphic symbol
20
Graphic symbols
for FFs with
asynchronous
inputs
21
In this lecture:
Ø Latchs and Flip-flops - Basic components of Memory
• State Minimization
• State Encoding
Step 1
Step 2 Step 3
25
Output equation:
Y = Q0.Q1
29
Output equation:
Y = Q0.Q1
Output equation:
Y = Q0.Q1.Cnt
31
Note:Output is dependent on
the present state and the input
of the FSM.
In this lecture:
Ø Latchs and Flip-flops - Basic components of Memory
• State Minimization
• State Encoding
State minimization
Ø State minimization reduces the number of states, and therefore,
number of flip-flops needed to implemented the circuit also reduce.
Ø State minimization is based on the concept of behavioral
equivalence in which two states are equivalent if they produce the
same sequence of next-state and output symbols for every
sequence of input symbols.
More formally, two states, sj and sk in a FSM are said to be equivalent if
the following two conditions are true
o Condition 1: Both states sj and sk produce the same output symbol
for every input symbol i: that is, h (sj ,i) = h (sk ,i)
o Condition 2: Both states have equivalent next sates for every input
symbol i: that is, f (sj ,i) = f (sk ,i)
Ø Minimization procedure:
1. Partition states into equivalence classes
2. Construct new FSM with one state for each equivalence class
41
Implication table
for the table above
45
State encoding
The cost and delay of FSM implementation
depends on encoding of symbolic states
Minimum-bit-change
Ø Minimum-bit change strategy assigns codes to states so
that the total number of bit changes for all state transitions
is minimized.
Prioritized adjacency
Prioritized adjacency strategy assigns adjacent encodings to all states
with common source, common destination or common output.
Ø The highest priority is given to states that have the same next state
for a given input value à the same next-state encoding will appear in
adjacent entries in the Karnaugh map.
Ø The second priority is given to the next states of the same state à
the next state also may appear adjacent in the Karnaugh map.
Ø The third priority is given to states that have the same output value
for the same input values à they may be adjacent in the output map.
Example: encoding based on prioritized adjacency.
Adjacency priorities
Hot-one encoding
Ø Hot-one encoding is a redundant encoding with
one flip-flop per state having value 1 and others
having value 0.
Encoding example
ØExample: State encodings for modulo-3 counter.
ØProblem: Given the up/down, modulo-3 counter which was
specified by the minimal next-state/output in the below table.
Find the encoding method that will minimize the cost and delay
of the counter logic.
Present NEXT STATE
State
CD = 0X CD = 10 CD = 11
Total cost = 64
Max. input delay = 4.0ns
Max. output delay = 3.2ns
56
Q0(next)
Q1(next)
Q2(next)
Cost (Q0) = Cost (Q1) = Cost (Q2) = 22 Cost (Y) = 16
Delay (Q0) = Delay (Q1) = Delay (Q2) =3.6 Delay (Y) = 3.2
Total cost = 82
Max. input delay = 3.6ns
Max. output delay = 3.2ns
58
Delay table
Logic schematic
65
Timing diagram
66
Chapter Summary
Ø We introduced memory elements
o Latches (asynchronous)
o Flip-flops (synchronous)
Ø We presented several ways to describe memory elements (flip-flops)
o Characteristic tables
o Characteristic equations
o State diagrams
o Timing diagrams
Ø We described procedures for sequential logic
o Analysis
o Synthesis (include design) with
q FSM capture
q state minimization
q state encoding