Nix flake to build the customized QMK firmware of my keyboard, a Anne Pro 2 (C18).
- C 62.6%
- Nix 31%
- Shell 6.3%
- Makefile 0.1%
| geoffreyfrogeye | ||
| .gitignore | ||
| flake.lock | ||
| flake.nix | ||
| keyboard.nix | ||
| README.md | ||
| run.sh | ||
| shine.nix | ||
| tools.nix | ||
Keyboard
Nix flake to build the customized QMK firmware of my keyboard, a Anne Pro 2 (C18).
(Yes, https://github.com/qmk/qmk_userspace is a thing but adding the flasher + shine firmware + nix goodness would be annoying)
Development
Best to do qmk clone and prepare environment as the packages do here.
Improvements
- Somewhat reproducible building
- Use macros to replicate more of vim outside of vim
- Can control mouse with it
Issues & attempted fixes
- LED turns on when plugging in only sometimes without possibility of reflashing (but always after flashing)
- Upgraded to 2025 version
- Tried reducing baud rate
- Fixed other issues
- Add a reboot button (doesn't seem to do anyting)
- Fix reboot button (now it works, and fixes the issues sometimes...)
- Can't set default animation (or manual mode?), either from post_init() or buttons
- Tried running post_init() on demand (e.g. on Caps Lock)
- Tried not setting masks on boot
- LED color updates visibly propagates
- Tried using manual mode and setting by row (get overriden by animation since can't enable manual mode)
- Setting by rows using mask
- Sometimes it goes into a glitch state where it only types \
- Figure out which pattern sequence triggers that
- Upgraded to 2025 version (fixed it, it seems!)
- LSHIFT + RSHIFT + B doesn't set it in IAP mode (anymore?)
- Find where it used to be in the code (didn't find anything)
- Reimplement it myself
- Enable commands
- Make bluetooth work https://github.com/qmk/qmk_firmware/issues/18547
- Upgrade to 2026 version
- Flash https://releases.obins.net/annepro2c18/firmware/1.14.1-alpha/ap2_c18_22_ble.bin
- Reduce baud rate to 57600 https://github.com/qmk/qmk_firmware/issues/18547#issuecomment-2608852087
- Forget on both side, then re-pair, and connect twice
Other
In case ever needed (though flasher can even do BLE so why would you), obinskit is super slow to download, I have it backed up.
It can be run with:
nix-store --add-fixed sha256 ObinsKit_1.2.11_x64.tar.gz
NIXPKGS_ALLOW_UNFREE=1 NIXPKGS_ALLOW_INSECURE=1 nix run --impure nixpkgs/nixos-23.11#obinskit