CAD FOR VLSI DESIGN - I Lecture 32. V. Kamakoti and Shankar Balachandran

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

Registers and Counters

ENGR 303 Introduction to Logic Design Lecture 10. Dr. Chuck Brown Engineering and Computer Information Science Folsom Lake College

ENGN3213 Digital Systems and Microprocessors Sequential Circuits

DEPARTMENT OF ELECTRICAL &ELECTRONICS ENGINEERING DIGITAL DESIGN

Synchronous Sequential Logic

Unit-5 Sequential Circuits - 1

EECS 3201: Digital Logic Design Lecture 9. Ihab Amer, PhD, SMIEEE, P.Eng.

CSCB58 - Lab 4. Prelab /3 Part I (in-lab) /1 Part II (in-lab) /1 Part III (in-lab) /2 TOTAL /8

EE178 Spring 2018 Lecture Module 5. Eric Crabill

EE178 Lecture Module 4. Eric Crabill SJSU / Xilinx Fall 2005

VARIABLE FREQUENCY CLOCKING HARDWARE

Sequential Design Basics

Sequential logic. Circuits with feedback. How to control feedback? Sequential circuits. Timing methodologies. Basic registers

Unit 11. Latches and Flip-Flops

CAD for VLSI Design - I Lecture 38. V. Kamakoti and Shankar Balachandran

Outputs Combinational circuit. Next state. Fig. 4-1 Block Diagram of a Sequential Circuit

ECE 545 Digital System Design with VHDL Lecture 2. Digital Logic Refresher Part B Sequential Logic Building Blocks

ACS College of Engineering. Department of Biomedical Engineering. HDL pre lab questions ( ) Cycle-1

Other Flip-Flops. Lecture 27 1

ECE 545 Digital System Design with VHDL Lecture 1. Digital Logic Refresher Part B Sequential Logic Building Blocks

Chapter 5 Synchronous Sequential Logic

HDL & High Level Synthesize (EEET 2035) Laboratory II Sequential Circuits with VHDL: DFF, Counter, TFF and Timer

Flip-Flops and Sequential Circuit Design

Sequential Logic. Sequential Circuits. ! Timing Methodologies " Cascading flip-flops for proper operation " Clock skew

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

Chapter 4: One-Shots, Counters, and Clocks

Digital Fundamentals: A Systems Approach

EECS150 - Digital Design Lecture 19 - Finite State Machines Revisited

Registers and Counters

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

CprE 281: Digital Logic

Registers & Counters. BME208 Logic Circuits Yalçın İŞLER

ECE 545 Digital System Design with VHDL Lecture 1B. Digital Logic Refresher Part B Sequential Logic Building Blocks

Digital Circuits ECS 371

Chapter 6. sequential logic design. This is the beginning of the second part of this course, sequential logic.

Chapter 5. Introduction

analysis with T flip-flops Follow the same procedure for JK flip-flops next state is determined by characteristic table or characteristic equation

Flip-flop and Registers

Modeling Latches and Flip-flops

CSE140: Components and Design Techniques for Digital Systems. More D-Flip-Flops. Tajana Simunic Rosing. Sources: TSR, Katz, Boriello & Vahid

Lecture 8: Sequential Logic

Register Transfer Level in Verilog: Part II

CSE140L: Components and Design Techniques for Digital Systems Lab. FSMs. Tajana Simunic Rosing. Source: Vahid, Katz

Two types of state machine as classified by output formation

Universal Asynchronous Receiver- Transmitter (UART)

SEQUENTIAL CIRCUITS SEQUENTIAL CIRCUITS

VeriLab. An introductory lab for using Verilog in digital design (first draft) VeriLab

Asynchronous (Ripple) Counters

Counters

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

Digital Logic Design Sequential Circuits. Dr. Basem ElHalawany

CSE115: Digital Design Lecture 23: Latches & Flip-Flops

