Smart Air Conditioner Project

Thread Starter


Joined Jun 29, 2017
I have an idea and I wanted to get some advice on potential dangers and practicality. Looking at it now, I might be better off just buying a smart outlet type device from Amazon, but it would be more fun to do it myself.

** Save money on electrical bill
** Keep apartment at a stable temperature

2 Raspberry Pi's, and various analog components, tbd

I have an Air Conditioner that came with my apartment which is some 8 years old, and isn't able to auto regulate itself. It's either on full blast all day resulting in an expensive ice box, or off all day creating a steamy sauna. I'm hoping to get things somewhere in the middle.

The strategy I have in mind is to setup my Rasberry Pi Zero W on the far wall, running a simple thermistor so I can get the +/- 1 or 2 degree temperature. That pi can also host an Apache server and save the temp data into a JSON file. Across the room is the A.C., which will need some sort of outlet intermediary. That is something I can plug the A.C. plug into which has a relay or such controlled by the 2nd Raspberry Pi before it plugs into the outlet. This way the Pi can control the logic of when to turn the A.C. on or off based on the temperature data is reading from the server across the room.

Few questions arise,
1.) Is serving the data with Apache the easiest method? If both Pi's have Bluetooth can they talk that way, this would be a new area to explore for me.
2.) Is a relay the best way to control the On/Off state of the A.C.? What would that be connected to the negative pole on the outlet and plug?
3.) Is this a bad idea that will ruin my AC, being turned on and off abruptly by cutting power rather than hacking it and using the dial?


Joined Dec 15, 2011
Oh boy a topic I can intelligently comment on!

At the beginning of the year I had the same basic idea. I thought I'd put my industrial controls experience towards designing a control system for my house AC. Typical (for North America) setup - condensing unit, AHU, etc. I'm using a Beagle Bone Black with a designed by me IO board.

Long story made short, if you're planning on doing this in order to save money, unless you have all the parts on hand, a properly equipped work shop, and your time is free, it will take you decades to save enough in electrical bills to make up for the expenses. I'm in well over $1K in *basic* equipment alone (proper meter, oscilloscope, soldering station, etc) and that doesn't include parts, PCB manufacturing costs, time, etc.

Thing that have seemed to be simple, especially analog stuff, (hey just terminate this ICTD against a 1k resistor and read the value via an ADC port), have turned out not to be so.

If you're thinking of doing it as a hobby that's a completely different story. Just don't expect to save any money by doing it :)



Joined Mar 14, 2008
As #12 said.
There likely is some sort of thermostat knob on the AC unit.
Just bypass that with a relay controlled by a standard room thermostat.
The relay circuit can be powered from a wall wort.


Joined Sep 22, 2013
Don't know what your exact needs are.......but there are thousands of smart temperature controllers.....on ebay and such.....dirt cheap. And if you want to build........thousands of non processor temperature control circuits on line as well.


Joined Sep 22, 2013
You can set different temps thru-out the day. Even shut down for periods.

Heck now days......stick a display and processor on it smart.


Joined Sep 9, 2010
My A/C is controlled by a smart thermostat that in turn is controlled by an app I'm working on. The thermostat of course comes with its own software that's pretty good. These apps enable full control and monitoring from anywhere.

A cheaper option is a simple smart outlet. You can get those for $20-30 and that includes power logging (like a Kill-A-Watt). This would work as long as the A/C will power-on to the right setting.
You could manually control your A/C from anywhere. One heckuva lot easier and more reliable than any DIY solution.
OK, I'll go in the "middle" here.

The AC might be 240 V - No mention of the region of the world you are in. In the US, you have to switch both poles.

Depends on what the AC does when it's cord is pulled out. Does it restart? More importantly, does it delay 1-5 minutes before restarting. That it needs to do. Modern Thermostats have that as an option.

That said, the easiest way I to get a modern thermostat with set-back capability. It may be smart enough to figure out what it has to do to have the temperature be X at some time. Mine knows too much, but it isn't a normal stat.

The coils freezing is potentially a bad thing. it's not productive.

So, simple solution: Modern thermostat (e.g. Honeywell Vision Pro See: (fancy model)), 24 VAC transformer, 24 VAC contactor. They put most of this together in a "Fan control center"; See:

Some stats have remote sensors. 24 VAC wiring doesn't need any special protections. Class 2 wiring should be limited to 100 W. The transformer itself, can be power limiting.

These thermostats can be really complex. I've looked at the non-wifi models.

What I've been wanting to do is to control a single damper, but not zone per se in a laundry room typically for a few hours. One caveat, I have is that between about 1:00 and 1:15 PM, that damper has to be full open. It's a luxury, so it hasn't been done yet.