seydx / homebridge-philipsair-platform

Homebridge plugin for philips air purifier and humidifier.
MIT License
25 stars 14 forks source link

Use config mappings #116

Open we5 opened 1 year ago

we5 commented 1 year ago

I think the current approach is quite limited to tackle the different behaviors and responses from all of the Philips Air Purifier line. Especially because it seems that Philips changes parameter names for newer models, as they appear to not be "plain text" anymore and are kind of obfuscated behind some kind of parameter mappings. See also issue #88.

I got two air purifiers myself just recently (AC3036 and AC1715) and both did not work with how the plugin sets/reads modes and speeds.

While the rotation speed slider generally is not my preferred way of setting modes, the current approach also was not working with both my models, so I tried to factor this in by providing some "speed configurations" where the parameters and values can be set, which are not only used for setting/reading the rotation speed based on the received device parameters.

This is still a bit WIP and extensivley monitored in my current home setup, but so far it is way more reliable than the original version.

Please do not hesitate to comment and also test existing devices with this new approach.

nashnix commented 11 months ago

Hi @we5,

I managed to get my homebridge to load and deploy your branch instead of this one (which doesn't work at all). It talks to one purifier (a 2939/70) with no problems at all - that one works perfectly.

The 1715/70 is not cooperating; it doesn't report air quality, doesn't signal commands across, I'm not even sure it's . I suspect this is because Philips has been mucking around the parameter mappings again. Unfortunately my knowledge of how to fix this is bordering on non-existent, but I think if you tell me how you found out parameter mappings you detail in issue #88 , then I'd be able to find them on the /70 and re-map accordingly (perhaps with my own fork of your fork - if that's OK with you).

Are you able to share that please? It would be a great help.

we5 commented 11 months ago

Hi @nashnix,

Unfortunately I do not recall anymore how I debugged all of this. I think there were some JSON responses flying around.

I also do not use this integration anymore as I migrated all of my former smart home system from FHEM/Homebridge over to Home Assistant and its integrations.

Sorry, but I think I cannot help you here. It took me a while back then to reverse engineer and debug the parameters and I just don’t have time at the moment for this.

Hope you will get some meaningful progress on this! 💪🏼

nashnix commented 11 months ago

Hey @we5,

Thanks for the very prompt reply - and that isn't an issue at all. I've not had a reason to start looking into Home Assistant as Homebridge has worked fine for everything, until now. But you letting me know that this works through HA and its integrations provides the perfect reason to start looking into that instead - and with a device that I don't need to be cooperating with me all the time (as opposed to, say, the lights).

we5 commented 11 months ago

@nashnix yes, overall I can say that the migration to home assistant made everything more reliable. And the Philips implementation is not perfect but a lot more reliable than what the homebridge plugin provided

nashnix commented 11 months ago

@we5 I'm now using your plug-in to capture the readings and logs for the author of the Home Assistant integration. It turned out that the HA will not talk to either device at all - but your plug-in talks to one of them and captures the activity from the Philips app to both of them without any trouble. Thought you'd get a smile out of that.