Open Marfre888 opened 2 years ago
Could you provide your accessory config? Also, HomeBridge debug log might help.
Sure;
Homebridge debug log:
[01/01/2022, 20:56:36] [Screen Light Bar] setBrightness to: 21 transformed: [ 21, 'smooth', 500 ] [01/01/2022, 20:56:36] [Screen Light Bar] setActive to: 1 transformed: [ 'on', 'smooth', 500 ] [01/01/2022, 20:56:36] [Screen Light Bar] setBrightness [ 'ok' ] [01/01/2022, 20:56:36] [Screen Light Bar] setActive [ 'ok' ] [01/01/2022, 20:56:36] [Screen Light Bar] setBrightness to: 0 transformed: [ 0, 'smooth', 500 ] [01/01/2022, 20:56:36] [Screen Light Bar] setActive to: 0 transformed: [ 'off', 'smooth', 500 ]
[01/01/2022, 20:56:37] [Screen Light Bar] setBrightness Error:
at Object.reject (/usr/local/lib/node_modules/homebridge-yeelight-screen-bar-pro/node_modules/miio/lib/network.js:475:13)
at DeviceInfo.onMessage (/usr/local/lib/node_modules/homebridge-yeelight-screen-bar-pro/node_modules/miio/lib/network.js:374:8)
at Socket.
[01/01/2022, 20:56:37] [Screen Light Bar] setActive [ 'ok' ] [01/01/2022, 20:56:41] [Screen Light Bar] Data fetched [ 'off', '21', '4431', '2', '51', '16712463', '357', '98', '0', 'off', 'off', '1', '4000' ] { power: 'off', bright: '21', ct: '4431', color_mode: '2', bg_bright: '51', bg_rgb: '16712463', bg_hue: '357', bg_sat: '98', bg_proact: '0', main_power: 'off', bg_power: 'off', bg_lmode: '1', bg_ct: '4000' }
Config file:
{
"ip": "192.168.1.xxx",
"token": "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"name": "Screen Light Bar",
"model": "Screen Bar Pro",
"manufacturer": "Yeelight",
"backgroundName": "Bedroom Monitor Backlight",
"backgroundColor": true,
"_bridge": {
"username": "xx:xx:xx:xx:xx:xx",
"port": xxxxx
},
"accessory": "YeelightScreenBarPro"
}
It's also worth noting that when I get the error, the tile changes to 'No Response' however after a couple of seconds the error clears itself.
The monitor light is able to be turned off despite the error (even though it won't work in automation), the backlight does not turn off (or does so very rarely).
Let me know if you need anything else from my end, and if you've been able to reproduce this issue.
@SR2k Do you have anything for me please 🙏
Sorry for still being occupied by company stuff. I'll turn to it this weekend.
Ahh no worries.
Thank you very much for your help
@Marfre888 I have published a new beta version. Could you try it? Here's the command to upgrade with npm:
npm i -g homebridge-yeelight-screen-bar-pro@0.0.1-beta.9
Hi @SR2k
I have tried beta 9 and I can confirm it does in fact fix this issue with crashing/ no response, and am finally able to use automations to set it to turn off.
However with the ability to do that, I’ve discovered another 3 bugs.
For specifically the back light, when using the scroll bar (in the tile) (it doesn’t seem an issue with automations), if you scroll it from 100% to 0% to turn the light off, it doesn’t actually do that, instead it just gets very dim. It seems you need to let it sit on 1% then moving it to 0% to turn the light off manually.
Another one is it seems in automations, specifically for the back light it correctly sets the light brightness, but ignores hues, it’s happy to set any type of white light, but the second you set it to a colour it will not work. I’m not exactly sure what it happening, but it my case it just seems to set the light to green if I set it to a colour.
Lastly, the tile doesn’t seem to update if I turn on the light using the physical button or through the MI app. Is that a problem with polling that I can fix by lowering the rate or is that a bug? If so, what’s the ideal polling rate.
Thanks
@Marfre888
The first two issues seem like bugs. I'll try to fix them later.
For the third point, this plugin uses the polling pattern to fetch data from your light bar. When data is fetched, the plugin will tell HomeBridge to update the tile. Say you config your pollingInterval
to 3000
, the plugin fetches the state of the bar every 3000ms. Reducing your pollingInterval
will shorten the delay for updating. However, I have tried to set such config to 500ms, but the bar seems not able to handle such a frequent update, and result in jams.
@Marfre888
The first two issues seem like bugs. I'll try to fix them later.
For the third point, this plugin uses the polling pattern to fetch data from your light bar. When data is fetched, the plugin will tell HomeBridge to update the tile. Say you config your
pollingInterval
to3000
, the plugin fetches the state of the bar every 3000ms. Reducing yourpollingInterval
will shorten the delay for updating. However, I have tried to set such config to 500ms, but the bar seems not able to handle such a frequent update, and result in jams.
Thank you @SR2k,
What would you say is the ideal sweet spot? 3000ms? That’s 3 seconds correct?
Regarding the other two issues, let me know if you also reproduce those issues.
@Marfre888
I set it to 2000
for 2 seconds and it works well for me. Also, here are some notes about those two issues:
For the first one, I have just published homebridge-yeelight-screen-bar-pro@0.0.1-beta.10
, and I'm not sure if it will work. Please have a try and let me know.
For the second one, I cannot reproduce it here, could you provide a HomeBridge debug log?
@Marfre888
I set it to
2000
for 2 seconds and it works well for me. Also, here are some notes about those two issues:For the first one, I have just published
homebridge-yeelight-screen-bar-pro@0.0.1-beta.10
, and I'm not sure if it will work. Please have a try and let me know.For the second one, I cannot reproduce it here, could you provide a HomeBridge debug log?
Hi,
Can confirm that a pollingInterval
of 2000
fixes issue 3
Beta10 unfortunately doesn't address any of the other issues. It actually reintroduces the No Response bug that was fixed with Beta9.
Issue 1: With Beta10, unfortunately, it still does not turn off completely, stops around 1%. However, when turning it off through an automation it does so successfully 99% of the time. Are you able to reproduce this on your end?
Regarding issue 2 I'm not exactly sure what debugs to provide you, as the problem seems very weird. If I manually change it inside the tile, it works correctly. However, the second I put it inside a scene it defaults to green. What's even more confusing is that after fiddling around with it, my scenes now change to the correct colour, but if I create a new scene, the problem returns. It could be a problem specific to my Homekit setup, however, none of my other Homekit lights experience this problem. Let me know what I can provide you to help you narrow it down.
Hi @SR2k,
Is this project dead?
Hi,
I've installed this plug in, and it works great in Homekit, however when I try to set to brightness to 0 it seems to error out.
Am I doing something wrong?