Counters and Registers

Slides:



Advertisements
Similar presentations
Counters and Registers
Advertisements

CHAPTER 3 Sequential Logic/ Circuits.  Concept of Sequential Logic  Latch and Flip-flops (FFs)  Shift Registers and Application  Counters (Types,
Flip-Flops, Registers, Counters, and a Simple Processor
Digital Logic Chapter 5 Presented by Prof Tim Johnson
Flip-Flops and Related Devices Wen-Hung Liao, Ph.D.
EKT 124 / 3 DIGITAL ELEKTRONIC 1
Counter Circuits and VHDL State Machines
Sequential Circuit - Counter -
Flip-Flops and Related Devices Wen-Hung Liao, Ph.D. 4/10/2002.
Homework Reading Machine Projects Labs Tokheim Chapter 9.1 – 9.6
ENGIN112 L27: Counters November 5, 2003 ENGIN 112 Intro to Electrical and Computer Engineering Lecture 27 Counters.
CS370 Counters. Overview °Counter: A register that goes through a prescribed series of states °Counters are important components in computers. °Counters.
Flip-Flops and Related Devices
M.S.P.V.L. Polytechnic College, Pavoorchatram
Asynchronous and Synchronous Counters
Counters and Registers Wen-Hung Liao, Ph.D.. Objectives Understand several types of schemes used to decode different types of counters. Anticipate and.
EET 1131 Unit 11 Counter Circuits  Read Kleitz, Chapter 12, skipping Sections and  Homework #11 and Lab #11 due next week.  Quiz next week.
Introduction Flip-flops are synchronous bistable devices. The term synchronous means the output changes state only when the clock input is triggered. That.
Chapter 3: Sequential Logic Circuit EKT 121 / 4 ELEKTRONIK DIGIT 1.
Counters  A counter is a device which stores (and sometimes displays) the number of times a particular event or process has occurred, often in relationship.
Design of Counters ..
Digital Fundamentals with PLD Programming Floyd Chapter 10
A presentation on Counters
Electronics Technology
Counters.
Chapter 1_4 Part II Counters
Counter Circuits and Applications Group 6 彭柏源 袁鋒 陳康本.
Chapter 7 Counters and Registers
Principles & Applications
Electronics Technology
Chapter 7 – Counters and Registers
Counter Application (Part B) By : Pn Siti Nor Diana Ismail CHAPTER 3.
Introduction to Chapter 7
© 2009 Pearson Education, Upper Saddle River, NJ All Rights ReservedFloyd, Digital Fundamentals, 10 th ed Digital Fundamentals Tenth Edition Floyd.
SEQUENTIAL CIRCUITS Component Design and Use. Register with Parallel Load  Register: Group of Flip-Flops  Ex: D Flip-Flops  Holds a Word of Data 
Counters By Taweesak Reungpeerakul
CYU / CSIE / Yu-Hua Lee / E- 1 數位邏輯 Digital Fundamentals Chapter 9 Counters.
ECEN 248: INTRODUCTION TO DIGITAL SYSTEMS DESIGN Lecture 17 Dr. Shi Dept. of Electrical and Computer Engineering.
Counters. November 5, 2003 Introduction: Counters  Counters are circuits that cycle through a specified number of states.  Two types of counters: 
CHAPTER 3 Counters.  One of the common requirement in digital circuits/system is counting, both direction (forward and backward)  Digital clocks and.
 Counters are sequential circuits which "count" through a specific state sequence. They can count up, count down, or count through other fixed sequences.
© 2009 Pearson Education, Upper Saddle River, NJ All Rights ReservedFloyd, Digital Fundamentals, 10 th ed Digital Fundamentals Tenth Edition Floyd.
Chapter 1_4 Part III more on … Counters Chapter 1_4 Part III more on … Counters.
CHAPTER 8 - COUNTER -.
Counter Circuits and VHDL State Machines
Sequential logic circuits
Counters and Registers
Decade Counter (BCD Counter). Introduction A counter which is reset at the 10 th clock pulse is called decade counter. The decade counter is otherwise.
Counters and Registers Synchronous Counters. 7-7 Synchronous Down and Up/Down Counters  In the previous lecture, we’ve learned how synchronous counters.
Counters.
Basic terminology associated with counters Technician Series
EKT 121 / 4 ELEKTRONIK DIGIT I
Unit 1 – Counters and Registers Mr. Grimming. Introduction FFs and logic gates are combined to form various counters and registers. Unit Goals Goals:
THEME 6: Frequency dividers. Digital counters with reduced counting modulus. Programmable digital counters. If the input pulses are more than K, the counter.
Ch.5 Flip Flops and Related Devices
1 Homework Reading –Tokheim Chapter 9.1 – 9.6 Machine Projects –Continue on mp3 Labs –Continue in labs with your assigned section.
Counters and Registers
FLIP FLOPS Binary unit capable of storing one bit – 0 or 1
Homework Reading Machine Projects Labs Tokheim Chapter 9.1 – 9.6
EET 1131 Unit 11 Counter Circuits
EKT 124 / 3 DIGITAL ELEKTRONIC 1
EKT 221 – Counters.
EKT 221 : Digital 2 COUNTERS.
Principles & Applications
Sequential Circuit - Counter -
Digital Fundamentals with PLD Programming Floyd Chapter 10
Counters and Registers
Counters and Registers
EET 1131 Unit 11 Counter Circuits
Chapter 8 Counters Changjiang Zhang
Presentation transcript:

Counters and Registers Wen-Hung Liao, Ph.D.

Objectives Understand the operation and characteristics of synchronous and asynchronous counters. Construct counters with MOD numbers less than 2N. Identify IEEE/ANSI symbols used in IC counters and registers. Construct both up and down counters. Connect multistage counters. Analyze and evaluate various types of presettable counters. Design arbitrary-sequence synchronous counters.

Objectives (cont’d) Understand several types of schemes used to decode different types of counters. Anticipate and eliminate the effects of decoding glitches. Compare the major differences between ring and Johnson counters. Analyze the operation of a frequency counter and of a digital clock. Recognize and understand the operation of various types of IC registers.

Asynchronous (Ripple) Counters FFs do not change states in exact synchronism with the applied clock pulses. In Figure 7-1, FF B must wait for FF A to change states before it can toggle. Similarly, FF C must wait for FF B to change states before it can toggle. Delay of 5-20 ns per FF Ripple Counter.

Figure 7-1: Four-Bit Ripple Counter

Signal Flow Convention: draw the circuits such that signal flow is from left to right. In this chapter, we often break this convention. For example, in Figure 7-1: FF A: LSB FF D: MSB

MOD Number The MOD number is equal to the number of states that the counter goes through in each complete cycle before it recycles back to its starting state. N flip-flops  MOD number=2^N Frequency division Problem: How to convert a 60Hz signal to a 1Hz signal using frequency division?

Counters with MOD number < 2^N Use asynchronous inputs to force the FFs to skip states. Refer to Figure 7-4, the NAND output is connected to the asynchronous CLEAR inputs of each FF. When A=0, B=C=1, (CBA = 1102= 610) the NAND output become active, resetting the FFs to 0.

Figure 7-4: MOD-6 Counter

Temporary State Notice that in Figure 7-4, 110 is a temporary state, so the state transition diagram for a MOD 6 counter does not stay at 110, but goes to 000 instead. 000001010011100101000 FF C output has a frequency equals to the one-sixth of the input frequency.

Construct a MOD X Counter Step 1: Find the smallest number of FFs such that 2^N >= X, and connect them as a counter. If 2^N=X, do not do steps 2 and 3. Step 2: Connect a NAND gate to the asynchronous CLEAR inputs of all the FFs. Step 3: Determine which FFs will be in the HIGH state at count = X; then connect the normal outputs of these FFs to the NAND gate inputs.

Examples Figure 7-6 (a): MOD-14 ripple counter

More Examples Figure 7-6 (b): MOD-10 ripple counter

Decimal/BCD Counter Widespread uses in applications where pulses and events are to be counted and the results displayed on some type of decimal numerical readout.

IC Asynchronous Counters TTL type: 74LS293: Four J-K flip-flops, Q3Q2Q1Q0 Each FF has a CP (clock pulse) input, just another name for CLK. The clock inputs to Q1 and Q0 are externally accessible (pin 11 and 10, respectively). Each FF has an asynchronous CLEAR input. These are connected together to the output of a two-input NAND gate with inputs MR1 and MR2. Q3Q2Q1 are connected as a 3-bit ripple counter. Q0 is not connected to anything internally.

Figure 7-8: 74LS293

Example: Figure 7-9 74LS293 wired as a MOD-16 counter.

More Examples Example 7-9: MOD-10 counter. Example 7-10: MOD-14 counter (an external AND gate is required in this case.) Example 7-11: cascading two 74LS293s to provide a MOD-60 counter. IEEE symbol: Figure 7.13 CMOS counter: 74HC4024 (7-bit counter)

Asynchronous Down Counter 111110101100011010001000 Driving each FF clock input from the inverted output of the preceding FF..

Propagation Delay Each FF introduces a delay of tpd Nth FF cannot change state until a time equal to Nxtpd after the clock transition occurs. Refer to Figure 7-16. Limit the maximum clock frequency.

Figure 7-16

Synchronous Counters All FFs are triggered simultaneously by the clock pulses. Figure 7-17. The CLK inputs are connected together. Only FF A has its J and K connected to HIGH, others are driven by some combination of FF outputs. Requires more circuitry than the asynchronous counterpart.

Synchronous MOD-16 Counter

Circuit Operation of Parallel Counter B must change state on each NGT that occurs while A=1 C must change state on each NGT that occurs while A=B=1 D must change state on each NGT that occurs while A=B=C=1 Design Principle: Each FF should have its J and K inputs connected such that they are HIGH only when the outputs of all lower-order FFs are in the HIGH state.

Advantages of Parallel Counter Total delay = FF tpd + AND gate tpd Actual IC: 74LS160/162, 74HC160/162: synchronous decade counters. 74LS161/163,74HC161/163: synchronous MOD-16 counters. Example 7-12.

Synchronous Down and Up/Down Counters Synchronous down counter: modify the connections in Figure 7-17. A A’, BB’… Up/Down counter: Figure 7-18.

Presettable Counters Starting state can be preset asynchronously or synchronously. The presetting operation is also referred to as parallel loading the counter. Refer to Figure 7-19.

The 74ALS193/HC193 MOD-16, presettable up/down counter with synchronous counting, asynchronous preset and asynchronous master reset. Figure 7-20: Clock inputs CPU and CPD Master reset (MR) Preset inputs Count outputs Terminal count outputs (when connecting two or more 74ALS193s.)

Figure 7-25 Multistage arrangement.

Decoding a Counter Use LEDs for small-size counter. Active-HIGH decoding (Figure 7-27) Active-LOW decoding

Decoding Glitches Caused by propagation delay. Temporary states are generated and may be detected by the AND decoder. Refer to Figure 7-30.

Solution Use parallel counters Strobing: use a strobe signal to keep the decoding AND gates disabled until all of the FFs have reached a stable state. (Figure 7-31)