2017-04-12

LED lighting circuits

The topic of LED lighting is a popular one, perhaps because there are always so many answers!

The big question is always how much resistance is needed to protect the LEDs, but this usually leads to other questions: "How bright do you want the LEDs to be and how much voltage will be used to power them?"

This page is now superseded by a more comprehensive page: Modelling with LEDs 

The original content is still below....

First, a bit of technical stuff...

White LEDs
Usually we are talking about white LEDs, so the tables below assume white LEDs (warm or cool white). Such LEDs have what is called a  forward voltage of 2.8 to 3 Volts. That means they will light up when they get between 2.8 and 3 Volts. Giving them more than 3V will shorten their life considerably. (Minutes or seconds!)

Most LEDs can take 20mA (milliamps) or even 30mA of current but I suggest running them at around 15 mA for a number of reasons:
  • 20mA can tend to be too bright
  • 20mA is too close to their maximum rating, meaning small variations in the power supply or other components may cause them to blow
LEDs can only use DC power and their polarity matters. Because of this I often install a diode in the circuit bringing power into a building using LEDs. This is simply to ensure that if I connect the wires to the building incorrectly, I won't destroy all the lights in an instant. The additional diode consumes between 0.5 V and 0.7 Volts

The next factor to consider is how many LEDs are to be powered on a single string. This is limited by voltage of the power supply. Each LED will use up its forward voltage (2.8V to 3 V), so a 12V supply could drive 4 LEDs per sub circuit.

Each little string of multiple LEDs (with their own resistor) will draw the same amount of current as a string with just 1 LED in it.  i.e. a circuit with 4 LEDs running at 15mA would also use 15mA with 4 LEDs (and would use a smaller resister).

The number of sub circuits you can connect to a single power supply is determined by the sum of all the mA used by all the sub circuits. So if your power supply can supply 1 Amp (1000 mA) of power, and you circuits draw 15mA each then you can power 66 such circuits (1000 / 15). If your power supply is rated in Watts, simply divide the Wattage by the Voltage to get the Amperage it can provide.  For example, a 24 W power supply at 12 Volts can provide 2 Amps.

Resistor values
Though resistors are available in almost all resistor values (Ohms), there are common sizes that are much more available and cheaper. So, after calculating a resistance, you should pick the next higher common resistor size.

Power supply
I recommend using a 12 Volt DC power supply for accessory lighting. PC power supplies are cheap and provide lots of Amperage, allowing you to power lots of lights. For convenience I have highlighted the 12 Volt column in the table below.

So here is a table of resistor values for between 1 and 7 LEDs connected in series using various voltages.


Here is how to use the tables:
  1. If you are not including a diode, use the upper table. If you are, use the lower table.
  2. Determine the voltage of your DC power supply. That determines what column you will use.
  3. Look at the row that matches the number of LEDs you want to string together into a circuit.
For example, a circuit with 3 LEDs, powered by 12 Volts, with a diode suggests a 200 Ohm resistor is needed. (This will run all 3 LEDs at 15mA.)

The next biggest common resistor size is 220Ω
(See http://www.logwell.com/tech/components/resistor_values.html for resistor size tables or search for "Decade resistor values")

The circuit will look like this (Components can be in any order)

AC supply

If your power supply is AC and you don't want to see flicker in the LEDs, then you need to rectify the power. Here is a sample circuit you can use. (You can use between 1 and 7 LEDs using the first table and the 22V column)
It uses:
4x  1N4001 diodes
2x 3mm white LEDs
1x 1100 Ohm resistor (2 LEDs)
and when soldered up it looks like this:

Note that when you rectify AC power, the resultant DC voltage is 1.4 times that of the AC voltage. So rectified 16 V AC will give you about 22 Volts DC

Note

If the components in your circuit are not high quality, their electrical characteristics may change after being powered up for a few minutes. If you suspect that your components are a bit flaky, here is how to determine what resistor to use:

  1. Select the resistor using the tables above.
  2. Using an ammeter, measure the current in the circuit. Let it sit a good 3 or 4 minutes. If the mA reading starts climbing above the desired amperage (15mA) remove the power and increase the size of the resistor, and try again. (To measure the current your ammeter must be in series with the circuit.) If the stable current reading is too low ( < 15mA) then decrease the size of the resistor and try again.
A variable voltage power supply comes in very handy when reducing resistor size, as one can start with a low voltage and bring it up to voltage while watching the mA reading, thus preventing LED damage by using a resistor that is too small.

Note that throughout this page I work towards 15mA - you may find that is still too bright depending on where you are placing the LEDs, if that is the case simply increase the size of the resistor. You can also add more than one resistor (in series) if you have bought a bunch of one size and you need more resistance.

LED related posts