Registers & Counters Registers. Shift Registers: Counters:

Slides:



Advertisements
Similar presentations
1 Sequential Circuits Dr. Pang. 2 Outline Introduction to sequential circuits Basic latch Gated SR latch and gated D latch D flip-flop, T flip-flop, JK.
Advertisements

Digital Digital: Chapter 8. Sequential Logic Design Practices 1 Chapter 8. Sequential Logic Design Practices.
CMPUT Computer Organization and Architecture II1 CMPUT329 - Fall 2003 TopicJ: Counters José Nelson Amaral.
CMPUT Computer Organization and Architecture II1 CMPUT329 - Fall 2003 TopicJ: Counters José Nelson Amaral.
Homework Reading Machine Projects Labs Tokheim Chapter 9.1 – 9.6
EECC341 - Shaaban #1 Final Review Winter Final Exam Review Combinational Logic Building Blocks: –Decoders, Encoders, Multiplexers, Demultiplexers.
Sequential PLD timing Registers Counters Shift registers
Chapter 7 - Part 2 1 CPEN Digital System Design Chapter 7 – Registers and Register Transfers Part 2 – Counters, Register Cells, Buses, & Serial Operations.
C.S. Choy1 SEQUENTIAL LOGIC A circuit’s output depends on its previous state (condition) in addition to its current inputs The state of the circuit is.
Sistemas Digitais I LESI - 2º ano Lesson 8 - Sequential Design Practices U NIVERSIDADE DO M INHO E SCOLA DE E NGENHARIA Prof. João Miguel Fernandes
Sequential Circuit Introduction to Counter
Lab 5 :JK Flip Flop and Counter Fundamentals:
KU College of Engineering Elec 204: Digital Systems Design
What is shift register? A shift register is a digital memory circuit found in calculators, computers, and data-processing systems. Bits (binary digits)
Registers and Counters
Counters and Registers
Lecture 21 Overview Counters Sequential logic design.
Counters.
EKT 124 / 3 DIGITAL ELEKTRONIC 1
Registers and Counters
Chapter 1_4 Part II Counters
1 Sequential Circuits Registers and Counters. 2 Master Slave Flip Flops.
EE345: Introduction to Microcontrollers Register and Counters Prof. Ahmad Abu-El-Haija.
Registers and Counters
ECE2030 Introduction to Computer Engineering Lecture 15: Registers, Toggle Cells, Counters Prof. Hsien-Hsin Sean Lee School of Electrical and Computer.
Registers and Counters
EE24C Digital Electronics Projects
Registers CPE 49 RMUTI KOTAT.
1 Registers and Counters A register consists of a group of flip-flops and gates that affect their transition. An n-bit register consists of n-bit flip-flops.
Digital Design: Principles and Practices
CEG 360/560; EE 451/651 Digital System Design Dr. Travis Doom, Associate Professor Department of Computer Science and Engineering Wright State University.
P. 4.1 Digital Technology and Computer Fundamentals Chapter 4 Digital Components.
Synchronous Counters with SSI Gates
EKT 221/4 DIGITAL ELECTRONICS II  Registers, Micro-operations and Implementations - Part3.
DIGITAL ELECTRONICS WORKSHOP
2017/4/24 CHAPTER 6 Counters Chapter 5 (Sections )
Princess Sumaya Univ. Computer Engineering Dept. Chapter 6:
EE365 Adv. Digital Circuit Design Clarkson University Lecture #12 Registers and Counters.
Counters By Taweesak Reungpeerakul
Digital Design Lectures 11 & 12 Shift Registers and Counters.
7-6 단일 레지스터에서 Microoperation Multiplexer-Based Transfer  Register 가 서로 다른 시간에 둘 이상의 source 에서 data 를 받을 경우 If (K1=1) then (R0 ←R1) else if (K2=1) then.
 Counters are sequential circuits which "count" through a specific state sequence. They can count up, count down, or count through other fixed sequences.
