I. Motivation & Examples

Similar documents
I. Motivation & Examples

Chapter 7 Sequential Logic

Synchronous Sequential Logic

LOGIC CIRCUITS. Basic Experiment and Design of Electronics

Sequential vs. Combinational

LOGIC CIRCUITS. Basic Experiment and Design of Electronics. Ho Kyung Kim, Ph.D.

ELCT201: DIGITAL LOGIC DESIGN

Chapter 5 Synchronous Sequential Logic

Sequential Logic Circuits

ELCT201: DIGITAL LOGIC DESIGN

ECEN 248: INTRODUCTION TO DIGITAL SYSTEMS DESIGN. Week 7 Dr. Srinivas Shakkottai Dept. of Electrical and Computer Engineering

Topic 8: Sequential Circuits

Digital Logic Design - Chapter 4

Sample Test Paper - I

Chapter 4. Sequential Logic Circuits

Counters. We ll look at different kinds of counters and discuss how to build them

Digital Electronics Final Examination. Part A

ELEC Digital Logic Circuits Fall 2014 Sequential Circuits (Chapter 6) Finite State Machines (Ch. 7-10)

Digital Circuits ECS 371

Sequential Logic. Rab Nawaz Khan Jadoon DCS. Lecturer COMSATS Lahore Pakistan. Department of Computer Science

CS221: Digital Design. Dr. A. Sahu. Indian Institute of Technology Guwahati

Sequential Circuits Sequential circuits combinational circuits state gate delay

CHW 261: Logic Design

Roger L. Tokheim. Chapter 8 Counters Glencoe/McGraw-Hill

Introduction EE 224: INTRODUCTION TO DIGITAL CIRCUITS & COMPUTER DESIGN. Lecture 6: Sequential Logic 3 Registers & Counters 5/9/2010

MAHALAKSHMI ENGINEERING COLLEGE TIRUCHIRAPALLI

Reg. No. Question Paper Code : B.E./B.Tech. DEGREE EXAMINATION, NOVEMBER/DECEMBER Second Semester. Computer Science and Engineering

Lecture 14: State Tables, Diagrams, Latches, and Flip Flop

ECE 341. Lecture # 3

Unit II Chapter 4:- Digital Logic Contents 4.1 Introduction... 4

Topic 8: Sequential Circuits. Bistable Devices. S-R Latches. Consider the following element. Readings : Patterson & Hennesy, Appendix B.4 - B.

Different encodings generate different circuits

Sequential Circuit Analysis

Synchronous Sequential Circuit

King Fahd University of Petroleum and Minerals College of Computer Science and Engineering Computer Engineering Department

Memory Elements I. CS31 Pascal Van Hentenryck. CS031 Lecture 6 Page 1

Lecture 7: Logic design. Combinational logic circuits

Latches. October 13, 2003 Latches 1

Chapter 14 Sequential logic, Latches and Flip-Flops

Digital Fundamentals

Sequential Logic Worksheet

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

Digital Fundamentals

Philadelphia University Student Name: Student Number:

ELEN Electronique numérique

COEN 312 DIGITAL SYSTEMS DESIGN - LECTURE NOTES Concordia University

WORKBOOK. Try Yourself Questions. Electrical Engineering Digital Electronics. Detailed Explanations of


Gates and Flip-Flops

Digital Design. Sequential Logic

MAHARASHTRA STATE BOARD OF TECHNICAL EDUCATION (Autonomous) (ISO/IEC Certified) State any two Boolean laws. (Any 2 laws 1 mark each)

L4: Sequential Building Blocks (Flip-flops, Latches and Registers)

Digital Logic and Design (Course Code: EE222) Lecture 19: Sequential Circuits Contd..

Digital Circuits and Systems

Written reexam with solutions for IE1204/5 Digital Design Monday 14/

L4: Sequential Building Blocks (Flip-flops, Latches and Registers)

