**Driving An LED With Or Without A Resistor**

In this post I will try to show, why it’s a good idea to use a current limiting resistor for an LED. And when it’s save to drive the LED without any resistor.

If you read about LEDs, you will notice that everyone tells you, that you need a current limiting resistor. But mostly they do not tell you why.

### LED WITH CURRENT LIMITING RESISTOR

If we look at a datasheet of an LED, we will notice that graphs shown are not linear. An LED is a diode, a semiconductor and behaves differently compared to a resistor.

If we apply a specific voltage to a resistor, we can compute the resulting current with:

I = V / R Example: I = 5 Volt / 100 Ohm = 50 mA

Obviously that does not work with LEDs because they don’t behave like a linear resistor. If we look at the graph above, we can rise the voltage from 0 Volt to 1.6 Volt without resulting in noticeable current. Apply a bit more voltage and there is current and the LED lights up. We have reached the Forward Voltage which is needed to open the pn-gate. Forward Voltage (VF) for a typical red LED is 1.7 to 2.2 Volt. Now small changes in the voltage produce large effects on the resulting forward current (IF). Datasheets normally state at least the absolute maximum ratings for IF, eg. 25 mA. If we apply a voltage that results in a larger current, the LED may be destroyed.

So it’s vital to stay within the limits of the LED. If we would attach an LED to a 5 Volt power supply directly, we would burn it instantly. The high current would destroy the pn-gate. That’s the point where the current limiting resistor comes in.

Assuming, we have a red LED with maximum rating of IF: 25 mA at VF: 2.1 Volt. Its VF related to IF is like the curve in the graph at the top. If we want to use it at 5 Volt, we have to use a resistor to dissipate the remaining 2.9 Volt. To compute the resitor, we use:

R = V / I = (5 Volt - 2.1 Volt) / 25 mA = 116 Ohm.

To be safe we use a 120, or better, 150 Ohm resistor. That way we don’t drive the LED near it’s maximum rating. We choose 20 mA, take a look at the curve and see a corresponding VF of 2 Volts. Now we recalculate the resistor.

R = V / I = (5 Volt - 2 Volt) / 20 mA = 150 Ohm.

Ok, 150 Ohm is fine. To be safe with the resistor, we have to take a look at the power dissipation. It calculates as:

P = V * I = 3 Volt * 20 mA = 60 mW

So it’s safe to choose a 150 Ohm resistor with 1/4 Watt rating.

### LED WITHOUT CURRENT LIMITTING RESISTOR

First of all, why would we want to get rid of the resistor? There are two reasons. First is, it wastes energy. It converts electrical energy into heat. But we want to light up an LED. Not good.

Second is, we can reduce the number of components. The circuit gets cheaper, because we saved a resistor and maybe space on a PCB.

There are two ways to bypass the resistor. One way is to lower the input voltage. If we are able to run your complete circuit with the same voltage as forward voltage of the LED, perfect. No resistor needed.

Another method is to use pulse width modulation (PWM). That means we are switching the LED on and off. If we are switching fast enough, the human eye can not tell the difference. It integrates the brightness over time, so to speak. Often there is a Peak Forward Current (IF(peak)) rating in the datasheet. As an example:

IF(peak) = 160 mA

Condition: Pulse Width <= 1 msec and Duty <= 1/10

Which means, it is safe to switch the LED with 1 kHz, where the LED is on for 0.1 msec and off for 0.9 msecs.

**If I get something wrong or mixed things up, please feel free to comment on this.**

## No comments:

## Post a Comment