A Lesson on Digital Clocks, One Shots and Counters



Similar documents
A Lesson on Digital Clocks, One Shots and Counters

Experiment # 9. Clock generator circuits & Counters. Eng. Waleed Y. Mousa

Chapter 9 Latches, Flip-Flops, and Timers

Designing With the SN54/74LS123. SDLA006A March 1997

1. Learn about the 555 timer integrated circuit and applications 2. Apply the 555 timer to build an infrared (IR) transmitter and receiver

Lab Unit 4: Oscillators, Timing and the Phase Locked Loop

TS555. Low-power single CMOS timer. Description. Features. The TS555 is a single CMOS timer with very low consumption:

ETEC 2301 Programmable Logic Devices. Chapter 10 Counters. Shawnee State University Department of Industrial and Engineering Technologies

css Custom Silicon Solutions, Inc.

NTE2053 Integrated Circuit 8 Bit MPU Compatible A/D Converter

Pulse Width Modulation (PWM) LED Dimmer Circuit. Using a 555 Timer Chip

Features. Applications

MM74HC4538 Dual Retriggerable Monostable Multivibrator

ARRL Morse Code Oscillator, How It Works By: Mark Spencer, WA8SME

The components. E3: Digital electronics. Goals:

CHAPTER 11: Flip Flops

LM555/NE555/SA555. Single Timer. Description. Features. Applications. Internal Block Diagram. Vcc GND. Trigger. Discharge. Output F/F.

To design digital counter circuits using JK-Flip-Flop. To implement counter using 74LS193 IC.

Wiki Lab Book. This week is practice for wiki usage during the project.

css Custom Silicon Solutions, Inc.

3-Digit Counter and Display

Fairchild Semiconductor Application Note July 1984 Revised May Definition

A Digital Timer Implementation using 7 Segment Displays

Having read this workbook you should be able to: recognise the arrangement of NAND gates used to form an S-R flip-flop.

Operational Amplifier as mono stable multi vibrator

Lesson 12 Sequential Circuits: Flip-Flops

DM74121 One-Shot with Clear and Complementary Outputs

Latches, the D Flip-Flop & Counter Design. ECE 152A Winter 2012

PLL frequency synthesizer

NOTE: The Flatpak version has the same pinouts (Connection Diagram) as the Dual In-Line Package.

Fig1-1 2-bit asynchronous counter

Operating Manual Ver.1.1

EXPERIMENT 8. Flip-Flops and Sequential Circuits

