hthiery / python-fritzhome

Python Library to access AVM Fritz!Box homeautomation
MIT License
52 stars 37 forks source link

Fix Telekom HANFUN Devices #83

Closed parliament119 closed 1 year ago

parliament119 commented 1 year ago

To correctly detect Telekom HANFUN Lightbulbs which only support warm-white colors the provided functionbitmask needs to be checked for Bit 2: Licht/Lampe (from the http api).

For Telekom HANFUN plugs the Bit 15: an-/ausschaltbares Gerät/Steckdose/Lampe/Aktor needs to be checked. Bit 9: Schaltsteckdose seems to be only valid for AVM-proprietary devices.

MattBavaria commented 1 year ago

Hello @hthiery,

I‘d like you to review that pull request. I tried with Magenta switching plugs and it works for me. Regards, MattBavaria

hthiery commented 1 year ago

@parliament119 could you please check and fix the failing pipelines. In addition some unittest and adding your devices you tested your change on to the tested devices section in the README would be great.

Thanks

coveralls commented 1 year ago

Coverage Status

Coverage: 92.411% (-0.4%) from 92.794% when pulling fcad7916d6e260bccb67031202b8deb4477a5ec1 on parliament119:fix/hanfun_lightbulbs_and_switches into e1ff69617966b3347aaf1063562f10e00eeb9fcc on hthiery:master.

hthiery commented 1 year ago

@parliament119 could you please meld the fix commits (fix flake and fix response) to the corresponding commit?

thanks

MattBavaria commented 1 year ago

Hello,

if you like, you can add following devices as “tested” as well.

I tested them both with the patch I provided as well as with that branch. Regards, MattBavaria

hthiery commented 1 year ago

Thanks!

hthiery commented 1 year ago

@MattBavaria @parliament119 just tagged to 0.6.8 and published on pypi

parliament119 commented 1 year ago

Great! Thank you!

MattBavaria commented 1 year ago

@hthiery Thank very much, looking forward to new integration in home assistant docker.

Regards, MattBavaria

parliament119 commented 1 year ago

I opened up a Pull Request to fix the Home Assistant Integration.