Philips Air Purifier

Yes I do see some warnings only regarding this:

2022-04-22 22:03:32 WARNING (SyncWorker_0) [homeassistant.loader] We found a custom integration philips_airpurifier_coap which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2022-04-22 22:03:32 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration hacs which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant

Later edit: as usual - as soon as I ask something online I get stuff working :sweat_smile: thought to fiddle with something else that is giving me grief, a Yamaha receiver, generating hundreds of errors. As soon as I reestablished connection and restarted HA (it was not the network, the receiver simply doesnā€™t respect MAC restrictions), thought to get back to purifiers. Andā€¦ it just worked WTF, so I added a purifier. Maybe the amount of errors that were delaying starting HA was the issueā€¦
Will report back if anything pops up but seems painless for now. Thanks!

1 Like

Hello @kongo09 , I am having an issue with AC2889

If the machine is off and I push the power button in HA (see picture) then the purifier starts and the button indicator become blue, but after a second or less it become grey.
So I donā€™t have any feedback of its status and I canā€™t power it off from HA.

Could it be caused by the fact that the machine is turned on without a preset mode?
Because the only way to power it off is to set a preset (like auto) and then push 2 times the power button (one to set on in HA and the other to really power off the machine).

I found it in 0.95 and 0.97.

The AC3033 works without this issue.

Also, sometimes I have this into my log. It is about both my purifier

the AC3033 (soggiorno - living room) and the AC2889 (camera da letto - bedroom)

Logger: homeassistant.components.sensor.recorder
Source: components/sensor/recorder.py:479 
Integration: Sensor (documentation, issues) 
First occurred: April 21, 2022, 7:20:10 PM (7 occurrences) 
Last logged: April 21, 2022, 7:20:10 PM

The unit of sensor.soggiorno_pm2_5 (Āµg/mĀ³) does not match the unit of already compiled statistics (None). Generation of long term statistics will be suppressed unless the unit changes back to None. Go to https://my.home-assistant.io/redirect/developer_statistics to fix this
The unit of sensor.soggiorno_total_volatile_organic_compounds (Level) does not match the unit of already compiled statistics (None). Generation of long term statistics will be suppressed unless the unit changes back to None. Go to https://my.home-assistant.io/redirect/developer_statistics to fix this
The unit of sensor.camera_da_letto_air_quality_index (AQI) does not match the unit of already compiled statistics (None). Generation of long term statistics will be suppressed unless the unit changes back to None. Go to https://my.home-assistant.io/redirect/developer_statistics to fix this
The unit of sensor.camera_da_letto_indoor_allergen_index (IAI) does not match the unit of already compiled statistics (None). Generation of long term statistics will be suppressed unless the unit changes back to None. Go to https://my.home-assistant.io/redirect/developer_statistics to fix this
The unit of sensor.camera_da_letto_pm2_5 (Āµg/mĀ³) does not match the unit of already compiled statistics (None). Generation of long term statistics will be suppressed unless the unit changes back to None. Go to https://my.home-assistant.io/redirect/developer_statistics to fix this

Thatā€™s great. However, donā€™t bet on it to be stable. For me, it sometimes works for a few days and then it totally doesnā€™t. Right now, I cannot even tinker with the integration as the purifiers totally refuse to play nice, no matter how often I reboot HA, the devices or both.

Please report issues on the repository:

Iā€™ve started your issue here, but I need your support to understand it:

This happens when you change sensor units. HA collects data for longterm statistics, but if the units change, it doesnā€™t know how to reconcile this. Maybe you can fix this on the statistics page:

image

Thank you, I was in doubt if post here or open an issueā€¦ but since i am not an expert (totally newbie) on github I posted here :innocent:

So far so good, but maybe a feature request: my devices have certain operation modes, which correspond to betaboonā€™s ā€œpreset_modesā€ GitHub - betaboon/philips-airpurifier-coap: šŸ’Ø Philips AirPurifier custom component for Home Assistant. With support for new Devices with CoAP protocol. Tested on AC2729/10 (bought early 2020)

Very important for automations and if you want to sleep in a room with one :hear_no_evil:
Is it possible to add it?

Preset modes are still there. Check fan.set_preset_mode

Yes it is true - tested them last night, seem to be working, thanks for confirming. But what about the interface, as a working dropdown like the humidity setting? Would that be possible because everything else was working out of the box?

BTW curious, did you include some tests and reconnects, something like this, solved for me lots of connectivity issues Disconnected Test Ā· mhetzi/philips-airpurifier-coap@5c8842c Ā· GitHub & Reconnect on connection failure Ā· mhetzi/philips-airpurifier-coap@19105db Ā· GitHub

That exists by default as part of the fan model. If you click on the fan entity and look at the controls there, youā€™ll see:

image

