# RGB Led problems

#### ton88

Joined Nov 10, 2019
9
Hello,
Iam still pretty new to electronics this is my first time using a RGB led i plan on each color to be on at one time no mixing colors, the part iam using is a common Anode RGB I planned on using a 5v power source to connect my anode to, the max led ma each color can handle is 20ma which i plan on using only 18ma per color.I'm using a online led current limiter calculator to calculate the ohms i need for each led color resistor but the calculators are giving me ohm values that would put my led around 30ma.Iam using a schematic i made in flastad to see how much current i would be drawing which came out to around 30ma using the falstad simulator.Im not sure were iam going wrong or were to look?Would falstad be given me bad results?There is a link to my schematic just a simple led with resistor.Any help is appreciated thanks
http://tinyurl.com/vl4khzv
https://ledcalculator.net/#p=5&v=3.3&c=18&n=1&o=s
Vf
Color****Typical****Max
Red 1.9v 2.6v
Green 3.3v 4.5v
Yellow 1.9v 2.4v

#### dl324

Joined Mar 30, 2015
10,933
Tell us what forward voltages you're assuming for each color and the corresponding resistor values to get 18mA.

If you want us to look at your schematic, post it on this site.

#### Audioguru again

Joined Oct 21, 2019
1,575
The LED calculator assumes all your LED colors have a forward voltage of 3.3V which is wrong.
Your red LED shows a typical forward voltage of 1.9V. Then simply use Ohm's law to calculate the resistor value.
(5V - 1.9V)/18mA= 172 ohms. Use the standard value of 180 ohms. But if the forward voltage is lower than typical then the current will be higher.

Why do you show the spec's for a yellow LED? RGB does not have yellow, instead the B is blue with a higher voltage like the green.

#### ElectricSpidey

Joined Dec 2, 2017
1,175
Mr. Guru, did you try changing the values in the calculator?

#### Bernard

Joined Aug 7, 2008
5,555
I like direct measurements over a LED calculator. Monitor current with a series connected 1k pot.
Adjust pot to desired current & read resistance. You might see little difference in light output from 10 mA to 20 mA.

#### ElectricSpidey

Joined Dec 2, 2017
1,175
Not so simple when dealing with the high power LEDs I use.

#### MisterBill2

Joined Jan 23, 2018
6,301
Indeed! The high powered LEDs that may take 300 or perhaps 700mA are quite something to work with. But they demand heat sinks if they will be on for more that one millisecond in any minute. QUITE non-forgiving in that area. I have been experimenting with some of the LED strips from allegedly failed 48 inch LED replacement tubes. Some types demand use with an external electronic "quick-start" ballast while others use 120 volts AC mains end to end.So I do not see standardization yet. Those LEDs seem to run about 3.28 to 3.33 forward drop at between 30 and 100 mA. Worse yet, they are set up in series strings of 24 and 26 LEDs, running at someplace above 70 volts on the string. 3 or 4 strings in parallel. 75 volts is not so much fun to experiment with.

#### ton88

Joined Nov 10, 2019
9
Tell us what forward voltages you're assuming for each color and the corresponding resistor values to get 18mA.

If you want us to look at your schematic, post it on this site.
I plan on R1.9v,G3.3v,Y1.9v vf values, i get resistor values of 180ohm,100ohm,180ohm
The LED calculator assumes all your LED colors have a forward voltage of 3.3V which is wrong.
Your red LED shows a typical forward voltage of 1.9V. Then simply use Ohm's law to calculate the resistor value.
(5V - 1.9V)/18mA= 172 ohms. Use the standard value of 180 ohms. But if the forward voltage is lower than typical then the current will be higher.

Why do you show the spec's for a yellow LED? RGB does not have yellow, instead the B is blue with a higher voltage like the green.
Ok ya thats the value i got to for red as well,also the i accidentally put RGB in the thread title the led is a RGY led.Something isnt clicking in my head is there a max forward voltage i can apply over each led iam assuming that max voltage is whats in the datasheet correct?Here is the led iam using https://www.bivar.com/Files/Datasheets/SMTL4-SRGY.pdf

#### dl324

Joined Mar 30, 2015
10,933
Based on the range of forward voltages and the resistor values you're using, this is the range of currents for each LED:
Code:
Color   Typ    Max    Ohms    mA
-------------------------------------
Red     1.9v   2.6v   180   13.3-17.2
Green   3.3v   4.5v   100    5.0-17.0
Yellow  1.9v   2.4v   180   14.4-17.2
If you want the current to be closer to 18mA, you need to measure the forward voltages of each LED at that current and then use an appropriate resistor. If you want the current to be 18mA independent of LED variation, you could use a current source.

