Today we'll turn our attention to yet another dedicated purpose chip: the 555 timer. While not the newest or fanciest way of generating signals, it is cheap, reliable, and well-known. While they're kind of a meme in the world of hobbyist electronics, you can do some surprisingly cool things with them like drive ultrasonic transducers to levitate things or amplify signals as part of a geiger counter. Let's dig into what it does.
The 555 timer is an integrated circuit (IC) that is primarily used to make square waves of a known frequency. It is a powered device, and therefore requires connections from pin 1 to ground and from pin 8 to a supply voltage ($V_{CC}$, typically +5 V) in order to function.
Many integrated circuits are fabricated on essentially a 2d piece of silicon. The way we interface our pin connections to that silicon is often done by bonding tiny gold wires to pads at the edge of the silicon. To avoid having wires cross one another (which could result in unexpected shorts), they're typically connected to whatever pin is closest physically. Since chips are typically manufactured at a massive scale, it is usually worth it to design a compact circuit in silicon that doesn't match up to human conventions in order to save space. More chips per cm${}^2$ means faster production and lower costs. All this is to the best knowledge of the author; there may well be other reasons for this design choice as well.
The 555 timer has two states: on and off.
The 555 timer has two inputs, the trigger ($\overline{\mathrm{TR}}$ ) and the threshold ($\mathrm{TH}$), which are typically wired together. The values of these inputs are compared to specific voltages, and the outcomes of these comparisons determine whether or not the 555 timer changes state.
Although the threshold and trigger voltages may change the 555 timer’s state, there is no current in or out of either pin (since they effectively have infinite input impedance). There may, however, be current at the other four pins, depending on the configuration. The reset ($\mathrm{R}$) pin will disable or reset the timer if it is at ground or lower, so it generally is tied to $V_{CC}$ to prevent unwanted behavior.
If you want some practice thinking through the logic of how this works, there is a tutorial exercise available here. This was meant to be done in class as guided practice, but it could still be useful on its own.
You might ask yourself why we're introducing new chips, if we can accomplish the same thing with other components we already know how to use. The answer is twofold: specialized parts tend to do the job better than general ones, and we'd like you to get comfortable learning about how to go about using new components and learning about them from their descriptions and datasheets. There are thousands upon thousands of different devices out there that can accomplish lots of useful tasks without the need to design a system from scratch, such as the SN74LS247N
which makes driving seven segment displays easy, to the MMA8452Q triple-axis accelerometer, which can be used to tell what direction something is facing or if a device is falling. Modern circuit design is often a mix of finding the right parts for the job and then adapting them to the situation at hand.
Alright, now that we've talked about what the chip's designed to do, we'll put it to work making an oscillator for us.
Let's start with a couple of predictions (If you did the tutorial these will be familiar). Assume the chip initially starts in the on state.
How long will it take the capacitor to charge up to the threshold voltage $\left(\frac{2}{3}V_{CC}\right)$?
After the chip is off, how long will it take the capacitor to discharge enough to turn the chip back on?
Finally, how long will it take in the next cycle for the capacitor to charge from $\frac{1}{3}V_{CC}$ to $\frac{2}{3}V_{CC}$ ?
If you get stuck, look at the “Astable Operation” section (7.4.2) of the datasheet. lm555.pdf Their schematic is drawn differently, but it has the same topology and thus the circuit is the same)
What is the resulting period of oscillation for this circuit's output?
Now that you have some idea of how the circuit works (or are thoroughly flummoxed), build it on your breadboard so that you can test it. Note that we don't do anything with pins 4 or 5 for now; that's coming up later.
Characterize the signals you see at both $V_{out}$ and across the capacitor, $V_C$. Do they behave as expected?
Connect your piezo speaker (shown below) with an inline resistor between $V_{out}$ and ground to listen to the dulcet tones of your circuit. I'd suggest using a wire you can easily disconnect when wiring this, especially if you don't want your classmates to disconnect it percussively.
Your signal will be distorted somewhat when you attach your speaker, but the effect will be greatly mitigated with the 100$\Omega$ resistor inline with it. This also results in the sound volume being reduced greatly, as you're effectively making about a 10:1 voltage divider. A properly designed transistor circuit would be able to boost the volume substantially, if you want to experiment with this sort of thing in your copious free time.
What do you hear when the speaker is connected?
Predict how the frequency of the sound would change (increase or decrease) if $R_2$ were replaced with a 2.2k resistor
Test your prediction and resolve any discrepancies.
Keep your circuit built, you'll be modifying it throughout the lab.
As you noticed, you get a somewhat lopsided square wave out of this circuit, because the capacitor charges through both resistors but only discharges through $R_2$. To fix this, we can use our good friend the diode (Use a 1N914, the smaller ones) to make it so that the capacitor charges through $R_1$ and discharges through $R_2$, letting us create a wider array of signals.
A modified circuit that allows for more flexibility in waveform. Note that the diode will result in slightly slower charging through $R_1$ due to the 0.6 V drop.
Modify your circuit by adding a diode, and observe its behavior.
What effect did adding the diode have on the output's waveform (without the speaker attached)?
What effect did adding the diode have on the speaker's sound?
Remember that pin 5 that we told you not to worry about before? It is the control pin, and it is used to modify the typical trigger and threshold settings by altering a voltage divider circuit. If we feed a different voltage threshold, then when our input signal is low it will result in the capacitor charging to a lower voltage, (causing quicker oscillations) and when it is higher it will take the capacitor longer to charge, resulting in slower oscillations.
See the wikipedia page for a schematic of the internals. It does include flip-flops, which you haven't encountered yet, and an inverter, which does exactly what you'd think.
Use the adjustable power supply for $V_{in}$, using a voltage between between 1 V and 4 V for $V_{in}$. (Why? Because it behaves fairly well in this regime.)
Do your tests support the idea that higher control voltages lead to the output staying high longer?
To start out with, we're going to modify the circuit in a few ways:
The first two changes is to up the frequency of the chip's output to 200+ kHz, well outside the audible range. The second will make it so that (when combined with the resistors internal to the timer) we'll effectively make a biased high-pass filter to let our AC signal modify the existing threshold values
Set the function generator to make a 1k Hz, 5V peak-to-peak square wave, but leave it off for the moment
Predict what parts of the square wave will correspond to higher/lower frequencies.
To make observations a little easier, set the scope to trigger off of this square wave signal. Test your circuit, and resolve any discrepancies between your predictions and observations.
What happens when you change the frequency and amplitude of the modulating signal?
Finally, let's try reconnecting the speaker to the circuit.
To test the difference the modulating signal makes, connect/disconnect the wire that goes to the pin 5 capacitor. (Turning off the channel on the function generator may give unanticipated results)
What difference does the modulating signal make?
You can also try changing the frequency and amplitude of the modulating signal. For bonus funky noises, go to the menu for your modulating signal and add a linear or log sweep.
By modulating one signal with another, you can send information much more reliably than you could with a pure analog signal. If you transmit a low-amplitude analog signal, you're likely to pick up a lot of unwanted noise along the way. But, if you use that signal to modulate a square wave, you can keep (much) of the same information while having to worry a lot less about noise, because we've essentially encoded the amplitude of our original signal as a frequency in our carrier.
This can also be used to play audio over things that were never meant to do so, such as toothbrushes, tesla coils, or (profanity warning) piezoelectrics hidden in electric drills. More practically, this is what lets the vibration motor in your phone make patterns instead of just buzzing.
In physics, sometimes we'll generate signals that are modulated in a similar manner, such as from a Surface Acoustic Wave (SAW) sensor. These sensors will reflect back signals of a certain frequency with modifications based on their physical parameters, and can be used for things like high temperature thermometers that don't need wires running directly to them.
Currently under maintenance for 2024.
Portions of this page are adapted from “Flexible Resources for Analog Electronics” by Stetzer and Van De Bogart .