This is still missing. There is a beta with some first code thankfully contributed by @mhetzi . For some people it seems to work. For me it throws errors. I just need some time to figure out if the problem is on my side. As soon as I get to it, Iā€™ll merge it into master.

v0.9.8 released

  • fixes turbo mode for AC1214
  • introduces autodiscovery (experimental)
2 Likes

Could you give me a hint: What exactly did you reload? And how do you detect when to reload?

Reload the integration.

Or you can reload it with the service homeassistant.reload_config_entry

1 Like

Hmmā€¦maybe that works for devices that are loaded:
image

But it doesnā€™t for the ohter one that didnā€™t load:
image

But Iā€™ll do some more testsā€¦

I guess, it didnā€™t load because the device has not been powered on when Home Assistant was started.
For this the integration should have a loop to try to connect to the device periodically.

But you can still try to use the service from Developer tools to reload the integration. It might work, disregarding the fact that it hasnā€™t got the option in the menu.

Nah, they are both powered onā€¦ In about 50% of the cases Iā€™m lucky, and they are found after a full rebootā€¦

Will try if I can reload if not loadedā€¦

As you see I have a 3829 as well. But I donā€™t have any issues with connections even in that troubling newish firmware, since the fix was deployed by somebody to flush states (I cannot remember exactly when and how was that.)
I do have issues when the power has been cut, as the device stops sending updates as being a local push. The CoAP connection has to be reestablished and it sends again, so this new version of the integration solves that problem as well. So I can reload the integration and it updates values as expected.

I did have some weird behaviour from the device when I was changing humidity levels and the display stuck at humidity, or I was fidling before with the display brightness, but not any connectivity issues.
I have a Velop mesh, and seems to be the recent firmware updates of the Velop solved most of the connectivity problems with my WiFi devices, which had before any, but not the Airpurifier, that was always reporting things correctly and had a stable connection to the WiFi.

So solving any misbehaviour of the device, I usually just unplug it, leave it that way for a minute or so, then plug it back and everything works again as it should be. (For sure it has plenty issues with its firmware.)

If you do have connectivity issues with the device, it might worth to reset it and set it up again with your WiFi. At some point during the years I had to do that once, but I cannot remember what was the reason for it.

Thanks! Sorry that I missed this earlier, but my unit arrived today and I was able to get the services and entity to appear with on/off and mode available.

I guess I had assumed this without properly confirming, but I had thought that an air quality sensor would be available. Is this not the case for the AC2939/70 or are some extra steps required to get it up and running?

I also have this integration working for some time, i notice the following since latest releases.

Issue 1 after I restart homeassistant it hangs on loading the integration until i do something with the airpurifier, change mode on the device or turn off or onā€¦ then the integration loads and homeassistant startsā€¦ otherwise it just hangs until a timeout and the device is greyed out.

Issue 2 After latest releases it looses state, Ha (or node red) turns it ā€¦ the device turns on but then after few seconds the button turns off (not the device) and the state is out of syncā€¦
See Logging:

