How to control brightness of LEDs, and other dumb questions

Ask and answer questions, share tips and resources for installing lighting and other electronics in your models.

Moderators: Sparky, Moderators

Post Reply
nicholjm
Posts: 506
Joined: Thu Aug 25, 2005 9:21 am
Location: Katy, TX

How to control brightness of LEDs, and other dumb questions

Post by nicholjm »

I'm probably gonna ask some stupid questions here because I'm just starting to learn about LEDs and lighting and wiring, etc. Just bear with me.

1. When an LED says 3V, or whatever, does that mean it takes a minimum of 3V to light it, or is that the maximum it can take without burning up? I know LEDs require a certain minimum voltage to even light at all, so I'm confused there.

2. How do you use resistors to control the brightness of your LED? I've seen some models lit up so that the LEDs seem WAY too bright, almost out of scale bright. Do you use the resistor to limit the voltage going to the LED by just putting in a larger (more Ohms) resistor? Or do you have to limit the amperage? How would you do that?

3. Do you have to put the resistor in a certain order if you are wiring it in series with an LED? Or can it just be anywhere in the circuit? Am I correct in assuming it would be pointless to wire a resistor parallel to an LED, because then they would both be getting the same voltage?

I plan on eventually lighting my Klingon BOP, so the more I know before I start the better. Electronics has always been my weak point, which is why I became an mechanical engineer!
"Dogs and cats, living together...MASS HYSTERIA!!!"
nicholjm
Posts: 506
Joined: Thu Aug 25, 2005 9:21 am
Location: Katy, TX

Post by nicholjm »

Through a little more research, I think I answered my own questions.

1. The voltage of an LED is the minimum required to get it to light. An LED does not burn out because it is supplied a higher voltage. It burns out because it has too much current running through it. Which leads to question 2...

2. Resistors limit the current. If a circuit is a 12V circuit, and you wish to lower the current I, then you just increase the resistance R. V=IR. Increasing the resistance will dim the LED. Just like if there is no resistance, the LED will be super bright and then burn out.

3. The LED and resistor have to be in series with each other, but the order does not matter. I'm not sure why, but that's what I've read. I always thought the electricity flowed from the negative terminal to the positive, so the resistor would have to be first in the circuit, but hey, what do I know.

Am I right? Can anyone verify my thinking?
"Dogs and cats, living together...MASS HYSTERIA!!!"
macfrank
Posts: 8726
Joined: Fri Oct 11, 2002 6:55 pm
Location: Los Angeles, CA
Contact:

Post by macfrank »

The LED Center is a great place to educate yourself on the proper way to use LEDs. They also have excellent LED resistor calculators, for a single LED or multiple LEDs. You can use the multiple LED calculator with a single LED.

Powered correctly, and within its limits, an LED will last for decades.

Frank
nicholjm
Posts: 506
Joined: Thu Aug 25, 2005 9:21 am
Location: Katy, TX

Post by nicholjm »

Thanks, I'll check it out. I think what I really need to do is just buy some LEDs, resistors, and wire and start playing around. These things run pretty cheap.
"Dogs and cats, living together...MASS HYSTERIA!!!"
User avatar
DLMatthys
Posts: 2707
Joined: Fri Jul 12, 2002 9:45 pm
Location: "Fracking? Not in my back yard. Now get off my ranch!
Contact:

Post by DLMatthys »

I'm thinking a neat thing tool for developing LED circuits is a "resister wheel".
It would select various R values to see what would happen with the brightness. That's what I'd like to find.
DL Matthys
don@dlmparts.com
http://www.dlmparts.com
Make it Glow!
macfrank
Posts: 8726
Joined: Fri Oct 11, 2002 6:55 pm
Location: Los Angeles, CA
Contact:

Post by macfrank »

LEDs are not filament lightbulbs; they're diodes, and they have a strict voltage vs current curve, as you can see in this graph.

Experimenting with resistors and voltages and currents is all fine and good, but if you don't know what the device limits are you're going to be damaging or destroying many if not most of the LEDs.