Digital Systems Based on Principles and Applications of Electrical Engineering/Rizzoni (McGraw Hill

Module 3: Floyd, Digital Fundamental

Digital Logic Elements, Clock, and Memory Elements

NE555 SA555 - SE555. General-purpose single bipolar timers. Features. Description

How to Read a Datasheet

Registers & Counters

LM139/LM239/LM339 A Quad of Independently Functioning Comparators

LAB4: Audio Synthesizer

NE555 SA555 - SE555. General-purpose single bipolar timers. Features. Description

Counters. Present State Next State A B A B

AP331A XX G - 7. Lead Free G : Green. Packaging (Note 2)

Cascaded Counters. Page 1 BYU

Interfacing To Alphanumeric Displays

On/Off Controller with Debounce and

Digital Fundamentals

Counters and Decoders

Sequential Logic Design Principles.Latches and Flip-Flops

INTEGRATED CIRCUITS. NE558 Quad timer. Product data Supersedes data of 2001 Aug Feb 14

Asynchronous counters, except for the first block, work independently from a system clock.

ICS379. Quad PLL with VCXO Quick Turn Clock. Description. Features. Block Diagram

VOLTAGE-TO-FREQUENCY CONVERTER

WEEK 8.1 Registers and Counters. ECE124 Digital Circuits and Systems Page 1

Decimal Number (base 10) Binary Number (base 2)

Programmable Single-/Dual-/Triple- Tone Gong SAE 800

Memory Elements. Combinational logic cannot remember

Step Response of RC Circuits

MADR TR. Quad Driver for GaAs FET or PIN Diode Switches and Attenuators. Functional Schematic. Features. Description. Pin Configuration 2

Lab 11 Digital Dice. Figure Digital Dice Circuit on NI ELVIS II Workstation

DIGITAL COUNTERS. Q B Q A = 00 initially. Q B Q A = 01 after the first clock pulse.

Design Example: Counters. Design Example: Counters. 3-Bit Binary Counter. 3-Bit Binary Counter. Other useful counters:

1. Description. 2. Feature. 3. PIN Configuration

LM 358 Op Amp. If you have small signals and need a more useful reading we could amplify it using the op amp, this is commonly used in sensors.

Supply voltage Supervisor TL77xx Series. Author: Eilhard Haseloff

CERAMIC RESONATOR PRINCIPLES

INTEGRATED CIRCUITS. For a complete data sheet, please also download:

HCC4541B HCF4541B PROGRAMMABLE TIMER

HT9170 DTMF Receiver. Features. General Description. Selection Table

74LS193 Synchronous 4-Bit Binary Counter with Dual Clock

Asynchronous Counters. Asynchronous Counters

CD4027BMS. CMOS Dual J-K Master-Slave Flip-Flop. Pinout. Features. Functional Diagram. Applications. Description. December 1992

SN54/74LS192 SN54/74LS193

Sequential Logic: Clocks, Registers, etc.

INTEGRATED CIRCUITS. For a complete data sheet, please also download:

Standart TTL, Serie Art.Gruppe

Push-Pull FET Driver with Integrated Oscillator and Clock Output

Conversion Between Analog and Digital Signals

ASYNCHRONOUS COUNTERS

A simple RF/Microwave frequency counter

Chapter 8. Sequential Circuits for Registers and Counters

Objectives: Part 1: Build a simple power supply. CS99S Laboratory 1

NOTE: The Flatpak version has the same pinouts (Connection Diagram) as the Dual In-Line Package.

DS1307ZN. 64 x 8 Serial Real-Time Clock

ICS Pentium/Pro TM System Clock Chip. Integrated Circuit Systems, Inc. General Description. Pin Configuration.

Upon completion of unit 1.1, students will be able to

INTEGRATED CIRCUITS. For a complete data sheet, please also download:

SG2525A SG3525A REGULATING PULSE WIDTH MODULATORS

Engr354: Digital Logic Circuits

A Trigger Circuit for the 555 Timer IC Scope

IEC ESD Immunity and Transient Current Capability for the SP72X Series Protection Arrays

Building an Auto-Ranging DMM with the ICL7103A/ICL8052A A/D Converter Pair

Physics 623 Transistor Characteristics and Single Transistor Amplifier Sept. 13, 2006

Flip-Flops and Sequential Circuit Design. ECE 152A Winter 2012

Flip-Flops and Sequential Circuit Design

Designer s Encyclopedia of Bipolar One-Shots

CD4093BM CD4093BC Quad 2-Input NAND Schmitt Trigger

DIGITAL ELECTRONICS. Counters. By: Electrical Engineering Department

Transcription:

A Lesson on Digital Clocks, One Shots and Counters

Topics Clocks & Oscillators LM 555 Timer IC Crystal Oscillators Selection of Variable Resistors Schmitt Gates Power-On Reset Circuits One Shots Counters Binary Counters Mod-n Counters Frequency Division Using Counters

Two Types of Digital Circuits Combinational: outputs at any instant of time are entirely dependent on the inputs present at that time Sequential: external outputs are a function of external inputs but also the present state

Sequential Circuits Synchronous: system whose behavior is defined by its signals and states at discrete instances of time Asynchronous: system whose behavior depends upon the order in which its inout signals change and can be affected at any instance of time

What is a clock? A clock is a device with no inputs and one output, defined by: Frequency Duty Cycle Magnitude f = 1/T DC = +pw/t* 100 where: +pw is positive pulse width and T is period

LM555 Timer IC The 555 is a multi-function device. Function depends on external configuration and components. Clock (Astable) One-Shot (Monostable) Pulse-Width Modulator And others...

LM555 Clock +V f = 1.44 / [ C1 * (Ra + 2Rb) ] range: 0.01 Hz to 1.00 MHz Ra 7 RESET* DISCH 4 Vcc 8 dc = 100 * { 1 - [Rb / (Ra + 2Rb) ] } range: 50 to 100 % Rb 6 2 THRES TRIG LM555 OUT 3 C1 CONT GND Magnitude = 0 V to +V range: 4.5 to 16V C2 5 1 0.01uF

LM555 Clock Example Design a clock circuit using a 555 timer IC to produce a TTL clock with the given specs: f = 9600 Hz dc = 66.7 % Step 1: Select C1. Let C1 = 0.01 µf Step 2: Solve Ra vs. Rb ratio. 66.7 = 100 * {1 - [Rb / (Ra + 2Rb)]} 1.0 Rb = Ra Step 3: Solve for Exact Values 9600 Hz = 1.44 / [0.01 µf * (Ra + 2Rb)] 9600 Hz / 1.44 = 1 / [0.01 µf * (3.0*Rb)] Rb = 5000 Ω Ra = Rb = 5000 Ω

Crystal Oscillators Crystals: A crystal is made from a thinly cut piece of quartz sandwiched between two metal leads. Quarts crystals force oscillation at their natural (mechanical) frequency (or harmonics). The natural frequency is primarily a function of quartz thickness. Crystals stabilize the frequency of an oscillating circuit. They provide extremely good frequency stability (0.001 %).

Crystal Oscillator Circuits R1 R1 R2 C1 X1 C1 R2 X1 R3 R1 = R2 = 1 k C1 = 0.1 uf CMOS Series Oscillator TTL Series Oscillator Equations for CMOS Series Oscillator: R1 = 5 MΩ * e-(10 * 10-6f) R2 = 0.12 * R1 R3 = R2 / (0.3 Vcc - 0.5) Use the TTL circuit for Lab 3

Selection Of Variable Resistors Variable resistors or potentiometers (pots) are used to provide variable: frequencies duty cycles pulse widths They are also used to fine tune circuits to exact values. Fixed resistors do not come in every value. Pots can be used to get any value. However pots should be used with a series resistor.

Example: Design a clock that can produce a variable frequency output in the range 1200 to 9600 Hz. Step 1. Keeping C, and Ra the same, compute Rb for both frequencies. Assume 1200 Hz 9600 Hz Rb = 7.0K Ohms 2.7K Ohms Step 2. Use a combination of a fixed resistor in series with a pot for Rb such that: Rfixed < 2.7K Ohms Rfixed + Rpot > 7.0K Ohms Solution: Rfixed = 2.2K, 2.2K < Rb < 7.2K Rpot = 5K Keep the resistance of the pot large to have maximum variability. A small turn of the pot results in big change in frequency. Rb Rfixed Rpot

Example: A clock of frequency 9600 Hz +/- 0.1% is needed. Rb = 5000 Ohms - tolerance of resistors 20, 10, 5, 1% - tolerance of capacitors +80% to -20% Solution: Large fixed resistor in series with a small pot. Rfixed = 4700 Ohms, Rpot = 1K Ohms 4700 Ohms < Rb < 5700 Ohms Keep the fixed resistor value large compared to the pot to get best accuracy or maximum precision. CAUTION: Use pots sparingly: - cost: $pots > $fixed $ to adjust - mechanical: noisy, unreliable

Schmitt Gates Schmitt Gate Characteristics Schmitt gates are essentially TTL inverters that treat inputs slightly different from normal CMOS or TTL. The input logic level is always defined. Schmitt-trigger inputs have different input threshold levels depending on the direction of the input signal. (Hysteresis) Inputs going from a low to a high voltage affect the output at V t+ (positive threshold). Inputs going from a high to a low voltage affect the output at V t- (negative threshold). Logic Symbol Vih = 3.15V Vin Vil = 1.35V Logic 1 undefined Logic 0 4.4V Vout 0.1V Vt+ = 3.0V Vin Vt- = 1.5V 1.5V 3.0V Vin Logic 1 Last unambiguous logic level Logic 0 a) HC Inputs b) HC Schmitt Inputs

