Princess Sumaya University

Slides:



Advertisements
Similar presentations
State-machine structure (Mealy)
Advertisements

COE 202: Digital Logic Design Sequential Circuits Part 3
1 Lecture 14 Memory storage elements  Latches  Flip-flops State Diagrams.
A. Abhari CPS2131 Sequential Circuits Most digital systems like digital watches, digital phones, digital computers, digital traffic light controllers and.
Classification of Digital Circuits  Combinational. Output depends only on current input values.  Sequential. Output depends on current input values and.
Princess Sumaya University
Sequential Circuits1 DIGITAL LOGIC DESIGN by Dr. Fenghui Yao Tennessee State University Department of Computer Science Nashville, TN.
Synchronous Sequential Logic
Digital Electronics Chapter 5 Synchronous Sequential Logic.
Multiplexors Sequential Circuits and Finite State Machines Prof. Sin-Min Lee Department of Computer Science.
Circuits require memory to store intermediate data
CSE 205: D IGITAL L OGIC D ESIGN Prepared By, Dr. Tanzima Hashem, Assistant Professor, CSE, BUET Updated By, Fatema Tuz Zohora, Lecturer, CSE, BUET.
1 Lecture 23 More Sequential Circuits Analysis. 2 Analysis of Combinational Vs. Sequential Circuits °Combinational : Boolean Equations Truth Table Output.
ECE 331 – Digital System Design Introduction to and Analysis of Sequential Logic Circuits (Lecture #20) The slides included herein were taken from the.
EECC341 - Shaaban #1 Lec # 14 Winter Clocked Synchronous State-Machines Such machines have the characteristics: –Sequential circuits designed.
Sequential Circuit Design
Overview Sequential Circuit Design Specification Formulation
Sequential Circuit Analysis. 2 Synchronous vs. Asynch. Synchronous sequential circuit:  The behavior can be defined from knowledge of its signal at discrete.
Sequential Circuit Analysis. 2 Synchronous vs. Asynch. Synchronous sequential circuit:  the behavior can be defined from knowledge of its signal at discrete.
A clocked synchronous state-machine changes state only when a triggering edge or “tick” occurs on the clock signal. ReturnNext  “State-machine”: is a.
ECE 301 – Digital Electronics
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)
1 Synchronous Sequential Circuit Analysis. 2 Synchronous Sequential Circuit State Memory – A set of n edge-triggered flip-flops that store the current.
A State Element “Zoo”.
BY: TRAVIS HOOVER 2/22/2011 CS 147 DR. LEE JK flip-flops.
SEQUENTIAL CIRCUITS Introduction
Digital Computer Design Fundamental
ECE 331 – Digital Systems Design Sequential Logic Circuits: FSM Design (Lecture #20)
1 Chapter 5 Synchronous Sequential Logic 5-1 Sequential Circuits Every digital system is likely to have combinational circuits, most systems encountered.
Chapter 5 - Part Sequential Circuit Design Design Procedure  Specification  Formulation - Obtain a state diagram or state table  State Assignment.
Rabie A. Ramadan Lecture 2
(Sequential Logic Circuit)
Synchronous Sequential Logic Part I
Digital Design Lecture 10 Sequential Design. State Reduction Equivalent Circuits –Identical input sequence –Identical output sequence Equivalent States.
Synchronous Sequential Logic Part II
Chap 4. Sequential Circuits
Synchronous Sequential Logic Chapter 5. Digital Circuits Sequential Circuits Combinational circuits contains no memory elements the outputs depends.
Chapter 6 Sequential Logic. Combinational circuit outputs depend on present inputs. Sequential circuit outputs depend on present inputs and the state.
Chap 4. Sequential Circuits
C HAPTER F IVE S YNCHRONOUS S EQUENTIAL L OGIC 1.
Introduction to Sequential Logic Design Flip-flops FSM Analysis.
Sequential Circuits. Two primary differences between combinational circuits and sequential circuits –Sequential circuits are synchronous (use a clock)
CENG 241 Digital Design 1 Lecture 10 Amirali Baniasadi
Sequential Circuit Design. Outline  Flip-flop Excitation Tables  Sequential Circuit Design  Design: Example #1  Design: Example #2  Design: Example.
Introduction to Sequential Logic Design Finite State-Machine Design.
Boolean Algebra and Logic Gates 1 Computer Engineering (Logic Circuits) Lec. # 10 (Sequential Logic Circuit) Dr. Tamer Samy Gaafar Dept. of Computer &
Digital Circuits State Reduction and Assignment State Reduction reductions on the number of flip-flops and the number of gates a reduction in the.
DESIGN OF SEQUENTIAL CIRCUITS by Dr. Amin Danial Asham.
1 State Reduction Goal: reduce the number of states while keeping the external input-output requirements unchanged. State reduction example: a: input 0.
C HAPTER F IVE S YNCHRONOUS S EQUENTIAL L OGIC 1.
C HAPTER F IVE S YNCHRONOUS S EQUENTIAL L OGIC 1.
Synchronous Sequential Logic Part I
5 Chapter Synchronous Sequential Circuits 1. Logic Circuits- Review 2 Logic Circuits Sequential Circuits Combinational Circuits Consists of logic gates.
Sahar Mosleh PageCalifornia State University San Marcos 1 More on Flip Flop State Table and State Diagram.
ENG241 Digital Design Week #7 Sequential Circuits (Part B)
Chapter 6 Analysis of Sequential Systems Sequential Memory Feedback.
Fuw-Yi Yang1 數位系統 Digital Systems Department of Computer Science and Information Engineering, Chaoyang University of Technology 朝陽科技大學資工系 Speaker: Fuw-Yi.
Digital Design: With an Introduction to the Verilog HDL, 5e M. Morris Mano Michael D. Ciletti Copyright ©2013 by Pearson Education, Inc. All rights reserved.
Week #7 Sequential Circuits (Part B)
FIGURE 5.1 Block diagram of sequential circuit
Digital Design Lecture 9
ECE 301 – Digital Electronics
Princess Sumaya University
332:437 Lecture 12 Finite State Machine Design
Sequential logic circuits
CENG 241 Digital Design 1 Lecture 11
Chapter 5 Synchronous Sequential Logic 5-1 Sequential Circuits
INTRODUCTION TO LOGIC DESIGN Chapter 5 Synchronous Sequential Logic
MTE 202, Summer 2016 Digital Circuits Dr.-Ing. Saleh Hussin
Presentation transcript:

Princess Sumaya University 4241 - Digital Logic Design SEQUENTIAL LOGIC CIRCUIT DESIGN Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Sequential Circuits Asynchronous Synchronous Combinational Circuit Memory Elements Inputs Outputs Combinational Circuit Flip-flops Inputs Outputs Clock Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Latches SR Latch S R Q0 Q Q’ 0 0 0 1 Q = Q0 1 Initial Value Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Latches SR Latch S R Q0 Q Q’ 0 0 0 1 0 0 1 Q = Q0 1 Q = Q0 1 Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Latches SR Latch S R Q0 Q Q’ 0 0 0 1 0 0 1 0 1 0 Q = Q0 1 Q = 0 1 1 Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Latches SR Latch S R Q0 Q Q’ 0 0 0 1 0 0 1 0 1 0 0 1 1 Q = Q0 Q = 0 1 1 1 Q = 0 Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Latches SR Latch S R Q0 Q Q’ 0 0 0 1 0 0 1 0 1 0 0 1 1 1 0 0 Q = Q0 Q = 0 1 Q = 1 1 1 Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Latches SR Latch S R Q0 Q Q’ 0 0 0 1 0 0 1 0 1 0 0 1 1 1 0 0 1 0 1 Q = Q0 1 Q = 0 Q = 1 1 Q = 1 1 Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Latches SR Latch S R Q0 Q Q’ 0 0 0 1 0 0 1 0 1 0 0 1 1 1 0 0 1 0 1 1 1 0 Q = Q0 1 Q = 0 Q = 1 Q = Q’ 1 1 Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Latches SR Latch S R Q0 Q Q’ 0 0 0 1 0 0 1 0 1 0 0 1 1 1 0 0 1 0 1 1 1 0 1 1 1 Q = Q0 1 1 Q = 0 Q = 1 Q = Q’ Q = Q’ 1 Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Latches SR Latch S R Q 0 0 Q0 0 1 1 0 1 1 1 Q=Q’=0 No change Reset Set Invalid S R Q 0 0 Q=Q’=1 0 1 1 1 0 1 1 Q0 Invalid Set Reset No change Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Latches SR Latch S R Q 0 0 Q0 0 1 1 0 1 1 1 Q=Q’=0 No change Reset Set Invalid S’ R’ Q 0 0 Q=Q’=1 0 1 1 1 0 1 1 Q0 Invalid Set Reset No change Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Controlled Latches SR Latch with Control Input C S R Q 0 x x Q0 1 0 0 1 0 1 1 1 0 1 1 1 1 Q=Q’ No change Reset Set Invalid Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Controlled Latches D Latch (D = Data) Timing Diagram C D Q t C D Q 0 x Q0 1 0 1 1 1 Output may change No change Reset Set Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Controlled Latches D Latch (D = Data) Timing Diagram C D Q C D Q 0 x Q0 1 0 1 1 1 Output may change No change Reset Set Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Flip-Flops Controlled latches are level-triggered Flip-Flops are edge-triggered C CLK Positive Edge CLK Negative Edge Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Flip-Flops Master-Slave D Flip-Flop D Latch (Master) D C Q (Slave) CLK Master Slave CLK D Looks like it is negative edge-triggered QMaster QSlave Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Flip-Flops Edge-Triggered D Flip-Flop D Q Positive Edge D Q Negative Edge Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Flip-Flops JK Flip-Flop J Q K D = JQ’ + K’Q Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Flip-Flops T Flip-Flop D Q T J Q K T T Q D = JQ’ + K’Q D = TQ’ + T’Q = T  Q Dr. Bassam Kahhaleh

Flip-Flop Characteristic Tables Princess Sumaya University 4241 - Digital Logic Design Flip-Flop Characteristic Tables D Q D Q(t+1) 1 Reset Set J K Q(t+1) Q(t) 1 Q’(t) J Q K No change Reset Set Toggle T Q T Q(t+1) Q(t) 1 Q’(t) No change Toggle Dr. Bassam Kahhaleh

Flip-Flop Characteristic Equations Princess Sumaya University 4241 - Digital Logic Design Flip-Flop Characteristic Equations D Q D Q(t+1) 1 Q(t+1) = D J K Q(t+1) Q(t) 1 Q’(t) J Q K Q(t+1) = JQ’ + K’Q T Q T Q(t+1) Q(t) 1 Q’(t) Q(t+1) = T  Q Dr. Bassam Kahhaleh

Flip-Flop Characteristic Equations Princess Sumaya University 4241 - Digital Logic Design Flip-Flop Characteristic Equations Analysis / Derivation J K Q(t) Q(t+1) 1 No change Reset Set Toggle J Q K Dr. Bassam Kahhaleh

Flip-Flop Characteristic Equations Princess Sumaya University 4241 - Digital Logic Design Flip-Flop Characteristic Equations Analysis / Derivation J K Q(t) Q(t+1) 1 No change Reset Set Toggle J Q K Dr. Bassam Kahhaleh

Flip-Flop Characteristic Equations Princess Sumaya University 4241 - Digital Logic Design Flip-Flop Characteristic Equations Analysis / Derivation J K Q(t) Q(t+1) 1 No change Reset Set Toggle J Q K Dr. Bassam Kahhaleh

Flip-Flop Characteristic Equations Princess Sumaya University 4241 - Digital Logic Design Flip-Flop Characteristic Equations Analysis / Derivation J K Q(t) Q(t+1) 1 No change Reset Set Toggle J Q K Dr. Bassam Kahhaleh

Flip-Flop Characteristic Equations Princess Sumaya University 4241 - Digital Logic Design Flip-Flop Characteristic Equations Analysis / Derivation J K Q(t) Q(t+1) 1 J Q K K 1 J Q Q(t+1) = JQ’ + K’Q Dr. Bassam Kahhaleh

Flip-Flops with Direct Inputs Princess Sumaya University 4241 - Digital Logic Design Flip-Flops with Direct Inputs Asynchronous Reset D Q R Reset R’ D CLK Q(t+1) x Dr. Bassam Kahhaleh

Flip-Flops with Direct Inputs Princess Sumaya University 4241 - Digital Logic Design Flip-Flops with Direct Inputs Asynchronous Reset D Q R Reset R’ D CLK Q(t+1) x 1 ↑ Dr. Bassam Kahhaleh

Flip-Flops with Direct Inputs Princess Sumaya University 4241 - Digital Logic Design Flip-Flops with Direct Inputs Asynchronous Preset and Clear D Q CLR Reset PR Preset PR’ CLR’ D CLK Q(t+1) 1 x Dr. Bassam Kahhaleh

Flip-Flops with Direct Inputs Princess Sumaya University 4241 - Digital Logic Design Flip-Flops with Direct Inputs Asynchronous Preset and Clear D Q CLR Reset PR Preset PR’ CLR’ D CLK Q(t+1) 1 x Dr. Bassam Kahhaleh

Flip-Flops with Direct Inputs Princess Sumaya University 4241 - Digital Logic Design Flip-Flops with Direct Inputs Asynchronous Preset and Clear D Q CLR Reset PR Preset PR’ CLR’ D CLK Q(t+1) 1 x ↑ Dr. Bassam Kahhaleh

Analysis of Clocked Sequential Circuits Princess Sumaya University 4241 - Digital Logic Design Analysis of Clocked Sequential Circuits The State State = Values of all Flip-Flops Example A B = 0 0 Dr. Bassam Kahhaleh

Analysis of Clocked Sequential Circuits Princess Sumaya University 4241 - Digital Logic Design Analysis of Clocked Sequential Circuits State Equations A(t+1) = DA = A(t) x(t)+B(t) x(t) = A x + B x B(t+1) = DB = A’(t) x(t) = A’ x y(t) = [A(t)+ B(t)] x’(t) = (A + B) x’ Dr. Bassam Kahhaleh

Analysis of Clocked Sequential Circuits Princess Sumaya University 4241 - Digital Logic Design Analysis of Clocked Sequential Circuits State Table (Transition Table) Present State Input Next State Output A B x y 1 0 0 0 0 1 0 0 0 1 1 1 0 1 0 0 A(t+1) = A x + B x B(t+1) = A’ x y(t) = (A + B) x’ t t+1 t Dr. Bassam Kahhaleh

Analysis of Clocked Sequential Circuits Princess Sumaya University 4241 - Digital Logic Design Analysis of Clocked Sequential Circuits State Table (Transition Table) Present State Next State Output x = 0 x = 1 A B y 1 t t+1 t A(t+1) = A x + B x B(t+1) = A’ x y(t) = (A + B) x’ Dr. Bassam Kahhaleh

Analysis of Clocked Sequential Circuits Princess Sumaya University 4241 - Digital Logic Design Analysis of Clocked Sequential Circuits State Diagram Present State Next State Output x = 0 x = 1 A B y 1 AB input/output 0/0 1/0 0/1 0 0 1 0 0/1 1/0 0/1 1/0 0 1 1 1 1/0 Dr. Bassam Kahhaleh

Analysis of Clocked Sequential Circuits Princess Sumaya University 4241 - Digital Logic Design Analysis of Clocked Sequential Circuits D Flip-Flops Example: D Q x CLK y A Present State Input Next State A x y 1 1 A(t+1) = DA = A  x  y 01,10 1 00,11 00,11 01,10 Dr. Bassam Kahhaleh

Analysis of Clocked Sequential Circuits Princess Sumaya University 4241 - Digital Logic Design Analysis of Clocked Sequential Circuits JK Flip-Flops Example: Present State I/P Next State Flip-Flop Inputs A B x JA KA JB KB 1 0 1 0 0 1 1 1 0 0 0 1 0 0 0 0 1 1 1 1 0 1 0 0 1 0 0 1 1 0 0 0 0 1 1 1 1 1 0 0 0 JA = B KA = B x’ JB = x’ KB = A  x A(t+1) = JA Q’A + K’A QA = A’B + AB’ + Ax B(t+1) = JB Q’B + K’B QB = B’x’ + ABx + A’Bx’ Dr. Bassam Kahhaleh

Analysis of Clocked Sequential Circuits Princess Sumaya University 4241 - Digital Logic Design Analysis of Clocked Sequential Circuits JK Flip-Flops Example: Present State I/P Next State Flip-Flop Inputs A B x JA KA JB KB 1 0 1 0 0 1 1 1 0 0 0 1 0 0 0 0 1 1 1 1 0 1 0 0 1 0 0 1 1 0 0 0 0 1 1 1 1 1 0 0 0 1 1 0 0 1 1 0 1 1 0 1 1 Dr. Bassam Kahhaleh

Analysis of Clocked Sequential Circuits Princess Sumaya University 4241 - Digital Logic Design Analysis of Clocked Sequential Circuits T Flip-Flops Example: Present State I/P Next State F.F Inputs O/P A B x TA TB y 1 0 0 0 1 1 0 1 1 0 0 0 1 1 1 1 TA = B x TB = x y = A B A(t+1) = TA Q’A + T’A QA = AB’ + Ax’ + A’Bx B(t+1) = TB Q’B + T’B QB = x  B Dr. Bassam Kahhaleh

Analysis of Clocked Sequential Circuits Princess Sumaya University 4241 - Digital Logic Design Analysis of Clocked Sequential Circuits T Flip-Flops Example: Present State I/P Next State F.F Inputs O/P A B x TA TB y 1 0 0 0 1 1 0 1 1 0 0 0 1 1 1 1 0/0 0/0 0 0 1/0 0 1 1/1 1/0 1 1 1 0 0/1 0/0 1/0 Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Mealy and Moore Models The Mealy model: the outputs are functions of both the present state and inputs (Fig. 5-15). The outputs may change if the inputs change during the clock pulse period. The outputs may have momentary false values unless the inputs are synchronized with the clocks. The Moore model: the outputs are functions of the present state only (Fig. 5-20). The outputs are synchronous with the clocks. Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Mealy and Moore Models Fig. 5.21 Block diagram of Mealy and Moore state machine Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Mealy and Moore Models Mealy Moore Present State I/P Next State O/P A B x y 1 Present State I/P Next State O/P A B x y 1 For the same state, the output changes with the input For the same state, the output does not change with the input Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Moore State Diagram State / Output 1 0 0 / 0 0 1 / 0 1 1 1 1 / 1 1 0 / 0 1 Dr. Bassam Kahhaleh

State Reduction and Assignment Princess Sumaya University 4241 - Digital Logic Design State Reduction and Assignment State Reduction Reductions on the number of flip-flops and the number of gates. A reduction in the number of states may result in a reduction in the number of flip-flops. An example state diagram showing in Fig. 5.25. Fig. 5.25 State diagram Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design State Reduction Only the input-output sequences are important. Two circuits are equivalent Have identical outputs for all input sequences; The number of states is not important. State: a b c d e f g Input: 1 Output: Fig. 5.25 State diagram Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Equivalent states Two states are said to be equivalent For each member of the set of inputs, they give exactly the same output and send the circuit to the same state or to an equivalent state. One of them can be removed. Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Reducing the state table e = g (remove g); d = f (remove f); Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design The reduced finite state machine State: a b c d e Input: 1 Output: Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design The unused states are treated as don't-care condition Þ fewer combinational gates. Fig. 5.26 Reduced State diagram Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design State Assignment State Assignment To minimize the cost of the combinational circuits. Three possible binary state assignments. (m states need n-bits, where 2n > m) Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Any binary number assignment is satisfactory as long as each state is assigned a unique number. Use binary assignment 1. Dr. Bassam Kahhaleh

Princess Sumaya University 4241 - Digital Logic Design Design Procedure Design Procedure for sequential circuit The word description of the circuit behavior to get a state diagram; State reduction if necessary; Assign binary values to the states; Obtain the binary-coded state table; Choose the type of flip-flops; Derive the simplified flip-flop input equations and output equations; Draw the logic diagram; Dr. Bassam Kahhaleh

Design of Clocked Sequential Circuits Princess Sumaya University 4241 - Digital Logic Design Design of Clocked Sequential Circuits Example: Detect 3 or more consecutive 1’s 1 S0 / 0 S1 / 0 State A B S0 0 0 S1 0 1 S2 1 0 S3 1 1 1 S3 / 1 S2 / 0 1 1 Dr. Bassam Kahhaleh

Design of Clocked Sequential Circuits Princess Sumaya University 4241 - Digital Logic Design Design of Clocked Sequential Circuits Example: Detect 3 or more consecutive 1’s Present State Input Next State Output A B x y 1 S0 / 0 S1 / 0 S3 / 1 S2 / 0 1 0 0 0 0 1 0 1 0 0 1 1 0 0 0 1 1 1 1 Dr. Bassam Kahhaleh

Design of Clocked Sequential Circuits Princess Sumaya University 4241 - Digital Logic Design Design of Clocked Sequential Circuits Example: Detect 3 or more consecutive 1’s Present State Input Next State Output A B x y 1 Synthesis using D Flip-Flops 0 0 0 0 1 0 1 0 0 1 1 0 0 0 1 1 1 1 A(t+1) = DA (A, B, x) = ∑ (3, 5, 7) B(t+1) = DB (A, B, x) = ∑ (1, 5, 7) y (A, B, x) = ∑ (6, 7) Dr. Bassam Kahhaleh

Design of Clocked Sequential Circuits with D F.F. Princess Sumaya University 4241 - Digital Logic Design Design of Clocked Sequential Circuits with D F.F. Example: Detect 3 or more consecutive 1’s Synthesis using D Flip-Flops B 1 A x DA (A, B, x) = ∑ (3, 5, 7) = A x + B x DB (A, B, x) = ∑ (1, 5, 7) = A x + B’ x y (A, B, x) = ∑ (6, 7) = A B B 1 A x B A 1 x Dr. Bassam Kahhaleh

Design of Clocked Sequential Circuits with D F.F. Princess Sumaya University 4241 - Digital Logic Design Design of Clocked Sequential Circuits with D F.F. Example: Detect 3 or more consecutive 1’s Synthesis using D Flip-Flops DA = A x + B x DB = A x + B’ x y = A B Dr. Bassam Kahhaleh

Flip-Flop Excitation Tables Princess Sumaya University 4241 - Digital Logic Design Flip-Flop Excitation Tables Present State Next State F.F. Input Q(t) Q(t+1) D 1 Present State Next State F.F. Input Q(t) Q(t+1) J K 1 0 0 (No change) 0 1 (Reset) 1 0 x 1 x x 1 x 0 1 0 (Set) 1 1 (Toggle) 0 1 (Reset) 1 1 (Toggle) 0 0 (No change) 1 0 (Set) Q(t) Q(t+1) T 1 1 Dr. Bassam Kahhaleh

Design of Clocked Sequential Circuits with JK F.F. Princess Sumaya University 4241 - Digital Logic Design Design of Clocked Sequential Circuits with JK F.F. Example: Detect 3 or more consecutive 1’s Present State Input Next State Flip-Flop Inputs A B x JA KA JB KB 1 Synthesis using JK F.F. JA (A, B, x) = ∑ (3) dJA (A, B, x) = ∑ (4,5,6,7) KA (A, B, x) = ∑ (4, 6) dKA (A, B, x) = ∑ (0,1,2,3) JB (A, B, x) = ∑ (1, 5) dJB (A, B, x) = ∑ (2,3,6,7) KB (A, B, x) = ∑ (2, 3, 6) dKB (A, B, x) = ∑ (0,1,4,5) 0 x 1 x x 1 x 0 0 x 1 x x 1 x 0 Dr. Bassam Kahhaleh

Design of Clocked Sequential Circuits with JK F.F. Princess Sumaya University 4241 - Digital Logic Design Design of Clocked Sequential Circuits with JK F.F. Example: Detect 3 or more consecutive 1’s Synthesis using JK Flip-Flops JA = B x KA = x’ JB = x KB = A’ + x’ B 1 A x B x A 1 B 1 x A B x 1 A Dr. Bassam Kahhaleh

Design of Clocked Sequential Circuits with T F.F. Princess Sumaya University 4241 - Digital Logic Design Design of Clocked Sequential Circuits with T F.F. Example: Detect 3 or more consecutive 1’s Present State Input Next State F.F. A B x TA TB 1 Synthesis using T Flip-Flops 1 1 TA (A, B, x) = ∑ (3, 4, 6) TB (A, B, x) = ∑ (1, 2, 3, 5, 6) Dr. Bassam Kahhaleh

Design of Clocked Sequential Circuits with T F.F. Princess Sumaya University 4241 - Digital Logic Design Design of Clocked Sequential Circuits with T F.F. Example: Detect 3 or more consecutive 1’s Synthesis using T Flip-Flops TA = A x’ + A’ B x TB = A’ B + B  x B 1 A x B 1 A x Dr. Bassam Kahhaleh