We started talking about this in another thred, and 603 had the idea that someone should make a post where people could talk about adding LEDs to projects.
So I thought I would start with the basics.
Places to Buy:
The two most comment trypes of LEDs you are most likly going to see or uses are 3mm and 5mm. You can pick them up at radio shack or online. They are also the type you will see in most flashlights, or even the solar powered lamps for your yard.
You will need to know a couple things before you start hooking up your LEDs.
Your source voltage (1.5v, 9v, 12v, ect.). IE the battery you are using for power. AA battery is 1.5v a computer power source is 5v. All of them say on them somplace how much thier voltage is. Even on transformers (power bricks) you might have from an old printer or cell phone will say power in power out. Power out would be your source voltage.
You will need to know the Voltage Drop Across or Forward Voltage for the LED. This is the amount of voltage to get the LED to work correctly. The information can normally be found on-line or on the LED package. If you don't know the exact voltage rating of the led, you can use the following values as guide lines.
Standard Red: 1.7
Super Bright Red: 2.2
Standard Green: 2.2
High Intensity Blue: 4.5
High Intensity White: 4.5
Disired LED Current. Amout of current that the led uses when powered up properly. 3mm and 5mm LEDs usually operate in the range of 20 - 30 mA. 20 mA is usually a good value to go with.
With these three numbers you can uses the calculator to figure out what type of resistor you will need.
Why do you need a resistor? Well, if you notice most of the LEDs uses around 3V or less. So if you plug a 9v into a 3mm Red that needs only 1.7V it will glow bright for about half a second and then start smoking. Resistors reduce the ammount of voltage that gets to the LED.
So lets do a quick calculation: You have a 9v Battery and one Super Blue LED you want to uses. So we know our voltage, 9. And the VDA for this moddel is 3.6V. Current we want is 20mA. So the resistor we need is 330 omhs. The calculator is great when you have a large collection of LEDs all running off one power source.
BUT it is important to remember how you will be turning them on and off. If you don't want them to all come on at once, or you have different switches for each one, then you want to calculate based on how many are coming on with that one switch. Its just a good rule of thumb.