You are on page 1of 10

Week 12

Finite State Machines

Part 1
Week 12: Finite State Machines 1

Learning Outcomes
1. Differentiate a Moore machine from a Mealy machine.
2. Use FSM to design synchronous sequential circuits
3. Sketch state transition diagrams for systems under consideration
4. Produce state transition tables, state encodings, and output encodings for systems
under consideration
Week 12: Finite State Machines 1

Finite State Machines (FSMs)


• Consists of two blocks of combinational logic
• Next state and output logic
• Register
• Provide a systematic way to design synchronous sequential circuits
• Two general classes
• Moore machines – outputs depend only on current state of machine
• Mealy machines – outputs depend on both current state & current inputs
Week 12: Finite State Machines 1

FSM Design Example


• Ben wants to solve the traffic problem on Academic Ave. and Bravado Blvd. He
installs two traffic sensors that indicate TRUE when students are present, and
FALSE when the streets are empty. He also installs two traffic lights to control traffic.
He uses FSM to design the traffic controller that takes in the sensor inputs and in
turn responds with the appropriate traffic light color.

Black box view of FSM


Campus Map
Week 12: Finite State Machines 1

FSM Design Example

State transition diagram State transition diagrm


Week 12: Finite State Machines 1

FSM Design Example

State encoding Output encoding


Week 12: Finite State Machines 1

FSM Design Example


Simplified next state equations:
𝑆′1 = 𝑆1 ⊕ 𝑆0
𝑆′0 = 𝑆1ҧ 𝑆0ҧ 𝑇ത𝐴 + 𝑆1 𝑆0ҧ 𝑇ത𝐵

State transition table with binary encodings


Week 12: Finite State Machines 1

FSM Design Example


Output logic equations:
𝐿𝐴1 = 𝑆1
𝐿𝐴0 = 𝑆1ҧ 𝑆0
𝐿𝐵1 = 𝑆1ҧ
𝐿𝐵0 = 𝑆1 𝑆0

Output table
Week 12: Finite State Machines 1

FSM Design Example

State machine circuit for traffic light controller


Thank You!

You might also like