! Two inverters form a static memory cell " Will hold value as long as it has power applied

Logic Design. Flip Flops, Registers and Counters

Digital Systems Laboratory 3 Counters & Registers Time 4 hours

Sequential Circuits. Sequential Logic. Circuits with Feedback. Simplest Circuits with Feedback. Memory with Cross-coupled Gates.

Linear-Feedback Shift-Registers (cont.)

55:131 Introduction to VLSI Design Project #1 -- Fall 2009 Counter built from NAND gates, timing Due Date: Friday October 9, 2009.

FSMD%Block%Diagram. FSM$Datapath*Systems. Datapath%Elements

4 of 40. Multi-ASIC reset synchronization Good Multi-Flip-Flop. Synthesis issues with reset nets. 3 of 40. Synchronous Resets? Asynchronous Resets?

Asynchronous & Synchronous Reset Design Techniques - Part Deux

Lab #5: Design Example: Keypad Scanner and Encoder - Part 1 (120 pts)

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

Sequential Circuit Design: Principle

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

Counter dan Register

Modeling Digital Systems with Verilog

Registers and Counters

IE1204 Digital Design F11: Programmable Logic, VHDL for Sequential Circuits

ELCT201: DIGITAL LOGIC DESIGN

Digital Fundamentals: A Systems Approach

CHAPTER1: Digital Logic Circuits

NH 67, Karur Trichy Highways, Puliyur C.F, Karur District DEPARTMENT OF INFORMATION TECHNOLOGY CS 2202 DIGITAL PRINCIPLES AND SYSTEM DESIGN

Synchronous Sequential Logic


CHAPTER 4: Logic Circuits

Individual Project Report

CMSC 313 Preview Slides

ELCT201: DIGITAL LOGIC DESIGN

CHAPTER 6 DESIGN OF HIGH SPEED COUNTER USING PIPELINING

EECS150 - Digital Design Lecture 13 - Project Description, Part 3 of? Project Overview

download instant at

Timing Pulses. Important element of laboratory electronics. Pulses can control logical sequences with precise timing.

0 0/1 0/1 0/1 0/1 0/1 0/1 0/1 0/1 1 1 Stop bits. 11-bit Serial Data format

IE1204 Digital Design. F11: Programmable Logic, VHDL for Sequential Circuits. Masoumeh (Azin) Ebrahimi

Feedback Sequential Circuits

Digital Circuit And Logic Design I. Lecture 8

Digital Circuit And Logic Design I

Laboratory Exercise 7

Chapter 5: Synchronous Sequential Logic

CprE 281: Digital Logic

Laboratory 4. Figure 1: Serdes Transceiver

Asynchronous Counter

Engr354: Digital Logic Circuits

ECE 263 Digital Systems, Fall 2015

CS 261 Fall Mike Lam, Professor. Sequential Circuits

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

6.S084 Tutorial Problems L05 Sequential Circuits

Combinational / Sequential Logic

Transcription:

CD FOR VLSI DESIGN - I Lecture 32 V. Kamakoti and Shankar Balachandran

Flip-flops with synchronous Preset and Clear Inferring a flip-flop with synchronous Preset and Clear comes out of a combination of clocked and non-clocked events inside an always block s sensitivity list. There is one clocked event, say, posedge clk or negedge clk

Cont d The remaining events are posedge or negedge, where can be any boolean expression. The always loop looks like always @(posedge or negedge B or posedge C or negedge D or posedge clk) if () <expression1> else if (!B) <expression2> else if (C ) <expression3> else if (!D) <expression4> else <expression5> Note that the conditions posedge in sensitivity list appears in the corresponding if as and similarly negedge in sensitivity list appears as! in the corresponding if.

Cont d <expression1>,,<expression4> forms the asynchronous part of the nested if while <expression5> forms the synchronous part (the default case). ny variable that is assigned both in the synchronous and asynchronous part becomes a flip-flop with asynchronous preset/clear. The logic that drives it in the asynchronous part drives the asynchronous preset/clear port of the corresponding flip-flop, while the logic that drives it in the synchronous part is assigned to the D- input