1 Registers & Counters Logic and Digital System Design - CS 303 Erkay Savaş Sabancı University.
Registers and Counters Chapter 6. Digital Circuits 2 Clocked sequential circuits a group of flip-flops and combinational gates connected to form a feedback.
Chap 5. Registers and Counters. Chap Definition of Register and Counter l a clocked sequential circuit o consist of a group of flip-flops & combinational.
© 2009 Pearson Education, Upper Saddle River, NJ All Rights ReservedFloyd, Digital Fundamentals, 10 th ed Digital Fundamentals Tenth Edition Floyd.
Registers Page 1. Page 2 What is a Register?  A Register is a collection of flip-flops with some common function or characteristic  Control signals.
Sequential Logic Circuit
Sequential Logic Circuit
Sequential logic circuits
Synchronous Counter with MSI Gates
EKT 124 / 3 DIGITAL ELEKTRONIC 1
EE121 John Wakerly Lecture #9
Counters.
SYEN 3330 Digital SystemsJung H. Kim 1 SYEN 3330 Digital Systems Chapter 7 – Part 2.
Chap 5. Registers and Counters
Counters and registers Eng.Maha Alqubali. Registers Registers are groups of flip-flops, where each flip- flop is capable of storing one bit of information.
Digital Design: Sequential Logic Blocks
Homework Reading Machine Projects Labs Tokheim Chapter 9.1 – 9.6
Registers and Counters
Synchronous Counter with MSI Gates
Prof. Hsien-Hsin Sean Lee
Sequential Logic Counters and Registers
3.2 Shift Register Basic shift register function
Digital Fundamentals with PLD Programming Floyd Chapter 10
Synchronous Counters with MSI Gates
Synchronous Counters with MSI Gates
CSE 370 – Winter Sequential Logic-2 - 1
Switching Theory and Logic Design Chapter 5:
Johnson Counter Program Studi T. Elektro FT - UHAMKA Slide - 10.
Presentation transcript:

Registers & Counters Registers. Shift Registers: Counters: Serial in, serial out shift register Serial in, parallel out shift register Parallel in, serial out shift register Parallel in, parallel out shift register Shift Register Applications Counters: Ripple Counters Synchronous Counters Counter Applications

Registers An n-bit register is a collection of n D flip-flops with a common clock used to store n related bits. D 1Q CLR Q /1Q 1D 2Q /2Q 2D 3Q /3Q 3D 4Q /4Q 4D CLK /CLR 74LS175 Example: 74LS175 4-bit register CLK CLR 4Q 3Q 2Q 1Q 74LS175 1D 2D 3D 4D

Shift Registers Multi-bit register that moves stored data bits left/right ( 1 bit position per clock cycle) Shift Left is towards MSB 0 1 1 1 LSI Q3 Q2 Q1 Q0 1 1 1 LSI Q3 Q2 Q1 Q0 Shift Right (or Shift Up) is towards MSB RSI 0 1 1 Q3 Q2 Q1 Q0 RSI 0 1 1 1 Q3 Q2 Q1 Q0

Serial In, Serial Out Shift Register D Q CLK · SERIN CLOCK SEROUT SRG n > SI SO For a n-bit SRG: Serial Out = Serial In delayed by n clock period 4-bit shift register example: serin: 1 0 1 1 0 0 1 1 1 0 serout: - - - - 1 0 1 1 0 0 clock:

Serial In, Parallel Out Shift register SRG n > SI 1Q · 2Q nQ D Q CLK · SERIN CLOCK nQ 2Q 1Q (SO) Serial to Parallel Converter 4-bit shift register example: serin: 1 0 1 1 0 0 1 1 1 0 1Q: - 1 0 1 1 0 0 1 1 1 2Q: - - 1 0 1 1 0 0 1 1 3Q: - - - 1 0 1 1 0 0 1 4Q: - - - - 1 0 1 1 0 0 clock:

Parallel In, Serial Out Shift Register SERIN CLOCK D Q CLK · SEROUT LOAD/SHIFT 1D 2D ND S L 1Q 2Q NQ Parallel to Serial Converter Load/Shift=1 Di Qi Load/Shift=0 Qi Qi+1

Parallel In, Parallel Out Shift Register SERIN CLOCK D Q CLK · LOAD/SHIFT 1D 2D ND 1Q 2Q NQ S L General Purpose: Makes any kind of (left) shift register

Bi-directional Universal Shift Registers 4-bit Bi-directional Universal (4-bit) PIPO CLK CLR S1 S0 LIN D QD C QC B QB A QA RIN 11 1 10 9 7 6 4 5 3 2 12 13 14 15 74x194 Modes: Hold Load Shift Right Shift Left R L Mode Next state Function S1 S0 QA* QB* QC* QD* Hold 0 0 QA QB QC QD Shift right/up 0 1 RIN QA QB QC Shift left/down 1 0 QB QC QD LIN Load 1 1 A B C D

Universal SR Circuit 74x194 SL HO LD SR D Q CLK CLR D Q CLK CLR CLK (11) /CLR (1) S1 S0 74x194 RIGHT LIN (7) SL HO LD SR 10 LEFT 00 (12) D Q CLK CLR QD (6) D 11 01 (10) S1 10 (9) S0 00 (15) D Q CLK CLR QA (3) A 11 (2) RIN 01 Universal SR Circuit

