# Ohms law + led

Discussion in 'LEDs and Optoelectronics' started by juantravel, Nov 6, 2010.

1. ### juantravel

41
0
May 14, 2010
Hello forum

I have a few questions if anyone got the time to correct me or answer some.
I have some knowledge of hardware, but mostly software(programming). I don't have much time for my hobby's. Due to work and family, so please excuse me for being rusty.
Ohms law is V=IxR, I=V/R, R=V/I.
If i have a 5 volt supply and want to power a led. To get the resistor value I would use:
voltage_source - led_voltage / 20 mA = Resistor_value

In parallel it would be:
voltage_source - led_voltage /(20 mA x number_of_leds) = Resistor_value

I have seen resistors in series with leds coming out of a micro. The micro can only output 25mA. So the resistor is pretty much there for the voltage drop?
5v - 2v / 25mA = 120 ohm

2. ### (*steve*)¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥdModerator

25,412
2,780
Jan 21, 2010
you need parentheses, and you need to use the correct units!

(voltage_source - led_voltage) / 0.020 A = Resistor_value

and

(voltage_source - led_voltage) / (led_current_in_amps x number_of_leds) = Resistor_value

however it is generally not good practice to place many LEDs in parallel. It is best if each has its own resistor.

The answer to the micro question is that a series resistor drops the voltage rather than the output transistor of the uC. It helps minimise issues with power dissipation in the chip (which may or may not be an issue). The current available from the uC may vary slightly, and you don't want a surprise if the manufacturer one day releases a part capable of sourcing or sinking 100mA

3. ### abhitech

2
0
Nov 6, 2010
R=(source voltage - LED voltage)/ current in ckt

LED voltage will be around 3.5 - 3.9 v
and current reqd. for this should be less than 36 mA for most of the LED's

if u r working with high glow devices than voltage across LED shold be 4v(max) to 3.3 v (min) to get max. intensity from it..

for further details on this I give u 1 URL
http://www.kpsec.freeuk.com/components/led.htm

this contains datasheets also...

hope this satisfies u

abhiSHEK
K.L University
INDIA

4. ### juantravel

41
0
May 14, 2010
Thank you

Thanks guys. Ill also work on naming conventions .