3 min read

IR Remote Controlled Home Automation Project

IR Remote Controlled Home Automation Project

In the summer of 2018 (16 years old at the time of writing), I came up with an idea to mitigate the cumbersomeness that had been bothering me for some time. I've been interested in Arduino, Raspberry Pi, FRC, and lots of other electronic, mechanical, and software-related concepts including Penetration Testing (Ethical Hacking); and so I was curious as to how all of these systems that we use in our daily lives work. In our household we have 6 lampshades in our living room that are not/were not connected via an electric cable and my dad has been switching these lights on and off every evening one by one. At first, I thought of the simplest solution of connecting all the lights into a single power grid/socket, but I wanted to solve this problem in a way that would not require any extra effort in the future. This was when I decided it should be remote-controlled. However, in order to do that, I had to do plenty of different things. So I started to research.

First, I learned how a TV remote was communicating with the TV, whether it was through an electromagnetic wave consisting of peaks and troughs corresponding to a binary code or not. After that, I learned how I can alter this process in a way that I can use it to do various tasks or assign commands to it. That was when I learned how to code in Arduino. I took lessons from sites like edX and Coursera to deepen my understanding of coding with Arduino. I bought the necessary infra-red sensors to receive the messages sent through any remote to feed them to my Arduino, which in return, would allow me to assign those values to a task. I cut the grounding and power cables, merged them, connected them to a relay to control the high voltage with a low voltage circuit, coded Arduino for our remote control’s specific HEX values, and put everything in a neat wooden box. Since then, we can turn our lights on with one button on our TV remote. You can do this too by using an Arduino, a relay, some jumper wires,1 TSOP 1738 IR Sensor, a wooden box, a bunch of electric terminals, and some coding :). This is how it works ↓

Our house and re-configured tv remote

This project is actually very easy to understand. When I press any button on the IR remote, it sends a code in form of a train of encoded pulses using 38Khz modulating frequency. These pulses are received by a TSOP1738 sensor and read by the Arduino and then the Arduino decodes the received train of pulse into a HEX value and compares that decoded value with the predefined HEX value of the pressed button. If any match occurs then Arduino performs relative operations. What I did differently in this project was that I didn't use the predefined remote controller that comes with Arduino, I used our TV remote. Like everyone, we also had a few buttons on our remote which we'd never used since we bought our TV, so I assigned a command to the related HEX value of the unused button.

I plan on automating different systems in our household with other rarely used buttons on our TV remote; For example our A/C, music system and curtains.

Credits: Alan Zucconi

Update: It has almost been 4 years and it still works! Even this toy project that I whipped up in a matter of hours has never caused any problems for 4 years straight. I'm starting to believe that there definitely is some planned obsolescence in many of the products we use in our daily lives.