2022-05-21 09:54:52 DEBUG (MainThread) [aioairctrl.coap.client] REQUEST: {"state": {"desired": {"CommandType": "app", "DeviceId": "", "EnduserId": "", "pwr": "1"}}}
2022-05-21 09:54:52 DEBUG (MainThread) [coap] Sending request - Token: 8cbd, Remote: <UDP6EndpointAddress 192.168.1.74>
2022-05-21 09:54:52 DEBUG (MainThread) [coap] Sending message <aiocoap.Message at 0x7f90ac3100: Type.NON POST (MID 42295, token 8cbd) remote <UDP6EndpointAddress 192.168.1.74>, 1 option(s), 264 byte(s) payload>
2022-05-21 09:54:52 DEBUG (MainThread) [coap] Incoming message <aiocoap.Message at 0x7f91c795e0: Type.NON 2.05 Content (MID 42295, token 8cbd) remote <UDP6EndpointAddress 192.168.1.74 (locally 192.168.1.75%eth0)>, 1 option(s), 19 byte(s) payload>
2022-05-21 09:54:52 DEBUG (MainThread) [coap] Received Response: <aiocoap.Message at 0x7f91c795e0: Type.NON 2.05 Content (MID 42295, token 8cbd) remote <UDP6EndpointAddress 192.168.1.74 (locally 192.168.1.75%eth0)>, 1 option(s), 19 byte(s) payload>
2022-05-21 09:54:52 DEBUG (MainThread) [coap] Response <aiocoap.Message at 0x7f91c795e0: Type.NON 2.05 Content (MID 42295, token 8cbd) remote <UDP6EndpointAddress 192.168.1.74 (locally 192.168.1.75%eth0)>, 1 option(s), 19 byte(s) payload> matched to request <PlumbingRequest at 0x7f90823160 around <aiocoap.Message at 0x7f90ac3100: Type.NON POST (MID 42295, token 8cbd) remote <UDP6EndpointAddress 192.168.1.74>, 1 option(s), 264 byte(s) payload> with 2 callbacks>
2022-05-21 09:54:52 DEBUG (MainThread) [aioairctrl.coap.client] RESPONSE: b'{"status":"failed"}'
2022-05-21 09:54:52 DEBUG (MainThread) [aioairctrl.coap.client] set_control_value failed. resyncing...
2022-05-21 09:54:52 DEBUG (MainThread) [aioairctrl.coap.client] syncing
2022-05-21 09:54:52 DEBUG (MainThread) [coap] Sending request - Token: 8cbe, Remote: <UDP6EndpointAddress 192.168.1.74>
2022-05-21 09:54:52 DEBUG (MainThread) [coap] Sending message <aiocoap.Message at 0x7f91c79940: Type.NON POST (MID 42296, token 8cbe) remote <UDP6EndpointAddress 192.168.1.74>, 1 option(s), 8 byte(s) payload>
2022-05-21 09:54:52 DEBUG (MainThread) [coap] Incoming message <aiocoap.Message at 0x7f91c79400: Type.NON 2.05 Content (MID 42296, token 8cbe) remote <UDP6EndpointAddress 192.168.1.74 (locally 192.168.1.75%eth0)>, 1 option(s), 8 byte(s) payload>
2022-05-21 09:54:52 DEBUG (MainThread) [coap] Received Response: <aiocoap.Message at 0x7f91c79400: Type.NON 2.05 Content (MID 42296, token 8cbe) remote <UDP6EndpointAddress 192.168.1.74 (locally 192.168.1.75%eth0)>, 1 option(s), 8 byte(s) payload>
2022-05-21 09:54:52 DEBUG (MainThread) [coap] Response <aiocoap.Message at 0x7f91c79400: Type.NON 2.05 Content (MID 42296, token 8cbe) remote <UDP6EndpointAddress 192.168.1.74 (locally 192.168.1.75%eth0)>, 1 option(s), 8 byte(s) payload> matched to request <PlumbingRequest at 0x7f90823340 around <aiocoap.Message at 0x7f91c79940: Type.NON POST (MID 42296, token 8cbe) remote <UDP6EndpointAddress 192.168.1.74>, 1 option(s), 8 byte(s) payload> with 2 callbacks>
2022-05-21 09:54:52 DEBUG (MainThread) [aioairctrl.coap.client] synced: 161A0377
2022-05-21 09:54:52 DEBUG (MainThread) [aioairctrl.coap.client] set_control_value failed. retrying...
2022-05-21 09:54:52 DEBUG (MainThread) [aioairctrl.coap.client] REQUEST: {"state": {"desired": {"CommandType": "app", "DeviceId": "", "EnduserId": "", "pwr": "1"}}}
2022-05-21 09:54:52 DEBUG (MainThread) [coap] Sending request - Token: 8cbf, Remote: <UDP6EndpointAddress 192.168.1.74>
2022-05-21 09:54:52 DEBUG (MainThread) [coap] Sending message <aiocoap.Message at 0x7f91c79700: Type.NON POST (MID 42297, token 8cbf) remote <UDP6EndpointAddress 192.168.1.74>, 1 option(s), 264 byte(s) payload>
2022-05-21 09:54:52 DEBUG (MainThread) [coap] Incoming message <aiocoap.Message at 0x7f9a2bab50: Type.NON 2.05 Content (MID 42297, token 8cbf) remote <UDP6EndpointAddress 192.168.1.74 (locally 192.168.1.75%eth0)>, 1 option(s), 20 byte(s) payload>
2022-05-21 09:54:52 DEBUG (MainThread) [coap] Received Response: <aiocoap.Message at 0x7f9a2bab50: Type.NON 2.05 Content (MID 42297, token 8cbf) remote <UDP6EndpointAddress 192.168.1.74 (locally 192.168.1.75%eth0)>, 1 option(s), 20 byte(s) payload>
2022-05-21 09:54:52 DEBUG (MainThread) [coap] Response <aiocoap.Message at 0x7f9a2bab50: Type.NON 2.05 Content (MID 42297, token 8cbf) remote <UDP6EndpointAddress 192.168.1.74 (locally 192.168.1.75%eth0)>, 1 option(s), 20 byte(s) payload> matched to request <PlumbingRequest at 0x7f91c79b20 around <aiocoap.Message at 0x7f91c79700: Type.NON POST (MID 42297, token 8cbf) remote <UDP6EndpointAddress 192.168.1.74>, 1 option(s), 264 byte(s) payload> with 2 callbacks>
2022-05-21 09:54:52 DEBUG (MainThread) [aioairctrl.coap.client] RESPONSE: b'{"status":"success"}'

Hopefully this can be fixedā€¦ did not have this behaviour beforeā€¦

Greetings

AC4236 My Device

Philips AirPurifier (with CoAP)

v0.10.7