Finite State Machines Mealy machine inputs Outputs next state function

Slides:



Advertisements
Similar presentations
ENGIN112 L23: Finite State Machine Design Procedure October 27, 2003 ENGIN 112 Intro to Electrical and Computer Engineering Lecture 23 Finite State Machine.
Advertisements

Introduction to Sequential Circuits
Chapter #10: Finite State Machine Implementation
TOPIC : Finite State Machine(FSM) and Flow Tables UNIT 1 : Modeling Module 1.4 : Modeling Sequential circuits.
COE 202: Digital Logic Design Sequential Circuits Part 3
Circuits require memory to store intermediate data
1 EE365 Sequential-circuit analysis. 2 Clocked synchronous seq. circuits A.k.a. “state machines” Use edge-triggered flip-flops All flip-flops are triggered.
ECE 331 – Digital System Design Introduction to and Analysis of Sequential Logic Circuits (Lecture #20) The slides included herein were taken from the.
ECE C03 Lecture 101 Lecture 10 Finite State Machine Design Hai Zhou ECE 303 Advanced Digital Design Spring 2002.
Dr. Turki F. Al-Somani VHDL synthesis and simulation – Part 3 Microcomputer Systems Design (Embedded Systems)
Contemporary Logic Design Finite State Machine Design © R.H. Katz Transparency No Chapter #8: Finite State Machine Design 8.5 Finite State Machine.
Give qualifications of instructors: DAP
George Mason University ECE 448 – FPGA and ASIC Design with VHDL Finite State Machines State Diagrams, State Tables, Algorithmic State Machine (ASM) Charts,
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)
IC-UNICAMP MC 603/ Finite State Machines Mixed Style RTL Modeling Extraído da George Mason Univ. ECE 545 Lecture 5.
Lecture 17 General finite state machine (FSM) design
Lecture 10 Topics: Sequential circuits Basic concepts Clocks
1 COMP541 State Machines Montek Singh Feb 8, 2012.
EE434 ASIC & Digital Systems
Sequential Logic Materials taken from: Digital Design and Computer Architecture by David and Sarah Harris & The Essentials of Computer Organization and.
George Mason University ECE 545 – Introduction to VHDL ECE 545 Lecture 5 Finite State Machines.
Lecture 18 More Moore/Mealy machines.
Introduction to Sequential Logic Design Finite State-Machine Design.
Module : FSM Topic : types of FSM. Two types of FSM The instant of transition from the present to the next can be completely controlled by a clock; additionally,
Lecture 5. Sequential Logic 2 Prof. Taeweon Suh Computer Science Education Korea University 2010 R&E Computer System Education & Research.
FINITE STATE MACHINES (FSMs)
DLD Lecture 26 Finite State Machine Design Procedure.
ANALYSIS OF SEQUENTIAL CIRCUITS by Dr. Amin Danial Asham.
Sequential Circuit: Analysis BIL- 223 Logic Circuit Design Ege University Department of Computer Engineering.
VHDL Discussion Finite State Machines
Analysis and Synthesis of Synchronous Sequential Circuits A “synchronizing” pulse/edge signal (clock) controls the operation of the memory portion of the.
VHDL Discussion Finite State Machines IAY 0600 Digital Systems Design Alexander Sudnitson Tallinn University of Technology 1.
Registers; State Machines Analysis Section 7-1 Section 5-4.
Digital System Design using VHDL

1 COMP541 Finite State Machines - 1 Montek Singh Sep 22, 2014.
© 2009 Pearson Education, Upper Saddle River, NJ All Rights ReservedFloyd, Digital Fundamentals, 10 th ed Digital Logic Design Dr. Oliver Faust.
ECE 448 Lecture 6 Finite State Machines State Diagrams vs. Algorithmic State Machine (ASM) Charts.
Introduction to Sequential Logic Design Finite State-Machine Analysis.
Computer Organization CS345 David Monismith Based upon notes by Dr. Bill Siever and notes from the Patterson and Hennessy Text.
State Machine Design State Machine Design Digital Electronics
Finite State Machine. Clock Clock cycle Sequential circuit Digital logic systems can be classified as combinational or sequential. – Combinational circuits.
Govt. Engineering College- Gandhinagar. It is all about……  STATE MACHINE.
1 COMP541 Sequential Logic – 2: Finite State Machines Montek Singh Feb 29, 2016.
George Mason University Finite State Machines Refresher ECE 545 Lecture 11.
Exp#7 Finite State Machine Design in Verilog COE203 Digital Logic Laboratory Dr. Ahmad Almulhem KFUPM Spring 2009.
Finite State Machines (part 1)
Sequential Networks and Finite State Machines
Lecture 4. Sequential Logic #2
Introduction to Sequential Logic Design
ECE 448 Lecture 6 Finite State Machines State Diagrams, State Tables, Algorithmic State Machine (ASM) Charts, and VHDL Code.
Introduction Introduction to VHDL Entities Signals Data & Scalar Types
COMP541 Sequential Logic – 2: Finite State Machines
ECE 448 Lecture 6 Finite State Machines State Diagrams vs. Algorithmic State Machine (ASM) Charts.
FINITE STATE MACHINES (FSMs)
Sequential Networks and Finite State Machines
Analysis of Synchronous Sequential Circuits
EEL 3705 / 3705L Digital Logic Design
Introduction to Sequential Circuits
Analysis of Synchronous Sequential Circuits
April 3 Fun with MUXes Implementing arbitrary logical functions
Finite State Machines (part 1)
ECE 448 Lecture 6 Finite State Machines State Diagrams, State Tables, Algorithmic State Machine (ASM) Charts, and VHDL Code.
Lecture 20 Logistics Last lecture Today HW6 due Wednesday
ECE 448 Lecture 6 Finite State Machines State Diagrams, State Tables, Algorithmic State Machine (ASM) Charts, and VHDL code ECE 448 – FPGA and ASIC Design.
Instructor: Alexander Stoytchev
ECE 448 Lecture 6 Finite State Machines State Diagrams vs. Algorithmic State Machine (ASM) Charts.
Finite State Machine Continued
Lecture 4: Finite State Machines
Presentation transcript:

