LED nightlamp

JoeyL

Enlightened
Joined
Mar 25, 2001
Messages
256
Location
California
I have a general question.

I want to make an LED plug-in nightlamp. I understand how to drop the voltage with a resistor and how to calculate the resistor needed. But since the LED is a diode and the source is AC, do I calculate the drop from 120 volts "peak-to-peak", or is it from 60 volts "peak to zero", since the diode should filter out one half of the sine wave?

Or should I use a rectifier and just forget using the LED as a diode?
 
D

**DONOTDELETE**

Guest
Of course you will have to use a rectifier, because the reverse voltage of a LED is not high enough to block (you would just blow the LED in a very spectacular way).

Calculate the resistor by using the RMS (which is the common voltage, the peak voltage is fctor 1.44 higher):

When using a bridge rectifier (4 diodes, f.e. 1N4007): R=60V/0.02A=3kOhms

Remember to use a big Resistor, because the power is P=60Vx0.02A=1.2W !!

And also think of appropriate cooling of this resistor (enough air surrounding it, mounting with a little space from the PC board).

If you want to use multiple LEDs, just connect them in serial, so you dont have to use higher current.

If the nightlight is too bright, try a resistor of, say, 30kOhms, to reduce the current to 2mA. I think it would be bright enough. This would also make it able to use a smaller resistor (0.12W dissipated).

Hope, I could help you...
 
D

**DONOTDELETE**

Guest
And of course dont forget to add a fuse to reduce the risk of burning down your house!!!

I would recommend 50mA, fast
 

X-CalBR8

Flashlight Enthusiast
Joined
Apr 14, 2001
Messages
1,098
Location
TN, USA
I believe a transformer would be best also. If you put all that electricity through one big resistor, you are going to have to dissipate a lot of heat and might even create a fire hazard if not done correctly. Also there is the matter of how efficient this is gonna be(As you probably already realize, heat created is electricity wasted). I would think that efficiency would be a big concern in making a night-light, because otherwise why not just leave a regular light on somewhere all night? I would recommend getting one of those cheap Wal-Mart variable power supplies(Still less than $10.00, I believe). That way you could just dial the exact amount of voltage you need for a circuit and can even reverse the polarity when needed. These sort of power supplies are very fun to play around with and even if you get bored with the night-light idea someday, you will always have the transformer to use on future projects.
smile.gif
 

Badbeams3

Flashlight Enthusiast
Joined
Sep 28, 2000
Messages
4,389
Hi Joe, I`ll add my 1 cent. I agree it would be safer to use a transformer and if you look around your house you might allready have one you can use...I have a bunch of them in a drawer from long dead things...maybe you do too...
 

JoeyL

Enlightened
Joined
Mar 25, 2001
Messages
256
Location
California
Thanks for all the info!

I already tried a few with transformers and they work great, but they are BIG.

I was hoping that a high value resistor would work. But if you need a heat sink and big resistor and a fuse this might not be such a good project.

I'll go back to putting an LED in a Hurricane Sure Fire backup battery pack...

Thanks!
 

php_44

Enlightened
Joined
Apr 4, 2001
Messages
210
My 2 cents....

Regarding efficiency - those wall type transformers consume 2-7 watts just being plugged in, which they dissipate as heat. If done correctly, a few of the proper value resistors in series might be more efficient than a wall type transformer.

There is an even better way.

Many circuits requiring a very small amount of power utilize a line rated self healing capacitor connected to a bridge rectifier, then the load (in this case an LED). Like this:
Code:
The theory of operation is that at 60Hz (or 50Hz) a line rated self healing cap is chosen with a value that has an impedance that will supply a desired amount of current. The load should have nearly constant current draw (as an LED would).
The cap's impedance is:
1/(2*pi*C*F)

To create an LED night light from a 120V AC 60Hz power line a 0.47uF polyester 250 volt (or more) rated cap would function like a 5.6K ohm resistor. This supplies 120/5.6K or about 21mA - just right for an LED.
The resistor is 120ohms (1/2 watt) and is there mostly for safety. The bridge rect should be rated for 250V or more.

Ideal capacitors dissipate no power, so this supply will run cool. All components are at line voltage so it is imperative that everything be insulated and enclosed so that nobody could ever come in contact with any of the components. The proper type of capacitor is essential for safety. Use only line rated polyester caps.

This type of circuit is widely used in consumer goods, and is very safe and efficient when properly constructed. If you're not completely familiar with the safety precautions and procedures one should follow in designing and constructing line operated equipment - do not attempt any project like this. This example is given for instructional purposes only. Don't blame me if you blow you self up, etc, etc.
 

Chris M.

Flashlight Enthusiast
Joined
Jan 17, 2001
Messages
2,564
Location
South Wales, UK
I wonder now why transformers are used on just about everything if resistors can be more efficient.

Loads of reasons, the most important being the fact that if no current flows through a resistor, no voltage gets dropped accross it. So you get the full input voltage appearing at the output. The voltage drop accross a resistor is proportional to the current flowing it- volt drop (volts)= current flow (amps) x resistance (ohms).

No current flow = no volt drop. Reduced current flow = reduced volt drop = more volts in to your equipment = fried equipment
shocked.gif


Transformers give a fairly constant output over the range of loading from 0 to full, though they do drop in voltage as the current increases due to the resistance of the internal windings- an inherited characteristic that can`t really be avoided. Some are better than others, depends on the build quality and how much you want to pay. And they are bulky and small ones are quite innefficient

