Sequential Circuit Timing. Young Won Lim 11/6/15

Similar documents
FSM Examples. Young Won Lim 11/6/15

Finite State Machine (1A) Young Won Lim 6/9/18

Higher Order ODE's (3A) Young Won Lim 7/7/14

Higher Order ODE's (3A) Young Won Lim 12/27/15

Expected Value (10D) Young Won Lim 6/12/17

Relations (3A) Young Won Lim 3/27/18

Matrix Transformation (2A) Young Won Lim 11/10/12

General CORDIC Description (1A)

Detect Sensor (6B) Eddy Current Sensor. Young Won Lim 11/19/09

Root Locus (2A) Young Won Lim 10/15/14

CT Rectangular Function Pairs (5B)

Background Trigonmetry (2A) Young Won Lim 5/5/15

Fourier Analysis Overview (0A)

DFT Frequency (9A) Each Row of the DFT Matrix. Young Won Lim 7/31/10

Higher Order ODE's (3A) Young Won Lim 7/8/14

General Vector Space (2A) Young Won Lim 11/4/12

Line Integrals (4A) Line Integral Path Independence. Young Won Lim 10/22/12

Matrix Transformation (2A) Young Won Lim 11/9/12

Capacitor Young Won Lim 06/22/2017

Introduction to ODE's (0A) Young Won Lim 3/9/15

Signal Functions (0B)

Group Delay and Phase Delay (1A) Young Won Lim 7/19/12

Capacitor in an AC circuit

Bayes Theorem (10B) Young Won Lim 6/3/17

Separable Equations (1A) Young Won Lim 3/24/15

Complex Trigonometric and Hyperbolic Functions (7A)

Discrete Time Rect Function(4B)

Fourier Analysis Overview (0A)

Propagating Wave (1B)

Down-Sampling (4B) Young Won Lim 10/25/12

Complex Series (3A) Young Won Lim 8/17/13

Audio Signal Generation. Young Won Lim 1/29/18

Discrete Time Rect Function(4B)

Dispersion (3A) 1-D Dispersion. Young W. Lim 10/15/13

Capacitor and Inductor

Capacitor and Inductor

Fourier Analysis Overview (0B)

Down-Sampling (4B) Young Won Lim 11/15/12

Group & Phase Velocities (2A)

Up-Sampling (5B) Young Won Lim 11/15/12

Digital Signal Octave Codes (0A)

The Growth of Functions (2A) Young Won Lim 4/6/18

Magnetic Sensor (3B) Magnetism Hall Effect AMR Effect GMR Effect. Young Won Lim 9/23/09

Higher Order ODE's, (3A)

Line Integrals (4A) Line Integral Path Independence. Young Won Lim 11/2/12

Signals and Spectra (1A) Young Won Lim 11/26/12

Bayes Theorem (4A) Young Won Lim 3/5/18

Implication (6A) Young Won Lim 3/17/18

Linear Equations with Constant Coefficients (2A) Young Won Lim 4/13/15

ODE Background: Differential (1A) Young Won Lim 12/29/15

Propositional Logic Resolution (6A) Young W. Lim 12/12/16

Digital Signal Octave Codes (0A)

Definitions of the Laplace Transform (1A) Young Won Lim 1/31/15

Sequential Logic Worksheet

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

CLTI System Response (4A) Young Won Lim 4/11/15

Digital Signal Octave Codes (0A)

Complex Functions (1A) Young Won Lim 2/22/14

Propositional Logic Resolution (6A) Young W. Lim 12/31/16

Differentiation Rules (2A) Young Won Lim 1/30/16

Digital Signal Octave Codes (0A)

Audio Signal Generation. Young Won Lim 2/2/18

Phasor Young Won Lim 05/19/2015

CT Correlation (2A) Young Won Lim 9/9/14

Digital Signal Octave Codes (0A)

Hamiltonian Cycle (3A) Young Won Lim 5/5/18

General Vector Space (3A) Young Won Lim 11/19/12

Resolution (7A) Young Won Lim 4/21/18

Background LTI Systems (4A) Young Won Lim 4/20/15

Audio Signal Generation. Young Won Lim 2/2/18

CSE 140 Midterm 2 - Solutions Prof. Tajana Simunic Rosing Spring 2013

Digital Signal Octave Codes (0A)

EECS Components and Design Techniques for Digital Systems. FSMs 9/11/2007

Propositional Logic Logical Implication (4A) Young W. Lim 4/11/17

Group Velocity and Phase Velocity (1A) Young Won Lim 5/26/12

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

Implication (6A) Young Won Lim 3/12/18

CMOS Inverter. Young Won Lim 3/31/16

Models for representing sequential circuits

Capacitor in an AC circuit

Introduction to ODE's (0P) Young Won Lim 12/27/14

Surface Integrals (6A)

Capacitor in an AC circuit

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

Metastability. Introduction. Metastability. in Altera Devices

Propositional Logic Logical Implication (4A) Young W. Lim 4/21/17

Capacitor in an AC circuit

Example: vending machine

Capacitor in an AC circuit

Capacitor in an AC circuit

Differentiation Rules (2A) Young Won Lim 2/22/16

Capacitor in an AC circuit

Laboratory Exercise #8 Introduction to Sequential Logic

Review: Designing with FSM. EECS Components and Design Techniques for Digital Systems. Lec09 Counters Outline.

Bandpass Sampling (2B) Young Won Lim 3/27/12

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

Timing Constraints in Sequential Designs. 63 Sources: TSR, Katz, Boriello & Vahid

