youridijk / homebridge-kaku-ics2000

HomeKit support for Klik Aan Klik Uit ICS-2000
Apache License 2.0
21 stars 6 forks source link

Issue when switching multiple devices at the same time #27

Open tidijo opened 1 year ago

tidijo commented 1 year ago

Hi, I have multiple switches in KAKU. I can all add them in Homekit, however when I create a scenario in Homekit to for example turn on all lamps, only a few lamps will go on (not always the same lamps). I tried to create a similar scenario in Apple Shortcuts with the difference that I added a delay between switching every lamp on and then it works. It is my guess that Homekit/Homebridge sends all commands almost at the same time to KAKU and that KAKU ICS2000 starts sending out the RF command also almost all at the same time, which makes that some RF commands won't reach the switches. Is it possible to build in a delay in the Homebridge-kaku interface (probably 200ms-500ms is enough) after is sends a command, so that KAKU ICS2000ms has the time to process the command before it receives a new one.

youridijk commented 1 year ago

I’m aware of this issue and created a sort of solution for this in #16. To control multiple accessories at the same time, you need to create a scene in the KlikAanKlikUit app. After that, the scene appears in HomeKit as a on/off switch. I was thinking of adding a queue with a delay to fix the problem, but didn’t work it out yet.