Schmitt Gates Schmitt Gate Applications Signal Conditioning: cleaning up noisy, or distorted digital signals Line Drivers & Receivers Clocks & Delay Circuits Vin Logic Input 3.0V 1.5V 1 0 t Logic Output 1 0

Schmitt Inverter Clock R1 1k +5V R R C1 Vx 1uF 14 1 2 IC1 7 Vout IC# Part# Vcc GND 1 74HC14 14 7 Vout 4.4V Vin Vin 4.4V Vout C C a) Vin == Logic 0 b) Vin == Logic 1 Assume C1 discharged before power is applied. Then Vx = 0.0V. Since Vx = Vin = logic 0, when power is applied Vout goes high (logic 1). Vth+ Vin Vth- 1 Input 0 1 Output 0 1 f t RC ln 2. 26

One Shot -- Monostable Multi-vibrators A one-shot is a circuit that produces a stable output (logic 1 or 0) until a trigger (+ or - edge) occurs. The trigger will cause the one-shot to produce a quasi-stable output for a time period determined by the circuit configuration. After the specified period of time, the output returns to the stable state. The pulse width of the quasi-stable state is independent of external stimulus. Usually, the pulse with is a function of a RC time constant. One-Shot TRIG OUT Tw = f(r,c) = 0.7RC (for a 74LS221) TRIG OUT Tw Tw A retriggerable one-shot output B Tw B non-triggerable one-shot output A

