555 Timers — The Basics
What even mildly-seasoned electronics geek has not used or at least heard of the 555 timer?
Few, as 555 timers have been around since the early 1970’s.
The timers are great for creating pulses of varying widths, among other things.
Why not use a microcontroller instead?
For one thing using an Arduino or a PIC just to create pulses is like killing a mouse with a hand grenade. It works, but it’s an extreme over-kill.
Second comes cost. I talked about the cost of some popular “trainers” like the Arduino in my post about working directly with microcontrollers vs trainers. A 555 timer can be purchased for about $0.35 in quantities of one. Buy more and the price drops.
Things like PICs and trainer boards are not only more complex to work with, they take up more real estate and power than a tiny 555 chip.
There is a myriad of other uses for the timers including switch debouncing, tone generators, triangular waveform generators, a voltage controlled oscillator and more. In fact, people are still coming up with new used for these ICs to this day.
The original version, which consists of bipolar transistors, can make an oscillator with stability that approaches 1%. It can also run from a supply voltage of 4.5 V to 16 V.
Refer to the figure below. The architecture of the 555 timer is relatively simple. It consists of three resistors forming a voltage divider. Traditionally, each resistor is a 5k resistor, which is where the name of the IC comes from. Newer versions may have other values for the resistors that make up the voltage divider. The voltage divider sets the threshold and trigger values at 2/3 Vcc and 1/3 Vcc, respectively.
The three-resistor network feeds two comparators which in turn drive a SR flip-flop. The output of the flip-flop is feed into a transistor and also comes out to an external pin on the IC.
The 555 timer is used for many things, but there are two”classical” circuits that employ the 555 timer at their hearts. These are the astable multivibrator (a.k.a. free-running oscillator) and the other is the monostable (a.k.a. one-shot) circuit. Let’s discuss each one in more detail.
555 Timers and the Astable Circuit
Refer to the figure below (taken from an old text book) for the following discussion.
In an astable multivibrator, the 2 resistors and capacitor form the timing circuit that controls the frequency of the output. External capacitor C charges through R1 and R2. This charging and discharging of the capacitor triggers the comparators alternately. The comparators set and reset the flip-flop. This produces a rectangular waveform at the output.
Let’s go into a bit more detail.
Assume that power has just been applied and the capacitor is at 0 V. The output of the flip-flop will also be low. Because the output of the flip-flop is fed into an inverter, the output of the 555 timer is high.
When the trigger voltage rises above 1/3 Vcc, comparator 2 goes low, which does not affect the flip-flop. Now, when the capacitor’s voltage goes above 2/3 Vcc the upper comparator goes high and resets the flip-flop. When the output of the timer is low (as it is now in this example), discharge transistor Qd kicks on, shorting pin 7 to ground which discharges the capacitor through R2.
Once the voltage on the cap drops below 1/3 Vcc, the output of comparator 2 jumps back to high, which sets the flip-flop, and makes the output of the chip high once again. Because the output of the flip-flop is low, the transistor turns off and the cycle starts again resulting in a rectangular wave.
The formula for the frequency of this waveform is:
f = 1.44/(R1 + 2R2)*C
And the duty cycle of this waveform is calculated as:
Duty Cycle = (R1+R2)/(R1 + 2R2)
Notice how the duty cycle is independent of the capacitor value. One caveat of this circuit is that the duty cycle cannot be made less than 50%. However, there are ways to get around this and achieve duty cycles of less than 50% using other components, but I’ll save the more advanced circuits for another post.
555 Timers and the Monostable Circuit
As usual, refer to the figure below for the following discussion.
In the monostable (one-shot) configuration, the 555’s output is low before a pulse is applied to the trigger (pin 2). The transistor is on, which shorts pin 7 to ground, keeping the capacitor uncharged.
Recall that an SR flip-flop has 2 outputs (only one is shown in the first diagram above): Q and not Q.
When a negative pulse hits pin 2, comparator 2 goes high, setting the flip-flop’s not Q output low, which is the one connected to the transistor and the inverter at the chip’s output (the Q output of the flip-flop is not used) making the output of the 555 timer high. This turns the transistor off which allows the capacitor to charge up through R to 2/3 Vcc. Once it reaches this level, comparator 1 goes high which causes the transistor to turn on again, discharging the cap. The output of the timer holds at this state (hence the names monostable and one-shot) until another negative pulse hits the trigger.
Something as simple as a momentary push button switch can provide the pulse that triggers the 555.
The formula for determining the width of the output pulse is:
Pulse Width = 1.1RC.
A Few Important Notes About 555 Timers
- We haven’t talked about the control voltage pin (pin 5). This pin can be used for a variety of things, including constructing a VCO (voltage controlled oscillator). To do this, set the chip up in the astable configuration, then apply some sort of variable control voltage to pin 5 rather than a bypass capacitor. This works by changing the threshold values of 1/3 Vcc and 2/3 Vcc to something else for the internal comparators.
- When not using the control voltage pin, you should add a 0.01 μF bypass cap between it and ground to help prevent false triggering.
- If you need more than one timer per IC, the 556 contains two 555 timers and the 558 is the quad version.
- Since its inception, new and better versions of the 555 have emerged. For example, the CMOS version surpasses the original version in all areas except output current capability. Other versions of the 555 timer will operate down to 1 V. There’s even one that’s like a microcontroller in the respect that it’s programmable: the CSS555, which sports an internal programmable counter.
The 555 timer is an old, but still very useful and versatile IC. Be sure to keep a few of them lying around. Also, try experimenting with some of the newer versions. As popular as these chips are, I doubt this is the last time we’ll be discussing them on this blog.
What other uses have you found for 555 timers? Comment and share!
- Floyd, Thomas L. Electronic Devices, 5th Ed. Prentice Hall, 1999. Print.
- Scherz, Paul & Monk, Simon. Practical Electronics for Inventors, 4th Ed. McGraw Hill, 2016. Print.
FREE Guide: 10 Mistakes ALL Electronic Enthusiasts Make
Learn the mistakes made by newbies and veterans alike...
... and HOW to avoid them