Appendix B. Review of Digital Logic. Baback Izadi Division of Engineering Programs

KUMARAGURU COLLEGE OF TECHNOLOGY COIMBATORE

Digital Electronics Circuits 2017

Vidyalankar S.E. Sem. III [CMPN] Digital Logic Design and Analysis Prelim Question Paper Solution

S.Y. Diploma : Sem. III [CO/CM/IF/CD/CW] Digital Techniques

Synchronous Sequential Logic Part I. BME208 Logic Circuits Yalçın İŞLER

EE 209 Logic Cumulative Exam Name:

MAHALAKSHMI ENGINEERING COLLEGE TIRUCHIRAPALLI

Week-5. Sequential Circuit Design. Acknowledgement: Most of the following slides are adapted from Prof. Kale's slides at UIUC, USA.

10/12/2016. An FSM with No Inputs Moves from State to State. ECE 120: Introduction to Computing. Eventually, the States Form a Loop

Digital Electronics Sequential Logic

MAHARASHTRA STATE BOARD OF TECHNICAL EDUCATION (Autonomous) (ISO/IEC Certified)

on candidate s understanding. 7) For programming language papers, credit may be given to any other program based on equivalent concept.

Fundamentals of Digital Design

Lecture 17: Designing Sequential Systems Using Flip Flops

ELE2120 Digital Circuits and Systems. Tutorial Note 9

Lecture 7: Sequential Networks

CPE100: Digital Logic Design I

CPE100: Digital Logic Design I

ECE/Comp Sci 352 Digital Systems Fundamentals. Charles R. Kime Section 2 Fall Logic and Computer Design Fundamentals

S.Y. Diploma : Sem. III [DE/ED/EI/EJ/EN/ET/EV/EX/IC/IE/IS/IU/MU] Principles of Digital Techniques

CHW 261: Logic Design

PGT104 Digital Electronics. PGT104 Digital Electronics

Lecture 10: Synchronous Sequential Circuits Design

ECEN 248: INTRODUCTION TO DIGITAL SYSTEMS DESIGN. Week 9 Dr. Srinivas Shakkottai Dept. of Electrical and Computer Engineering

EE40 Lec 15. Logic Synthesis and Sequential Logic Circuits

( c) Give logic symbol, Truth table and circuit diagram for a clocked SR flip-flop. A combinational circuit is defined by the function

Digital Logic: Boolean Algebra and Gates. Textbook Chapter 3

EECS150 - Digital Design Lecture 23 - FFs revisited, FIFOs, ECCs, LSFRs. Cross-coupled NOR gates

Introduction to Digital Logic

Synchronous Sequential Circuit Design. Dr. Ehab A. H. AL-Hialy Page 1

Computers also need devices capable of Storing data and information Performing mathematical operations on such data

Appendix A: Digital Logic. Principles of Computer Architecture. Principles of Computer Architecture by M. Murdocca and V. Heuring

EECS150 - Digital Design Lecture 18 - Counters

EECS150 - Digital Design Lecture 18 - Counters

Synchronous Sequential Logic Part I

EECS150 - Digital Design Lecture 23 - FSMs & Counters

Dr. Nicola Nicolici COE/EE2DI4 Midterm Test #2 Nov 22, 2006

Boolean Algebra and Digital Logic 2009, University of Colombo School of Computing

Schedule. ECEN 301 Discussion #25 Final Review 1. Date Day Class No. 1 Dec Mon 25 Final Review. Title Chapters HW Due date. Lab Due date.

Clocked Synchronous State-machine Analysis

ESE 570: Digital Integrated Circuits and VLSI Fundamentals

Chapter 7. Sequential Circuits Registers, Counters, RAM

DE58/DC58 LOGIC DESIGN DEC 2014

Transcription:

I. Motivation & Examples Output depends on current input and past history of inputs. State embodies all the information about the past needed to predict current output based on current input. State variables, one or more bits of information. If the current State of the circuit is known at time t, what is the state of the circuit at time (t+) Answer: the next state depends on current state and input