74LS221 Dual One-Shot The 74LS221 is a dual version of the 74LS121 TTL one-shot. The '221 has either a positive or negative edge trigger, and an active-high, or active-low output. C + 1Cext R 5 V 1Rext/Cext Tw = ln2 * RC range: 35 ns to 70 s for jitter free operation: 1A 1B 1CLR* 74LS221 (1/2) 1Q 1Q* 10 pf C 10 µf

Counters Binary Counters 0000,0001,0010,,1110,1111,0000 BCD Counters 0000,0001,,1000,1001,0000 Mod-n Counters 0,1,,n-1 or 1,2,,n 74HC161: 4-bit Counter 74HC190 BCD up/down Counter

Frequency Division Using Counters clk a b c d rco rco BCD Counter Timing Diagram Each bit on the output of a counter changes at a lower frequency than the previous bit. Freq d < Freq c < Freq b < Freq a < Freq clk How much of a difference are they?

Frequency Division Using Mod-n Counters f Mod-n clk counter F clk /n

Experiment #3: One Shots, Clocks and Counters Goals: Learn about one-shot circuits as pulse generators. Learn about crystal oscillators, counters and Mod-N counters. Prelab: Design a one-shot to produce an active low pulse from a positive-edge trigger. The pulse width should be the 4 msd s of your student ID as xxx.x ms. Suggestion Use the 74HC221 (or 74HC121) for one-shots. Complete the schematic diagram for a crystal TTL oscillator. Use a 4MHz crystal or other available crystal (<20MHz). Design an 8-bit synchronous counter. Design a Mod-7 counter that counts the sequence: 1,2,3,4,5,6,7 repeat. *Note-Review Experiment procedure for other Prelab needs.

Experiment Procedure: Build and test your one-shot. Measure Vhigh,Vlow,pulse width and rise time. Look for ringing and noise. Build and test your crystal oscillator. Measure: Vhigh, Vlow, frequency, Duty Cycle, pulse width and rise time. Measure frequency using the logic analyzer. Look for ringing and noise. Do not disassemble your circuit. Build and test your 8-bit counter. First use the CADET s TTL clock for trigger input. Then use a logic switch. Then use the bounceless pushbutton with a pull-up resistor. Connect the crystal oscillator output to the counter s trigger input. Measure the frequency at each counter output. Build and test your Mod-7 counter. Connect the output to a 7- segment display circuit.