Dynamic hotkey dashboard, using off-the-shelf parts
NOTE: This is a work in progress!
- 1 Γ Adafruit Feather
I used a Feather RP2040 for its USB-C and speedy chip, but any which support CircuitPython and STEMMA QT ought to work - 1 Γ USB Cable
The exact type depends on your computer and your choice of Feather; I already had a USB-C to USB-C 2.0 cable! - 1 Γ Adafruit 2.9" Grayscale eInk Display FeatherWing
- 2 Γ Adafruit NeoKey 1x4 QT
- 8 Γ Cherry MX-compatible Key Switches
The Kalih models Adafruit sell work just fine for this - 8 Γ Cherry MX-compatible Keycaps
Mine is using these windowed ones but any will do. Bear in mind there are RGB LEDs under them! - 3 Γ STEMMA QT Cables
I wound up with three 100mm cables but I would suggest getting two 100mm and one 50mm cable instead! - 1 Γ Adafruit QT Rotary Encoder Breakout with NeoPixel
Important to note that this doesn't come with a rotary encoder, you'll need to get that separately! - 1 Γ Rotary Encoder
At this time, I do not have a design for an enclosure for this - I built mine into a recycled cardboard box!
Some fairly easy soldering is required for this build;
- Solder headers to the Feather's pins.
The Feather itself may not come with enough, but the rest of the components should supply enough if you don't already have some. You'll want the header pins' long end to be on the opposite side of the board to the USB port, connectors and other components. - Solder the rotary encoder to the rotary encoder breakout.
You can read Adafruit's instructions for this. - Solder the
A0
address jumper on one of the NeoKey boards
Adafruit describe the pins in these instructions.
Once the soldering is done, the remainder of the assembly is very easy.
- Plug the Feather, with headers attached, into the socket on the underside of the eInk Display Featherwing
- Use the STEMMA QT Cables to connect the Feather, two NeoKey 1x4 QTs and Rotary Encoder Breakout via their STEMMA QT connectors.
The order in which they are connected does not matter, but in my assembly I connected the Rotary Encoder Breakout directly to the Feather, and the two NeoKey 1x4 QTs followed after that. - Connect the Feather to your comptuer with your USB cable
And then it's time to move on to software!
Because the Feather range generally ship with it, the software for this is written in CircuitPython!
You may need to update to the latest CircuitPython - instructions vary somewhat by Feather board, but here's the guide for the Feather RP2040.
You will also need to install these libraries from the Adafruit CircuitPython Library Bundle;
adafruit_bitmap_font/
adafruit_display_shapes/
adafruit_display_text/
adafruit_displayio_layout/
adafruit_hid/
adafruit_il0373.mpy
adafruit_itertools/
adafruit_neokey/
adafruit_seesaw/
NOTE: If you are on macOS, copying these in Finder may result in them taking up more than the total storage available on your Feather due to Finder metadata - you may need to run find /Volumes/CIRCUITPY -name '._*' -exec rm {} \;
to remove that excess metadata.
The dashboard can optionally use any bdf
format bitmap font. Some good options include Galmuri and the modified Chicago from danfe/fonts.
Place your preferred font in a fonts
folder on the CIRCUITPY
drive, and update default.json
with its file name.
If your font fails to load for any reason, it will fall back to the built-in font.
Finally, copy code.py
and default.json
to the CIRCUITPY
drive. If everyhing went to plan, LEDs under each key should light up as it gets things set up, and it should then show a series of labels on the eInk screen.
The key mapping and labels are controlled by the default.json
file.
Each input can have a label
which is displayed on the screen, and either a consumer_control_code
, keycode
or write
value.
The first two will send the corresponding input as defined in adafruit_hid.consumer_control_code.ConsumerControlCode
or adafruit_hid.keycode.Keycode
respectively.
write
accepts an ASCII string and will type that string as a series of keystrokes when the input is used.