From cdc911bb9cf62a61d138c6ebe3bf8cc715908aa7 Mon Sep 17 00:00:00 2001 From: phiwan-dev <75113544+phiwan-dev@users.noreply.github.com> Date: Sat, 19 Jul 2025 22:34:15 +0200 Subject: [PATCH] dev: add zmk docker tutorial to readme --- README.md | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/README.md b/README.md index 72d2bda..8df81c8 100644 --- a/README.md +++ b/README.md @@ -57,6 +57,35 @@ Lastly, you can replace the point array in [`footprints/phi-caps`](./footprints/ - 2 oled 0.91 inch i2c (optional) - 2 batteries 3.7v (optional, requres cable otherwise) +# Firmware +## Using ZMK locally using docker +For now, this is the tutorial to get the goosekb to work. +```bash +cd +docker volume create --driver local -o o=bind -o type=none -o device="/config/" zmk-config # enter absolute path +git clone https://github.com/zmkfirmware/zmk.git firmware/zmk +nix shell nixpkgs#devcontainer # or install devcontainer otherwise +devcontainer up --workspace-folder firmware/zmk +docker ps -a # get zmk container name +docker exec -it /bin/bash +# now from within container +cd /workspaces/zmk +west init -l app/ +west update +# actually build the firmware +cd app +rm -rf build/ +west build -p -d build/left -b seeeduino_xiao_ble -- -DSHIELD=goose_left -DZMK_CONFIG="/workspaces/zmk-config" +west build -p -d build/right -b seeeduino_xiao_ble -- -DSHIELD=goose_right -DZMK_CONFIG="/workspaces/zmk-config" +cp build/left/zephyr/zmk.uf2 build/left.uf2 +cp build/right/zephyr/zmk.uf2 build/right.uf2 +# connect mcu with pc +# double press the reset button +# the file explorer should now show a usb media +# copy the corresponding .uf2 firmware to the usb media +# it should now auto-eject and run the new firmware +``` + # Thanks - to https://github.com/MvEerd/ergogen/tree/mveerd for ergogen - to https://flatfootfox.com/ergogen-introduction/ for teaching ergogen