Shift Register Applications State Registers Shift registers are often used as the state register in a sequential device. Usually, the next state is determined by shifting right and inserting a primary input or output into the next position (i.e. a finite memory machine) Very effective for sequence detectors Serial Interconnection of Systems keep interconnection cost low with serial interconnect Bit Serial Operations Bit serial operations can be performed quickly through device iteration Iteration (a purely combinational approach) is expensive (in terms of # of transistors, chip area, power, etc). A sequential approach allows the reuse of combinational functional units throughout the multi-cycle operation

Shift Register Applications: Serial Interconnection of Systems CLOCK Transmitter Receiver Control Circuits Control Circuits /SYNC Parallel Data from A-to-D converter Parallel Data to D-to-A converter Serial-to-parallel converter Parallel-to-serial converter Serial DATA n One bit n

Shift Register Applications Example: 8-Bit Serial Adder ... 7 6 5 > x7 x6 x5 x0 y7 y6 y5 y0 FA Cout S Cin A B D Q CLK CLR CLEAR_C z7 z6 z5 z0 CTL Sequential Implementation of: Z[7..0] = X[7..0] + Y[7..0] V

Counters Clocked sequential circuit with single-cycle state diagram Modulo-m counter = divide-by-m counter Most Common: n-bit binary counter, where m = 2n Ù n flip-flops, counts 0 … 2n-1 S3 S2 S1 Sm

4-bit Ripple Counter 1 bit divide-by-2 Q T CLK Q0 Q1 Q2 Q3 2 bit Uses Minimal Logic 3 bit divide-by-8 4 bit divide-by-16

Ripple Counter Timing CLK 1D Q0 Q1 2D Q2 3D 0 1 2 3 4

Ripple Counter Problem n · TCQ for MSB change for n-bit ripple counter => minimum clk period CLK 1D Q0 Q1 2D Q2 3D 7 Should be 0 1 2

Synchronous Counters All clock inputs connected to common CLK signal All flip-flop outputs change simultaneously tCQ after CLK Faster than ripple counters More complex logic Most frequently used type of counter

Synchronous Serial Counter Q EN CLK CNTEN Q0 Q1 Q2 Q3 Flip-flops enabled when all lower flip-flops = 1. Enable propagates serially — limits speed Requires (n-1) D t < TCLK All outputs change simultaneously tCQ after CLK D t D t D t

Synchronous Parallel Counter CNTEN Q0 EN Q CLK >T Q1 >T Q EN Single-level enable logic per flip-flop Fastest and most complex type of counter Requires D t < TCLK All outputs change simultaneously tCQ after CLK Q2 >T Q EN Q3 >T Q EN

74X163 4-bit Synchronous Parallel Counter Common Clock Synchronous Clear Synchronous Load Count Enable = ENP · ENT Load Data Inputs >CLK CLR LD ENP ENT A B C D QA QB QC QD RCO LSB MSB RCO = Ripple Carry Out, when Count = 1111 and ENT = 1

74X163 State Table Inputs Current State Next State /CLR /LD ENT ENP QD QC QB QA QD* QC* QB* QA* 0 X X X 1 0 X X 1 1 0 X 1 1 1 0 1 1 1 1 Clear Load Hold Count . X X X X 0 0 0 0 0 0 0 1 0 0 1 0 0 0 1 1 0 1 0 0 0 1 0 1 0 1 1 0 0 1 1 1 1 0 0 0 1 0 0 1 1 0 1 0 1 0 1 1 1 1 0 0 1 1 0 1 1 1 1 0 1 1 1 1 0 0 0 0 D C B A QD QC QB QA 0 0 0 1 0 0 1 0 0 0 1 1 0 1 0 0 0 1 0 1 0 1 1 0 0 1 1 1 1 0 0 0 1 0 0 1 1 0 1 0 1 0 1 1 1 1 0 0 1 1 0 1 1 1 1 0 1 1 1 1 0 0 0 0

74X169 Up/Down Counter 74X169 UP/DN = 1 = up Ù RCO = 15 UP/DN = 0 = down Ù RCO = 0 up down up Ex: 0,1,2, 1,0,15,14, 15,0,1,2 RCO RCO >CLK UP/DN LD ENP ENT A B C D QA QB QC QD RCO

Counter Applications Count the number of times an event takes place Control the number of steps in a sequence of fixed actions (a sequencer) Generate timing signals (frequency divider, etc.) ENTER UP Decoder CLK CTR DIV 6 > COUNTER CLR_R DOWN EXIT IN_A 1 EN IN_B 2 3 EXE 1 4 EXE # of spaces Comparator 2 5 OUT_C < = 4 6 7 Lot Open Lot Full >