The maxiumum brightness of an LED is almost always at its max forward current (around 20ma - 30ma). Ffigure out what resistor value will provide no more than that at whatever voltage you want to work at, and put it in series with a potentiometer with a maximum value that's 1x-4x greater than the resistor. Then hook up the LED. In the worst case (with the pot at "0" ohms) the LED will be at its maximum safe operating current and maximum brightness. When you find the brigtness level that you're looking for, use a multimeter to measure the resistance of the trimpot and add it to the value of the resistor, or measure the resistance of both the pot and resistor. Then find a single resistor that's close to this value.


Frank
User avatar
DLMatthys
Posts: 2707
Joined: Fri Jul 12, 2002 9:45 pm
Location: "Fracking? Not in my back yard. Now get off my ranch!
Contact:

Post by DLMatthys »

I read that about LEDs and resisters and it makes sense. The true test is post build and endurance testing of the intire circuit. If it aint smokin or sparkin after an hour... your good to go!
DL Matthys
don@dlmparts.com
http://www.dlmparts.com
Make it Glow!
jwrjr

Post by jwrjr »

As long as you STAY within the max current for a led, the led will almost always last for a very long time. (Poorly manufactured leds do sometimes make it through inspection.) Running it over the max current will make the led burn out sooner or later. If you want to see something fun (as long as itis not inside a project). hook the led to an AC adapter or large battery (higher than 4 volts) with no resistor. It will explode (or at least, pop).
User avatar
Pat Amaral
Posts: 3730
Joined: Fri Jul 12, 2002 2:44 pm
Location: Ok, I'm here. You can start now

Post by Pat Amaral »

nicholjm wrote: 3. The LED and resistor have to be in series with each other, but the order does not matter. I'm not sure why, but that's what I've read. I always thought the electricity flowed from the negative terminal to the positive, so the resistor would have to be first in the circuit, but hey, what do I know.

Am I right? Can anyone verify my thinking?
Let me see if I can clarify this some. Imagine you're the battery being used in a simple LED circuit. What you see beyond your plus and minus teminals (wires, resistor, LED, etc) is called the load. The load is whatever is doing the work in the circuit. Loads convert one type of energy to another (in our case, light and, if designed well, a very little bit of heat). Because all you (the battery) can see beyond your terminals is some kind of load, not individual components, it doesn't matter what comes first down the wire. You're going to provide just the right amount of current to get the load to do some work.

Now, about the current. The term "current flow" is somewhat misleading. Current can be described as the transfer of electrons from atom to atom inside a conductor. Although, technically, there is movement of a kind, you can't really call it a "flow".

Think back to your high school physics class. Electrons are negatively charged atomic particles. They're attracted towards the positively charged protons in the atoms of a material.

Atoms desparately want to be stable. That is, they want to NOT have any kind of charge. Therefore they usually try to have the same number of negative charges (electrons) as positive charges (protons).

When you close an electrical circuit, the electrons in the conductor are attracted to the positively charged plus terminal of the battery. That, in turn, charges the atoms of the conductor and devices in the cicuit, which attracts the high concentration of electrons at the negative terminal of the battery.

Bang! Zoom! We have current!

To finish, When the electrons in the devices (Leds, resistors, etc) feel the difference in charges, they transfer their energy as either light or heat.

Hope that makes some sense,

By the way,
If you want to see something fun (as long as itis not inside a project). hook the led to an AC adapter or large battery (higher than 4 volts) with no resistor. It will explode (or at least, pop).
Please be careful if you're going to try this "fun" something. Given enough energy (like that from some AC adaptors), an LED can an will explode with the force of a gunshot. Although it might be an interesting effect, trying to McGyver some kind of IED from a wall wart and some LEDs is not my kind of good idea. I'm just saying.
Pat A.
=============================
50% Nerd, 50% Geek, 100% Cool
jwrjr

Post by jwrjr »

It appears that I have given a bad impression. I would not ever recommend trying what I have described above. It is caused by the actual led vaporizing, blowing the plastic package apart. At best, you have wasted a led. At worst, the plastic fragments could damage something ... like YOU.
Sparky
Moderator
Posts: 2404
Joined: Thu Jun 05, 2003 8:28 am
Location: Are we there yet? (Chicago)
Contact:

Post by Sparky »

