Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Newbie needs help with wiring LED

Status
Not open for further replies.

SykesIT

New Member
Hi I am wanting to wire 4 led, these are to light a model train so very small to match scale.

I have ordered them from Ebay as they are the right size and look like small spotlights to fit the model look. The listing says they are 3v 20mA white.

All I want to do is wire all 4 to a psu that I can plug in to mains 240v.

I have read a little and that in series would be best and with a resistor not sure on size.

Can someone point me in a direction that may help me. As not sure what resistor or psu would be best I assumed a 12v psu would be ok but I guess other factors for the psu may need to be considered.

Thanks
 
Answer depends on what voltage you are plugging the LEDs into. That voltage will determine the resistor required to limit the current to 20mA,though you can probably get away with less current, like 10mA.
Also, the voltage across 4 LEDs in series must be more than 4x 3V = 12V. So, you would need at least 13VDC, maybe up to around 15V to run those LEDs in series. Many wall plug type of transformers could do the job, provided they are rated around 12VDC. With only a 10 to 20mA load, any transformer would do.
Based on 13VDC supply, you would need a 68 ohm 1/8 watt resistor to supply 15mA, as calculated by:

You can calculate for 10mA or 20mA if you wish. (120 ohm for 10mA, 56 ohm for 20mA).

I always calculate for 10mA, as those wall plug in transformers tend to have a higher DC voltage with very light loads. Hence it is safer to estimate for 10mA, and end up getting 12 or 15mA. This prevents destroying the LEDs. That 20mA rating for the LED is the "maximum" safe current, but usually they work just as well at around 1/2 the maximum.
 
Last edited:
Four 3V Leds need 12V if their 3V is true..
Nobody makes a 3V LED, The have a range of voltages, maybe 2.8V to 3.4V. The resistor also needs some voltage across it so its calculation can limit the current. Use a 16V Dc power supply and a 330 ohm series resistor for 14.5mA if all four Leds are 2.8V each.
 
i think we can assume that the maximum voltage the LED will drop at 20 mA is 3V.
You can buy LEDS that are specified at 12 and 24 V and don;t require a current limiting resistor.
Ideally, you want a DC power supply. Some trains use a variable AC supply, but this might be for layout use.

That said, you may want to put a diode in series with the LED to "protect" against accdental polarity reversal. This will drop about 0.6 V.

So, with 4 LEDs, you could use whatever voltage you have available. You can run each LED off of 5 V and a resistor or 2 sets of 2 LEDS in series and a single resistor for a 12 V supply. The sets being in parallel. With 24 V you can put them all in series.

A cell phone charger that supplies 5V might be idea, They are good for 100 mA and are plentiful.

In any event, i would consider making the lighting voltage a standard voltage. If 12 VDC is used for track switches, then consider using a resistor that would make each operate at 12V.

e.g. R<(12 VDC-(2 LEDS) * 20e-3 + 0.6)

20e-3 is 20 mA or less

Vf of the LEDS can vary, It can be measured. It's an indicator of LED brightness uniformity if it's the same type LED.
Vf varies with the color of the LED.
 
Last edited:
i think we can assume that the maximum voltage the LED will drop at 20 mA is 3V.
You can buy LEDS that are specified at 12 and 24 V and don;t require a current limiting resistor.
Ideally, you want a DC power supply. Some trains use a variable AC supply, but this might be for layout use.

That said, you may want to put a diode in series with the LED to "protect" against accdental polarity reversal. This will drop about 0.6 V.

So, with 4 LEDs, you could use whatever voltage you have available. You can run each LED off of 5 V and a resistor or 2 sets of 2 LEDS in series and a single resistor for a 12 V supply. The sets being in parallel. With 24 V you can put them all in series.

A cell phone charger that supplies 5V might be idea, They are good for 100 mA and are plentiful.

In any event, i would consider making the lighting voltage a standard voltage. If 12 VDC is used for track switches, then consider using a resistor that would make each operate at 12V.

Hi I cant change the LED as these are designed to look like small spotlights. This is not a live model train it is a model train in a small display case.
 
Answer depends on what voltage you are plugging the LEDs into. That voltage will determine the resistor required to limit the current to 20mA,though you can probably get away with less current, like 10mA.
Also, the voltage across 4 LEDs in series must be more than 4x 3V = 12V. So, you would need at least 13VDC, maybe up to around 15V to run those LEDs in series. Many wall plug type of transformers could do the job, provided they are rated around 12VDC. With only a 10 to 20mA load, any transformer would do.
Based on 13VDC supply, you would need a 68 ohm 1/8 watt resistor to supply 15mA, as calculated by:

You can calculate for 10mA or 20mA if you wish. (120 ohm for 10mA, 56 ohm for 20mA).

I always calculate for 10mA, as those wall plug in transformers tend to have a higher DC voltage with very light loads. Hence it is safer to estimate for 10mA, and end up getting 12 or 15mA. This prevents destroying the LEDs. That 20mA rating for the LED is the "maximum" safe current, but usually they work just as well at around 1/2 the maximum.

Hi the voltage is 240v mains voltage, but will get a suitable psu 12v or 16v to work.
 
