Counters - II. Outline  Synchronous (Parallel) Counters  Up/Down Synchronous Counters  Designing Synchronous Counters  Decoding A Counter  Counters.

Slides:



Advertisements
Similar presentations
Lecture 23: Registers and Counters (2)
Advertisements

Registers and Counters
Sequential Circuit - Counter -
RIPPLE COUNTERS A register that goes through a prescribed sequence of states upon the application of input pulses is called a counter. The input pulses.
Homework Reading Machine Projects Labs Tokheim Chapter 9.1 – 9.6
Counters Mano & Kime Sections 5-4, 5-5. Counters Ripple Counter Synchronous Binary Counters –Design with D Flip-Flops –Design with J-K Flip-Flops Counters.
Registers and Counters
CS370 Counters. Overview °Counter: A register that goes through a prescribed series of states °Counters are important components in computers. °Counters.
ECE 331 – Digital System Design Counters (Lecture #18)
Digital Logic Design Lecture 24. Announcements Homework 8 due today Exam 3 on Tuesday, 11/25. – Topics for exam are up on the course webpage.
M.S.P.V.L. Polytechnic College, Pavoorchatram
Sequential Logic Combination logic: outputs are based on a combination of present inputs only. Sequential logic: outputs depend on present and past inputs.
Sequential Circuit Introduction to Counter
A.Abhari CPS2131 Registers A register is a group of n flip-flops each of them capable of storing one bit of information There are two types of registers:
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  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 ..
CHAPTER 3 Counters.  One of the common requirement in digital circuits/system is counting, both direction (forward and backward)  Digital clocks and.
Counters.
A State Element “Zoo”.
Registers and Counters
Chapter 1_4 Part II Counters
Flip-Flop Applications Registers.  a register is a collection of flip-flops  basic function is to hold information  a shift register is a register.
Counter Section 6.3.
Sequential Circuit - Counter -
ECE 301 – Digital Electronics Counters (Lecture #16)
Registers & Counters M. Önder Efe
CHAPTER 6 MODULAR SQUENTIAL CIRCUITS & APPLICATIONS
CS1104 – Computer Organization Aaron Tan Tuck Choy School of Computing National University.
Rabie A. Ramadan Lecture 3
Counters Dr. Rebhi S. Baraka Logic Design (CSCI 2301) Department of Computer Science Faculty of Information Technology The Islamic University.
2017/4/24 CHAPTER 6 Counters Chapter 5 (Sections )
Princess Sumaya Univ. Computer Engineering Dept. Chapter 6:
Counters By Taweesak Reungpeerakul
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: 
Counters - I. Outline  Introduction: Counters  Asynchronous (Ripple) Counters  Asynchronous Counters with MOD number < 2 n  Asynchronous Down Counters.
CHAPTER 3 Counters.  One of the common requirement in digital circuits/system is counting, both direction (forward and backward)  Digital clocks and.
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.
Chapter 1_4 Part III more on … Counters Chapter 1_4 Part III more on … Counters.
Chapter 1 Counters. Counters Counters are sequential circuits which "count” through a specific state sequence. They can count up, count down, or count.
Digital Logic Design.
C HAPTER S IX R EGISTERS AND C OUNTERS 1. A clocked sequential circuit consists of a group of flip-flops and combinational gates connected to form a feedback.
Digital Electronics.
Counters.
Basic terminology associated with counters Technician Series
Basic Counters: Part I Section 7-6 (pp ).
SYEN 3330 Digital SystemsJung H. Kim 1 SYEN 3330 Digital Systems Chapter 7 – Part 2.
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.
CHAPTER 14 Digital Systems. Figure 14.1 RS flip-flop symbol and truth table Figure
1 Registers A register is a group of n flip-flops each of them capable of storing one bit of information There are two types of registers: parallel and.
1 CHAPTER 12 REGISTERS AND COUNTERS This chapter in the book includes: Objectives Study Guide 12.1Registers and Register Transfers 12.2Shift Registers.
Chapter 35 Sequential Logic Circuits. Objectives After completing this chapter, you will be able to: –Describe the function of a flip-flop –Identify the.
Synchronous Counters, ripple counter & other counters Lecture 2
UP/DOWN SYNCHRONOUS COUNTERS An up/down counter is one that is capable of progressing in either direction through a certain sequence. An up/down counter,
CS1104 – Computer Organization Aaron Tan Tuck Choy School of Computing National University.
Sequential Logic Counters and Registers
Sequential Circuit: Counter
Dr. Clincy Professor of CS
Presented by Ali Maleki Spring Semester, 2009
Registers and Counters Register : A Group of Flip-Flops. N-Bit Register has N flip-flops. Each flip-flop stores 1-Bit Information. So N-Bit Register Stores.
29-Nov-18 Counters Chapter 5 (Sections ).
Digital Logic Department of CNET Chapter-6
Digital Logic Department of CNET Chapter-6
Counters.
Presentation transcript:

Counters - II

Outline  Synchronous (Parallel) Counters  Up/Down Synchronous Counters  Designing Synchronous Counters  Decoding A Counter  Counters with Parallel Load

Outline  Synchronous (Parallel) Counters  Up/Down Synchronous Counters  Designing Synchronous Counters  Decoding A Counter  Counters with Parallel Load

Synchronous (Parallel) Counters  Synchronous (parallel) counters: the flip-flops are clocked at the same time by a common clock pulse.  We can design these counters using the sequential logic design process.  Example: 2-bit synchronous binary counter (using T flip-flops, or JK flip-flops with identical J,K inputs)

Synchronous (Parallel) Counters  Example: 2-bit synchronous binary counter (using T flip-flops, or JK flip-flops with identical J,K inputs). TA 1 = A 0 TA 0 = 1 1 K J K J A1A1 A0A0 C C CLK Q Q' Q Q

Synchronous (Parallel) Counters  Example: 3-bit synchronous binary counter (using T flip-flops, or JK flip-flops with identical J, K inputs). TA 2 = A 1.A 0 A2A2 A1A1 A0A0 1 1 TA 1 = A 0 TA 0 = 1 A2A2 A1A1 A0A A2A2 A1A1 A0A

Synchronous (Parallel) Counters  Example: 3-bit synchronous binary counter (cont’d). TA 2 = A 1.A 0 TA 1 = A 0 TA 0 = 1 1 A2A2 CP A1A1 A0A0 K Q JK Q JK Q J

Synchronous (Parallel) Counters  Note that in a binary counter, the n th bit (shown underlined) is always complemented whenever 011…11  100…00 or111…11  000…00  Hence, X n is complemented whenever X n-1 X n-2... X 1 X 0 = 11…11.  As a result, if T flip-flops are used, then TX n = X n-1. X n X 1. X 0

Synchronous (Parallel) Counters  Example: 4-bit synchronous binary counter. TA 3 = A 2. A 1. A 0 TA 2 = A 1. A 0 TA 1 = A 0 TA 0 = 1 1 K J K J A1A1 A0A0 C C CLK Q Q' Q Q K J A2A2 C Q K J A3A3 C Q A 1.A 0 A 2.A 1.A 0

Synchronous (Parallel) Counters  Example: Synchronous decade/BCD counter. T 0 = 1 T 1 = Q 3 '.Q 0 T 2 = Q 1.Q 0 T 3 = Q 2.Q 1.Q 0 + Q 3.Q 0

Synchronous (Parallel) Counters  Example: Synchronous decade/BCD counter (cont’d). T 0 = 1 T 1 = Q 3 '.Q 0 T 2 = Q 1.Q 0 T 3 = Q 2.Q 1.Q 0 + Q 3.Q 0 1 Q1Q1 Q0Q0 CLK T C Q Q' Q Q2Q2 Q3Q3 T C Q Q T C Q Q T C Q Q

Outline  Synchronous (Parallel) Counters  Up/Down Synchronous Counters  Designing Synchronous Counters  Decoding A Counter  Counters with Parallel Load

Up/Down Synchronous Counters  Up/down synchronous counter: a bidirectional counter that is capable of counting either up or down.  An input (control) line Up/Down (or simply Up) specifies the direction of counting.  Up/Down = 1  Count upward  Up/Down = 0  Count downward

Up/Down Synchronous Counters  Example: A 3-bit up/down synchronous binary counter. TQ 0 = 1 TQ 1 = (Q 0.Up) + (Q 0 '.Up' ) TQ 2 = ( Q 0.Q 1.Up ) + (Q 0 '. Q 1 '. Up' ) Up counter TQ 0 = 1 TQ 1 = Q 0 TQ 2 = Q 0.Q 1 Down counter TQ 0 = 1 TQ 1 = Q 0 ’ TQ 2 = Q 0 ’.Q 1 ’

Up/Down Synchronous Counters  Example: A 3-bit up/down synchronous binary counter (cont’d). TQ 0 = 1 TQ 1 = (Q 0.Up) + (Q 0 '.Up' ) TQ 2 = ( Q 0.Q 1.Up ) + (Q 0 '. Q 1 '. Up' ) 1 Q1Q1 Q0Q0 CLK T C Q Q' Q T C Q Q T C Q Q Up Q2Q2

Outline  Synchronous (Parallel) Counters  Up/Down Synchronous Counters  Designing Synchronous Counters  Decoding A Counter  Counters with Parallel Load

Designing Synchronous Counters  Covered in previous units.  Example: A 3-bit Gray code counter (using JK flip-flops)

Designing Synchronous Counters  3-bit Gray code counter: flip-flop inputs Q2Q2 Q1Q0Q1Q0 XXXX 1 JQ 2 = Q 1.Q 0 ' Q2Q2 Q1Q0Q1Q0 XXXX 1 KQ 2 = Q 1 '.Q 0 ' Q2Q2 Q1Q0Q1Q0 XX XX1 JQ 1 = Q 2 '.Q Q2Q2 Q1Q0Q1Q0 XX XX 1 KQ 1 = Q 2.Q Q2Q2 Q1Q0Q1Q0 XX XX1 JQ 0 = Q 2.Q 1 + Q 2 '.Q 1 ' = (Q 2  Q 1 )' Q2Q2 Q1Q0Q1Q0 XX XX1 1 KQ 0 = Q 2.Q 1 ' + Q 2 '.Q 1 = Q 2  Q 1

Designing Synchronous Counters  3-bit Gray code counter: logic diagram. JQ 2 = Q 1.Q 0 ' JQ 1 = Q 2 '.Q 0 JQ 0 = (Q 2  Q 1 )' KQ 2 = Q 1 '.Q 0 ' KQ 1 = Q 2.Q 0 KQ 0 = Q 2  Q 1 Q1Q1 Q0Q0 CLK Q2Q2 J C Q Q' K J C Q K J C Q K Q2'Q2' Q0'Q0' Q1'Q1'

Outline  Synchronous (Parallel) Counters  Up/Down Synchronous Counters  Designing Synchronous Counters  Decoding A Counter  Counters with Parallel Load

Decoding A Counter  Decoding a counter involves determining which state in the sequence the counter is in.  Differentiate between active-HIGH and active-LOW decoding.  Active-HIGH decoding: output HIGH if the counter is in the state concerned.  Active-LOW decoding: output LOW if the counter is in the state concerned.

Decoding A Counter  Example: MOD-8 ripple counter (active-HIGH decoding). A' B' C' Clock HIGH only on count of ABC = 000 A' B' C HIGH only on count of ABC = 001 A' B C' HIGH only on count of ABC = ABCABC HIGH only on count of ABC =

Decoding A Counter  Example: To detect that a MOD-8 counter is in state 0 (000) or state 1 (001). A' B' Clock HIGH only on count of ABC = 000 or ABC =  Example: To detect that a MOD-8 counter is in the odd states (states 1, 3, 5 or 7), simply use C. C Clock HIGH only on count of odd states 100 A' B' C' A' B' C

Outline  Synchronous (Parallel) Counters  Up/Down Synchronous Counters  Designing Synchronous Counters  Decoding A Counter  Counters with Parallel Load

Counters with Parallel Load  Counters could be augmented with parallel load capability for the following purposes:  To start at a different state  To count a different sequence  As more sophisticated register with increment/decrement functionality.

Counters with Parallel Load  Different ways of getting a MOD-6 counter: Count = 1 Load = 0 CP I 4 I 3 I 2 I 1 Count = 1 Clear = 1 CP A 4 A 3 A 2 A 1 Inputs = 0 Load (a) Binary states 0,1,2,3,4,5. I 4 I 3 I 2 I 1 A 4 A 3 A 2 A 1 Inputs have no effect Clear (b) Binary states 0,1,2,3,4,5. I 4 I 3 I 2 I 1 Count = 1 Clear = 1 CP A 4 A 3 A 2 A Load (d) Binary states 3,4,5,6,7,8. I 4 I 3 I 2 I 1 Count = 1 Clear = 1 CP A 4 A 3 A 2 A Load Carry-out (c) Binary states 10,11,12,13,14,15.

Counters with Parallel Load  4-bit counter with parallel load.