I exploded an LED once, they guys where even there for a buildfest. Usually they just gas out through one of the legs of the LED, by this one poped sending part of the LED bulb flying.

What people usually don't realize about currnet and power for the LED-resistor combo, is that the current in loop is set by the diode. The resistor eats the extra power.

When calculating the resistor's value, you take the steady state current you want for the LED, and divide that into the extra voltage. So you take the (power supply voltage - the LED's desired voltage) and divide that by the LED's desired current. As you can see the current used is whatever the LED's current should be, the voltage the resistor drops is what you have that is extra. If the power supply voltage drops the LED grows dim, if it rises the LED will be getting more power and the resistor won't stop this.

What it protects against is if the diode suddenly allows more current through. The voltage it sees will drop, as the current that passes through the resistor goes up, the voltage it drops goes up, so there is less voltage for the LED (if the power supply voltage remains the same). If you look at the LED graph of current and voltage, you see that this will keep you on the working curve of the LED.

Current through the loop is assumed constant the current in the resistor is the same as the current through the LED, it has to be. The resistor works no magic it won't change the current, add or take away voltage. The votlage it drops is directly related to the current passing through it, and its resistance. The Voltage / (current * resistance) Ohms law is all that is going on in the resistor when working with batteries (DC).

The device or load is what sets the current, given that the battery or power supply can supply it.
<a href="http://www.kc6sye.com/2_wheresaneatpart.jpg" target="_Sparky">Is this plastic thingy on the counter a neat part?</a> <a href="http://www.kc6sye.com/1_casting_inprogress.jpg" target="_Sparky">Let's cast it.</a>
jwrjr

Post by jwrjr »

I never run a led at the rated maximum current. Not because of shortening the life of the led (it shouldn't do that), but because calculating the resistor is based on the power supply voltage - which is never exact. The no-load voltage of an unregulated 12 v. AC adapter is never 12 volts. It will run between 14 and 15 volts. This is not a defect, It is normal. Better to calculate your led resistor so that even with the max voltage for your power supply you don't exceed the max current for your led. If it works out to not be a standard resistor value, go UP to the next resistor ... never down.
As for dimming leds, I prefer pulse width modulation. But electronics is my profession.
Madman Lighting
Posts: 1816
Joined: Sat Mar 05, 2005 9:16 am
Location: Serenity.
Contact:

Post by Madman Lighting »

jwrjr is right, always go with a slightly lower current and slightly higher resistor value given a choice. When I calculated out how much current to use for my product, I had to include all the tolerances for the parts controlling the LED current and make sure that when all the parts were at the upper limit of tolerance the LED current was still within the LED's rated current. Thats why the "nominal" drive current I use is 18mA for a 20mA LED. When everything is a the high end of tolerance, you will get 20mA.
That Madman Who Lit Up Deep Space Nine
octagon
Posts: 335
Joined: Fri Dec 12, 2003 12:15 am
Location: Singapore

Post by octagon »

Someone please help to clarify this bit. Sorry if this has been mentioned a million times before. Thanks in advance.

a) Does the length of the cable make any difference to the battery power required?

b) Does having different color LEDs again make any different in the construction?

c) Would different color LEDs require different cable/wire?

d) Not sure how much heat will be coming off each LED, does seating a LED on styrene melt/burn the plastics eventually? Or we must make sure the LED never touches the plastic of our model kit?

e) When you put LED in an enclosed or concealed or permanently glued area which you cannot reach later on in your project, is it a good idea to have 2 LEDs of the same everything (color/size) so that overtime when one burnt/died, the other one can kick in as backup? Or this is just not the way its being commonly done?
Sparky
Moderator
Posts: 2404
Joined: Thu Jun 05, 2003 8:28 am
Location: Are we there yet? (Chicago)
Contact:

Post by Sparky »

