Lecture 8 Sequential Logic Prof. Sin-Min Lee Department of Computer Science.

Slides:



Advertisements
Similar presentations
COE 202: Digital Logic Design Sequential Circuits Part 2
Advertisements

Lab 2: Finite State Machines CS 3410 Spring 2015.
FSM Design & Implementation
State-machine structure (Mealy)
Review for Exam 2 Using MUXs to implement logic
Analysis of Clocked Sequential Circuits
TOPIC : Finite State Machine(FSM) and Flow Tables UNIT 1 : Modeling Module 1.4 : Modeling Sequential circuits.
EKT 124 / 3 DIGITAL ELEKTRONIC 1
Sequential Logic Design
Sequential Circuits1 DIGITAL LOGIC DESIGN by Dr. Fenghui Yao Tennessee State University Department of Computer Science Nashville, TN.
CSCE 211: Digital Logic Design. Chapter 6: Analysis of Sequential Systems.
Computing Machinery Chapter 5: Sequential Circuits.
1 Lecture 23 More Sequential Circuits Analysis. 2 Analysis of Combinational Vs. Sequential Circuits °Combinational : Boolean Equations Truth Table Output.
How Computers Work Lecture 6 Page 1 How Computers Work Lecture 6 Finite State Machines.
EECC341 - Shaaban #1 Lec # 14 Winter Clocked Synchronous State-Machines Such machines have the characteristics: –Sequential circuits designed.
Give qualifications of instructors: DAP
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)
Sequential Circuit Introduction to Counter
1 Lecture 15 Registers Counters Finite State Machine (FSM) design.
1 Sequential Circuits Registers and Counters. 2 Master Slave Flip Flops.
Lecture 10 Topics: Sequential circuits Basic concepts Clocks
Circuit, State Diagram, State Table
State Machines.
1 Lecture 22 Sequential Circuits Analysis. 2 Combinational vs. Sequential  Combinational Logic Circuit  Output is a function only of the present inputs.
Finite State Machines CT101 – Computing Systems. FSM Overview Finite State Machine is a tool to model the desired behavior of a sequential system. The.
Computer Organization & Programming Chapter 5 Synchronous Components.
The George Washington University School of Engineering and Applied Science Department of Electrical and Computer Engineering ECE122 – Lab 7 Binary Counter.
1 Chapter 2 Introduction To Finite State Machines Presented By: Cecilia Parng Class: C.S. 147 Prof: Sin-Min Lee.
SEQUENTIAL LOGIC By Tom Fitch. Types of Circuits Combinational: Gates Combinational: Gates Sequential: Flip-Flops Sequential: Flip-Flops.
DLD Lecture 26 Finite State Machine Design Procedure.
A sequential logic circuit (a.k.a. state machine) consists of both combinational logic circuit(s) and memory devices (flip flops). The combinational circuits.
© 2009 Pearson Education, Upper Saddle River, NJ All Rights ReservedFloyd, Digital Fundamentals, 10 th ed Digital Logic Design Dr. Oliver Faust.
Sequential Logic Flip-Flop Circuits By Dylan Smeder.
Logic Design (CE1111 ) Lecture 6 (Chapter 6) Registers &Counters Prepared by Dr. Lamiaa Elshenawy 1.
COMBINATIONAL AND SEQUENTIAL CIRCUITS Guided By: Prof. P. B. Swadas Prepared By: BIRLA VISHVAKARMA MAHAVDYALAYA.
Chapter 3 Boolean Algebra and Digital Logic T103: Computer architecture, logic and information processing.
Mealy and Moore Machines Lecture 8 Overview Moore Machines Mealy Machines Sequential Circuits.
Synchronous Counters, ripple counter & other counters Lecture 2
FSM Design & Implementation
ANALYSIS OF SEQUENTIAL CIRCUITS
Introduction to Advanced Digital Design (14 Marks)
Sequential Logic Counters and Registers
Figure 12-13: Synchronous Binary Counter
FIGURE 5.1 Block diagram of sequential circuit
Sequential Circuit: Counter
Digital Design Lecture 9
Overview Introduction Logic Gates Flip Flops Registers Counters
Overview Instruction Codes Computer Registers Computer Instructions
Digital Logic & Design Dr. Waseem Ikram Lecture No. 30.
Asynchronous Inputs of a Flip-Flop
ECE 301 – Digital Electronics
FINITE STATE MACHINES (FSMs)
CENG 241 Digital Design 1 Lecture 11
Jeremy R. Johnson Mon. Apr. 3, 2000
Digital Logic & Design Dr. Waseem Ikram Lecture No. 34.
CSE 140L Discussion Finite State Machines.
Electronics II Physics 3620 / 6620
Recap D flip-flop based counter Flip-flop transition table
Digital Logic & Design Dr. Waseem Ikram Lecture No. 31.
CSE 370 – Winter Sequential Logic-2 - 1
CSE 370 – Winter Sequential Logic-2 - 1
Lecture 17 Logistics Last lecture Today HW5 due on Wednesday
Lecture No. 32 Sequential Logic.
SYEN 3330 Digital Systems Chapter 6 – Part 3 SYEN 3330 Digital Systems.
Systems Architecture I
ANALYSIS OF SEQUENTIAL CIRCUIT LOGIC DIAGRAM
Lecture 17 Logistics Last lecture Today HW5 due on Wednesday
Lecture 22 Logistics Last lecture Today HW7 is due on Friday
Lecture 22 Logistics Last lecture Today HW7 is due on Friday
Presentation transcript:

