Airtouch 5 Integration (Aus)

Hey all, finally installed thie integration. I want to add it to my page of room temps

image

which are like this for each room.

The default is a bit big.

Any good idea how to make a small bit, Basically I just want a slider + on/off toggle in 1 line.

Also what does it mean if I try to change the temperature in the air conditioner?

Thereā€™sThereā€™s no such setting in the actual tablet because the temperatures are set per zone.

I think you could add switch entities which when turned on and off control the aircon for each room. That would be how I would do it if I wanted smaller switches but not sure if there is a better way

The air con temperature itself is read-only. If you try to change it it will just revert back to what it was (based on the temp of the zones)

I havenā€™t found a good way to prevent changing the set point on the AC climate entity without removing the display of the current set point. Itā€™s on my to-do list to investigate further but I suspect the best I could do is report an error for systems with active temperature controlled zones.

As mentioned by @Dr-Inkduff, the AirTouch will just ignore any changes and quickly revert back to the automatic set point.

Thereā€™s a few custom climate cards available which might suit your use case better. Smart Home Scene has a good overview of the options:

Hey - just wondering if any one has the actual AirTouch 5 API reference? Iā€™m making changes on the airtouch4pyapi code for my own usage, and need the reference in order to make the changes. I see in this thread itā€™s been mentioned that some people have it. If youā€™re able to DM it to me, that would be appreciated.
Thanks,
Josh

Hi Josh,

Iā€™ve included a copy of the docs in the backing library for my integration:

You can find them in the docs/protocol folder. There are also comments in the implementation and you could compare AirTouch 4 and 5 differences since the API supports both versions.

If youā€™re developing a standalone application, you would be also able to use the pyairtouch library directly if you want rather than the old airtouch4pyapi. My library provides a slightly higher level of abstraction and implements the auto discovery parts of the protocol.

Happy to answer questions if youā€™re unsure about anything.

Hi - thanks so much for this! This implementation seems to be far more sophisticated than the airtouch4pyapi - I think Iā€™ll be using this instead!

Mind you, Iā€™m a .Net, not a Python programmer, so Iā€™ll be porting it to .Net, as Iā€™m writing a .Net/React BE/FE implementation of the interface, because I think the one that comes with Airtouch sucks balls big time (particularly for my AC/Zoning setup).

If anyone else is interested in creating and maintaining a .Net port of this API, let me know!

I have edit the default add-on to ha, And then removed the airtouch from Google assistant.

Iā€™m finding that now if I turn on the air conditioner using Google assistant/home, It always automatically changes it to heat mode. With the airtouch integration it would just do the power as expected.

Any ideas?

Iā€™ve encountered a problem today that I havenā€™t seen anyone mention yet.
TL;DR state updates are no longer processed.

I had a Daikon ducted system installed last September, and had this integration working before the installer had finished cleaning up. And it has been great! Until now. Iā€™ll try to explain, but basically updates from the Airtouch 5 arenā€™t being processed in HA.

In more detail, Iā€™ve noticed that:

  • control commands from HA to Airtouch seem to work, like changing modes, changing zone temperatures or closing a damper
  • the current state of the entities do update when HA is restarted, but after that there will be no further updates in HA

My investigation so far:

  • enabled debug logging, and confirmed that airtouch5py.airtouch5_client is receiving data packets, no errors logged
  • uninstalled the custom component, migrating to the official integration (and then realised that some sensors are missing, for now)
  • and yes, HA has been restarted a bunch of times, has been updated to the latest version etc

The only thing I can think of now is to get the python libraries so that I can run it for myself and compare to the API docs linked above to see if anything has changed.

One thing worth mentioning is that, quite randomly last week, a 2nd AC unit appeared in the Airtouch UI. Itā€™s name is NO AC, and I canā€™t work out how to remove it - there is definitely only 1 AC unit connected to Airtouch. I donā€™t think that is linked, as HA was working fine after it occurred.

Has anyone seen this before?

This comes from the Home Assistant default implementation of the turn_on service in climate entities. Unless it is overridden, turn_on will choose the first supported mode from the list:

  1. Heat/Cool
  2. Heat
  3. Cool

The built-in AirTouch 5 integration uses Auto mode instead of Heat/Cool mode (which is incorrect according to the description of the modes in the documentation) so Heat becomes the highest priority. Iā€™ve just released a v0.4.5 of my custom integration which makes it so that the turn on command will just turn on the power like you are expecting.

Feel free to give it a try and let me know if you have any issues.

I havenā€™t seen any errors with state updates not coming through (but I use my custom integration instead of the default).

I think the debug logging in my integration might be a bit more detailed with regards to connection and message handling (because I needed detailed logs to find issues with the AirTouch 4 implementation). If you install my integration and generate a set of debug logs, feel free to DM them through to me and Iā€™m happy to take a look and see if anything stands out.