octagon wrote: a) Does the length of the cable make any difference to the battery power required?
Only if you add a lot of wire and are using a lot of current (jumper cables have to be very thick to carry all that current over such a short distance), then the resistance of small AWG wire will start to impact you.
octagon wrote:b) Does having different color LEDs again make any different in the construction?
Typically different color LEDs will require different currents or voltages. If you do a careful selection of LEDs from a place like digikey you could:
Get them so that they all want the same voltage (then hook them in parallel to that you have one voltage buss running around the internals of the model)
Get them so that they all want the same current (hook them in series so that you have one giant chain of LEDs, however if one goes out they all go out). You could set up mini chains of LEDs with this idea though its worth considering for sub sections of a model.
octagon wrote:c) Would different color LEDs require different cable/wire?
I cant think of any reason this would need to be considered, maybe if you were trying the high output white LEDs, like 1 or more watts. But then you're looking at heat issues. . .
octagon wrote:d) Not sure how much heat will be coming off each LED, does seating a LED on styrene melt/burn the plastics eventually? Or we must make sure the LED never touches the plastic of our model kit?
LEDs are very efficient, unless you want actual high beams or something crazy you should be fine, steer clear of the expensive white LED high output guy and you'll be fine. As you design you can calculate how much power you are pumping into the system by logging the current draw of each LED, and it's operating voltage. You will need to do this any ways, to size your battery pack/power supply. Power is current * voltage (P=IE).
octagon wrote:e) When you put LED in an enclosed or concealed or permanently glued area which you cannot reach later on in your project, is it a good idea to have 2 LEDs of the same everything (color/size) so that overtime when one burnt/died, the other one can kick in as backup? Or this is just not the way its being commonly done?
You would have some complexity to have another LED that was rigged to come on if the other one failed. As long as you are careful with your calculations, wiring and power supplies, you shouldn't need to worry about sealing the LEDs up.
I suggest avoiding putting the resistor right on the LED leg and then wiring the assembly out to some place. If you have the room, wire up all the lights with 'pigtails' then have a small distribution board that has all the resistors and or FX circuitry. If you have an engine module with multiple LEDs and resistors that ends up being to dim or wired wrong (you can under power an LED to really extend its life) you can't change it after its all sealed up. Best to just wire the assembly and bring out all the connections. Get multiple colors of wires so you can easily track what wire goes to what LED (if you're mixing LED colors/currents/voltages. You can use one color, black or green for all their commons/negative that’s a standard setup. . .

anything else I forgot :?:
<a href="http://www.kc6sye.com/2_wheresaneatpart.jpg" target="_Sparky">Is this plastic thingy on the counter a neat part?</a> <a href="http://www.kc6sye.com/1_casting_inprogress.jpg" target="_Sparky">Let's cast it.</a>
octagon
Posts: 335
Joined: Fri Dec 12, 2003 12:15 am
Location: Singapore

Post by octagon »

Hello Sparky,

Thank you so much for taking notice of my queries.

a) The length of the wire should be just under 50 inches for 'each' LED.
If constructed in parallel, the wire I need is about 2 for each LED?!?:
- 2 white LEDs for the cockpit. (50 inches x 4 wires)
- 4 strong white LEDs for the front lighting. (50 inches x 8 wires)
- 3 warm white LEDs for the engines behind. (50inches x 6wires)
Will this be considered a lot of wire?

e) Really like your colored-wire strategy. Just make so much sense. That would help me determine which has gone where exactly in the model. Cool!

I think for places like a concealed cockpit, I would arrange to have two sets of LED each leading to a different pack of batteries. Whereas the external bits, I dont have to seal the LEDs.

I will see if I could get someone locally to put it all together for me. At least now I could tell the expert what "I think" I want.
Sparky
Moderator
Posts: 2404
Joined: Thu Jun 05, 2003 8:28 am
Location: Are we there yet? (Chicago)
Contact:

Post by Sparky »

50 inches isn't to bad. you might want to look at some larger guage wire. I think 18 AWG will still be over kill. But if when you say strong white LEDs you are talking more than 500 mA each. That means you'll have 2 watts of power drawing through the power wires.

You can reduce the wires by combining commons so one black wire from both grounds, just keep the gauge big enough to handle the combined currents.

Interestingly enough, if all your white leds are 3.3 volt, you could set up the LEDs in 2 serial pairs, that way each pair wnats 6.6 volts. That's pretty close to a 6 volt power supply or a 6 volt pack.

