So I'm not a fan of getting up once I've decided to fall asleep. Sometimes I just want to do some reading prior to falling asleep and need the light to be on. So I decided to make this light switch manipulator.
I realized this has a couple of other implications:
- Children who are too short to reach the switch
- People who are limited in mobility
This project is largely based on the 433 MHz RF boards talking to each other. Sometimes this can be quite a feat. If the code doesn't work well for you, try modifying these values in Slave_servo.ino:
const unsigned int upperThreshold = 70; //upper threshold value const unsigned int lowerThreshold = 50; //lower threshold value
- Master_Remote.ino goes on the Arduino with the transmitter
- Slave_Servo.ino goes on the same Arduino as the receiver
The wiring for this is quite simple, just use the images at this link, and the images under "Schematics".
- The button goes on the same Arduino as the transmitter, and the servo goes on the same Arduino as the receiver.
As for the mount for the servo onto the wall, you are going to need access to a 3D printer. The servo mount has been modeling in OpenSCAD, you may have to change where the hole is located. I have included the OpenSCAD file, so that the hole parameters can be modified. You will want to print mhacks_lightswitchv4.stl for starters.
Once printed, secure the servo in and adhere the mount on the switch (this can be done with something as simple as command strips, or if you are really sure you like it, super glue (I don't recommend this).Final Project
Here is the final project (I submitted this for an online hackathon called Mhacks).
To make the setup more permanent, you may want to print off an Arduino case. This case works really well. You can mount it as well as the breadboard to the wall using command strips.Future Developments
- Use an ESP8266 based board to control the servo, rather than 2 Arduinos
- Make a light switch cover that embeds a servo more eloquently
- Develop Alexa code such that it is capable of being voice controlled