IR remote control

In this post I want to share my knowledge about device which now controls my air conditioner and allows me remotely through my home automation system control temperature.

Some time ago I bought huge Air-to-Air heat pump/air conditioner to make my life more convenient. And then I started to think how I can connect this device to my home automation system. First of all I went to the supplier site and found that they have some module which could be installed into air conditioner and I will be able control it through Wi-Fi, the bad thing that it has own protocol and implementation and I can use only their software to manage device.

After some googling I decided that easiest way to reach my goal will be build own IR remote control and capture original commands. I used my Raspberry PI and IR receiver to capture data from original IR remote control. I captured a pulses which IR sends each time when I’m pressing buttons. The worst thing that I found is that implementation of the protocol wasn’t based on NEC or any others popular manufacturers standards, the protocol had strange signals. But my curiosity helped me determine root of cause. I figured out that it sends two 32 bits commands divided by some binary template “010” and then repeat these two commands in some curios way again. I also figured out that I can send only first two command without repeating part to make it work. When I did my reverse engineering  of the command I determined the meaning of each bit in the protocol, I found temperature, air motor speed, mode and many others parameters. My goal was limited to switch the mode of air conditioner and set proper temperature based on room temperature sensor.

The device which I built is not really smart, it just converts two 32 bits commands and sends the IR signal through IR LED. The “smart part” located on the server side under OpenHAB rules, there is JAVA rule which builds a commands based on air conditioner protocol.

Now my Home Automation system got another one smart device and it controls air temperature in the house, system decreases the temperature when I’m not at home and heats up or cool down air when I’m in, to decrease the costs of my bills.

Here is my current working code, but I’m continue develop and improve this IoT device and the code and want to make it more flexible to control others IR manageable devices.

Flexible, convenient, this is how life should be!

Leave a Reply

Your email address will not be published. Required fields are marked *