I know that ESPHome can currently copy commands from my IR remote but those commands would be very dumb. It has up and down pushbuttons for temperature, a single pushbutton to cycle through the modes and a single pushbutton to cycle on/off. If HA can’t get feedback regarding current temp, mode or power I’m doubtful that I would have much success controlling this unit remotely or via automations but I’m hoping I’m wrong. What I want is to be able to operate this unit like a smart thermostat. Set modes and temperatures based on room temp,
You didn't include exactly which LG air conditioner you have.
Look here for how someone else solved a similar problem.
That indicates that while the remote only has buttons that are incremental, what it sends are more definitive.
You also didn't state your goal clearly, with the why.
What do you hope to gain with "smart" control?
I control a dehumidifier remotely, because the control system it uses is very energy inefficient. My dehumidifier comes on automatically (to the last setting) when power is restored. So I have it set to lower the humidity to 40% or so. It will never be able to achieve that, so I know it will come on when needed. I have humidity sensors that let me decide when I want it to come on and also when to turn off. This has worked well for my needs and is quite simple.
The dehumidifier has a protection system so it will wait at least 3 min before starring the compressor. Normally it would run the fan after turning off the compressor. That is actually a bad idea since it just puts back some of the moisture it just extracted.
Your needs might be different. If you want both manual and auto control that will likely be hard to achieve with a good experience.
You could use a binary sensor helper for on/off. Anything that just has 2 values. Almost easier to put an ESP32 with temp.sensor.near the AC unit. obviously not 100% accurate but with IR and no 2 way communication it's pretty much impossible to get some data. I use binary sensor helpers all the time to give device power states that don't have them. They can get out of whack sometimes but it's rare and easy to fix.
You can create automations to say, turn the temp up/down five times but two way communication is needed to be 100% accurate. Temperature sensor near the unit then figuring out any offset would probably work best. Then you could say, turn it off if it drops below a certain defined temp value.
I didn't see anyone having done the work to figure that particular one out. It might be like the one I linked above that does need to send full state out each time, or not. It will require some reverse engineering of the protocol to figure out.
Note that getting a combo heating cooling device to work well can be complicated. How does the automation know for sure if it should be in heat or cool mode?
Do you want to use the heat pump thermostat for temperature control?
You will need to use a different temperature sensor, since there likely isn't a way to get the temperature from the heat pump.
I am still not really seeing the need for this, and I live in a climate where it can be winter in the morning and summer in the afternoon. My furnace definitely comes on in the morning some days in June (and sometimes even in July) and some days it is hot enough to really need AC (but usually not the same day).
Right now I just use the remote and put it into cool mode in the summer and heat mode in the winter. The problem is that we can have days in the middle of winter that the high temp might be 90-100F and then a few days later they might be below freezing. I was hoping that the new IR capabilities in HA might be a way to deal with that but I’m not sure they’re up to it yet. I suppose it would be possible to setup an automation that adjusts the mode every 5 minutes (for example) until the temperature starts to change in the proper direction but that wouldn’t be very energy efficient.
Depending on what you consider to be comfortable, this could be done.
Let's say your winter/heating set point is 68 to 70 degrees.
If it is currently colder than 68 or 70, turn the heater on. If the heater is on and it is now over the set point, turn it off.
That is easy.
If your cooling set point is 74 or higher and it is currently hotter than 74, turn on the AC. When it is cooler than the set point turn off the AC.
That is also easy.
The problem is when you want the set points closer and you don't want to short cycle your equipment. To not short cycle, you need to keep the equipment on longer and turn on less frequently. This could mean the temperature ranges get closer or even overlap. So the system alternates heating and cooling in a not good way.
Looks like it handles the required control for both heating and cooling and can automatically select which to use.
I have not used it this way so no idea how well it does it. If you keep the set points far enough away from each other it should be fine.
That component needs a heat action an idle action and a cool action.
Once you decode the remote (see the links above). Cool action would be: Cool, cold temperature set point, medium or high fan speed
Heat action would be: Heat, warm/hot temperature set point, some fan speed
So it is completely doable, even if I don't really see the need/point of it.
I have been playing with dozens of AC IR-protocols including one LG, all mini-splits though. They all worked same way, sending all parameters with every single button press. Even if you need to "scroll" with the remote when you adjust mode or temp, the final button press state is all what the device cares about. Many ACs do not even consider the intermediate signals when you scroll.
For basic use you only need to capture 3 remote signals, for example HEAT/70F, COOL/72F and OFF.
You're not entirely wrong—but your expectations are a bit higher than what IR control without feedback typically delivers.
With ESPHome, you're essentially working "blind" via IR: the device receives commands but doesn't report back its current status (temperature, mode, power, etc.). Therefore, Home Assistant can't reliably know the current state of the air conditioner/heater—it can only guess.
Yes and no. With just IR you can't know for sure if the command made it all the way there or not. Way back in the dark ages before the esp chips became prevalent and before even Home Assistant was an idea, there were RF controlled outlets. Some of them used a toggle function for power. This was very bad for automated control.
I made sure to get ones that supported definitely ON and OFF. I then reverse engineered the protocol so that I could automate it and be reasonably sure the command had been accepted. I settled on 3 times on quick succession for each state change.
Today, it is even easier. Get a power measuring device and additional sensors. Power draw tells you the device is doing something. Temperature sensors tell you it is doing the right thing. Many of these remotes send the full state even if the buttons are up/down. So a definite control is reasonably easy to do. Additional sensors make it even easier to tell the device is doing the thing you want.
Another option is simply to build it well. About 15 years ago I built lot of AC controllers, I don't remember any missed transmission ever happened on non-battery-powered devices even at >5m distances.
A lot depends on the device and protocol. Some IR remotes only send "toggle" style commands, which makes automation unreliable because you have no idea if you are turning something on or off. Devices with explicit ON/OFF commands are much easier to work with.
The sensor approach is probably the most robust solution. If you can verify the result (power consumption, temperature, state feedback, etc.), then you’re no longer guessing whether the IR command worked.
Except if sensor didn't work. AC remote systems are pretty reliable, put fresh batteries on your remote and send 100 signals with few sec interval. Did it miss some?
The whole story about unreliable IR is coming from crap design of diy stuff, bad coding, incorrect circuits, absurd transmitter modules etc.
Obviously you can never be sure without feedback.