Lecture 8 Sequential Logic Prof. Sin-Min Lee Department of Computer Science

Implement D Flip-flop by T Flip-flop DT Q Q T = D Q’ + D’ Q D D’ T

Implement JK Flip-flop by D Flip-flop J K Q D = J Q’ + K’ Q D 0 1 J K Q DQ+Q J K Q Q’

Implement JK Flip-flop by T Flip-flop J K Q T = J Q’ + K Q T 0 1 J K TQ+Q Q Q’ J K Q Q Q+Q+ J KQ+Q Q 0 1 Q’

Implement T Flip-flop by JK Flip-flop 0 X 1 X X 1 X 0 J K T Q Q Q+ 0 1 T Q X 1 X 0 1 T Q 0101 X 0 X J = T K = T

Random-Access Memory Can read and write at any point in memory Implemented using D Flip-Flops Each row contains 16 Flip-Flops A Decoder

Binary Counter Holds each pulse in memory Each pulse add another number Binary format

Register Used to hold one item of information CPU’s have many registers AX is an example in Assembly

Clocks and Sequencers To perform operations a CPU often requires a specific sequence of sub operations A sequencer is used to make sure operations happen in correct order A clock is a circuit that outputs 0’s and 1’s at specific frequencies

Real World Application The RAM discussed is a model for a chip that can actually be found in a computer The binary counter can be bought at tronics.com/webtronics/74hc161n.html for 45 cents each tronics.com/webtronics/74hc161n.html The Flip-Flop circuits are models of usable chips

State Diagrams A state diagram: –Each state is represented by a circled vertex –Each row of the state table is shown as directed arc J’ Y

Important Rule for State Diagram State diagram has same situation as state table. Their conditions should be mutually exclusive, no input values should meet the condition of more than one arc.

The Alarm Clock Present state AlarmWeekdayNext state Turn off alarm OnXAwake in bed YesAsleep Awake in bedOffYes Awake and up No Awake in bed Off No AsleepNo

State Diagram for The Alarm Clock (a) Awake in bedAsleep Alarm’ Alarm Awake and up 1 (Always) Alarm Alarm’ /\ Weekday’ Alarm’ /\ Weekday Turn off Alarm = Yes ( a )

