Week 4: Sequential Circuits

Similar documents
Chapter 5 Sequential Circuits

D Latch (Transparent Latch)

(CSC-3501) Lecture 7 (07 Feb 2008) Seung-Jong Park (Jay) CSC S.J. Park. Announcement

6. Sequential Logic Flip-Flops

Chapter 8 Sequential Circuits

Synchronous Sequential Logic

Rangkaian Sekuensial. Flip-flop

Lecture 8: Sequential Logic

Flip-Flops. Because of this the state of the latch may keep changing in circuits with feedback as long as the clock pulse remains active.

Chapter 6 Sequential Circuits

Unit 9 Latches and Flip-Flops. Dept. of Electrical and Computer Eng., NCTU 1

Last time, we saw how latches can be used as memory in a circuit

RS flip-flop using NOR gate

COMP sequential logic 1 Jan. 25, 2016

Chapter 5 Sequential Circuits

Name Of The Experiment: Sequential circuit design Latch, Flip-flop and Registers

EMT 125 Digital Electronic Principles I CHAPTER 6 : FLIP-FLOP

Sequential Circuits. Introduction to Digital Logic. Course Outline. Overview. Introduction to Digital Logic. Introduction to Sequential Circuits

Digital Circuits ECS 371

Logic Design ( Part 3) Sequential Logic (Chapter 3)

Chapter 6. Flip-Flops and Simple Flip-Flop Applications

UNIT IV. Sequential circuit

12/31/2010. Overview. 12-Latches and Flip Flops Text: Unit 11. Sequential Circuits. Sequential Circuits. Feedback. Feedback

Overview of Chapter 4

Chapter. Synchronous Sequential Circuits

COE 202: Digital Logic Design Sequential Circuits Part 1. Dr. Ahmad Almulhem ahmadsm AT kfupm Phone: Office:

Unit 11. Latches and Flip-Flops

We are here. Assembly Language. Processors Arithmetic Logic Units. Finite State Machines. Circuits Gates. Transistors

ECE 25 Introduction to Digital Design. Chapter 5 Sequential Circuits ( ) Part 1 Storage Elements and Sequential Circuit Analysis

ELCT201: DIGITAL LOGIC DESIGN

(Refer Slide Time: 2:05)