You should hook it up in a bread board or with aligator clip leads to see how bright they look when you under drive them.

If you don't like the idea of underdriving them, you can run one set of wires out to each subsection and hook all the LEDs on to the wire in a buss style, (say the red wire going to all the positive legs, and the black wire to all the negative sides). Remember that the current drawn throught he wire is cumulitive, so if each LEd takes 20 mA and you have 4, the wire feels 80 mA of current going through it.

I think the wire I got is 24 AWG stranded, hard to strip the insultation at this size its teflon and that just wants to stretch when you take the strippers to it. Maybe get some 20 awg, I think that was one of the options when I got the stack of spools from digikey. We were wireing the nacelle rings for the 1:1000 enterprises then and I new I needed thin wires to get away with it.

Here's my big breadboard and all the wire spools, you probably don't need that much realestate. . .
http://www.kc6sye.com/images/circuits/6 ... n_wire.jpg
<a href="http://www.kc6sye.com/2_wheresaneatpart.jpg" target="_Sparky">Is this plastic thingy on the counter a neat part?</a> <a href="http://www.kc6sye.com/1_casting_inprogress.jpg" target="_Sparky">Let's cast it.</a>
Sparky
Moderator
Posts: 2404
Joined: Thu Jun 05, 2003 8:28 am
Location: Are we there yet? (Chicago)
Contact:

Post by Sparky »

have you decided what the power supply will be?
A double D pack is 3 volts max, peak output. Then it will dwindle down farily soon, with the ultra brights and the others drawing on it. If you have the LEDs picked out we can look at their power draw and voltages as a starting point.
<a href="http://www.kc6sye.com/2_wheresaneatpart.jpg" target="_Sparky">Is this plastic thingy on the counter a neat part?</a> <a href="http://www.kc6sye.com/1_casting_inprogress.jpg" target="_Sparky">Let's cast it.</a>
octagon
Posts: 335
Joined: Fri Dec 12, 2003 12:15 am
Location: Singapore

Post by octagon »

Good suggestion Sparky.

I am looking through a link suggested by En'til Zog and found a catalog of different LEDs here http://www.jameco.com/Jameco/catalogs/c264/P56.pdf

Its difficult to pick which one as I dont know how much light come out of each or what color it will turn out when actually lighted.

For the engines behind, I am thinking of those ones similar to this screencap.
http://s4.photobucket.com/albums/y121/B ... nt=re4.jpg
If the diameter of the back-engine is about 3cm, what color and LED strength do you think I should shoot for?
Sparky
Moderator
Posts: 2404
Joined: Thu Jun 05, 2003 8:28 am
Location: Are we there yet? (Chicago)
Contact:

Post by Sparky »

Go with white, and if you want to, you can slightly tint it with say tamyia smoked yellow, you can add and remove the acrylic paint as you like.

There are some ultra bright yellows, but they will look very yellow though. That might fit with what is seen on the screen cap for the bigger engines. We used one of these ultra bright yellows on the little Joe yard tug. It’s the 'tractor beam.' It’s in the middle of the back wall of the tug projecting a beam of light on the nacelle it’s towing to the space station.

For the area you circled any of the newer yellow LEDs will be fine, don't go with the regular yellow looking LED, the water clears will work best, you can sand down the lens and get a more omni directional projection, but the ones that are yellow plastic are really much lower light output. You can diffuse something that’s too bright, not much you can do if it's to dim.

BY the way I looked at my spools of wire last night, they were from Mouser (another online parts supplier). I also got a lot of LEDs from them, I think they had a better selection than digikey at the time.
Last edited by Sparky on Fri Dec 08, 2006 5:15 am, edited 1 time in total.
<a href="http://www.kc6sye.com/2_wheresaneatpart.jpg" target="_Sparky">Is this plastic thingy on the counter a neat part?</a> <a href="http://www.kc6sye.com/1_casting_inprogress.jpg" target="_Sparky">Let's cast it.</a>
octagon
Posts: 335
Joined: Fri Dec 12, 2003 12:15 am
Location: Singapore

Post by octagon »

Thank you plenty for all the good advise. Now I can go back to the local LED shop and ask some intelligent sounding questions. :lol:
Post Reply