The alarm clock problem with inaction states Present stateAlarmWeekdayNext stateTurn off alarm AsleepOffX Asleep No Asleep On Awake in bed Yes Awake in bed On X Awake in bed yes Awake in bed OffYesAwake and upNo Awake in bedOffNoAsleep No Awake and upX X No X

State Diagram for The Alarm Clock State Diagram for The Alarm Clock (b) ( b ) AsleepAwake in bed Awake and up Alarm’ / 0 Alarm / 1 Alarm’ /\ Weekday’ / 0 1 (Always) / 0 Alarm’ /\ Weekday / 0 Alarm / 1 1 = yes turn off alarm (output) 0 – no turn off alarm (output)

State Tables for The JK Flip-Flop ( a ) Present State Y Z Z Z Z Y Y Y JK Next StateQ Y Y Z Z Z Y Z Y

Condition in Terms of J and K Z J K J’K’ Q=0 Q=1 Y

Mealy and Moore Machines A finite state machine can represent outputs in one of two ways –Moore Machines –Mealy Machines

Moore Machines –Moore Machines Associates its outputs with the states. Output values depend only on the state and not on the transitions. It requires less hardware to produce the output values It is well suited for representing the control units of microprocessors and cpu.

State Diagram for The Alarm Clock (a) Awake in bedAsleep Alarm’ Alarm Awake and up 1 (Always) Alarm Alarm’ /\ Weekday’ Alarm’ /\ Weekday Turn off Alarm = Yes Moore Machine

Mealy Machines –Mealy Machines Associates outputs with the transitions. It depends on both its state and its input values

State Diagram for The Alarm Clock State Diagram for The Alarm Clock (b) Mealy Machine AsleepAwake in bed Awake and up Alarm’ / 0 Alarm / 1 Alarm’ /\ Weekday’ / 0 1 (Always) / 0 Alarm’ /\ Weekday / 0 Alarm / 1

Designing State Diagrams Counter String Checker Toll Booth

Modulo 6 Counter A modulo 6 counter is a 3-bit counter that counts through the sequence. – … – … Unlike a regular 3-bit counter 110(6) and 111(7) do not count

State Table for The Modulo 6 Counter Present StateNext StateCV 2 V 1 V 0 U S0S0 S0S0 S1S1 S1S1 S2S2 S2S2 S3S3 S3S3 S4S4 S4S4 S5S5 S5S S0S0 S1S1 S1S1 S2S2 S2S2 S3S3 S3S3 S4S4 S4S4 S5S5 S5S5 S0S

State Diagram for The Modulo 6 Counter (Mealy) S0S0 S5S5 S1S1 S4S4 S2S2 S3S3 0 / / / / / / / / / / / / 1000 ( a ) Mealy

State Diagram for The Modulo 6 Counter (Moore) S5S5 S0S0 S1S1 S4S4 S2S2 S3S3 U’ C=1 V =000 U C=0 V=0010 U C=0 V=010 U C=0 V=011 U C=0 V=100 U C=0 V=101 ( b ) Moore

String Checker A String Checker inputs a string of bits, one bits per clock cycle. It checks bits 1,2, and 2, then 2,3,and 4 and so forever

State Table For String Checker Present State S 0 S1 S 2 S 3 S 4 S 5 S 6 S LNext State S0S1S2S3S4S5S6S7S0S1S2S3S4S5S6S7S0S1S2S3S4S5S6S7S0S1S2S3S4S5S6S7 M

State Diagrams for the String Checker ( Mealy) S3S3 S7S7 S0S0 S1S1 S4S4 S6S6 S5S5 S2S2 0/0 1/0 0/0 1/0 0/1 1/0 Mealy

State Diagrams for the String Checker (Moore) S7S7 S0S0 S6S6 S5S5 S4S4 S3S3 S2S2 S1S1 M=1 I’ M=0 I’ M=0 I I I I I’ I I I I M=0 Moore