`COEN 312 DIGITAL SYSTEMS DESIGN - LECTURE NOTES Concordia University

UNIT 11 LATCHES AND FLIP-FLOPS

Sequential Logic and Clocked Circuits

DALHOUSIE UNIVERSITY Department of Electrical & Computer Engineering Digital Circuits - ECED 220. Experiment 4 - Latches and Flip-Flops

FLIP-FLOPS AND RELATED DEVICES

ELCT201: DIGITAL LOGIC DESIGN

Sequential Digital Design. Laboratory Manual. Experiment #3. Flip Flop Storage Elements

COMP2611: Computer Organization. Introduction to Digital Logic

A clock is a free-running signal with a cycle time. A clock may be either high or low, and alternates between the two states.

RS flip-flop using NOR gate

LATCHES & FLIP-FLOP. Chapter 7

LAB #4 SEQUENTIAL LOGIC CIRCUIT

cascading flip-flops for proper operation clock skew Hardware description languages and sequential logic

Sequentielle Schaltelemente

Chapter 3 Unit Combinational

Chapter 1: Switching Algebra Chapter 2: Logical Levels, Timing & Delays. Introduction to latches Chapter 9: Binary Arithmetic

The NOR latch is similar to the NAND latch

Chapter 11 Latches and Flip-Flops

Module for Lab #16: Basic Memory Devices

EKT 121/4 ELEKTRONIK DIGIT 1

Introduction to Sequential Circuits

ASYNCHRONOUS SEQUENTIAL CIRCUIT CONCEPTS

CHAPTER 1 LATCHES & FLIP-FLOPS

Engr354: Digital Logic Circuits

Computer Science 324 Computer Architecture Mount Holyoke College Fall Topic Notes: Sequential Circuits

Sequential Logic Circuits

Review of digital electronics. Storage units Sequential circuits Counters Shifters

MUX AND FLIPFLOPS/LATCHES

DIGITAL CIRCUIT LOGIC UNIT 11: SEQUENTIAL CIRCUITS (LATCHES AND FLIP-FLOPS)

Introduction to Microprocessor & Digital Logic

Introduction. NAND Gate Latch. Digital Logic Design 1 FLIP-FLOP. Digital Logic Design 1

Chapter 5 Synchronous Sequential Logic

Other Flip-Flops. Lecture 27 1

ECE 341. Lecture # 2

Logic Design ( Part 3) Sequential Logic- Finite State Machines (Chapter 3)

Sequential Logic. E&CE 223 Digital Circuits and Systems (A. Kennings) Page 1

Sequential Design Basics

Digital Logic Design Sequential Circuits. Dr. Basem ElHalawany

Computer Science 324 Computer Architecture Mount Holyoke College Fall Topic Notes: Sequential Circuits

Sequential Logic Basics

Part 4: Introduction to Sequential Logic. Basic Sequential structure. Positive-edge-triggered D flip-flop. Flip-flops classified by inputs

Problems with D-Latch

Digital Fundamentals: A Systems Approach

INTRODUCTION TO SEQUENTIAL CIRCUITS

Switching Circuits & Logic Design

Clocks. Sequential Logic. A clock is a free-running signal with a cycle time.

YEDITEPE UNIVERSITY DEPARTMENT OF COMPUTER ENGINEERING. EXPERIMENT VIII: FLIP-FLOPS, COUNTERS 2014 Fall

CPS311 Lecture: Sequential Circuits

Sequential Circuits: Latches & Flip-Flops

Combinational vs Sequential

COSC 243. Sequential Logic. COSC 243 (Computer Architecture) Lecture 5 - Sequential Logic 1

Chapter 5 Flip-Flops and Related Devices

Sequential Circuits. Output depends only and immediately on the inputs Have no memory (dependence on past values of the inputs)

Chapter 4. Logic Design

ELE2120 Digital Circuits and Systems. Tutorial Note 7

Logic Design. Flip Flops, Registers and Counters

The outputs are formed by a combinational logic function of the inputs to the circuit or the values stored in the flip-flops (or both).

NAME SYMBOL CHARACTERISTIC TABLE EXCITATION TABLE. S R Q(next) 0 0 Q. (hold) (reset) (set) 1 1? (undefined) J K Q(next) (hold) (reset) (set) 1 1 Q'

CHAPTER 11 LATCHES AND FLIP-FLOPS

CS 261 Fall Mike Lam, Professor. Sequential Circuits

MC9211 Computer Organization

Physics 323. Experiment # 10 - Digital Circuits

NH 67, Karur Trichy Highways, Puliyur C.F, Karur District UNIT-III SEQUENTIAL CIRCUITS

Introduction to Digital Logic Missouri S&T University CPE 2210 Flip-Flops

Final Exam review: chapter 4 and 5. Supplement 3 and 4

Digital Logic Design ENEE x. Lecture 19

Chapter 5: Synchronous Sequential Logic

Basis of sequential circuits: the R-S latch

(Refer Slide Time: 2:00)

Transcription:

Week 4: equential ircuits

omething to consider omputer specs use terms like 8 GB of AM and 2.2GHz processors. ú What do these terms mean? AM = andom Access Memory; 8GB = 8 billion ints 2.2 GHz = 2.2 billion clock pulses per second. ú But what does this mean in circuitry? How do you use circuits to store values? What is the purpose of a clock signal?

omething else to consider How does Tickle Me Elmo work?

Two kinds of circuits o far, we ve dealt with combinational circuits: ú ircuits where the output values are entirely dependent and predictable from the input values. Another class of circuits: sequential circuits ú ircuits that also depend on both the inputs and the previous state of the circuit.

equential circuits This creates circuits whose internal state can change over time, where the same input values can result in different outputs. Why would we need circuits like this? ú Memory values ú eacting to changing inputs

reating sequential circuits Essentially, sequential circuits are a result of having feedback in the circuit. ú How is this accomplished? ú What is the result of having the output of a component or circuit be connected to its input? Inputs Inputs ircuit Feedback ombinational ircuit torage Units Outputs Outputs

Feedback ircuit Examples ome gates don t have useful results when outputs are fed back on inputs. A A A T T+ 0 0 0 0 0 0 0 A T T+ 0 0 0 0 0 In these truth tables, T and T+ represent the values of at a time T, and a point in time immediately after (T+)

Feedback Examples Others have more interesting characteristics, which lend themselves to storage devices. A A A T T+ 0 0 0 0 0 A T T+ 0 0 0 0 0 0 0

Feedback behaviour NAN behaviour NO behaviour A T T+ 0 0 0 0 0 A T T+ 0 0 0 0 0 0 0 What makes NAN and NO feedback circuits different? Unlike the AN and O gate circuits (which get stuck), the output T+ can be changed, based on A. However, gates like these that feed back on themselves could enter an unsteady state.

NAN waveform behaviour A A T T+ 0 0 0 0 0 A

Latches If multiple gates of these types are combined, you can get more steady behaviour. A A B B These circuits are called latches.

latch Let s see what happens when the input values are changed ú Assume that and are set to and 0 to start. ú The input sets the output to, which sets the output to 0. ú etting to keeps the output value at, which maintains both output values. 0 0 0

latch 0 0 (continuing from previous) ú and start with values of, when is set to 0. ú This sets output to, which sets the output to 0. ú etting back to keeps the output value at 0, which maintains both output values. Note: inputs of maintain the previous output state! 0 0 0

latch T T T+ T+ 0 0 X X 0 X X 0 0 X X 0 0 0 0 0 and are called set and reset respectively. Note how the circuit remembers its signal when going from 0 or 0 to. Going from 00 to produces unstable behaviour! ú epending on which input changes first.

latch T T T+ T+ 0 0 0 0 0 0 0 0 0 X X 0 0 X X 0 X X 0 0 In this case, and are set and reset. In this case, the circuit remembers previous output when going from 0 or 0 to 00. As with latch, unstable behaviour is possible, but this time when inputs go from to 00.

latch timing diagram Important to note that the output signals don t change instantaneously.

More on instability Unstable behaviour occurs when a latch goes from 00 to, or a latch goes from to 00. ú The signals don t change simultaneously, so the outcome depends on which signal changes first. Because of the unstable behaviour, 00 is considered a forbidden state in NAN-based latches, and is considered a forbidden state in NO-based latches.

eading from latches Now we have circuit units that can store high or low values. How can we read from them? ú For instance, when do we know when the output is ready to be sampled? ú If the output is high, how can we tell the difference between a single high value and two high values in a row? Need some sort of timing signal, to let the circuit know when the output may be sampled. à clock signals.

Break

lock signals locks are a regular pulse signal, where the high value indicates that the output of the latch may be sampled. Usually drawn as: voltage 5V But looks more like: time

ignal restrictions What s the limit to how fast the latch circuit can be sampled? etermined by: ú latency time of transistors etup and hold time ú setup time for clock signal Jitter Gibbs phenomenon Frequency = how many pulses occur per second, measured in Hertz (or Hz).

locked latch By adding another layer of NAN gates to the latch, we end up with a clocked latch circuit. The clock is often connected to a pulse signal that alternates regularly between 0 and.

locked latch behaviour ame behaviour as latch, but with timing: ú tart off with =0 and =, like earlier example. ú If clock is high, the first NAN gates invert those values, which get inverted again in the output. ú etting both inputs to 0 maintains the output values. 0 0 0 0 0 0 0

locked latch behaviour ontinued from previous: ú Now set the clock low. ú Even if the inputs change, the low clock input prevents the change from reaching the second stage of NAN gates. ú esult: the clock needs to be high in order for the inputs to have any effect. 0 0 0 0 0 0 0 0

locked latch This is the typical symbol for a clocked latch. This only allows the and signals to affect the circuit when the clock input () is high. Note: the small NOT circle after the output is simply the notation to use to denote the inverted output value. It s not an extra NOT gate.

locked latch behaviour T T+ esult 0 0 0 0 no change 0 0 0 reset 0 0 set 0???? 0 0 no change Assuming the clock is, we still have a problem when and are both, since the state of is indeterminate. 0 0 reset 0 set???? ú Alternative design: prevent and from both going high.

latch T T+ 0 0 0 0 0 0 By making the inputs to and dependent on a single signal, you avoid the indeterminate state problem. The value of now sets output low or high.

latch This design is good, but still has problems. ú i.e. timing issues.

Latch timing issues onsider the circuit on the right: When the clock signal is high, the output looks like the waveform below: ú Output keeps toggling back and forth.

Latch timing issues Preferable behaviour: ú Have output change only once when the clock pulse changes. ú olution: create disconnect between circuit output and circuit input, to prevent unwanted feedback and changes to output.

master-slave flip-flop A flip-flop is a latched circuit whose output is triggered with the rising edge or falling edge of a clock pulse. Example: The master-slave flip-flop 0 0

master-slave flip-flop 0 0 0 0

Edge-triggered flip-flop flip-flops still have issues of unstable behaviour. olution: flip-flop ú onnect latch to the input of a latch. ú Negative-edge triggered flip-flop (like the )

Flip-flop behaviour Observe the behaviour: ú If the clock signal is high, the input to the first flip-flop is sent out to the second. ú The second flip-flop doesn t do anything until the clock signal goes down again. ú When it clock goes from high to low, the first flip-flop stops transmitting a signal, and the second one starts. 0 0 0 0 0 0 0 Z Z 0

Flip-flop behaviour ontinued from previous: ú If the input to changes, the change isn t transmitted to the second flip-flop until the clock goes high again. ú Once the clock goes high, the first flip-flop starts transmitting at the same time as the second flipflop stops. 0 0 0 0 0 0 0 0

onfused yet? Maybe a demonstration will help

Edge-triggered flip-flop Alternative: positive-edge triggered flip-flops These are the most commonly-used flip-flop circuits (and our choice for the course).

Notation Latches with ontrol with 0 ontrol Master-slave flip-flops Triggered Triggered Triggered Triggered Edge-triggered flip-flops Triggered Triggered Note: While all these are possible, we mainly use edgetriggered flip-flops in our designs.

Other Flip-Flops The T flip-flop: ú Like the flip-flop, except that it toggles its value whenever the input to T is high.

Other Flip-Flops The JK Flip-Flop: ú Takes advantage of all combinations of two inputs (J & K) to produce four different behaviours: if J and K are 0, maintain output. if J is 0 and K is, set output to 0. if J is and K is 0, set output to. if J and K are, toggle output value.

equential circuit design imilar to creating combinational circuits, with extra considerations: ú The flip-flops now provide extra inputs tothe circuit Inputs ú Extra circuitry needs to be designed for the flip-flop inputs. ú which is next week s lecture J ombinational ircuit torage Units Outputs