Chapter 5 Sequential Circuits

Similar documents
Chapter 5 Sequential Circuits

Chapter. Synchronous Sequential Circuits

Other Flip-Flops. Lecture 27 1

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

CSE Latches and Flip-flops Dr. Izadi. NOR gate property: A B Z Cross coupled NOR gates: S M S R Q M

CHAPTER 4: Logic Circuits

1. a) For the circuit shown in figure 1.1, draw a truth table showing the output Q for all combinations of inputs A, B and C. [4] Figure 1.

Unit 11. Latches and Flip-Flops

Digital Logic Design Sequential Circuits. Dr. Basem ElHalawany

The word digital implies information in computers is represented by variables that take a limited number of discrete values.

CHAPTER 4: Logic Circuits

1. Convert the decimal number to binary, octal, and hexadecimal.

Introduction to Sequential Circuits

Chapter 5 Synchronous Sequential Logic

Combinational vs Sequential

Chapter 8 Sequential Circuits

Sequential Circuits: Latches & Flip-Flops

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

ELCT201: DIGITAL LOGIC DESIGN

Sequential Logic Circuits

LATCHES & FLIP-FLOP. Chapter 7

ELCT201: DIGITAL LOGIC DESIGN

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

Section 6.8 Synthesis of Sequential Logic Page 1 of 8

Chapter 5 Sequential Circuits

EE292: Fundamentals of ECE

MC9211 Computer Organization

RS flip-flop using NOR gate

Department of Electrical and Computer Engineering Mid-Term Examination Winter 2012

Logic and Computer Design Fundamentals. Chapter 7. Registers and Counters

AIM: To study and verify the truth table of logic gates

EXPERIMENT: 1. Graphic Symbol: OR: The output of OR gate is true when one of the inputs A and B or both the inputs are true.

B.Tech CSE Sem. 3 15CS202 DIGITAL SYSTEM DESIGN (Regulations 2015) UNIT -IV

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

Lecture 8: Sequential Logic