Capacitors in an AC circuit

Background ODEs (2A) Young Won Lim 3/7/15

Design of Datapath Controllers

Transcription:

Copyright (c) 2011 2015 Young W. Lim. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled "GNU Free Documentation License". Please send corrections (or suggestions) to youngwlim@hotmail.com. This document was produced by using OpenOffice and Octave.

Latches and FF's 3

Register D 3 D Q Q 3 D 2 D Q Q 2 D 1 D Q Q 1 D 0 D Q Q 0 CLK CLK without delay without delay

Types of Diagrams a timing diagram without delays no delay (ideal case) no delay (ideal case) a timing diagram with delays input delay output delay Clk->Q 5

DFF Testbench module dff(d, clk, rst, q, qb); input d, clk, rst; output q, qb; reg q; always @(posedge clk) begin if (~rst) q = 0; else q = d; end assign qb = ~q; endmodule Nonblocking Assignments Blocking Assignments <= = initial begin clk =0; d =0; rst =1; rst =0; #20 rst = 1; #10 d <= 0; #10 d <= 0; $finish; end #10 d = 1; #10 d = 0; #10 d = 1; #10 d = 0; #10 d = 1; #10 d = 1; `timescale 1ns/100ps module dff_tb; reg d, clk, rst; dff U1 (d, clk, rst, q, qb); always #10 clk = ~clk; initial begin $dumpfile("test.vcd"); $dumpvars(0, dff_tb); end endmodule 6

Testbench with Nonblocking Assignments module dff(d, clk, rst, q, qb); input d, clk, rst; output q, qb; reg q; always @(posedge clk) begin if (~rst) q = 0; else q = d; end assign qb = ~q; endmodule initial begin clk =0; d =0; rst =1; rst =0; #20 rst = 1; #10 d <= 0; #10 d <= 0; $finish; end `timescale 1ns/100ps module dff_tb; reg d, clk, rst; dff U1 (d, clk, rst, q, qb); always #10 clk = ~clk; initial begin $dumpfile("test.vcd"); $dumpvars(0, dff_tb); end endmodule 7

DFF Testbench Waveforms Nonblocking Assignments #10 d <= 0; #10 d <= 0; samples the unchanged d input values at the posedge of clk Blocking Assignments #10 d = 1; #10 d = 0; #10 d = 1; #10 d = 0; #10 d = 1; #10 d = 1; samples the changed d input values at the posedge of clk 8

Blocking Assignments #10 d = 1; #10 d = 0; #10 d = 1; #10 d = 0; #10 d = 1; #10 d = 1; always @(posedge clk) begin if (~rst) q = 0; else q = d; end clk:0 1 d:0 1 d:1 0 @(posedge clk) At the posedge of clk clk has changed to 1 Also, d has changed to its new value 9

Nonblocking Assignments Nonblocking Assignments #10 d <= 0; #10 d <= 0; In each of time slot which is delayed by 10 time units, there is only one assignment that can be scheduled simultaneously, (1) Allowing scheduling of assignments without waiting for its completion (2) Executed last in the time step in which it is scheduled (after all blocking assignments' execution) Regular Events samples the unchanged d input values at the posedge of clk Nonblocking Update Events Monitor Events Evaluate So, the input d update is done Update after the posedge clk 10

FF Input and Output Delays No delay No delay t d1 t d2 Inputs with delays t d3 Output with a delay 11

Reg to Reg 12

Clock Skew Clock skew Clock Source 13

Path Delay X X delay due to combinational blocks Y Y 1

Setup & Hold Time (1) Inputs with delays Output with a delay set up time hold time 15

Setup & Hold Time (2) 16

Clock Gating CLK EN possible clock skew problem EN 17

Max Path / Min Path Max path contamination delay propagation delay min path t c d the output is changing t c d t c d t delay 18

Rise / Fall Times t r Rise Time t pd f Fall Time Rise Time t pd r Fall Time t f v in v out v in t f t r = 2.2 τ n 2.2 τ p β n β p > 1 τ n τ p = R nc out R p C out R n R p < 1 = R n R p < 1 β n = 1.0 β p β n = 1.5 β p β n = 2.0 β p v out t pdf t pdr 19

PVT Variation Process Voltage Temperature High temperature Low temperature 20

FF Output Delay t c cq contamination delay propagation delay t p cq t c cq t p cq flipflop clock-to-q t c cq t delay t p cq 21

Path Delay t c d contamination delay propagation delay t c d combinational logic delay t c d t delay 22

Reg-to-Reg Delay (1) t c cq t FF t p cq t c cq t p cq t c d t c d t comb t c cq t p cq t c cq + t cd t delay t p cq + t pd t c d 23

Reg-to-Reg Delay (2) t c cq t FF t p cq t c d t comb t c cq t c d t c cq + t cd t delay t p cq + t pd t p cq 2

Setup Time / Hold Time Setup Time OK Setup Time Violation t p cq t p cq Hold Time OK Hold Time Violation t c cq t c d t c cq + t c d 25

Setup Time / Hold Time Setup Time Violation This part has been stabilized t p cq This is the intended operation Hold Time Violation Since the delay is too small signal passes through the 2nd FF t c cq + t c d 26

Resolution Time 27

References [1] http://en.wikipedia.org/ [2] M. M. Mano, C. R. Kime, Logic and Computer Design Fundamentals, th ed. [3] J. Stephenson, Understanding Metastability in FPGAs. Altera Corporation white paper. July 2009.