To be clear, this question is not about physically wiring into the light switch to control the lights - simply pressing on the switch from the outside. I apologize in advance if my electrical vocabulary isn't up to par - I'm very new to this.

I have been developing an Android app that allows me to control Particle Photon boards over the internet, and I have already installed a board that turns my computer on and off. However, I am researching ways to automate the lights (ceiling lights, not lamps) without interacting with high voltage. I have not been able to find any good information.

Does anybody have any advice?

  • 1
    Other than with X10? Apr 26, 2017 at 2:41
  • Welcome to Arduino Stack Exchange. Be sure to take the tour at arduino.stackexchange.com/Tour
    – SDsolar
    Apr 26, 2017 at 3:23
  • Get those RF wall switches. Then connect a RF transmitted to your photon. The protocol for most name brand switches have already been reverse engineered.
    – Gerben
    Apr 26, 2017 at 8:34

4 Answers 4


you can glue an LED controlled by an MCU into the sensor hole of a dusk to dawn sensor. these are available in socket and outlet shapes, are UL certified, and require no messy wiring. I've been able to switch an outlet model by duct-taping an ESP8266's built-in LED against the window; can it get any simpler?

Here's a working example's parts, exploded for easy identification. enter image description here

You can spot an inline socket-to-outlet adapter, a dusk-to-dawn sensor, a bulb, a cheap nodeMCU ESP8266 devboard, a short micro usb cable, a USB wall wort, and an RGB LED module attached to dupont wires. I'm wiling to bet anyone here can figure out how these pieces fit together to make a $10 "smart bulb". You can get most of these parts at the local home center, and everything shown on amazon/ebay.

Of course you won't get a lot of respect from EEs, but you will get the job done quickly and safely, and the opto-isolated controls work with any platform. I have cheaper/smaller build i've moved onto, but i still have several of these switch builds in-place for years and they work great.

I would recommend getting a dusk-to-dawn switch that is labeled as being compatible with LED bulbs; they tend to use a lower-"bleed" IGBT instead of the older/cheaper diac/triac combo which causes some low-energy bulbs to flicker when off.


I have built a 'switch-flip' controller that just attach to the regular light switch. The controller has both RFM69 radio and Bluetooth module in it so it can use iPhone (iOS app only for now) to control the switch on/off.

enter image description here

enter image description here


Walmart and others sell battery-operated units that can flip switches to turn lights off or on. Example: AutoChron Wireless Light Switch Timer, as seen in following picture.

AutoChron Wireless Light Switch Timer

You could buy one of these (for about $25) then hack into it and attach wires to the On and Off buttons to allow an Arduino to simulate presses of those buttons. The unit would move the switch handle accordingly.


A clumsy way would be to use a servo motor connected to the mechanics of the switch, somehow. Or in a dimmer, replace the rotating knob with the output of a servo, thus simulating it turning. Not sure if that's what you were after.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.