Thanks @TheNoctambulist I will have a crack at using yours. Iā€™ve been experimenting with the airtouchpy5 library that the official integration usesā€¦ adding some extra debugging I seemed to have proven that the library itself is receiving and decoding packets correctly.

So Iā€™m really not sure where my problem lies!

Wow, hass-airtouch does have a lot more to say. It is failing to complete the initial setup, spitting out this message:

2024-02-29 22:48:01.212 ERROR (MainThread) [pyairtouch.comms.socket] _read(): Unexpected exception in socket handling
Traceback (most recent call last):
  File "/usr/local/lib/python3.12/site-packages/pyairtouch/comms/socket.py", line 349, in _read
    read_result = await self._read_one_message()
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pyairtouch/comms/socket.py", line 416, in _read_one_message
    message_result = message_decoder.decode(message_buffer, header)
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pyairtouch/at5/comms/xC0_ctrl_status.py", line 211, in decode
    sub_message_result = sub_message_decoder.decode(
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pyairtouch/at5/comms/xC023_ac_status.py", line 249, in decode
    mode=self._decode_mode(b2),
         ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pyairtouch/at5/comms/xC023_ac_status.py", line 274, in _decode_mode
    return AcMode((byte2 & 0xF0) >> 4)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/enum.py", line 744, in __call__
    return cls.__new__(cls, value)
           ^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/enum.py", line 1158, in __new__
    raise ve_exc
ValueError: 15 is not a valid AcMode

Edit: With a little more digging/debugging I can see that the invalid AC mode is coming from the bizarre 2nd non-existent AC that appeared in my console. Iā€™ve contacted Polyaire if they can explain how this could happen.

I have successfully switched over to the hacs version

I have a query - these 2 are the same for a zone:

cannot have a distinct mode from the other zones

I use mushroom-climate-card

also you are supporting .5Ā°
in the official app it only supports full numbers does it actually work with half degrees?


also I canā€™t see it in google home.

image

but in dash I see sensors but not the control

The mode and fan speed represent slightly different things for a zone.

If the AC is turned off, the mode will always be off. If the AC is turned on the mode will be off if the zone is off or the same as the AC mode if the zone is on. You cannot have different modes for each zone because that is controlled by the AC.

The fan speed always represents the state of the zone, either off, on, or turbo. This should match the state of the zoneā€™s power button in the official app. It can be used to identify which zones will turn on if the air conditioner is turned on.

To get the control in the dashboard you need to add a climate card (built-in or mushroom) with the climate entity. My integration also exposes seperate sensors for temperature values which is what you would be seeing on your dashboard.

The API for the AirTouch 5 actually supports 0.1 degree increments. 0.5 degrees work as far as I can tell but you will see a rounded number in the official app.

I havenā€™t experimented with voice control at all yet, so I canā€™t help much with this one. Do you need to set an alias in the voice assistant settings?
The other thing to check might be whether there are any leftover entities from the other integration interfering. I noticed that the temperature sensor was called ā€œAircon Temperatureā€ but your climate entity is called ā€œAir Conditionerā€. By default the prefix of the temperature sensor matches the name of the climate entity.

Hopefully they can sort it out. If not feel free to send through a set of debug logs including a home assistant restart and I could look into adding a workaround to try and ignore the invalid AC.

Yes Iā€™m seeing a lot more senses Iā€™m not fully understanding if I need or want them all in HA

What is the temperature sensor in the main device because as far as I know the main device does not contain a sensor

and then what is the point of this device that only contains the air conditioner


whatā€™s Google Home the entity is simply appear from home assistant so itā€™s appearing now however the voice command isnā€™t working so well.

For example normally you could say turn off air conditioner master zone and it will toggle that zone on and off. It seems to be doing something strange but I will have to test it a bit more.

One of the problems Google Home has always had is that it doesnā€™t know how to deal with air conditioner the name of the device versus air conditioner the type of a device and I donā€™t know how to get around that.

And half the time it wants to list air conditioner repair people nearby.

The temperature sensor for the main Air Conditioner indicates the temperature being used as the control temperature for the AC. It will usually match the temperature of one of the zone sensors but may also be the temperature of the sensor in the return air duct depending on the settings for the AirTouch. The value is the same as the current temperature shown on the main screen of the official app.

There is a description of every entity created by the integration in the README of the repository (also visible in HACS). You can disable any entities you arenā€™t using.

This device represents the AirTouch console. It contains an update entity which will tell you when a software update is available. The AirTouch also supports multiple ACs in one system, all ACs connected to the AirTouch will be shown there.

Would the new alias feature help with that?

1 Like

thanks. Iā€™m not sure if this is a bug, but Changing the mode on the air conditioner also turns it on. I would have expected this to change the mode without Changing the power.