homebridge-switchbot
homebridge-switchbot copied to clipboard
Bug: Light sensing doesn't communicate with homebridge and homekit
Describe The Bug
Light sensor doesn't register the actual Lux, it's stuck on 6001 Lux
To Reproduce
No steps necesarry, it's on 6001 Lux all the time
Expected behavior
Correct register of the amount / level of light that the switchbot curtain registers in the switchbot app
Relevant log output
[16/06/2022, 20:05:40] [SwitchBot] Curtain: Gordijn voordeur OpenAPI parseStatus
[16/06/2022, 20:05:40] [SwitchBot] Curtain Gordijn voordeur CurrentPosition: 1
[16/06/2022, 20:05:40] [SwitchBot] Curtain: Gordijn voordeur Standby, CurrentPosition: 1
[16/06/2022, 20:05:40] [SwitchBot] Curtain: Gordijn voordeur Stopped
[16/06/2022, 20:05:40] [SwitchBot] Curtain: Gordijn voordeur CurrentPosition: 1, TargetPosition: 1, PositionState: 2,
[16/06/2022, 20:05:40] [SwitchBot] Curtain: Gordijn voordeur CurrentAmbientLightLevel: 6001
[16/06/2022, 20:05:40] [SwitchBot] Curtain: Gordijn voordeur updateCharacteristic CurrentPosition: 1
[16/06/2022, 20:05:40] [SwitchBot] Meter: Gordijn voordeur MQTT message: CurrentPosition/1 options:{}
[16/06/2022, 20:05:40] [SwitchBot] Curtain: Gordijn voordeur updateCharacteristic PositionState: 2
[16/06/2022, 20:05:40] [SwitchBot] Meter: Gordijn voordeur MQTT message: PositionState/2 options:{}
[16/06/2022, 20:05:40] [SwitchBot] Curtain: Gordijn voordeur updateCharacteristic TargetPosition: 1
[16/06/2022, 20:05:40] [SwitchBot] Meter: Gordijn voordeur MQTT message: TargetPosition/1 options:{}
[16/06/2022, 20:05:40] [SwitchBot] Curtain: Gordijn voordeur updateCharacteristic CurrentAmbientLightLevel: 6001
[16/06/2022, 20:05:40] [SwitchBot] Meter: Gordijn voordeur MQTT message: CurrentAmbientLightLevel/6001 options:{}
Config for homebridge-switchbot
{
"bridge": {
"name": "",
"username": "",
"port": 51738,
"pin": "",
"advertiser": "bonjour-hap"
},
"accessories": [],
"platforms": [
{
"name": "Config",
"port": 8581,
"platform": "config"
},
{
"refreshToken": "",
"hideDoorbellSwitch": false,
"platform": "Ring"
},
{
"name": "SwitchBot",
"credentials": {
"openToken": "",
"notice": "Keep your token a secret!"
},
"platform": "SwitchBot"
}
]
}
Screenshots
Device & Model
Raspberry PI 4 (4gb)
Node.js Version
v16.14.2
NPM Version
dont know where to find this!
Homebridge Version
v1.4.1
Homebridge Switchbot Plugin Version
V1.13.0
Homebridge Config UI X Plugin Version
v4.47.0
Operating System
Raspbian
Hi,
I'm relatively new to homebridge (,Github) and Raspberry Pi at all. But this is a description of the problem:
Can somebody please help me with getting my Switchbot light-sensors from the curtain bots to work properly in Apple Homekit.
I've connected the curtain bots to Homekut throughout Homebridge but the light-sensors in Homebridge and Homekit keep on saying the same amount of Lux (6000Lux) throughout the whole day, even though the light-sensors registers other values in de Switchbot app.
I really want this to work so i can make my automations work with it.
Thanks!
This is all based off the API data.
I have this problem as well. Running Homebridge on Mac OS
Same here. I haven’t found any solution so far (except for hiding the light sensor for HomeKit, although I didn’t succeed in that either).
@donavanbecker Said in another comment:
BLE sees different values for Lux levels then OpenAPI.
And then in another thread:
BLE Sends me info 10 different amounts, if you set the maxLux and minLux then these numbers would divide by 9 and would set the value for each interval.
OpenAPI only sends me 2 either
dim
orbright
. So it will always be either 1 or 6001 unless you change the maxLux and minLux.
Would it be possible to update open API to send more than two values? It would be awesome if the light sensor were more accurate with OpenAPI.
Same issue here