Go Down

Topic: PLEASE HELP~ How can I dim two 220v ac lamps? (Read 5939 times) previous topic - next topic


I am live in hong kong....and very newable in arduino....
I want to use arduino to do a interactive installation, and using a infared distance senser to dim 2 ac lamps. how can I do it?

this is no budget project...I can't buy very expensive hardware....thank you :'( :'(


I have a sharp infrared sensor, GP2Y0A710YK0F


you may want to look for a chinese forum for arduinos, or start your own! ubuntu server + phpbb + modx cms!

to get you start find some solid state relays that are designed for 220v ac, then use PWM (pulse width modulation) to dim them.

test it with LEDs first, and check the arduino guides! then find some solid state relays


find some solid state relays that are designed for 220v ac, then use PWM (pulse width modulation) to dim them.

Sorry this will not work. Solid state relays switch off only at the zero crossing points. Therefore once a PWM switches it off it will stay on for the rest of the mains cycle and not dim.

Get an AC dimmer and feed it with a variable voltage derived from a PWM signal that has been filtered to take away the high frequency components.


grumpy_mike, isn't that why you'd want to turn on the SSR with the PWM and also would require a zero-crossing detector? The concept is to turn the SSR on at a time X after zero-crossing and off ASAP so the SSR really turns off at the next zero-crossing. I know this is how it works using Triacs.

Another option I was thinking about would be to take a standard light dimmer and change out the dimmer POT with a digital POT and some kind of isolation to keep Arduino away from the AC voltages. The OP doesn't come across as being electronically or electrically savvy so keeping it to mostly off-the-shelf parts is probably best. Maybe even X10 based for the dimming if there's a 220V version.


Jan 07, 2009, 01:18 pm Last Edit: Jan 07, 2009, 02:42 pm by RIDDICK Reason: 1
i would use
12V LED lamps, which use not so much power (2W for a "60W-light"),
and a L293 (1A driver) (or a thyristor/transistor or so) at a arduino PWM pin...

u would need a 12V voltage source (PSU), which should be properly shaped, so that u dont waste the saved energy in that PSU... :-)
a Switched-mode power supply would be fine, i think...


If I use 12V power, can I use 100W light bulb?? because I need to light up a big model....about 1.5m high....


hm - the LED light sources use much less power (just 10%)...
so u only have to power a 10W load, if u want "100W light"... :-)

an http://en.wikipedia.org/wiki/Incandescent_light_bulb incandescent light bulb, that uses 100W electricity produces 110cd (110 candela).

there are single LEDs with up to 60cd at just about 10% of the electrical power...

when u combine several LEDs, u can get a light source that is as light as an incandescent light bulb, but it produces less heat, which might be good for ur model...

these r LED light sources from ebay.com:
650lumen http://

"30W" http://cgi.ebay.com/3-x-36-LED-Day-White-light-bulb-12V-MR16-spot-lamp_W0QQitemZ360121467172QQcmdZViewItemQQptZUK_Light_Bulbs?hash=item360121467172&_trksid=p3286.c0.m14&_trkparms=72%3A570|66%3A2|65%3A12|39%3A1|240%3A1318|301%3A0|293%3A1|294%3A50


The concept is to turn the SSR on at a time X after zero-crossing

Yes it is but a solid state relay don't work like that. It has a digital input that turns on the load as soon as you apply a logic input.

only have to power a 10W load, if u want "100W light"

Bollocks.  >:(
Using LED for high level illumination is difficult and not one for a beginner. It is not just a matter of supplying voltage to it you have to control the current and with high current LEDs you can't just put a resistor in line. Then you have to get rid of the heat with a massive cooling system. Yes you can do it but it is complex.


thank you all~ and 10W led is very very expensive.......

Can i diy something like K8064?? DC controlled dimmer?? any idea??

I can't find K8064 in Hong kong... I asked a shop to order, but they say I need to order 10 in one time......

no budget....


Jan 07, 2009, 05:11 pm Last Edit: Jan 07, 2009, 05:38 pm by RIDDICK Reason: 1
is it this: http://store.qkits.com/moreinfo.cfm/K8072 ?
it looks like it uses a mechanical relay (or what is it in the right lower corner?)...
a mechanical relay cannot be used as a dimmer...
and it costs about 32USD...

they ship to asia, too: http://store.qkits.com/shipping.cfm
but it costs 42USD...

and why can i just turn on my 60 LED lamp and light my bedroom (i mean, if others can't, why can i... my bedroom is at least 2m high...)...?
and what heat? isn't it true, that those glowing coils in conventional light bulbs get very hot (they can burn cotton through a vacuum and the glass hull)...


hm - ok - it looks like the recommended "solid state relay"...

1. it is still expensive (33USD)
2. it needs a 12V control signal (0V off? ... 12V on?)...


Jan 07, 2009, 05:58 pm Last Edit: Jan 07, 2009, 06:00 pm by dmesser Reason: 1
That apogee kit looks like what I was going to suggest. Use a digital pot for the control voltage.

According to the manual for that unit. It can use 0-12v for control, or 0-5v.


Jan 07, 2009, 06:26 pm Last Edit: Jan 07, 2009, 06:38 pm by RIDDICK Reason: 1
ok - i read the manual of that thing and it can be used for 0V..5V...

the arduino doesnt have an DAC, so that we will need a further device, that transforms a digital value or a PWM signal into an analog value...
that apogee kit needs assembling and possibly has dangerous voltage levels at some contacts, so that u need to be much more careful than with a 12V PSU...

Go Up