Other power supply ccts do exist without step-down transformers. The thing inside your PC most likely is a switch-mode type. I don`t really know how they work, and they do have a small transformer or 2 inside (I looked!), probably for mains isolation or other reasons, but the reduction in voltage is achieved by different means and they usually have a very constant output over a range of loads. They`re also quite efficient but oddly enough transformers can be the most efficient means of stepping down voltage, provided they run at the rated load. A big 50w transformer running a teeny led would be very innefficient due to losses within the transformer. A 50w transformer running a 50w load would be many times more efficient though it still does have losses. The small battery charger plug for you cell-phone may probably be a tiny switch-mode power supply.
Now as to building one for running a LED nightlight, it`s probably not practical and I wouldn`t know where to point you to find the details. The capacitor setup is probably the best because of its simplicity and is what I would choose. Might even try that one myself.


php_44- what do the "C" and "F" values in the calculation 1/(2*pi*C*F) stand for, I`m not 100% sure.

confused.gif
 

Mike

Newly Enlightened
Joined
Oct 26, 2000
Messages
179
In the above formula -
C = Capacitance in Farads.
F = The line frequecy (60Hz)
 

The_LED_Museum

*Retired*
Joined
Aug 12, 2000
Messages
19,414
Location
Federal Way WA. USA
Just another advocate for not using resistors to power an LED from AC mains voltage. It is generally accepted that the maximum voltage one can run a single LED using a resistor is 49 volts. Above that, and you start having problems with heat, smoke, fire, and being forced to use large power resistors to prevent a fire.
mad.gif
 

JoeyL

Enlightened
Joined
Mar 25, 2001
Messages
256
Location
California
Great Ideas!

Thanks and of course I would not hold anyone responsible for my tinkering. The circuit
offered is intriguing.
 

X-CalBR8

Flashlight Enthusiast
Joined
Apr 14, 2001
Messages
1,098
Location
TN, USA
php_44: Good points you've made. I should have thought to mention the constant current draw associated with using transformers. It just slipped my mind to mention it. Interesting circuit to. I'm gonna have to have another look at that. I never realized that using resistors could be more efficient than using transformers. I wonder now why transformers are used on just about everything if resistors can be more efficient. Hmm…
 
D

**DONOTDELETE**

Guest
I still think the easiest way to make your nightlight is a fuse, bridge rectifier, resistor and LED...
At 2mA, which will give a good night light, use a 30kOhms resistor, which will burn 120mW, thats almost nothing...
If you build it in a plastic case with no touchable metallic parts on the outside and take care you dont have any shortcuts inside, this will make a safe device.

Just keep it simple!
 

Chris M.

Flashlight Enthusiast
Joined
Jan 17, 2001
Messages
2,564
Location
South Wales, UK
Just keep it simple!

The capacitor circuit is simple, plus you don`t have problems with power dissipation. Even a large high powered resistor is still going to run warm. Smaller metal film types of maybe 2 or 3 watts, when they get too hot, smell horrible and give off loads of acrid white smoke when the epoxy coating starts to roast- and it will if something goes wrong. If you are absolutely set on using a resistor, I would suggest a 3 watt wirewound type- the white ceramic box shape ones. Have plenty of ventilation holes in the case too and don`t let the resitor touch the sides of the case.

2mA through an LED is very dim. If you wanted to use it like that then why not just have an Eternalight on the dimmest setting? It would run for weeks on normal cheap alkaline cells, so I`ve read.

Joey- I would suggest the capacitor arangement. You can run the LED at more like its rated current (Infinity brightness is about 18-20mA from what I remembered messing round with them last) and have little worries about power dissipation- it will run fairly cool if all is well, just remember to use a suitably rated capacitor for mains line voltage- here in the UK they are called class X, but you may have a different notation for them.
Take care- mains voltage isn`t fun when things go wrong
shocked.gif
. Believe me, cos I know, and we have 240v over here
blush.gif


grin.gif
 

X-CalBR8

Flashlight Enthusiast
Joined
Apr 14, 2001
Messages
1,098
Location
TN, USA
KenBar: That's a great idea. You could build the entire circuit right on top of the D battery cell holder. I've got some nice thin cedar wood that I could use to build a little project box to put it in to. Then put a little hook on the back and hang it close to the ceiling in the bathroom and it would make a perfect little night-light. Hehe, I wasn't even thinking about doing a night-light till now, but I think this would make a cool little project.
smile.gif
 

JoeyL

Enlightened
Joined
Mar 25, 2001
Messages
256
Location
California
Wow!

One Single D cell alkaline works a whole year?
Do you have to turn it off in the daytime,
or is that one year continuously?
 

Mike

Newly Enlightened
Joined
Oct 26, 2000
Messages
179
It would be cheaper to just use the glowing night lights that run for a few cents a year. They give off a reasonable amount of light.
 
Top