-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Zigbee things only work on a second click #322
Comments
Thanks for the bug report @evert. Some Zigbee devices do go to into sleep mode, but it's usually battery powered devices rather than mains powered devices which do that. The error looks like there might be a bug in the Zigbee adapter which is worth investigating so I've moved the issue to the zigbee-adapter repository. It might help if you provide the model numbers of the devices you're using as this may be difficult to reproduce. |
Yeah my intuition is that this is not a sleep issue, especially since it switches to a 'broken' state relatively quickly after the plugin is restarted. Also worth noting that this used to never be a problem, and I've been a Webthings Gateway user for 2ish years. The dongle is a Conbee II, this is my output from
If there is a way I can assist with this, let me know! It makes webthings very hard to use right now, because a lot of what I do is based on events & timers. |
So I've started hacking in the conbee.js file and I managed to stop it from crashing. Probably entirely in a bad way, maybe by ignoring an underlying problem. There are 2 places in conbee.js where there's a block like if (paramId == C.PARAM_ID.SCAN_CHANNELS) {
value = value.toString(16).padStart(8, '0');
} This fails because in my case if (paramId == C.PARAM_ID.SCAN_CHANNELS && value) {
value = value.toString(16).padStart(8, '0');
} This stops the zigbee adapter from crashing every minute. I have no idea if this is an appropriate fix though. The 2 places where I had to do this was in Happy to submit this as a PR too, but I don't know if there's additional adverse effects. |
At home I have a Webthings gateway (on raspberry pi). This pi has a zigbee adapter, and I have a couple of lights and switches.
When I click any 'thing' it typically does not respond. It almost feels like it takes a few minutes after interacting with it to 'wake up', after which they do work when turning on/off. This is very reliable, so when I use the gateway, I:
This is a bit frustrating, but it also means that my scheduled things (like turning on a light at a certain time of the day) typically doesn't work. My theory is that the events trigger the switches one, and then doesn't' try again after the 'wake up'.
I dusted off my Pi recently after not having used it for 10ish months, but I don't think this was ever an issue before.
This appears in my logs:
The text was updated successfully, but these errors were encountered: