I have some Mitsubishi Heat Pumps that have the terrible Kumo Cloud WiFi module, and they find themselves offline for a few minutes out of the hour. While maybe one day I’d like to replace the Kumi WiFi module with an ESP32, in the meantime now I’d just like a way to set basically the equivalent of an MQTT Retain flag for my heat pumps. I don’t need them to take the command (ie temperature change, etc) immediately, but when they do come back online I want that to be pushed to the device.
For example, I have an automation that disables the AC if I open the window. Sometimes the Mitsubishi is offline when I open the window, and so it never gets the command to turn off. Ideally HASS would hold that command and push it again once the Mitsubishi decides its ready to come back online.
Do you think this might be possible? I have 7 heat pumps so the config might get complicated but thats fine.
I would create template climate entity to receive all the commands that is never unavailable. I would let that try to relay all the commands to the real one if the real one is available, and (only) copy its state from the real one if that is available.
Then I would create an automation to look for the real device going from unavaliable to anything other than unavailable. When it fires, you can copy the state from your template climate entity to the real entity.
Edit: just realized Home Assistent has no climate template entity, so some integration like this should help:
I came here for the Mitsubishi integration and stayed for the “update when offline” comment.
This is a general issue with Home Assistant in that it’s event-driven rather than state-driven. I can schedule an event to say, turn on a light at a certain time, but if the device is unavailable or HA is down at that moment it skips it. So I have a bunch of integrations that wake up periodically to poll conditions, etc. etc.
What I WANT is a simple option on entities to make them a “digital shadow” that caches the device state and tries to synchronize them with the device, polling the actual device state behind the scenes when necessary. This would let me set the STATE of the entity and then HA will try to make the device have the same state. If the device is offline, it should apply the state when it comes online. Ideally (although this is harder) if HA is down and misses a scheduled update to a state, it should catch up and get the state and the device to where it should have been. In other words, rather than keeping the state of the devices in the devices themselves, HA would keep the “master” state.
Unfortunately… that’s not how it works. At least I don’t think so. If there is some simple way to enable the behaviour above that I’ve overlooked someone PLEASE let me know!
Yes, you can program this behaviour, probably, by using a bunch of automations and templates etc. But I wish it was built in.