How To Make Remote Control Bluetooth Light Switch

Have you ever stayed in bed late at night reading or using your laptop to watch Netflix? Of course, getting out of bed to switch out the lights is the worst part. Here is an overly complex answer to that surprisingly simple issue.

Use a relay and wire it in behind the light switch in the wall for a much nicer-looking solution if you are comfortable and knowledgeable enough to experiment with your mains electricity. However, I don’t believe this would make my landlord particularly happy given I rent my home.

Components Required

  • HC-05 Bluetooth Modules * 2
  • ATtiny85 chips * 2
  • 8 pin IC socket * 2
  • Small Lipo batteries * 2
  • Push buttons * 2
  • 470 ohm resistors (there is a bit of flexibility with this, the values don’t need to be exactly 470) * 2
  • Sg90 servo * 1
  • Solid core wire
  • Prototype board
  • Arduino Uno
Parts

Remote Control and Switch

Remote Control and Switch
Remote Control and Switch

The two circuits should be put together as in the above images. (Attiny85 chips should not be inserted into the 8-pin socket just yet; we still need to program them).

Remote Control and Switch
Remote Control and Switch

Print the switch’s components on a 3D printer. They are located here. The files for this design were created by Thingiverse user Carjo3000, and they are not mine.

Pair the Bluetooth Modules

The two HC-05 Bluetooth modules must then be connected to one another. The light switch will be controlled by the slave and the remote control by the master. I could describe how to build this, but there are many other excellent instructions available and there is no need to create the wheel from scratch. Before returning to finish this guide, I would advise using one of these two to link the Bluetooth modules.

Upload The Code To The Attiny85 And Programme It

Program the ATtiny85 and Upload the Code
Program the ATtiny85 and Upload the Code

Before burning the bootloader, make sure you change the clock to “8Mhz (internal)” on the stage under “Uploading program to ATtiny85.”

Install the SoftwareServo library instead of the normal servo library for Arduino since it supports the ATtiny85 chip. The answer is to open the file Software.h in a text editor and change the line from #include to #include. After uploading the code to the ATtiny85, When you press the buttons, your lights will now switch on and off after you’ve plugged the chips into the two circuits!

Hope you find this project simple. Superkitz will be back soon with more informative blogs. Thank you Bye.

Leave a Reply