I. Motivation & Examples Describing sequential circuit State table For each current-state, specify next-states as function of inputs For each current-state, specify outputs as function of inputs State diagram Graphical version of state table Example : TV channel control Let the channel # represent the state of the circuit Input are up/down on the channel control 2 on u u u u u 2 3 4 99 d d d d d u: up d: down

I. Motivation & Examples Example 2: A sequential process that inputs an n-bit binary string and outputs if the string contains an even number of s 0 SLN (final output) 0 SLN 0 (final output) What represents the state of the circuit? Case: State as the number of s read so far (possibly infinite # of states) 3 Case 2: Two states E and O E (even): if the # of s read so far is even O (odd) if the # of s read so far is odd

I. Motivation & Examples Example 2: State Diagram for Case Input Output 0 /0 / /0 / 2 3 4 /0 / 2n 0/ 0/0 0/ 0/0 0/ 0/ Example 2: State Diagram for Case 2 Input Output 4 E 0/ /0 / O 0/0

I. Motivation & Examples Example 2: State Diagram for Case 2 Input Output E 0/ /0 / O 0/0 Better design Has less states 5

I. Motivation & Examples Example 3: Discuss sequential n-bits comparator Compare two n-bits numbers X=[Xn-,, X0], Y=[Yn-,, Y0] Output if X>Y Use the basic -bit comparator designed in class Shift right... Xn- Xn-2 Xn-3 X2 X X0 Xi Fi- -bit Comparator Yi Ci Operation controlled by a clock to decide:.when to shift input data.when output Fi is stable Yn- Yn-2 Yn-3... Y2 Y Y0 Shift right Fi 6

I. Motivation & Examples Example 4: Discuss sequential n-bits adder Add two n-bits numbers X=[Xn-,, X0], Y=[Yn-,, Y0] Output S=X+Y where [Sn,Sn-,,S0] Use the basic -bit adder with carry in and carry out Shift right... Xn- Xn-2 Xn-3 X2 X X0 Xi Ci- -bit Full adder Ci Yi Operation controlled by a clock to decide:.when to shift input data.when output are ready 7... Shift right Yn- Yn-2 Yn-3 Y2 Y Y0 Sn Ci Shift right... Sn- Sn-2 S2 S S0

II. General Representation Clock signals Sequential circuit are controlled by a clock signal Very important with most sequential circuits State variables change state at clock edge. 8

II. General Representation General diagram of sequential circuit Sequential circuit are controlled by a clock signal Very important with most sequential circuits State variables change state at clock edge. Input Output i0 i in Current states SLN Next states o0 o om Feedback Memory components 9 State variables: s0,s, sk

II. General Representation Some important questions How to represent the states of a sequential circuit? How to memorize the (current and next) states? How to determine the next of the circuit? How to determine the outputs as a function F(state) of current state only? as a function F(input,state) of both input and current state? The concept of STATE is very important 0

II. General Representation Memory component How do we represent the states? Memory component are used as state variables Goal: Memorize the current state of the circuit How are memory components implemented? Latch, Flip-flop are -bit memory component

Bistable element The simplest sequential circuit Two states One state variable, say, (N or _L the complement of ) HIGH LOW LOW HIGH 2

Bistable element The simplest sequential circuit Two states One state variable, say, LOW HIGH HIGH LOW 3

Bistable element: Analog analysis Assume pure CMOS thresholds, 5V rail Theoretical threshold center is 2.5 V 4

Bistable element: Analog analysis Assume pure CMOS thresholds, 5V rail Theoretical threshold center is 2.5 V 2.5 V 2.5 V 2.5 V 2.5 V 5

Bistable element: Analog analysis Assume pure CMOS thresholds, 5V rail Theoretical threshold center is 2.5 V 4.8 2.5 VV 2.5 2.0 0.0 V 2.5 2.0 0.0 V 4.8 5.0 2.5 V 6

II. General Representation Bistable element: summary 2 7 If (=0), then input to Not gate 2 is 0 ==> Output of Not gate 2 is (_L =) ==> The input of Not gate is, so output of Not gate is 0 ==> Stable output (=0) and (_L = ) If (=), then input to Not gate 2 is ==> Output of Not gate 2 is 0 (_L =0) ==> The input of Not gate is 0, so output Not gate is ==> Stable output (=) and (_L = 0)

S-R Latch. How to control it? Screwdriver Control inputs S-R latch Contradiction!!!! 8

S-R Latch. 9 Set operation: SR 00 ----> 0, set the device output to = regardless of current value of Reset operation: SR 00 ----> 0, set the device output to =0 regardless of current value of Hold operation: SR 0 ----> 00 or 0 ----> 00, Device output are the same as last output values Only one input value changes Possible input changes: SR: 00 ---> 0 ---> 00 ---> 0 ---> 00. Input SR = is not allowed ( Both NOR gates output 0, i.e = =0 )

S-R latch operation 20

Propagation delay Minimum pulse width S-R latch timing parameters 2 Progation delay Minimum time to maintain signal at

S-R latch symbols 22

S-R latch with enable 23

Sequential network architecture (revisited) Input i in... SLN... Output o om M... Components Mi are latches/flip flops 24 Mk Operation rules: Memory components Mi must be in stable state before input changes Only one input of the component Mi can change at a time

Charcteristics equation of S-R latch Definition: The characteristic equation specifies a flip-flop next state as a function of its current state and inputs 25 Notation: Let q represent the current state of the flip-flop and its next Characteristics table S R q 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 X X =q =0 = Not allowed Hold Reset Set

Charcteristics table (other representation) Characteristics table S R 0 0 q =q 0 0 =0 0 = X Not allowed Hold Reset Set 26

Charcteristics equation of S-R latch Use the characteristics table to get an excitation map of the flip flop Characteristics table S R q 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 X X =q =0 = SR q 0 00 0 0 X X Use K-map method to derive the characteristics equation: 27 = S + R q

Excitation table of SR flip flop The excitation table describes the input values of S and R that cause the corresponding transitions (q ---> ) from current to next state 28 Types of transitions: q ---> 0 ---> 0 0 ---> ---> 0 Excitation table of S R latch ---> 0 0 to hold current value OR 0 to set = q ---> S R 0 ---> 0 0 X 0 ---> 0 ---> 0 0 ---> X 0 0 0 to hold current value OR 0 to reset =0

JK Flip- Flop Recall: In SR flip flop, both input S, R cannot be (SR=) This restriction is removed in a JK flip flop. The behavior of the JK flip flop is as follows: 29 Characteristics table J K q 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 =q =0 = = (Toggle) Hold Reset Set

Charateristics of JK flip flop (other representation) Characteristics table J K 0 0 q 0 0 0 q' =q =0 = = q (Toggle) Hold Reset Set 30 Characteristics table ( Clocked JK flip flop ) C J K 0 0 0 0 q 0 q' 0 x x Disabled =q =0 = = q (Toggle) Hold Reset Set

Charcteristics equation of Jk Flip flop Use the characteristics table to get an excitation map of the flip flop Characteristics table J K q 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 =q =0 = = JK q 00 0 0 0 0 0 0 Use K-map method to derive the characteristics equation: 0 3 = Jq + Kq

Excitation table of JK flip flop The excitation table describes the input values of S and R that cause the corresponding transitions (q ---> ) from current to next state 32 Types of transitions: q ---> 0 ---> 0 0 ---> ---> 0 Excitation table of JK flip flop ---> 0 0 to hold current value OR 0 to set = q ---> J K 0 ---> 0 0 X 0 ---> X ---> 0 X ---> X 0 0 0 to hold current value OR 0 to reset =0

Excitation table of JK flip flop The excitation table describes the input values of S and R that cause the corresponding transitions (q ---> ) from current to next state 33 Types of transitions: q ---> 0 ---> 0 0 ---> ---> 0 Excitation table of JK flip flop ---> 0 0 to hold current value OR 0 to set = q ---> J K 0 ---> 0 0 X 0 ---> X ---> 0 X ---> X 0 0 0 to hold current value OR 0 to reset =0

JK Flip flop Symbols J J K N K Clocked JK Flip flop J J CK CK K N K N 34

D Flip- flop ( Delay flip flop) 35 This flip flop has only one control input. The D flip flop simply retains its input between clock pulses Characteristics table D q 0 0 0 0 0 0 =d Characteristics table ( Clocked D flip flop ) C D 0 0 x 0 =d Disabled

Charcteristics equation of D Flip flop Use the characteristics table to get an excitation map of the flip flop Characteristics table D q 0 0 0 0 0 0 Characteristics equation: = D 36

D Flip flop Symbols D D N Clocked JK Flip flop D D CK CK N N 37

D latch 38

D-latch operation 39

D-latch timing parameters Propagation delay (from C or D) Setup time (D before C edge) Hold time (D after C edge) 40

Edge-triggered D flip-flop behavior 4

Edge-triggered D flip-flop behavior 42

D flip-flop timing parameters Propagation delay (from CLK) Setup time (D before CLK) Hold time (D after CLK) 43

IV. Counters Definitions A counter is a sequential-circuit that generates a predetermined number sequence over and over again A counter can be used as a digital clock special sequence generator program counter pulse counter 44

IV. Counters Examples 0 2 3 4 5 6 7 8 9 0 2 3 4 5 6 00 0 0 0000 000 00 000 00 000 45

IV. Counters Types of counters 46 Counters are often implemented by Flip flops. They are synchronous if all flip flops are clocked by the same signal ripple (asynchronous) individual flip flop are clocked at different times Counters may be classified by other characteristics: mod N counter or divide-by- N counter, if counter has N distinct states (State = a number of the counted sequence) by the number of fli flops in the counter: n bit counter Other types of counter: binary up (or down) counter : successive states represent an increasing binary count 00 --> 0 --> 0 --> --> 00.. gray code binary counter 00 --> 0 ---> ---> 0 ---> 00

IV. Counters Problem Statement Intuitive Design of a counter Design a sequential device to generate the sequence 0,, 2, 3 over and over again There are 4 distinct states (divide-by-4) counter Encode the four states as follows; 0 encoded by 00 encoded by 0 2 encoded by 0 3 encoded by Represent each binary bit of a code by a flip flop (in this example, let us use JK flip flops to design the counter) 00 0 0 47

00 IV. Counters Intuitive Design of a counter 00 0 0 0 0 Flip flop 0 changes state at every clock pulse Flip flop changes states every two clock pulses 00 Flip flop Flip flop 0 48 State transition flip flop 0 State transition flip flop 0

IV. Counters Intuitive Design of a counter Design using JK flip flops for states 0 and of the counter SS0 : 00 --> 0 --> 0 --> --> 00. S S0 J J CK CK K N K N EN 49

IV. Counters Intuitive Design of a 4 bit binary counter Design using JK flip flops S3S2SS0 : 0000 --> 000 --> 000 --> 00 --> 000 --> 00 --> --> 0000 There are 6 states design requires four flip flops Synchronous design, all flip flops clocked by the same signal S0 Changes state (toggles) every clock pulse S Changes state (toggles) when S0 = S2 Changes state (toggles) when S= and S0 = S3 Changes state (toggles) when S2=, S= and S0= 50

IV. Counters Intuitive Design of a 4 bit binary counter Design using JK flip flops J J J J CK CK CK CK K N K N K N K N S3 S2 S S0 EN 5