#### Audioguru again

Joined Oct 21, 2019
1,575
The max forward voltage is set by the LEDs, not given by you. You cannot buy minimum, typical or maximum forward voltage, you get whatever they have.

You must NEVER apply a voltage to an LED, if you do then the LED will instantly burn out with the very high unlimited current or it will not light with no current.

You must limit the current with a resistor to less than 30mA, 20mA is fine, but some of your LEDs might have a minimum forward voltage (less than the typical shown on the datasheet) which will need higher resistance.

#### MisterBill2

Joined Jan 23, 2018
6,301
I routinely apply a direct voltage to LEDs, and carefully slowly raise it until they show close to the intensity that they should have. Then I measure the voltage. The secret to avoiding destruction is paying attention and starting from a lower voltage.

#### dl324

Joined Mar 30, 2015
10,933
You can use a variable power supply, a 100 ohm resistor, and your LEDs to determine experimentally what the forward voltage is at 18mA.

Start with V at 2-3V, increase until the voltage across R1 is 1.8V, then measure the voltage across the LED. Record voltage and repeat for each color. Then calculate the resistor value required for each using the closest resistor value you can obtain.

Another option is to make an 18mA current source.

#### Audioguru again

Joined Oct 21, 2019
1,575
I routinely apply a direct voltage to LEDs, and carefully slowly raise it until they show close to the intensity that they should have. Then I measure the voltage. The secret to avoiding destruction is paying attention and starting from a lower voltage.
Since current in the LED causes it to heat up then the heating causes its forward voltage to drop which causes more current and more heat and more current and more heat.... It is called "Thermal Runaway".
That is another reason why LEDs are never fed a voltage, instead they are fed current.

#### ton88

Joined Nov 10, 2019
9
Based on the range of forward voltages and the resistor values you're using, this is the range of currents for each LED:
Code:
Color   Typ    Max    Ohms    mA
-------------------------------------
Red     1.9v   2.6v   180   13.3-17.2
Green   3.3v   4.5v   100    5.0-17.0
Yellow  1.9v   2.4v   180   14.4-17.2
If you want the current to be closer to 18mA, you need to measure the forward voltages of each LED at that current and then use an appropriate resistor. If you want the current to be 18mA independent of LED variation, you could use a current source.
Ok so this is were iam getting thrown off so since following this equation (vs - vf) / I = ohm say for example i have this equation for red.
(5 - 1.9) / 0.018=ohm so when i subtract voltage supply - vf i get 3.1v which means iam pass the max vf for red correct?Iam sorry if iam not understanding everyone thats really were i feel stuck at right now.
edit:just saw audioguru's post now iam really confused lol

#### djsfantasi

Joined Apr 11, 2010
6,501
When you get 3.1V, that’s not the voltage across the LED. It’s the excess voltage after the LED drops Vf in the circuit. This excess voltage is the drop across the current control resistor. To set the appropriate current for the LED, divide this excess voltage by the desired LED current to get the necessary value in ohms for the current control resistor.

#### dl324

Joined Mar 30, 2015
10,933
Ok so this is were iam getting thrown off so since following this equation (vs - vf) / I = ohm say for example i have this equation for red.
(5 - 1.9) / 0.018=ohm so when i subtract voltage supply - vf i get 3.1v which means iam pass the max vf for red correct?
The point you're not getting is that you don't know what the forward voltage of the red LED will be at 18mA, so you can't do the calculation above.

The manufacturer is giving you a range of forward voltages for the red LED at 20mA and you don't know which applies to your particular LED.
Iam sorry if iam not understanding everyone thats really were i feel stuck at right now.
The manufacturer doesn't provide the data you want, so you need to determine the forward voltages for your particular LEDs by measuring them. If you use the circuit I suggested, you can find out what the forward voltages of your LEDs are at 18mA, then you can calculate the correct series resistor to give that current.

The process is a little easier if you can build an 18mA current source.

#### ton88

Joined Nov 10, 2019
9
The point you're not getting is that you don't know what the forward voltage of the red LED will be at 18mA, so you can't do the calculation above.

The manufacturer is giving you a range of forward voltages for the red LED at 20mA and you don't know which applies to your particular LED.
The manufacturer doesn't provide the data you want, so you need to determine the forward voltages for your particular LEDs by measuring them. If you use the circuit I suggested, you can find out what the forward voltages of your LEDs are at 18mA, then you can calculate the correct series resistor to give that current.

The process is a little easier if you can build an 18mA current source.
ok gotcha thanks for everyones replies