Four 3V Leds need 12V if their 3V is true..
Nobody makes a 3V LED, The have a range of voltages, maybe 2.8V to 3.4V. The resistor also needs some voltage across it so its calculation can limit the current. Use a 16V Dc power supply and a 330 ohm series resistor for 14.5mA if all four Leds are 2.8V each.
So a 16v DC psu would be best. Thanks
 
As I said above, use a 16Vdc power supply and a 330 ohm resistor in series the the four series Leds.
 
If this is for street lighting or house lighting, I'd consider a 12 V power supply and a PWM motor controller for dimming.

This https://www.jameco.com/z/K8004-Vell...h-Modulator-Kit-Control-DC-Motors_120539.html is a kit which I have used. www.pololu.com and ebay also may have suitable devices.

You can use a single power supply and multiple dimmers. The resistor would set the maximum brightness. there might be a maximum duty cycle, so 100% is not achievable and a small voltage drop.

You can buy some resistors to parallel to fine tune brightness. 1/Rt=1/R1+1/r2+....1/Rn

You can get 5% resistors or 1%, 5% should be fine. Metal oxide or metal film should be used,

The parallel combination of two resistors will always be less than the smallest valued resistor.
 
As I said above, use a 16Vdc power supply and a 330 ohm resistor in series the the four series Leds.


16V isn't common, however an 18 or 19V laptop brick may be.

12V is better yet, in my opinion. Two or 4 resistors. Add one or 2 diodes for string protection.
 
16V isn't common, however an 18 or 19V laptop brick may be.

12V is better yet, in my opinion. Two or 4 resistors. Add one or 2 diodes for string protection.
Sorry this is where I get confused.

Why 2 resistors?

I was going 12v dc psu, to 1 x 330 ohms 1/2w resistor then to each led so in series.

Is that wrong?

Sorry for being a little dumb with this stuff.
Was trying to keep simple and compact but safe.

Thanks for you help.
 
3+3+3+3 =12 not good at all. Each LED drops close to 3 V.

If we add a diode for reverse polarity protection
3+3+3+3+0.6 >12 so won;t work.

we need (3+3+.6+R) * 20 mA to be less than or equal to 12V

R< (6-0.6)/20e-3

That turns out to be 270 ohms.

I'll pick 1 /2 W metal oxide. https://www.digikey.com/products/en...9|0&quantity=&ColumnSort=0&page=1&pageSize=25

270, 240 and 220 ohms are available, so pick 270.

You can check the power dissipation P = I^2 * R is about 0.1 W. I would not use an 1/8W (0.125W) resistor

Use heat shrink over the diode and resistor bodies. heat shrink shrinks ny where from 1:2 to 1:4

I don;t know your logistics.
4 street lights?
4 houses
2 houses with 2 LEDs in each

That would change how I would do things.

So, two of these (1N4001+LED+LED+270) in parallel with (1N4001+LED+LED+270) combination will do what you ask.

You can reduce it to one diode if you want. The diode prevents damage if it's plugged in backwards.

and 12V is a common available power supply.

5, 12, 15 and 24 VDC are common available power supplies. 15 V is rarer.
+-15 was common for OP amp circuits.
1.8, 3,3 and 5V are common for logic supplies. 1.8V and lower reduces power requirements.

the first IBM power supply provided +5 and +12 and -5 and -12. The +12 for disk drives and the -5 and -12 for memory.
Cars and truck are 12 and 24. telco is 48 VDC.

Transistor radios ran off a multiple of 1.5V. Now 3.7 V is common for battery powered stuff.
 
Or ...

If you have a small USB wall wart or some other wall wart / battery charger / power supply that makes 5 V out at at least-.2 A (200 mA), it will work well as the power source. If you don't have one, they are available on ebay for $2.00. With that low voltage, the four LEDs are connected in a parallel circuit rather than in series. Each LED has its own current limiting resistor. The supply is 5 V and the LED drops 3 V, so there is 2 V across each resistor. Using Ohm's Law:

E = I x R

R = E / I

R = 2 / 0.02

R = 100 ohms

Get four 100 ohm, 1/4 or 1/8 W, 5% tolerance resistors.

4 LED cathodes connect together, and connect to the supply - output.

Each LED anode connects to one end of its own resistor.

The other ends of all four resistors connect together, and connect to the supply + output.

ak
 
f you have a small USB wall wart or some other wall wart / battery charger / power supply that makes 5 V out at at least-.2 A (200 mA),

I said that a while ago.

AnalogKid . Please take the following constructively, Always write 2 as 0.2. It is a Wikipedia writing style and it got hammered into my head in chemistry and mechanical drawing.

Numbers between −1 and +1 require a leading zero (0.02, not .02); exceptions are sporting performance averages (.430 batting average) and commonly used terms such as .22 caliber.

Wikipedia https://en.wikipedia.org/wiki/Wikipedia:Manual_of_Style/Dates_and_numbers#Decimals under Decimals:

The decimal can also get lost on schematics especially the old blue print ones.
 
The ebay Leds are tiny surface mount ones so 20mA might quickly burn them out. Use no more then 10mA to be safe. Since four Leds are wanted then three Leds in series will be akward to have one LED by itself. Then four 3V Leds can be in series and use an 18Vdc to 20Vdc power supply with a series resistor calculated for 10ma.
 
A 12Vdc power supply with one resistor can power three 3V Leds plus power the four LED with another resistor. An 18Vdc power supply can power all four Leds with one resistor.
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top