keyboardio / Chrysalis-Firmware-Bundle

Firmware sketches for boards supported by Chrysalis
GNU General Public License v2.0
32 stars 25 forks source link

Model01 & Model100: Turn the LEDs off when going to sleep #31

Closed algernon closed 1 year ago

algernon commented 1 year ago

We were turning the LEDs off when the host suspended, but not when it went to sleep. Thus, the LEDs remained on in that case unless the hosts' sleep procedure involved going into suspend first.

Lets turn the LEDs explicitly off on sleep.

algernon commented 1 year ago

FWIW, this shouldn't be necessary, @tlyu told me on Discord that suspend is the transition event, so the suspend branch should fire when going to sleep too. But at least one customer reported that it didn't, and adding the code to the sleep branch made things work.

It doesn't really hurt us to do it both times, as far as I can tell, so we can err on the safe side.