This repo is for me to compile QMK firmware for my Keychron Q2 keyboard.
Huge thanks to QMK-on-K6 for outlining this process!
My Q2 keymap is at keyboards/keychron/q2/keymaps/ansi-josh/keymap.c
.
It is a copy of the keychron/q2/ansi_encoder:keychron
files.
See the releases page for tagged builds.
- Map the Esc key to `~.
- Map Caps Lock to Esc.
- Map Fn1+Caps Lock to Caps Lock for the rare moments I want to YELL.
- Map Del (immediately under the knob) to Home to match the keycaps I have.
- Map Home to Page Up to match my keycaps.
- On Mac:
- Turning the knob with no modifiers adjusts volume.
- Holding Ctrl and turning the knob clockwise sends Ctrl+Mouse Wheel Up. Counter-clockwise sends Ctrl+Mouse Wheel Down. This zooms in and out on macOS (with an Accessibility setting enabled).
- Holding Fn1 and turning the knob adjusts brightness on a second display.
- Holding Fn2 and turning the knob adjusts brightness on the primary display.
- Holding Fn1 and pressing the knob maxes out the brightness on a secondary display (by sending 16x brightness up calls).
Make changes to keymap.c
and then commit/push them to GitHub. If a build
passes, the compiled firmware will be uploaded as a build artifact. It can be
downloaded from the view build page on GitHub. These uploads will be deleted
eventually, so do not rely on being able to download them forever.
When the firmware reaches a good saving point, uploading a git tag will trigger a build and upload the compiled firmware as a release asset. These files stay on GitHub for the life of the project.
To see how to do this Linux, see
.github/workflows/build.yml
.
- Install QMK Toolbox and launch it.
- Unplug the Q2. Hold Esc and Ctrl and plug the
keyboard in. If you see "DFU device connected" in QMK Toolbox, move on to
step 3.
- If you do not, you need to manually put the keyboard in DFU mode. Follow these steps but stop short of uploading any firmware (since you're about to upload your own). Unplug it again. Remove the spacebar. Press and hold the small button that is visible in the left opening on the case. Plug the keyboard in again.
- Click "Open" and upload the
.bin
file that GitHub Actions generated. - Click the "Flash" button.