SphtKr / homebridge-zway

Homebridge plugin for (better) HomeKit support of RaZBerry and Z-Way Server
ISC License
85 stars 38 forks source link

0 Lux from brightness sensors shows as an error in Homekit apps #104

Open naofireblade opened 7 years ago

naofireblade commented 7 years ago

When it's dark the homebridge-zway plugin reports a value of 0 lux to homekit. The minimum value for the mapped characteristic CurrentAmbientLightLevel in homekit is 0.0001. As a result the value 0 leads to an error in homekit. As a solution all lux values below 0.0001 should be set to 0.0001.

SphtKr commented 7 years ago

Great catch! And easy to implement. I'll try to knock this out in the next day or two...meanwhile put a night-light in the room? (JK)

naofireblade commented 7 years ago

Thanks for the fast reply. I will try your workaround :D.