Smarten Up Your Air Conditioning With The ESP8266

If you’re looking for “smart” home appliances, there’s no shortage of options on the market. Even relatively low-end gadgets are jumping on the Internet of Things bandwagon these days (for better or for worse). But what if you’re not looking to purchase a brand new major appliance right now? In that case, you might be interested in seeing how [Giulio Pons] added some high-tech features to his existing air conditioner on the cheap.

Since his AC unit had an infrared remote control, the first thing [Giulio] needed to do was come up with a way to emulate it. An easy enough project using the ESP8266 and an IR LED, especially when he found that somebody had already written a IR communications library for his particular brand of AC. From there, he could start tacking on sensors and functionality.

With the addition of a DHT11 sensor, [Giulio] can have the AC turn on and off based on the current room temperature. It also gives him an easy way to verify the AC is actually on and operating. By checking to see if the room starts cooling off after sending the IR command to start the AC, his software can determine whether it should try resending the code, or maybe send a notification to alert him that something doesn’t seem right. Of course, it wouldn’t be a proper ESP8266 project without some Internet connectivity, so he’s also created a smartphone application that lets him control the system while away from home.

Now admittedly nothing in this project is exactly new, we’ve seen plenty of hackers switch on their AC with the ESP8266 at this point. But what we particularly liked was how well thought out and documented the whole process was. The rationale behind each decision is explained, and he even documented things like his network topology to help illustrate how the whole system comes together. Even if the techniques are well known by many of us, this is the kind of project documentation that makes it accessible to newcomers. Our hats off to [Giulio] for going the extra mile.

In the past we’ve seen a similar project that allowed you to control your AC from Slack, and our very own [Maya Posch] took us on a whirlwind tour of the very impressive ESP8266-powered environmental monitoring system she helped develop.

14 thoughts on “Smarten Up Your Air Conditioning With The ESP8266

      1. I can offer the opposite thanks to an awesome resource:

        http://www.kandrsmith.org/RJS/Misc/Hygrometers/calib_dht22_dht11_sht71.html

        DHT11

        As specified on the data sheet, this device is of no use below 20% or above 90%, but then in terms of physical comfort, anything above 90% humidity feels the same, i.e., wet. Similarly at anything below 20% my lips start cracking so for many uses the difference between 5% and 15% may not be important. The repeatability (scatter of the data points) is markedly worse than all the other sensors (±5%) but within its valid range (20 < %RH < 90) its absolute calibration is almost as good as the DHT22

        Personally I use the BME280 in anything I what to know about environmentals.

        http://www.kandrsmith.org/RJS/Misc/Hygrometers/calib_many.html

        Because it's cheap enough, it's got temp, baro and humd in one package and its' I2C (and I've tried to standardise on I2C modules for less pin usage with ESP's)
        And it is overkill where a DHT11 would do, but for the reasons I gave.

    1. There are other options than port forwarding. Simply have the device send a GET request every few seconds to a server on the Internet that you rent ( have FTP credentials for) Write a script on that server that sends back the contents of a file. Write another script that lets you write instructions for you equipment to that file.

      The device reads your instructions every few seconds with no need for port forwarding.

  1. I’ve done almost the same thing using a DHT22 and cloning the commands from the original remote (cool down at 16C, heat at 30C,dry,off) because I didn’t find a lib for my AC.
    And for the remote control I’ve wrote a Flask Rest API app that runs on Rpi with an Auth token that is exposed on the public IP so I can control it via IFTTT app

  2. Nice job. A DHT22 might be a bit more accurate sure, but trying to control the A/C in a room, the DHT11 will be plenty accurate enough. I’ve had a few DHT11 sensors running with Arduino Nanos around my house for a few years now. They hold up pretty well if they aren’t getting moved around or bumped. And if it fails, I think Fred is right that a DHT22 is pretty much plug and play upgrade from the DHT11.

    And for having PCB breadboard around the antenna on the ESP8266, if you are getting a strong enough signal from your router, then no big deal. You might get a slightly better signal if the antenna was on the edge of the project and the electronics and copper wasn’t near it, but I think that comment is a bit of overkill. It’s a nice project to learn some electronics and programming and be useful at the same time. Sure beats the blinking sketch. LOL

    Keep making, and keep documenting your makes.

Leave a Reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.