dahlb / ha_blueair

Home Assistant Integration for Blueair Class Filters
MIT License
25 stars 6 forks source link

Enable multiple sensors for 411i Max #65

Open musicjeremy opened 5 months ago

musicjeremy commented 5 months ago

A number of items are not showing up on my 411i Max models. I would be happy to provide info/data dumps to help you make these features work.

Snag_dff98d1

nickwest commented 4 months ago

I also have a 411i Max and see similar results as @musicjeremy. However, I'm fairly sure the 411i Max only has a PM 2.5 sensor in it. In the Blueair app I also only see PM 2.5 readings. I believe this is functioning as expected.

I think the only integration improvement would be to hide/disable those sensors if the model is 411i Max. If it helps, the device SKU of the 411i Max is 110057.

Great integration, works well!

jonathanrobichaud4 commented 3 months ago

@nickwest is correct. There's only PM2.5 for the 411i Max. The only reason these sensors are showing up is because they are available on the models the integration was originally written for. I just went into the the entities and disabled them which works well enough. Model handling could be implemented to make sure these entities only show up on supported models but as it is right now it doesn't break anything plus it would be hard to test.

dahlb commented 3 months ago

those entities were intentionally marked unavailable because the device doesn't support them. That is the only way I know to handle which devices support which entities dynamically. I think duck typing is much more resilient then maintaining a comprehensive list of which models support which entities.

we could try to affect the disabled status but the methods are under a warning

    # DO NOT OVERWRITE
    # These properties and methods are either managed by Home Assistant or they
    # are used to perform a very specific function. Overwriting these may
    # produce undesirable effects in the entity's operation.

so I've only make the availability dynamic