Finite State Machines Mealy machine inputs Outputs next state function current state next state function output function Outputs inputs clock next state function: Fnext state ( I, S(i) )  S(i+1) output function: Foutput ( I, S(i) )  O(i) S(i) - Current state

Example -- Traffic Lights Controller The controller operates the traffic lights at one intersection. Detectors in both directions provide input signals to controllers: car approaching NS / car approaching EW. Outputs control the traffic light: set to green / set to red. When cars approach in both directions, toggle the light. The controller needs two states, green/red. state(i) carNS carEW state(i+1) NSgo no no NSgo NSgo no yes EWgo NSgo yes no NSgo NSgo yes yes EWgo EWgo no no EWgo EWgo no yes EWgo EWgo yes no NSgo EWgo yes yes NSgo A state/output table is used to construct the controller

State Diagram NSgo EWgo carEW or both directions NSgo EWgo carNS or both directions carNS or nothing carEW or nothing Calculate next state transitions using the table and Boolean identities This example is a Moore machine  the outputs are a function only of the state. In this case the output function is trivial: In state NSgo we want a signal for a NS green light. In state EWgo we want a signal for an EW green light.

Moore and Mealy Machines Both these machine types follow the basic characteristics of state machines, but differ in the way that outputs (not next state) are produced. Moore Machine: Outputs are independent of the inputs, i. e. outputs are effectively produced from within only the state of the state machine. Mealy Machine: Outputs can be determined by the present state alone, or by the present state and the present inputs, i. e. outputs are produced as the machine makes a transition from one state to another.

Machine Models Moore Machine Mealy Machine Inputs Combinatorial Logic to Determine State Present State Register Bank Determine Output Based on: Output Moore Machine Inputs Combinatorial Logic to Determine State Present State Register Bank Determine Output Based on: Present Inputs Output Mealy Machine

Advantages of Mealy FSM Moore and Mealy FSMs Can Be Functionally Equivalent. Mealy FSM Has a Richer Description and Usually Requires Smaller Number of States Smaller circuit area. Mealy FSM Computes Outputs as soon as Inputs Change Mealy FSM responds one clock cycle sooner than equivalent Moore FSM.

Advantages of Moore FSM Moore FSM Has No Combinational Path Between Inputs and Outputs. output changes only when clock ends  short inputs that temporarily generated during the clock cycles will be ignored.

Moore FSM that Recognizes Sequence 10 1 reset S0: No elements of the sequence observed S1: “1” observed S1: “10” observed Meaning of states:

Mealy FSM that Recognizes Sequence 10 0 / 0 1 / 0 1 / 0 S0 S1 reset 0 / 1 S0: No elements of the sequence observed S1: “1” observed Meaning of states:

Moore & Mealy Time Line clock input 0 1 0 0 0 Moore S0 S1 S2 S0 S0 0 1 0 0 0 Moore S0 S1 S2 S0 S0 Mealy S0 S1 S0 S0 S0

Finite State Machine Any circuit with memory is a Finite State Machine Even computers can be viewed as huge FSMs Design of FSMs Involves Defining states Defining transitions between states Optimization / minimization

Implementation Finite state machine with a state variable Outputs Combinational Logic State Register inputs

General Digital System Control control lines Combinational Logic Architecture State Register CLOCK Opcode

Finite State Machine: Conclusion State Diagram Illustrates the form and function of a state machine. Usually drawn as a bubble-and-arrow diagram. State A uniquely identifiable set of values measured at various points in a digital system. Next State The state to which the state machine makes the next transition, determined by the inputs present when the device is clocked. Mealy Machine A state machine that determines its outputs from the present state and from the inputs. Moore Machine A state machine that determines its outputs from the present state only.