Digital Logic Design Lecture 27.

Slides:



Advertisements
Similar presentations
State-machine structure (Mealy)
Advertisements

TOPIC : Finite State Machine(FSM) and Flow Tables UNIT 1 : Modeling Module 1.4 : Modeling Sequential circuits.
Sequential Circuits1 DIGITAL LOGIC DESIGN by Dr. Fenghui Yao Tennessee State University Department of Computer Science Nashville, TN.
Computing Machinery Chapter 5: Sequential Circuits.
Digital Logic Design Lecture 22. Announcements Homework 7 due today Homework 8 on course webpage, due 11/20. Recitation quiz on Monday on material from.
CS 151 Digital Systems Design Lecture 21 Analyzing Sequential Circuits.
ECE 331 – Digital System Design Introduction to and Analysis of Sequential Logic Circuits (Lecture #20) The slides included herein were taken from the.
ECE 331 – Digital System Design State Reduction and State Assignment (Lecture #22) The slides included herein were taken from the materials accompanying.
ECE 331 – Digital System Design
ECE C03 Lecture 111 Lecture 11 Finite State Machine Optimization Hai Zhou ECE 303 Advanced Digital Design Spring 2002.
08/07/041 CSE-221 Digital Logic Design (DLD) Lecture-8:
ECE C03 Lecture 131 Lecture 13 Finite State Machine Optimization Prith Banerjee ECE C03 Advanced Digital Design Spring 1998.
EECC341 - Shaaban #1 Lec # 14 Winter Clocked Synchronous State-Machines Such machines have the characteristics: –Sequential circuits designed.
CSCE 211: Digital Logic Design
Overview Sequential Circuit Design Specification Formulation
Chapter 8 -- Analysis and Synthesis of Synchronous Sequential Circuits.
Digital Logic Design Lecture 26. Announcements Exams will be returned on Thursday Final small quiz on Monday, 12/8. Final homework will be assigned Thursday,
Digital Logic Design Lecture 19. Announcements Homework 6 due Thursday 11/6 Recitation quiz on Monday, 11/10 – Will cover material from lectures 18,19,20.
Digital Logic Design Lecture 28. Announcements Homework 9 due on Thursday 12/11 Please fill out Course Evaluations online. Final exam will be on Thursday,
ECE 301 – Digital Electronics Introduction to Sequential Logic Circuits (aka. Finite State Machines) and FSM Analysis (Lecture #17)
ECE 331 – Digital Systems Design Introduction to Sequential Logic Circuits (aka. Finite State Machines) and FSM Analysis (Lecture #19)
IKI c-Synthesis of Sequential Logic Bobby Nazief Semester-I The materials on these slides are adopted from: Prof. Daniel Gajski’s transparency.
Zvi Kohavi and Niraj K. Jha 1 Capabilities, Minimization, and Transformation of Sequential Machines.
ECE 331 – Digital Systems Design Sequential Logic Circuits: FSM Design (Lecture #20)
Chapter 5 - Part Sequential Circuit Design Design Procedure  Specification  Formulation - Obtain a state diagram or state table  State Assignment.
Digital Design Lecture 10 Sequential Design. State Reduction Equivalent Circuits –Identical input sequence –Identical output sequence Equivalent States.
Circuit, State Diagram, State Table
CSCE 211: Digital Logic Design Chin-Tser Huang University of South Carolina.
State Machines.
Unit 14 Derivation of State Graphs
Lecture 4 – State Machine Design 9/26/20081ECE Lecture 4.
Lecture 18 More Moore/Mealy machines.
CENG 241 Digital Design 1 Lecture 10 Amirali Baniasadi
Chapter 8 -- Analysis and Synthesis of Synchronous Sequential Circuits.
1 Lecture #12 EGR 277 – Digital Logic Synchronous Logic Circuits versus Combinational Logic Circuits A) Combinational Logic Circuits Recall that there.
ENEE244-02xx Digital Logic Design Lecture 3. Announcements Homework 1 due next class (Thursday, September 11) First recitation quiz will be next Monday,
1 © 2014 B. Wilkinson Modification date: Dec Sequential Logic Circuits Previously, we described the basic building blocks of sequential circuits,
Introduction to State Machine
Fall 2004EE 3563 Digital Systems Design EE3563 Chapter 7, 8, 10 Reading Assignments  7.1, 7.2, 7.3  8.1, ,   8.5.1, 8.5.2,
General model of a sequential network.
1 Finite State Machines (FSMs) Now that we understand sequential circuits, we can use them to build: Synchronous (Clocked) Finite State Machines Finite.
ANALYSIS OF SEQUENTIAL CIRCUITS by Dr. Amin Danial Asham.
Digital Circuits State Reduction and Assignment State Reduction reductions on the number of flip-flops and the number of gates a reduction in the.
DESIGN OF SEQUENTIAL CIRCUITS by Dr. Amin Danial Asham.
1 State Reduction Goal: reduce the number of states while keeping the external input-output requirements unchanged. State reduction example: a: input 0.
1Sequential circuit design Acknowledgement: Most of the following slides are adapted from Prof. Kale's slides at UIUC, USA by Erol Sahin and Ruken Cakici.
Chapter 8 -- Analysis and Synthesis of Synchronous Sequential Circuits.
ENG241 Digital Design Week #7 Sequential Circuits (Part B)
© 2009 Pearson Education, Upper Saddle River, NJ All Rights ReservedFloyd, Digital Fundamentals, 10 th ed Digital Logic Design Dr. Oliver Faust.
Synthesis Synchronous Sequential Circuits synthesis procedure –Word description of problem /hardest; art, not science/ –Derive state diagram & state table.
Sequential Circuit: Design BIL- 223 Logic Circuit Design Ege University Department of Computer Engineering.
1 Lecture #14 EGR 277 – Digital Logic Self-starting counters Counters are considered to be self-starting if all unused counts eventually lead to the correct.
Partitioning of a digital system.
Digital Logic Design Lecture 29. Announcements Homework 9 due today Please fill out Course Evaluations online. Final exam will be on Thursday, Dec. 18.
Partitioning of a digital system.
Week #7 Sequential Circuits (Part B)
SLIDES FOR CHAPTER 15 REDUCTION OF STATE TABLES STATE ASSIGNMENT
ANALYSIS OF SEQUENTIAL CIRCUITS
Lab. on Finite State Machine
Digital Principles and Design Algorithmic State Machines
332:437 Lecture 12 Finite State Machine Design
CENG 241 Digital Design 1 Lecture 11
Instructor: Alexander Stoytchev
State Reduction and State Assignment
Implement FSM with fewest possible states • Least number of flip flops
DESIGN OF SEQUENTIAL CIRCUITS
Instructor: Alexander Stoytchev
Chapter5: Synchronous Sequential Logic – Part 4
EGR 2131 Unit 12 Synchronous Sequential Circuits
Chapter5: Synchronous Sequential Logic – Part 3
Presentation transcript:

Digital Logic Design Lecture 27

Announcements Exams returned at end of lecture Homework 9 is up, due Thursday, 12/11 Recitation quiz on Monday, 12/8 Will cover material from Lectures 26, 27

Agenda Last time: This time: Structure and Operation of Clocked Synchronous Sequential Networks (7.1) Analysis of Clocked Synchronous Sequential Networks (7.2) This time: Modeling Clocked Synchronous Sequential Network Behavior (7.3) State Table Reduction (7.4)

Modeling clocked synchronous sequential network behavior Approach for the synthesis of clocked synchronous sequential networks: State table/state diagram is constructed from word specifications. State reduction technique to obtain a state table with minimum number of states. Transition table is formed by coding the states of the state table. Excitation table is constructed based on the flip-flop types to be used. From the excitation table, the excitation and output expressions for the network are determined. Finally, the logic diagram is drawn.

Examples of Modeling Step

State Diagram for Mealy serial binary adder

State Diagram for Moore serial binary adder

A Sequence Recognizer An output of 1 is to be produced iff the three input symbols following two consecutive input 0’s include at least one 1. At all other times the output is to be 0. The output of 1 is to be coincident with the third input symbol of the three-input-symbol sequence. Upon completing the analysis of the three input symbols followin the pair of 0 inputs, the network is to reset itself and await for another pair of 0’s and then at least one 1 in the following seqence of three input symbols. Since the output is to be coincident with the third input symbol, a Mealy netword is implied. Example: x = 1 z

A Sequence Recognizer

Another Sequence Recognizer Network produces a 1 output iff the current input and the previous three inputs correspond to either 0110 or 1001 0110/1001 Sequence Recognizer The 1 output is to occur at the time of the fourth input of the recognized sequence. Outputs of 0 are to be produced at all other times. A Mealy network model is developed since the output is a function of the current input x. Network is not required to reset upon the occurrence of the fourth input. Sequences may overlap. Example: x = 1 z

Another Sequence Recognizer

Final Example Single input 𝑥 and a single output 𝑧. The output of the network is initially 0. Changes on the next input immediately following each even occurrence of 𝑥=1. The effect of the input is to be delayed by one clock period. The value of 𝑥 during the next clock period does not affect the output of the network at that time. A Moore sequential network is to be realized Example: x = 1 a b c z

Final Example A: The output changes to 0 since the last occurrence of 𝑥=1 was even B: The output remains at 0 since the last occurrence of 𝑥=1 was odd C: The output changes to 1 since the last occurrence of 𝑥=1 was even D: The output remains at 1 since the last occurrence of 𝑥=1 was odd

State Table Reduction

State Table Reduction The state table is a description of the terminal behavior of a clocked synchronous sequential network. During the process of creating the state table, more states may be defined then are really necessary. In analysis of synchronous sequential networks, bin codes for the states were replaced by arbitrary symbols when going from transition table to state table. For synthesis, the opposite process is performed: Arbitrary state symbols are replaced with binary codes. Smaller number of binary digits necessary -> smaller number of flip-flops. Reducing number of states may also simplify the combinational logic.

State Table Reduction Procedure 3-step process: Equivalent pairs of states are determined Sets of equivalent states are established Reduced state table is constructed with one state for each of the sets of equivalent states

Determining Equivalent Pairs of States Recall that given a state table, an input sequence and some starting state, the resulting output sequence can be determined. Assume we run two experiments: One starts in state p The second starts in state q

Determining Equivalent Pairs of States States 𝑝 and 𝑞 are said to be equivalent or indistinguishable 𝑝≡𝑞 iff for all input sequences applied to the two starting states, identical output sequences from both networks result 𝑍 1 ≡ 𝑍 2 . If states 𝑝 and 𝑞 are not equivalent, then they are said to be distinguishable 𝑝≠𝑞 .

Determining Equivalent Pairs of States Theorem: Two states 𝑝 and 𝑞 of a clocked synchronous sequential network are equivalent iff for each combination of values of the input variables Their outputs are identical Their next states are equivalent

Determining Equivalent Pairs of States Proof: First direction: If the states are equivalent, then for each combination of values of the input variables Their outputs are identical Their next states are equivalent Assume there is some input combination such that outputs differ. Then clearly 𝑝≠𝑞. Assume there is some input combination 𝑋 such that next states 𝑝 ′ , 𝑞 ′ are distinguishable. Then by definition of distinguishable, there is some input sequence 𝑋 ′ for states 𝑝 ′ , 𝑞 ′ that produces different output sequences. Thus, 𝑋,𝑋′ is a distinguishing input sequence for 𝑝,𝑞 and so 𝑝≠𝑞.

Determining Equivalent Pairs of States Proof: Second direction If for each combination of values of the input variables Their outputs are identical Their next states are equivalent Then the two states are equivalent. Assume 𝑝,𝑞 are not equivalent. Then there is some input sequence 𝑋=𝑥𝑋′ such that the outputs 𝑍 1 = 𝑧 1 𝑍 ′ 1 and 𝑍 2 = 𝑧 2 𝑍 ′ 2 differ. Assume that 𝑝 ′ ,𝑞′ are the pair of next states on this input. If 𝑧 1 ≠ 𝑧 2 , then condition 1 is not satisfied. If 𝑧 1 = 𝑧 2 , then 𝑋′ must be an input sequence such that the outputs 𝑍 ′ 1 , 𝑍 ′ 2 differ. Then 𝑝 ′ ≠ 𝑞 ′ and condition 2 is not satisfied.

Example of State Table in Which State Reduction can be performed 𝐴≡𝐵? No. Why not? 𝐴≡𝐸? 𝐴≡𝐷? Need to check 𝐵≡𝐹 Circle back to 𝐴≡𝐷 So yes, 𝐴≡𝐷.

Algorithm for Determining Equivalent Pairs of States Uses an implication table 𝑞 1 , …, 𝑞 𝑛 are the states of the state table. There is one cell in the implication table for each pair of distinct cells.

Algorithm for Determining Equivalent Pairs of States Place a × in the 𝑞 𝑖 , 𝑞 𝑗 -cell if the outputs are contradictory for some input. If there are no contradictory outputs then enter the pair of next states for each input. If neither a × nor pairs of states are entered in the cell, then a check mark is inserted (denoting equivalence of the two states). All state pair entries are inspected by the following process: If ( 𝑞 𝑎 , 𝑞 𝑏 ) is an entry in the ( 𝑞 𝑖 , 𝑞 𝑗 )-cell and if the 𝑞 𝑎 , 𝑞 𝑏 -cell contains an × then an × is placed in the the ( 𝑞 𝑖 , 𝑞 𝑗 )-cell and all other entries are ignored. Otherwise, process is repeated on one of these other state pairs. Repeat Step 2 until it is possible to make an entire pass of the implication table without any additional × being entered. If the ( 𝑞 𝑖 , 𝑞 𝑗 )-cell has no × at this time, then 𝑞 𝑖 ≡ 𝑞 𝑗 .

Example of Algorithm

Algorithm for Obtaining the Equivalence Classes of States Starting with the rightmost column of the processed implication table and working toward the left, move to the first column that has a cell that does not contain a ×. Write down the pairs of equivalent states for this column. Move to the next column to the left, column 𝑖, which contains one or more non × cells. If state 𝑖 is equivalent to all members of any set of states in the list, then add state 𝑖 to the set. Otherwise, add to the list the pairwise equivalent states containing state 𝑖. Repeat Step 2 until all columns are examined. Add to the list, as sets consisting of single states, any states that do not appear in one of the other sets in the list.

Example for Implication Table 𝐷,𝐺 𝐷,𝐺 , 𝐵,𝐹 𝐴,𝐷,𝐺 , 𝐵,𝐹 𝐴,𝐷,𝐺 , 𝐵,𝐹 , 𝐶 ,(𝐸)

Constructing the Minimal State Table Original state table is 𝑄 and minimal state table is 𝑃. The set of states making up the equivalence classes are denoted 𝐶 1 , …, 𝐶 𝑠 . The input columns for state tables 𝑃 and 𝑄 are the same and denoted 𝐼 1 , …, 𝐼 𝑚 . Assign a state 𝑝 𝑖 to each of the sets 𝐶 𝑖 for 𝑖=1,2, …, 𝑠. The present state section of table 𝑃 consists of 𝑝 1 , …, 𝑝 𝑠 . To determine the next-state entry in the 𝑝 𝑖 -row, 𝐼 𝑘 -column of table 𝑃: Select any state in the set 𝐶 𝑖 . Use state table 𝑄 to determine its next state for input 𝐼 𝑘 . Next state is in some set 𝐶 𝑗 so table entry is 𝑝 𝑗 Output entries are determined similarly. If the initial state of state table 𝑄 is a member of 𝐶 𝑟 then 𝑝 𝑟 is the initial state of state table 𝑃.

Constructing the Minimal State Table