python-limitlessled
python-limitlessled copied to clipboard
priority/configurable repetitions
Hey,
I've partly implemented a way to a) configure the command repetitions and b) prioritize commands.
The idea behind this is to allow for faster switching times (especially when switching multiple bulbs at once): You could then set "reps" to 1 and add every command to be issued three times (with different priorities). This way the module tries to first switch all the bulbs correctly and then repeats all the commands in case a bulb didn't respond.
I am not yet completely sure if this does interfere with the "synchronization"? I haven't really implemented it completely - so please take it as a suggestions - how would you implement this features?
Hm, I like where this idea is going. I need to look closer at the commit, but consider these repetition possibilities:
- Some commands must not repeat (white bulb temp/brightness)
- Some commands must always repeat (on/off)
- Some commands change repetitions based on context (see
ratedecorator): For example, transition brightness reps is1while regular brightness is3. This is because a transition can afford to skip one step in order to go faster (that is, fit more commands into the allotted time for a smoother transition). This is why groups look at their ownrepsmember instead of the bridge'sreps. - Some commands actually require two (anything with
select=true): when no group is specified in the requested command (example:color) and the previous group was different.
Ah, i see. I think i haven't really thought this through completely. I'll try to have a more detailed look at some time