The terms “pull up” and “pull down” resistors confused the heck out of me but I get it now.
A resistor limits current. In the water analogy, current is the speed of the flow of water. But I never knew what a pull up/pull down resistor was. Until a few weeks ago when I started building a set of buttons for a project I’m working on…
Essentially a button is a switch, when the switch is closed the current flows, when it’s open the current doesn’t flow. Now if your switch is open, without anything driving the circuit, the value on the line is going to float all over the place, sometimes high, sometimes low. Any electrical noise will cause a change in the circuit. This causes a problem as when reading a value off the circuit you might think the switch is closed when in fact it’s just floating high.
The circuit on the left uses a pull up resistor. If Vcc is +5Volts, that goes through the 10k resistor and has nowhere to go but to pin 1. So when the switch is open, pin 1 is showing +5Volts (but very low current due to the 10k). Pin 1 will be steady, it won’t float up or down since it’s got some power to it.
When you close the switch, the current flows to ground. It’s always going to go to ground if it can so Pin 1 will show 0Volts.
The pic on the right is the pull down resistor. Same thing but the 10k resistor is between the pin and ground, causing it to “pull down” whilst the switch is open. Once it’s closed the majority of the current flows through the pin vs going to ground hence the pin reads +5V.
It’s making sense to me and now that I’ve actually built some stuff from scratch, I’ve actually experienced this voltage float and fixed it with a pull down. This blog will help me remember it in a year.
P.S. The Image is from “Resistance 2″ on the PS3. Pardon the pun.