Cont d The variable that forms the Clocked event, (the default case) drives the clock input of the flip-flop.

n Example module synpreclrcounter(clock,preset,updown,clear,presetdata,counter); parameter NUM_BITS = 2; input Clock, Preset, UpDown, Clear; input [NUM_BITS 1:0] PresetData; output [NUM_BITS 1:0] Counter; reg [NUM_BITS-1:0] Counter; always @(posedge Preset or posedge Clear or posedge Clock) if (Preset) Counter <= PresetData; else if (Clear) Counter <= 0; else begin if (UpDown) Counter <= Counter + 1; else Counter <= Counter 1; end endmodule

B B 1 2 B1 B2 1 2 B1 B2 1 2 B1 B2 O122 O122 ND2 ND2 Preset Datel Preset INRBH INRBH PLLS3CX PLLS3CX 0 ON Preset Dateil PD CD PD CD Counter1 Clock Clock Up Down D1 D0 S0 D1 D0 S0 ON B

Caution When Preset is 1 and Presetdata changes, this will NOT be reflected in Verilog HDL but will be propogated to the flip-flops in the synthesized netlist. Be careful while using synchronous Inputs to flip-flops for functional mismatch.

nother Example module synflipflop(clk,reset,set,currentstate,nextstate); input Clk, Reset, Set; input [3:0] CurrentState; output [3:0] NextState; reg [3:0] NextState; always @(negedge Reset or negedge Set or negedge Clk) if (!Reset) NextState <=12; else if (!Set) NextState <= 5; else NextState <= CurrentState; endmodule

Current State0 0 PD NextState0 Set Reset B NR2 CD FD1S2CX INRBH 0 PDN NextState3 Current State3 FD1S2CX CDN FD1S2CX Current State1 INRBH 0 NextState1 B CD FD1S2CX Current State2 ND2 0 PD NextState2 FD1S2CX

Some Interesting facts Second flip-flop has only preset and third has only clear, while the others have both.

Flip-flops with Synchronous Preset/Clear Define the preset and clear logic inside a Clocked lways Statement. module SyncPresetCounter(Clock,Preset,UpDown,PresetData,Counter); input Clock, Preset, UpDown; input [0:NBITS-1] PresetData; output [0:NBITS-1] Counter; reg [0:NBITS-1] Counter; always @(negedge Clock) if (Preset) Counter <= PresetData; else if (UpDown) Counter <= Counter + 1; else Counter <= Counter 1; endmodule

Two pproaches Direct the PresetData input to synchronous preset input of the synthesized flip-flops Direct the PresetData input to the data input of the flip-flops. The following circuit is got using the latter option.

Preset Date1 Preset Clock D1 D0 S0 1 2 0 D1 0 D0 B B1 0122 B2 XDR2 S0 ON ON FL1S2X FL1S2X Counter0 Counter1 INRBH Preset Date0

nother Example module SyncFlipFlop (ClkB, Reset, Set, CurrentState, NextState); input ClkB, Reset, Set; input [3:0] CurrentState; output [3:0] NextState; reg [3:0] NextState; always @(negedge ClkB) if (!Reset) NextState <= 12; else if (!Set) NextState <= 5; else NextState <= CurrentState; endmodule

The Values The value 12, 5 and CurrentState are to be multiplexed and directed to the D inputs.

The Circuit Current State3 0 0 NextState3 B ND2 B ND2 0 0 ON FD1S2X NextState1 Reset Set B C ND3 ON NextState0 0 0 1 2 INRBH O121 INRBH ON INRBH B C NR3 0 0 NextState2 ON FD1S2X

Reference Chapter 2, Verilog HDL Synthesis, by J. Bhasker.

Questions and nswers Thank You