`COEN 312 DIGITAL SYSTEMS DESIGN - LECTURE NOTES Concordia University

Digital Design, Kyung Hee Univ. Chapter 5. Synchronous Sequential Logic

Chapter 5: Synchronous Sequential Logic

ELE2120 Digital Circuits and Systems. Tutorial Note 8

REPEAT EXAMINATIONS 2002

Logic Design. Flip Flops, Registers and Counters

D Latch (Transparent Latch)

Chapter 3 Unit Combinational

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

Synchronous Sequential Logic

Combinational / Sequential Logic

10.1 Sequential logic circuits are a type of logic circuit where the output of the circuit depends not only on

Bachelor Level/ First Year/ Second Semester/ Science Full Marks: 60 Computer Science and Information Technology (CSc. 151) Pass Marks: 24

Asynchronous (Ripple) Counters

ELE2120 Digital Circuits and Systems. Tutorial Note 7

ECE 301 Digital Electronics

Analysis of Clocked Sequential Circuits

DIGITAL CIRCUIT COMBINATORIAL LOGIC

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

Switching Circuits & Logic Design, Fall Final Examination (1/13/2012, 3:30pm~5:20pm)

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

Synchronous Sequential Logic

Chapter 4. Logic Design

Rangkaian Sekuensial. Flip-flop

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

Flip-Flops and Sequential Circuit Design

Chapter 3. Boolean Algebra and Digital Logic

ELEN Electronique numérique

Part II. Chapter2: Synchronous Sequential Logic

INTRODUCTION TO SEQUENTIAL CIRCUITS

MODULE 3. Combinational & Sequential logic

Logic. Andrew Mark Allen March 4, 2012

ECE 341. Lecture # 2

CHAPTER 4 RESULTS & DISCUSSION

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

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

RS flip-flop using NOR gate

CHAPTER1: Digital Logic Circuits

DIGITAL SYSTEM FUNDAMENTALS (ECE421) DIGITAL ELECTRONICS FUNDAMENTAL (ECE422) LATCHES and FLIP-FLOPS

1.b. Realize a 5-input NOR function using 2-input NOR gates only.

Fall 2000 Chapter 5 Part 1


R13 SET - 1 '' ''' '' ' '''' Code No: RT21053

WEEK 10. Sequential Circuits: Analysis and Design. Page 1

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

Synchronous Sequential Logic. Chapter 5

Experiment 8 Introduction to Latches and Flip-Flops and registers

MODU LE DAY. Class-A, B, AB and C amplifiers - basic concepts, power, efficiency Basic concepts of Feedback and Oscillation. Day 1

UNIVERSITI TEKNOLOGI MALAYSIA

Vignana Bharathi Institute of Technology UNIT 4 DLD

Chapter 6 Sequential Circuits

COMP2611: Computer Organization. Introduction to Digital Logic

SEMESTER ONE EXAMINATIONS 2002

R13. II B. Tech I Semester Regular Examinations, Jan DIGITAL LOGIC DESIGN (Com. to CSE, IT) PART-A

Principles of Computer Architecture. Appendix A: Digital Logic

The basic logic gates are the inverter (or NOT gate), the AND gate, the OR gate and the exclusive-or gate (XOR). If you put an inverter in front of

University of California at Berkeley College of Engineering Department of Electrical Engineering and Computer Science SOLUTIONS

Introduction to Microprocessor & Digital Logic

Course Administration

Find the equivalent decimal value for the given value Other number system to decimal ( Sample)

To design a sequential logic circuit using D-Flip-flop. To implement the designed circuit.

ELCT201: DIGITAL LOGIC DESIGN

Digital Circuit And Logic Design I. Lecture 8

Digital Circuit And Logic Design I

EET2411 DIGITAL ELECTRONICS

Transcription:

Logic and Computer Design Fundamentals Chapter 5 Sequential Circuits Part 2 Sequential Circuit Design Charles Kime & Thomas Kaminski 28 Pearson Education, Inc. (Hyperlinks are active in View Show mode)

Overview Part - Storage Elements and Sequential Circuit Analysis Part 2- Sequential Circuit Design Specification Formulation State Assignment Flip-Flop Input and Output Equation Determination Verification Chapter 5 - Part 2 2

The Design Procedure Specification Formulation - Obtain a state diagram or state table State Assignment - Assign binary codes to the states Flip-Flop Input Equation Determination - Select flip-flop types and derive flip-flop equations from next state entries in the table Output Equation Determination - Derive output equations from output entries in the table Optimization - Optimize the equations Technology Mapping - Find circuit from equations and map to flip-flops and gate technology Verification - Verify correctness of final design Chapter 5 - Part 2 3

State Assignment Example Present Next State Output State x= x= x= x= A A B B A B How may assignments of codes with a minimum number of bits? Two A =, B = or A =, B = Does it make a difference? Only in variable inversion, so small, if any. Chapter 5 - Part 2 4

State Assignment Example 2 Present Next State Output State x= x= x= x= A A B B A C C D C D A B How may assignments of codes with a minimum number of bits? 4 3 2 = 24 Does code assignment make a difference in cost? Chapter 5 - Part 2 5

State Assignment Example 2 (continued) Counting Order Assignment: A =, B =, C =, D = The resulting coded state table: Present State Next State x = x = Output x = x = Chapter 5 - Part 2 6

State Assignment Example 2 (continued) Gray Code Assignment: A =, B =, C =, D = The resulting coded state table: Present State Next State x = x = Output x = x = Chapter 5 - Part 2 7

Find Flip-Flop Input and Output Equations: Example 2 Counting Order Assignment Assume D flip-flops Interchange the bottom two rows of the state table, to obtain K-maps for D, D 2, and Z: D D 2 Z Y Y 2 Y Y 2 Y Y 2 Chapter 5 - Part 2 8

Optimization: Example 2: Counting Order Assignment Performing two-level optimization: D D 2 Z Y Y 2 Y Y 2 Y Y 2 D = Y Y 2 + Y Y 2 D 2 = Y Y 2 + Y Y 2 + Y Y 2 Z = Y Y 2 Gate Input Cost = 22 Chapter 5 - Part 2 9

Find Flip-Flop Input and Output Equations: Example 2 Gray Code Assignment Assume D flip-flops Obtain K-maps for D, D 2, and Z: D D 2 Z Y Y 2 Y Y 2 Y Y 2 Chapter 5 - Part 2

Optimization: Example 2: Assignment 2 Performing two-level optimization: D D 2 Z Y 2 Y Y 2 2 Y Y Y D = Y Y 2 + Y 2 Gate Input Cost = 9 D 2 = Select this state assignment to Z = Y Y 2 complete design in slide Chapter 5 - Part 2

One Flip-flop per State (One-Hot) Assignment Example codes for four states: (Y 3, Y 2, Y, Y ) =,,, and. In equations, need to include only the variable that is for the state, e. g., state with code, is represented in equations by Y instead of Y 3 Y 2 Y Y because all codes with or two or more s have don t care next state values. Provides simplified analysis and design Combinational logic may be simpler, but flipflop cost higher may or may not be lower cost Chapter 5 - Part 2 2

State Assignment Example 2 (continued) One-Hot Assignment : A =, B =, C =, D = The resulting coded state table: Present State Next State x = x = Output x = x = Chapter 5 - Part 2 3

Optimization: Example 2: One Hot Assignment Equations read from next state variable entries in table: D = (Y + Y + Y 3 ) or Y 2 D = (Y + Y 3 ) D 2 = (Y + Y 2 ) or (Y + Y 3 ) D 3 = Y 2 Z = Y 3 Gate Input Cost = 5 Combinational cost intermediate plus cost of two more flip-flops needed. Chapter 5 - Part 2 4

Map Technology Library: D Flip-flops with Reset (not inverted) NAND gates with up to 4 inputs and inverters Initial Circuit: D D C R Y Y 2 Z Clock Reset C R Chapter 5 - Part 2 5

Mapped Circuit - Final Result D Y C R Z D Y 2 Clock Reset C R Chapter 5 - Part 2 6

Sequential Design: Example Design a sequential modulo 3 accumulator for 2- bit operands Definitions: Modulo n adder - an adder that gives the result of the addition as the remainder of the sum divided by n Example: 2 + 2 modulo 3 = remainder of 4/3 = Accumulator - a circuit that accumulates the sum of its input operands over time - it adds each input operand to the stored sum, which is initially. Stored sum: (Y,Y ), Input: (, ), Output: (Z,Z ) Chapter 5 - Part 2 7

Example (continued) Complete the state table Y Y Z Z Y (t+), Y (t+) Y (t+), Y (t+) State Assignment: (Y,Y ) = (Z,Z ) Y (t+), Y (t+) Y (t+), Y (t+) A () B () - () C () Codes are in gray code order to ease use of K-maps in the next step Chapter 5 - Part 2 8

Example (continued) Complete the state diagram: Reset C/ A/ B/ Chapter 5 - Part 2 9

Example (continued) Find optimized flip-flop input equations for D flip-flops D D Y Y Y Y D = D = Chapter 5 - Part 2 2

Circuit - Final Result with AND, OR, NOT D Y Z C R D Y Z Reset Clock C R Chapter 5 - Part 2 2

Other Flip-Flop Types J-K and T flip-flops Behavior Implementation Basic descriptors for understanding and using different flip-flop types Characteristic tables Characteristic equations Excitation tables For actual use, see Reading Supplement - Design and Analysis Using J-K and T Flip-Flops Chapter 5 - Part 2 22

J-K Flip-flop Behavior Same as S-R flip-flop with J analogous to S and K analogous to R Except that J = K = is allowed, and For J = K =, the flip-flop changes to the opposite state As a master-slave, has same s catching behavior as S-R flip-flop If the master changes to the wrong state, that state will be passed to the slave E.g., if master falsely set by J =, K = cannot reset it during the current clock cycle Chapter 5 - Part 2 23

J-K Flip-flop (continued) Implementation To avoid s catching behavior, one solution used is to use an edge-triggered D as the core of the flip-flop Symbol J K C J D K C Chapter 5 - Part 2 24

T Flip-flop Behavior Has a single input T For T =, no change to state For T =, changes to opposite state Same as a J-K flip-flop with J = K = T As a master-slave, has same s catching behavior as J-K flip-flop Cannot be initialized to a known state using the T input Reset (asynchronous or synchronous) essential Chapter 5 - Part 2 25

T Flip-flop (continued) Implementation To avoid s catching behavior, one solution used is to use an edge-triggered D as the core of the flip-flop Symbol T T D C C Chapter 5 - Part 2 26

Basic Flip-Flop Descriptors Used in analysis Characteristic table - defines the next state of the flip-flop in terms of flip-flop inputs and current state Characteristic equation - defines the next state of the flip-flop as a Boolean function of the flip-flop inputs and the current state Used in design Excitation table - defines the flip-flop input variable values as function of the current state and next state Chapter 5 - Part 2 27

D Flip-Flop Descriptors Characteristic Table D Q(t ) + Operation Reset Set Characteristic Equation Q(t+) = D Excitation Table Q(t +) D Operation Reset Set Chapter 5 - Part 2 28

T Flip-Flop Descriptors Characteristic Table T Q(t+ ) Operation Q(t) Q(t) No change Complement Characteristic Equation Q(t+) = T Q Excitation Table Q(t+) Q(t) Q(t) T Operation No change Complement Chapter 5 - Part 2 29

S-R Flip-Flop Descriptors Characteristic Table S Characteristic Equation Q(t+) = S + R Q, S. R = Excitation Table Q(t) R Q(t +) Q(t)? Q(t+) S Operation No change Reset Set Undefined R Operation No change Set Reset No change Chapter 5 - Part 2 3

J-K Flip-Flop Descriptors Characteristic Table Characteristic Equation Q(t+) = J Q + K Q Excitation Table J Q(t) K Q(t+) Q(t) Q(t) Q(t + ) J Operation No change Reset Set Complement K Operation No change Set Reset No Change Chapter 5 - Part 2 3

Flip-flop Behavior Example Use the characteristic tables to find the output waveforms for the flip-flops shown: Clock D,T D Q D C T Q T C Chapter 5 - Part 2 32

Flip-Flop Behavior Example (continued) Use the characteristic tables to find the output waveforms for the flip-flops shown: Clock S,J R,K S C R Q SR? J C K Q JK Chapter 5 - Part 2 33