How to add sleep and power keys?


I would like to add Sleep and Power keys. They seem to be missing from chrysalis.
So, I have looked into updating the firmware from the Arduino IDE, but it seems that the instructions to do so are not up to date for model 100. I can compile the model 100 example, but I get errors when trying to “upload” : “dfu-util: No DFU capable USB device available”.

There two workarounds at the moment:

  • Sketch | Export compiled Binary from the IDE, then in Chrysalis, Firmware Update | Custom firmware (you should find the binary in the same folder as your sketch)


  • Unplug the keyboard and hold Prog while it boots to get into Programmable mode. This will let you use upload, but may make the EEPROM do unusual things unless you use a script to back it up & restore it.

Option 1 is a bit tedious, but works.

1 Like

Another option might be to change those keys to ones you can set in Chrysalis. You can set them to any key in Linux, so I just changed Sleep to a combo that was free.

You can get the System_Sleep and System_PowerDown keys (terms used in Kaleidoscope) by entering the following values as a Custom Keycode (at the bottom of the right-hand panel) in Chrysalis:

  • System_Sleep: 16770
  • System_PowerDown: 16769


  • Consumer_Sleep: 18482
  • Consumer_Power: 18480

Thanks a lot for all these answers !

1/ Exporting the binary and flashing it from chrysalis makes sense.
2/ Ok, let’s avoid this one if it messes with the EEPROM.
3/ Changing the combo in the system settings would work, but I would rather have something standard to be portable. And I also use Windows sometimes.

4/ Wow, I have been looking for those codes for a few hours, even in the source code of Chrysalis. I will try them tonight ! Edit: It works !

Most Consumer Control and System Control keys are not called out in Chrysalis, but can be found in Kaleidoscope’s source code. The easiest way to be certain to get those “custom keycodes” correct is to define them in a Kaleidoscope sketch’s keymap, and look at the values in Chrysalis.