mirror of
https://github.com/qmk/qmk_firmware.git
synced 2025-09-10 17:15:43 +00:00
Compare commits
229 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a9dcfac7b6 | ||
|
|
e3534cd705 | ||
|
|
0188038bc0 | ||
|
|
2a4b9f79fd | ||
|
|
b43ec9d65a | ||
|
|
df8bb7ce24 | ||
|
|
7110708d0f | ||
|
|
b834819a35 | ||
|
|
cc696a2ae8 | ||
|
|
f29d8117bf | ||
|
|
d2ec940da5 | ||
|
|
da2c6a41d8 | ||
|
|
ed62464c06 | ||
|
|
3a1f3e440c | ||
|
|
7947cd57a7 | ||
|
|
9e0321dfb4 | ||
|
|
57f61c209c | ||
|
|
d5193cf45b | ||
|
|
a3ecbc53f6 | ||
|
|
2695344241 | ||
|
|
00ca362826 | ||
|
|
9dcf2a11b2 | ||
|
|
12dc6d1ac8 | ||
|
|
843fdba1d4 | ||
|
|
b0ca90520e | ||
|
|
a8cdb0c59b | ||
|
|
5e2ea31187 | ||
|
|
4c09a9fe15 | ||
|
|
1650dccef0 | ||
|
|
c05ffd8777 | ||
|
|
4633459329 | ||
|
|
5de15af41f | ||
|
|
00d3627d9d | ||
|
|
75115250a6 | ||
|
|
cabda8be67 | ||
|
|
d425385664 | ||
|
|
6c2e58eb4d | ||
|
|
1a58fce043 | ||
|
|
24492d4058 | ||
|
|
7af4ead24a | ||
|
|
a369a10ded | ||
|
|
b9991cb6b8 | ||
|
|
48846aaa93 | ||
|
|
4d869011af | ||
|
|
a77acc04a0 | ||
|
|
445c12e552 | ||
|
|
0a41dd5b8d | ||
|
|
96ee4c21a3 | ||
|
|
ae07dee941 | ||
|
|
efce9bc9b5 | ||
|
|
d575bf7ddc | ||
|
|
7a939ec218 | ||
|
|
542440eac5 | ||
|
|
717b6b8f13 | ||
|
|
36c3f4deba | ||
|
|
a954b568ea | ||
|
|
74d64c7f43 | ||
|
|
65cce9105d | ||
|
|
43853b337b | ||
|
|
8474aee2fe | ||
|
|
7098252252 | ||
|
|
16ffaa6482 | ||
|
|
865c29f4de | ||
|
|
507c948ed8 | ||
|
|
f0b04b2a3a | ||
|
|
20555f9a33 | ||
|
|
56ad3a5f43 | ||
|
|
5ef94415aa | ||
|
|
d67e94fb1b | ||
|
|
f797d4f49d | ||
|
|
ad4233d078 | ||
|
|
2c34b480fc | ||
|
|
86badb394e | ||
|
|
e295937e54 | ||
|
|
c7a24a441f | ||
|
|
a08ee4a737 | ||
|
|
9e757bc2ec | ||
|
|
5ef7919022 | ||
|
|
6b38dc17cd | ||
|
|
71b88b333d | ||
|
|
108a2fceca | ||
|
|
c3773d9c35 | ||
|
|
e1b42d5252 | ||
|
|
558fee16e4 | ||
|
|
87e5df1b9e | ||
|
|
4b295009ae | ||
|
|
3d61139567 | ||
|
|
15e7c8f37a | ||
|
|
8d29bd07c2 | ||
|
|
75b899d87d | ||
|
|
c3b3f09702 | ||
|
|
56650d7a2b | ||
|
|
8a47896263 | ||
|
|
0f182ef674 | ||
|
|
f1b2449ce5 | ||
|
|
a26dbbfe96 | ||
|
|
bf28a303c6 | ||
|
|
e814bb9453 | ||
|
|
2916c3f098 | ||
|
|
8644965c81 | ||
|
|
0524a6d848 | ||
|
|
e19991ec46 | ||
|
|
e4e5bca6bc | ||
|
|
8ff7b1de11 | ||
|
|
7827f9fbe3 | ||
|
|
d9f2d8d241 | ||
|
|
058919923a | ||
|
|
d151b1bef5 | ||
|
|
baf0060761 | ||
|
|
036745e853 | ||
|
|
b99e2f7230 | ||
|
|
9c965bb62e | ||
|
|
e68389a11e | ||
|
|
ba63bac661 | ||
|
|
0842f54a27 | ||
|
|
584ad807cc | ||
|
|
e92f1fb220 | ||
|
|
67c97da654 | ||
|
|
0b33318a24 | ||
|
|
a9a2b699cd | ||
|
|
49a4ec538d | ||
|
|
711b109246 | ||
|
|
6347d18a2d | ||
|
|
d7b09ad560 | ||
|
|
52e2af7753 | ||
|
|
fef7932e55 | ||
|
|
48a421bb10 | ||
|
|
f09f3643ad | ||
|
|
5b0039aae6 | ||
|
|
18f5a04eaa | ||
|
|
3db5ffcfb7 | ||
|
|
0dee127b29 | ||
|
|
21ca1eb7ae | ||
|
|
a1a5869ef8 | ||
|
|
bc5c5e3251 | ||
|
|
f39e08e2ba | ||
|
|
eeac23464b | ||
|
|
35785a6c49 | ||
|
|
ea5ef746e2 | ||
|
|
8c8f4b3c06 | ||
|
|
55e1acec07 | ||
|
|
584e390703 | ||
|
|
2c152c3425 | ||
|
|
d28377237f | ||
|
|
8a06238054 | ||
|
|
25d7ac9ecc | ||
|
|
2c8b8ef713 | ||
|
|
681d6a29e6 | ||
|
|
d044a6bcc2 | ||
|
|
091eac1fce | ||
|
|
02bed7e5a5 | ||
|
|
7919848324 | ||
|
|
a4436b32df | ||
|
|
0f9c1c57b4 | ||
|
|
e725cdbc4b | ||
|
|
9ef5dcd113 | ||
|
|
ef6e9a5312 | ||
|
|
5bdeb7dad1 | ||
|
|
8347a6688f | ||
|
|
3ce196ff52 | ||
|
|
0326355edc | ||
|
|
94f1aade5c | ||
|
|
fe54121cfa | ||
|
|
77b2742863 | ||
|
|
021c3cc125 | ||
|
|
0b3a54f9f2 | ||
|
|
7808f8f56b | ||
|
|
e3c8c23d91 | ||
|
|
b4cabc3cf7 | ||
|
|
e8e3c7addb | ||
|
|
608ce78778 | ||
|
|
977433443a | ||
|
|
44ec55032e | ||
|
|
d4cb53e264 | ||
|
|
70ce814790 | ||
|
|
4d7764f7f6 | ||
|
|
5bf8248dd3 | ||
|
|
7b36727ed1 | ||
|
|
f096e5a3f3 | ||
|
|
53c6fa5de7 | ||
|
|
97168180cf | ||
|
|
57374489da | ||
|
|
1d145c7511 | ||
|
|
820202cd53 | ||
|
|
4c773971a7 | ||
|
|
9e8e9af485 | ||
|
|
4f60946513 | ||
|
|
ac9318c78f | ||
|
|
76cf8dff93 | ||
|
|
558cce683f | ||
|
|
cb46402a5f | ||
|
|
5920274d70 | ||
|
|
90ed47945f | ||
|
|
6d481f176d | ||
|
|
ef67e89836 | ||
|
|
92bc5ec044 | ||
|
|
c80de06b66 | ||
|
|
454767e758 | ||
|
|
176aa1f7db | ||
|
|
e52491a71f | ||
|
|
758ae5d584 | ||
|
|
65c3c0bf6a | ||
|
|
77366af7ec | ||
|
|
b998dcfd0e | ||
|
|
decf39592e | ||
|
|
de8d66b6fd | ||
|
|
a171b36eaf | ||
|
|
36c2db8629 | ||
|
|
c57add534e | ||
|
|
7c7a9e0e34 | ||
|
|
fa1e51dd19 | ||
|
|
0d38d2adcf | ||
|
|
d10d637762 | ||
|
|
1fb6323a0d | ||
|
|
10faf16edf | ||
|
|
a8d4e89e41 | ||
|
|
9b201d362c | ||
|
|
1e80179941 | ||
|
|
0d18136fdb | ||
|
|
73b0a6d37c | ||
|
|
99bf22a50e | ||
|
|
1921a4808f | ||
|
|
4ef00cd6e8 | ||
|
|
fa170a7c15 | ||
|
|
6c92b08d8f | ||
|
|
ad8c332b59 | ||
|
|
99f2b767be | ||
|
|
ddd0f54c94 | ||
|
|
cb4043ec4c |
232
.github/workflows/bootstrap_testing.yml
vendored
Normal file
232
.github/workflows/bootstrap_testing.yml
vendored
Normal file
@@ -0,0 +1,232 @@
|
||||
name: Bootstrap Script Testing
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [bootstrap]
|
||||
paths:
|
||||
- "util/env-bootstrap.sh"
|
||||
- ".github/workflows/bootstrap_testing.yml"
|
||||
pull_request:
|
||||
branches: [master, develop, xap]
|
||||
paths:
|
||||
- "util/env-bootstrap.sh"
|
||||
- ".github/workflows/bootstrap_testing.yml"
|
||||
workflow_dispatch:
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
jobs:
|
||||
bootstrap-test-linux:
|
||||
name: Bootstrap (Linux)
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
distribution:
|
||||
# Ubuntu/Debian based
|
||||
- debian:11
|
||||
- debian:12
|
||||
- ubuntu:20.04
|
||||
- ubuntu:22.04
|
||||
- ubuntu:24.04
|
||||
|
||||
# RHEL/CentOS/Fedora based
|
||||
- fedora:40
|
||||
- fedora:41
|
||||
- fedora:42
|
||||
- rockylinux:8
|
||||
- rockylinux:9
|
||||
- rockylinux/rockylinux:10
|
||||
- almalinux:8
|
||||
- almalinux:9
|
||||
- almalinux:10
|
||||
|
||||
# OpenSUSE based (we skip Tumbleweed as it has issues with package versions between pattern installs and other dependencies preinstalled into the base container)
|
||||
- opensuse/leap:latest
|
||||
|
||||
# Arch based
|
||||
- archlinux:latest
|
||||
- cachyos/cachyos:latest
|
||||
- manjarolinux/base:latest
|
||||
|
||||
container:
|
||||
image: ${{ matrix.distribution }}
|
||||
options: --privileged
|
||||
|
||||
steps:
|
||||
- name: Install base dependencies
|
||||
run: |
|
||||
case "${{ matrix.distribution }}" in
|
||||
*ubuntu*|*debian*)
|
||||
apt-get update
|
||||
apt-get install -y sudo git passwd
|
||||
;;
|
||||
*fedora*|*rockylinux*|*almalinux*)
|
||||
dnf install -y sudo git passwd findutils # findutils=xargs
|
||||
;;
|
||||
*suse*)
|
||||
zypper --non-interactive refresh
|
||||
zypper --non-interactive install sudo git shadow findutils # findutils=xargs
|
||||
;;
|
||||
*archlinux*|*cachyos*|*manjaro*)
|
||||
pacman -Syu --noconfirm
|
||||
pacman -S --noconfirm sudo git
|
||||
;;
|
||||
esac
|
||||
|
||||
# Fix PAM configuration for sudo in containers
|
||||
# Fix /etc/shadow permissions - common issue in container environments
|
||||
chmod 640 /etc/shadow || chmod 400 /etc/shadow || true
|
||||
|
||||
# Disable problematic PAM modules that commonly fail in RHEL-like containers
|
||||
sed -i 's/^session.*pam_systemd.so/#&/' /etc/pam.d/sudo || true
|
||||
sed -i 's/^session.*pam_loginuid.so/#&/' /etc/pam.d/sudo || true
|
||||
|
||||
# Ensure proper sudoers configuration
|
||||
echo "Defaults !requiretty" >> /etc/sudoers
|
||||
echo "Defaults secure_path=\"/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin\"" >> /etc/sudoers
|
||||
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 1
|
||||
submodules: recursive
|
||||
path: qmk_firmware
|
||||
|
||||
- name: Create test user
|
||||
run: |
|
||||
# Create a test user for the bootstrap script
|
||||
useradd -m -s /bin/bash -U testuser
|
||||
echo 'testuser:testpassword' | chpasswd
|
||||
|
||||
# Configure passwordless sudo
|
||||
echo "root ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers # some distros complain about root not being in sudoers
|
||||
echo "testuser ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers
|
||||
|
||||
# Test sudo functionality
|
||||
sudo -u testuser whoami || echo "Sudo test failed, but continuing..."
|
||||
|
||||
- name: Move QMK repository to test user home
|
||||
run: |
|
||||
# Add upstream remote to the cloned repository so `qmk doctor` doesn't flag a warning
|
||||
git -C qmk_firmware remote add upstream https://github.com/qmk/qmk_firmware.git
|
||||
# Move the QMK repository to the test user's home directory
|
||||
mv qmk_firmware /home/testuser/qmk_firmware
|
||||
chown -R testuser:testuser /home/testuser/qmk_firmware
|
||||
|
||||
- name: Run bootstrap script
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
run: |
|
||||
# Ensure the bootstrap script can access sudo
|
||||
sudo -u testuser --preserve-env=GITHUB_TOKEN bash -c "
|
||||
export CONFIRM=1
|
||||
export PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
|
||||
cd /home/testuser
|
||||
bash /home/testuser/qmk_firmware/util/env-bootstrap.sh
|
||||
"
|
||||
|
||||
- name: Test QMK CLI
|
||||
run: |
|
||||
sudo -u testuser bash -c "
|
||||
export PATH=/home/testuser/.local/bin:\$PATH
|
||||
cd /home/testuser
|
||||
qmk setup -y -H /home/testuser/qmk_firmware # setup implies doctor, no need to run it separately
|
||||
qmk mass-compile -j $(nproc) -e DUMP_CI_METADATA=yes -f 'keyboard_name==*onekey*' -km reset || touch .failed # Compile a bunch of different platforms
|
||||
"
|
||||
|
||||
cd /home/testuser/qmk_firmware
|
||||
./util/ci/generate_failure_markdown.sh > $GITHUB_STEP_SUMMARY || true
|
||||
[ ! -e .failed ] || exit 1
|
||||
|
||||
bootstrap-test-macos:
|
||||
name: Bootstrap (macOS)
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
os:
|
||||
- macos-13 # Intel x64
|
||||
- macos-14 # Apple Silicon ARM64
|
||||
- macos-15 # Apple Silicon ARM64
|
||||
|
||||
runs-on: ${{ matrix.os }}
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 1
|
||||
submodules: recursive
|
||||
|
||||
- name: Run bootstrap script
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
run: |
|
||||
# Add upstream remote to the cloned repository so `qmk doctor` doesn't flag a warning
|
||||
git remote add upstream https://github.com/qmk/qmk_firmware.git
|
||||
# Run the bootstrap script
|
||||
export CONFIRM=1
|
||||
sh ./util/env-bootstrap.sh
|
||||
|
||||
- name: Test QMK CLI
|
||||
run: |
|
||||
# Add QMK CLI to PATH (bootstrap script installs it to ~/.local/bin on macOS)
|
||||
export PATH="$HOME/.local/bin:$PATH"
|
||||
qmk setup -y -H . # setup implies doctor, no need to run it separately
|
||||
qmk mass-compile -j $(sysctl -n hw.ncpu) -e DUMP_CI_METADATA=yes -f 'keyboard_name==*onekey*' -km reset || touch .failed # Compile a bunch of different platforms
|
||||
|
||||
./util/ci/generate_failure_markdown.sh > $GITHUB_STEP_SUMMARY || true
|
||||
[ ! -e .failed ] || exit 1
|
||||
|
||||
bootstrap-test-windows:
|
||||
name: Bootstrap (Windows)
|
||||
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
msys-variant:
|
||||
- mingw64
|
||||
- clang64
|
||||
- ucrt64
|
||||
|
||||
runs-on: windows-latest
|
||||
defaults:
|
||||
run:
|
||||
shell: msys2 {0}
|
||||
|
||||
steps:
|
||||
- name: Install MSYS2
|
||||
uses: msys2/setup-msys2@v2
|
||||
with:
|
||||
msystem: ${{ matrix.msys-variant }}
|
||||
pacboy: >-
|
||||
git:
|
||||
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 1
|
||||
submodules: recursive
|
||||
|
||||
- name: Run bootstrap script
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
run: |
|
||||
# Add upstream remote to the cloned repository so `qmk doctor` doesn't flag a warning
|
||||
git remote add upstream https://github.com/qmk/qmk_firmware.git
|
||||
# Run the bootstrap script
|
||||
export CONFIRM=1
|
||||
sh ./util/env-bootstrap.sh
|
||||
|
||||
- name: Test QMK CLI
|
||||
run: |
|
||||
# Add QMK CLI to PATH (bootstrap script installs it to /opt/uv/tools/bin on Windows MSYS2)
|
||||
export PATH="/opt/uv/tools/bin:$PATH"
|
||||
qmk setup -y -H . # setup implies doctor, no need to run it separately
|
||||
qmk mass-compile -j $(nproc) -e DUMP_CI_METADATA=yes -f 'keyboard_name==*onekey*' -km reset || touch .failed # Compile a bunch of different platforms
|
||||
|
||||
./util/ci/generate_failure_markdown.sh > $GITHUB_STEP_SUMMARY || true
|
||||
[ ! -e .failed ] || exit 1
|
||||
|
||||
2
.github/workflows/ci_build_major_branch.yml
vendored
2
.github/workflows/ci_build_major_branch.yml
vendored
@@ -88,7 +88,7 @@ jobs:
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Download firmwares
|
||||
uses: actions/download-artifact@v4
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
pattern: firmware-*
|
||||
path: .
|
||||
|
||||
@@ -92,7 +92,7 @@ jobs:
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Get target definitions
|
||||
uses: actions/download-artifact@v4
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
name: targets-${{ inputs.keymap }}
|
||||
path: .
|
||||
@@ -139,7 +139,7 @@ jobs:
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Download firmwares
|
||||
uses: actions/download-artifact@v4
|
||||
uses: actions/download-artifact@v5
|
||||
with:
|
||||
pattern: firmware-${{ inputs.keymap }}-*
|
||||
path: .
|
||||
|
||||
1
.gitignore
vendored
1
.gitignore
vendored
@@ -64,6 +64,7 @@ build/
|
||||
cmake-build-debug
|
||||
CMakeLists.txt
|
||||
*.pdf
|
||||
*.zip
|
||||
|
||||
# Let these ones be user specific, since we have so many different configurations
|
||||
*.code-workspace
|
||||
|
||||
8
Makefile
8
Makefile
@@ -115,7 +115,7 @@ endef
|
||||
TRY_TO_MATCH_RULE_FROM_LIST = $(eval $(call TRY_TO_MATCH_RULE_FROM_LIST_HELPER,$1))$(RULE_FOUND)
|
||||
|
||||
# As TRY_TO_MATCH_RULE_FROM_LIST_HELPER, but with additional
|
||||
# resolution of DEFAULT_FOLDER and keyboard_aliases.hjson for provided rule
|
||||
# resolution of keyboard_aliases.hjson for provided rule
|
||||
define TRY_TO_MATCH_RULE_FROM_LIST_HELPER_KB
|
||||
# Split on ":", padding with empty strings to avoid indexing issues
|
||||
TOKEN1:=$$(shell python3 -c "import sys; print((sys.argv[1].split(':',1)+[''])[0])" $$(RULE))
|
||||
@@ -255,7 +255,7 @@ endef
|
||||
# if we are going to compile all keyboards, match the rest of the rule
|
||||
# for each of them
|
||||
define PARSE_ALL_KEYBOARDS
|
||||
$$(eval $$(call PARSE_ALL_IN_LIST,PARSE_KEYBOARD,$(shell $(QMK_BIN) list-keyboards --no-resolve-defaults)))
|
||||
$$(eval $$(call PARSE_ALL_IN_LIST,PARSE_KEYBOARD,$(shell $(QMK_BIN) list-keyboards)))
|
||||
endef
|
||||
|
||||
# Prints a list of all known keymaps for the given keyboard
|
||||
@@ -447,7 +447,7 @@ git-submodules: git-submodule
|
||||
|
||||
.PHONY: list-keyboards
|
||||
list-keyboards:
|
||||
$(QMK_BIN) list-keyboards --no-resolve-defaults | tr '\n' ' '
|
||||
$(QMK_BIN) list-keyboards | tr '\n' ' '
|
||||
|
||||
.PHONY: list-tests
|
||||
list-tests:
|
||||
@@ -455,7 +455,7 @@ list-tests:
|
||||
|
||||
.PHONY: generate-keyboards-file
|
||||
generate-keyboards-file:
|
||||
$(QMK_BIN) list-keyboards --no-resolve-defaults
|
||||
$(QMK_BIN) list-keyboards
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
|
||||
@@ -62,6 +62,7 @@ include $(BUILDDEFS_PATH)/common_features.mk
|
||||
include $(BUILDDEFS_PATH)/generic_features.mk
|
||||
include $(PLATFORM_PATH)/common.mk
|
||||
include $(TMK_PATH)/protocol.mk
|
||||
include $(QUANTUM_PATH)/battery/tests/rules.mk
|
||||
include $(QUANTUM_PATH)/debounce/tests/rules.mk
|
||||
include $(QUANTUM_PATH)/encoder/tests/rules.mk
|
||||
include $(QUANTUM_PATH)/os_detection/tests/rules.mk
|
||||
|
||||
@@ -29,6 +29,8 @@ QUANTUM_SRC += \
|
||||
$(QUANTUM_DIR)/logging/debug.c \
|
||||
$(QUANTUM_DIR)/logging/sendchar.c \
|
||||
$(QUANTUM_DIR)/process_keycode/process_default_layer.c \
|
||||
$(QUANTUM_DIR)/process_keycode/process_oneshot.c \
|
||||
$(QUANTUM_DIR)/process_keycode/process_quantum.c \
|
||||
|
||||
include $(QUANTUM_DIR)/nvm/rules.mk
|
||||
|
||||
@@ -633,6 +635,9 @@ ifeq ($(strip $(VIA_ENABLE)), yes)
|
||||
RAW_ENABLE := yes
|
||||
BOOTMAGIC_ENABLE := yes
|
||||
TRI_LAYER_ENABLE := yes
|
||||
ifeq ($(strip $(VIA_INSECURE)), yes)
|
||||
OPT_DEFS += -DVIA_INSECURE
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(strip $(RAW_ENABLE)), yes)
|
||||
@@ -940,21 +945,25 @@ ifeq ($(strip $(DIP_SWITCH_ENABLE)), yes)
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(strip $(BATTERY_ENABLE)), yes)
|
||||
BATTERY_DRIVER_REQUIRED := yes
|
||||
endif
|
||||
|
||||
VALID_BATTERY_DRIVER_TYPES := adc custom vendor
|
||||
|
||||
BATTERY_DRIVER ?= adc
|
||||
BATTERY_DRIVER ?= none
|
||||
ifeq ($(strip $(BATTERY_DRIVER_REQUIRED)), yes)
|
||||
ifeq ($(filter $(BATTERY_DRIVER),$(VALID_BATTERY_DRIVER_TYPES)),)
|
||||
$(call CATASTROPHIC_ERROR,Invalid BATTERY_DRIVER,BATTERY_DRIVER="$(BATTERY_DRIVER)" is not a valid battery driver)
|
||||
endif
|
||||
|
||||
OPT_DEFS += -DBATTERY_DRIVER
|
||||
OPT_DEFS += -DBATTERY_$(strip $(shell echo $(BATTERY_DRIVER) | tr '[:lower:]' '[:upper:]'))
|
||||
OPT_DEFS += -DBATTERY_DRIVER_$(strip $(shell echo $(BATTERY_DRIVER) | tr '[:lower:]' '[:upper:]'))
|
||||
|
||||
COMMON_VPATH += $(DRIVER_PATH)/battery
|
||||
|
||||
SRC += battery.c
|
||||
SRC += battery_$(strip $(BATTERY_DRIVER)).c
|
||||
ifneq ($(strip $(BATTERY_DRIVER)), custom)
|
||||
SRC += battery_$(strip $(BATTERY_DRIVER)).c
|
||||
endif
|
||||
|
||||
# add extra deps
|
||||
ifeq ($(strip $(BATTERY_DRIVER)), adc)
|
||||
|
||||
@@ -1,8 +1,3 @@
|
||||
ifneq (,$(filter $(MCU),atmega32u4))
|
||||
# TODO: opt in rather than assume everything uses a pro micro
|
||||
PIN_COMPATIBLE ?= promicro
|
||||
endif
|
||||
|
||||
# Remove whitespace from any rule.mk provided vars
|
||||
# - env cannot be overwritten but cannot have whitespace anyway
|
||||
CONVERT_TO:=$(strip $(CONVERT_TO))
|
||||
|
||||
@@ -21,6 +21,7 @@ SPACE_CADET_ENABLE ?= yes
|
||||
GENERIC_FEATURES = \
|
||||
AUTO_SHIFT \
|
||||
AUTOCORRECT \
|
||||
BATTERY \
|
||||
BOOTMAGIC \
|
||||
CAPS_WORD \
|
||||
COMBO \
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
TEST_LIST = $(sort $(patsubst %/test.mk,%, $(shell find $(ROOT_DIR)tests -type f -name test.mk)))
|
||||
FULL_TESTS := $(notdir $(TEST_LIST))
|
||||
|
||||
include $(QUANTUM_PATH)/battery/tests/testlist.mk
|
||||
include $(QUANTUM_PATH)/debounce/tests/testlist.mk
|
||||
include $(QUANTUM_PATH)/encoder/tests/testlist.mk
|
||||
include $(QUANTUM_PATH)/os_detection/tests/testlist.mk
|
||||
|
||||
@@ -43,6 +43,14 @@
|
||||
"BOOTMAGIC_ROW": {"info_key": "bootmagic.matrix.0", "value_type": "int"},
|
||||
"BOOTMAGIC_ROW_RIGHT": {"info_key": "split.bootmagic.matrix.0", "value_type": "int"},
|
||||
|
||||
// Battery
|
||||
"BATTERY_SAMPLE_INTERVAL": {"info_key": "battery.sample_interval", "value_type": "int"},
|
||||
"BATTERY_ADC_PIN": {"info_key": "battery.adc.pin"},
|
||||
"BATTERY_ADC_REF_VOLTAGE_MV": {"info_key": "battery.adc.reference_voltage", "value_type": "int"},
|
||||
"BATTERY_ADC_VOLTAGE_DIVIDER_R1": {"info_key": "battery.adc.divider_r1", "value_type": "int"},
|
||||
"BATTERY_ADC_VOLTAGE_DIVIDER_R2": {"info_key": "battery.adc.divider_r2", "value_type": "int"},
|
||||
"BATTERY_ADC_RESOLUTION": {"info_key": "battery.adc.resolution", "value_type": "int"},
|
||||
|
||||
// Caps Word
|
||||
"BOTH_SHIFTS_TURNS_ON_CAPS_WORD": {"info_key": "caps_word.both_shifts_turns_on", "value_type": "flag"},
|
||||
"CAPS_WORD_IDLE_TIMEOUT": {"info_key": "caps_word.idle_timeout", "value_type": "int"},
|
||||
@@ -120,6 +128,7 @@
|
||||
"MATRIX_HAS_GHOST": {"info_key": "matrix_pins.ghost", "value_type": "flag"},
|
||||
"MATRIX_INPUT_PRESSED_STATE": {"info_key": "matrix_pins.input_pressed_state", "value_type": "int"},
|
||||
"MATRIX_IO_DELAY": {"info_key": "matrix_pins.io_delay", "value_type": "int"},
|
||||
"MATRIX_MASKED": {"info_key": "matrix_pins.masked", "value_type": "flag"},
|
||||
|
||||
// Mouse Keys
|
||||
"MOUSEKEY_DELAY": {"info_key": "mousekey.delay", "value_type": "int"},
|
||||
@@ -183,7 +192,7 @@
|
||||
|
||||
// Split Keyboard
|
||||
"SOFT_SERIAL_PIN": {"info_key": "split.serial.pin"},
|
||||
"SOFT_SERIAL_SPEED": {"info_key": "split.soft_serial_speed"},
|
||||
"SELECT_SOFT_SERIAL_SPEED": {"info_key": "split.serial.speed"},
|
||||
"SPLIT_HAND_MATRIX_GRID": {"info_key": "split.handedness.matrix_grid", "value_type": "array", "to_c": false},
|
||||
"SPLIT_HAND_PIN": {"info_key": "split.handedness.pin"},
|
||||
"SPLIT_USB_DETECT": {"info_key": "split.usb_detect.enabled", "value_type": "flag"},
|
||||
|
||||
@@ -13,6 +13,7 @@
|
||||
|
||||
"AUDIO_DRIVER": {"info_key": "audio.driver"},
|
||||
"BACKLIGHT_DRIVER": {"info_key": "backlight.driver"},
|
||||
"BATTERY_DRIVER": {"info_key": "battery.driver"},
|
||||
"BLUETOOTH_DRIVER": {"info_key": "bluetooth.driver"},
|
||||
"BOARD": {"info_key": "board"},
|
||||
"BOOTLOADER": {"info_key": "bootloader", "warn_duplicate": false},
|
||||
@@ -53,8 +54,8 @@
|
||||
"WS2812_DRIVER": {"info_key": "ws2812.driver"},
|
||||
|
||||
// Items we want flagged in lint
|
||||
"DEFAULT_FOLDER": {"info_key": "_deprecated.default_folder", "deprecated": true},
|
||||
"CTPC": {"info_key": "_invalid.ctpc", "invalid": true, "replace_with": "CONVERT_TO=proton_c"},
|
||||
"CONVERT_TO_PROTON_C": {"info_key": "_invalid.ctpc", "invalid": true, "replace_with": "CONVERT_TO=proton_c"},
|
||||
"DEFAULT_FOLDER": {"info_key": "_invalid.default_folder", "invalid": true},
|
||||
"VIAL_ENABLE": {"info_key": "_invalid.vial", "invalid": true}
|
||||
}
|
||||
|
||||
@@ -68,6 +68,81 @@
|
||||
"bakeneko80": {
|
||||
"target": "kkatano/bakeneko80"
|
||||
},
|
||||
"bastardkb/charybdis/3x5/v2/elitec": {
|
||||
"target": "bastardkb/charybdis/3x5/elitec"
|
||||
},
|
||||
"bastardkb/charybdis/3x5/v2/splinky_2": {
|
||||
"target": "bastardkb/charybdis/3x5/elitec"
|
||||
},
|
||||
"bastardkb/charybdis/3x5/v2/splinky_3": {
|
||||
"target": "bastardkb/charybdis/3x5/elitec"
|
||||
},
|
||||
"bastardkb/charybdis/3x5/v2/stemcell": {
|
||||
"target": "bastardkb/charybdis/3x5/elitec"
|
||||
},
|
||||
"bastardkb/charybdis/3x6/v2/elitec": {
|
||||
"target": "bastardkb/charybdis/3x6/elitec"
|
||||
},
|
||||
"bastardkb/charybdis/3x6/v2/splinky_2": {
|
||||
"target": "bastardkb/charybdis/3x6/elitec"
|
||||
},
|
||||
"bastardkb/charybdis/3x6/v2/splinky_3": {
|
||||
"target": "bastardkb/charybdis/3x6/elitec"
|
||||
},
|
||||
"bastardkb/charybdis/3x6/v2/stemcell": {
|
||||
"target": "bastardkb/charybdis/3x6/elitec"
|
||||
},
|
||||
"bastardkb/charybdis/4x6/v2/elitec": {
|
||||
"target": "bastardkb/charybdis/4x6/elitec"
|
||||
},
|
||||
"bastardkb/charybdis/4x6/v2/splinky_2": {
|
||||
"target": "bastardkb/charybdis/4x6/elitec"
|
||||
},
|
||||
"bastardkb/charybdis/4x6/v2/splinky_3": {
|
||||
"target": "bastardkb/charybdis/4x6/elitec"
|
||||
},
|
||||
"bastardkb/charybdis/4x6/v2/stemcell": {
|
||||
"target": "bastardkb/charybdis/4x6/elitec"
|
||||
},
|
||||
"bastardkb/dilemma/3x5_2/splinky": {
|
||||
"target": "bastardkb/dilemma/3x5_2/promicro"
|
||||
},
|
||||
"bastardkb/scylla/v2/elitec": {
|
||||
"target": "bastardkb/scylla/promicro"
|
||||
},
|
||||
"bastardkb/scylla/v2/splinky_2": {
|
||||
"target": "bastardkb/scylla/promicro"
|
||||
},
|
||||
"bastardkb/scylla/v2/splinky_3": {
|
||||
"target": "bastardkb/scylla/promicro"
|
||||
},
|
||||
"bastardkb/scylla/v2/stemcell": {
|
||||
"target": "bastardkb/scylla/promicro"
|
||||
},
|
||||
"bastardkb/skeletyl/v2/elitec": {
|
||||
"target": "bastardkb/skeletyl/promicro"
|
||||
},
|
||||
"bastardkb/skeletyl/v2/splinky_2": {
|
||||
"target": "bastardkb/skeletyl/promicro"
|
||||
},
|
||||
"bastardkb/skeletyl/v2/splinky_3": {
|
||||
"target": "bastardkb/skeletyl/promicro"
|
||||
},
|
||||
"bastardkb/skeletyl/v2/stemcell": {
|
||||
"target": "bastardkb/skeletyl/promicro"
|
||||
},
|
||||
"bastardkb/tbkmini/v2/elitec": {
|
||||
"target": "bastardkb/tbkmini/promicro"
|
||||
},
|
||||
"bastardkb/tbkmini/v2/splinky_2": {
|
||||
"target": "bastardkb/tbkmini/promicro"
|
||||
},
|
||||
"bastardkb/tbkmini/v2/splinky_3": {
|
||||
"target": "bastardkb/tbkmini/promicro"
|
||||
},
|
||||
"bastardkb/tbkmini/v2/stemcell": {
|
||||
"target": "bastardkb/tbkmini/promicro"
|
||||
},
|
||||
"bear_face": {
|
||||
"target": "bear_face/v1"
|
||||
},
|
||||
@@ -257,44 +332,11 @@
|
||||
"handwired/jscotto/scottostarter": {
|
||||
"target": "handwired/scottokeebs/scottostarter"
|
||||
},
|
||||
"helix/pico/sc/back": {
|
||||
"target": "helix/pico/sc"
|
||||
"helix": {
|
||||
"target": "helix/beta"
|
||||
},
|
||||
"helix/pico/sc/under": {
|
||||
"target": "helix/pico/sc"
|
||||
},
|
||||
"helix/rev2/back/oled": {
|
||||
"target": "helix/rev2/back"
|
||||
},
|
||||
"helix/rev2/oled": {
|
||||
"target": "helix/rev2"
|
||||
},
|
||||
"helix/rev2/oled/back": {
|
||||
"target": "helix/rev2/back"
|
||||
},
|
||||
"helix/rev2/oled/under": {
|
||||
"target": "helix/rev2/under"
|
||||
},
|
||||
"helix/rev2/sc/back": {
|
||||
"target": "helix/rev2/sc"
|
||||
},
|
||||
"helix/rev2/sc/oled": {
|
||||
"target": "helix/rev2/sc"
|
||||
},
|
||||
"helix/rev2/sc/oledback": {
|
||||
"target": "helix/rev2/sc"
|
||||
},
|
||||
"helix/rev2/sc/oledunder": {
|
||||
"target": "helix/rev2/sc"
|
||||
},
|
||||
"helix/rev2/sc/under": {
|
||||
"target": "helix/rev2/sc"
|
||||
},
|
||||
"helix/rev2/under": {
|
||||
"target": "helix/rev2/sc"
|
||||
},
|
||||
"helix/rev2/under/oled": {
|
||||
"target": "helix/rev2/under"
|
||||
"helix/rev2": {
|
||||
"target": "helix/beta"
|
||||
},
|
||||
"honeycomb": {
|
||||
"target": "keyhive/honeycomb"
|
||||
@@ -407,6 +449,9 @@
|
||||
"lfkeyboards/smk65": {
|
||||
"target": "lfkeyboards/smk65/revb"
|
||||
},
|
||||
"ll3macorn/bongopad": {
|
||||
"target": "ll3ma/bongopad"
|
||||
},
|
||||
"m3v3van": {
|
||||
"target": "matthewdias/m3n3van"
|
||||
},
|
||||
@@ -1881,6 +1926,12 @@
|
||||
"kin80": {
|
||||
"target": "kin80/blackpill401"
|
||||
},
|
||||
"kprepublic/cstc40/daughterboard": {
|
||||
"target": "kprepublic/cstc40/rev1"
|
||||
},
|
||||
"kprepublic/cstc40/single_pcb": {
|
||||
"target": "kprepublic/cstc40/rev2"
|
||||
},
|
||||
"kumaokobo/kudox_full": {
|
||||
"target": "kumaokobo/kudox_full/rev1"
|
||||
},
|
||||
@@ -2214,8 +2265,17 @@
|
||||
"trnthsn/s6xty5neor2": {
|
||||
"target": "trnthsn/s6xty5neor2/stm32f103"
|
||||
},
|
||||
"tweetydabird/lotus58": {
|
||||
"target": "tweetydabird/lotus58/promicro"
|
||||
"tweetydabird/lotus58/elite_c": {
|
||||
"target": "tweetydabird/lotus58"
|
||||
},
|
||||
"tweetydabird/lotus58/nanoboot": {
|
||||
"target": "tweetydabird/lotus58"
|
||||
},
|
||||
"tweetydabird/lotus58/promicro": {
|
||||
"target": "tweetydabird/lotus58"
|
||||
},
|
||||
"tweetydabird/lotus58/rp2040_ce": {
|
||||
"target": "tweetydabird/lotus58"
|
||||
},
|
||||
"unison": {
|
||||
"target": "unison/v04"
|
||||
@@ -2258,5 +2318,54 @@
|
||||
},
|
||||
"zsa/planck_ez": {
|
||||
"target": "zsa/planck_ez/base"
|
||||
},
|
||||
// DEFAULT_FOLDER removed during 2025 Q3 cycle
|
||||
"cannonkeys/satisfaction75": {
|
||||
"target": "cannonkeys/satisfaction75/rev1"
|
||||
},
|
||||
"converter/adb_usb": {
|
||||
"target": "converter/adb_usb/rev1"
|
||||
},
|
||||
"converter/sun_usb": {
|
||||
"target": "converter/sun_usb/type5"
|
||||
},
|
||||
"converter/usb_usb": {
|
||||
"target": "converter/usb_usb/hasu"
|
||||
},
|
||||
"durgod/dgk6x": {
|
||||
"target": "durgod/dgk6x/hades_ansi"
|
||||
},
|
||||
"ergodox_ez": {
|
||||
"target": "ergodox_ez/base"
|
||||
},
|
||||
"ferris/0_2": {
|
||||
"target": "ferris/0_2/base"
|
||||
},
|
||||
"handwired/dygma/raise": {
|
||||
"target": "handwired/dygma/raise/ansi"
|
||||
},
|
||||
"helix/rev3_4rows": {
|
||||
"target": "helix/rev3"
|
||||
},
|
||||
"helix/rev3_5rows": {
|
||||
"target": "helix/rev3"
|
||||
},
|
||||
"ibm/model_m/mschwingen": {
|
||||
"target": "ibm/model_m/mschwingen/led_wired"
|
||||
},
|
||||
"mechwild/sugarglider": {
|
||||
"target": "mechwild/sugarglider/wide_oled/f401"
|
||||
},
|
||||
"mechwild/sugarglider/wide_oled": {
|
||||
"target": "mechwild/sugarglider/wide_oled/f401"
|
||||
},
|
||||
"novelkeys/nk65": {
|
||||
"target": "novelkeys/nk65/v1"
|
||||
},
|
||||
"novelkeys/nk65/base": {
|
||||
"target": "novelkeys/nk65/v1"
|
||||
},
|
||||
"sirius/uni660/rev2": {
|
||||
"target": "sirius/uni660/rev2/ansi"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -188,6 +188,28 @@
|
||||
"as_caps_lock": {"type": "boolean"}
|
||||
}
|
||||
},
|
||||
"battery": {
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"driver": {
|
||||
"type": "string",
|
||||
"enum": ["adc", "custom", "vendor"]
|
||||
},
|
||||
"adc": {
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"pin": {"$ref": "./definitions.jsonschema#/mcu_pin"},
|
||||
"reference_voltage": {"type": "integer"},
|
||||
"divider_r1": {"type": "integer"},
|
||||
"divider_r2": {"type": "integer"},
|
||||
"resolution": {"type": "integer"}
|
||||
}
|
||||
},
|
||||
"sample_interval": {"type": "integer"}
|
||||
}
|
||||
},
|
||||
"bluetooth": {
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
@@ -473,6 +495,7 @@
|
||||
"ghost": {"type": "boolean"},
|
||||
"input_pressed_state": {"$ref": "./definitions.jsonschema#/unsigned_int"},
|
||||
"io_delay": {"$ref": "./definitions.jsonschema#/unsigned_int"},
|
||||
"masked": {"type": "boolean"},
|
||||
"direct": {
|
||||
"type": "array",
|
||||
"items": {"$ref": "./definitions.jsonschema#/mcu_pin_array"}
|
||||
@@ -863,8 +886,7 @@
|
||||
},
|
||||
"soft_serial_speed": {
|
||||
"type": "integer",
|
||||
"minimum": 0,
|
||||
"maximum": 5
|
||||
"$comment": "Deprecated: use split.serial.speed instead"
|
||||
},
|
||||
"serial": {
|
||||
"type": "object",
|
||||
@@ -874,7 +896,12 @@
|
||||
"type": "string",
|
||||
"enum": ["bitbang", "usart", "vendor"]
|
||||
},
|
||||
"pin": {"$ref": "./definitions.jsonschema#/mcu_pin"}
|
||||
"pin": {"$ref": "./definitions.jsonschema#/mcu_pin"},
|
||||
"speed": {
|
||||
"type": "integer",
|
||||
"minimum": 0,
|
||||
"maximum": 5
|
||||
}
|
||||
}
|
||||
},
|
||||
"transport": {
|
||||
|
||||
181
docs/ChangeLog/20250831.md
Normal file
181
docs/ChangeLog/20250831.md
Normal file
@@ -0,0 +1,181 @@
|
||||
# QMK Breaking Changes - 2025 Aug 31 Changelog
|
||||
|
||||
## Changes Requiring User Action
|
||||
|
||||
### Updated Keyboard Codebases
|
||||
|
||||
| Old Keyboard Name | New Keyboard Name |
|
||||
|--------------------------------------|----------------------------------|
|
||||
| bastardkb/charybdis/3x5/v2/elitec | bastardkb/charybdis/3x5/elitec |
|
||||
| bastardkb/charybdis/3x5/v2/splinky_2 | bastardkb/charybdis/3x5/elitec |
|
||||
| bastardkb/charybdis/3x5/v2/splinky_3 | bastardkb/charybdis/3x5/elitec |
|
||||
| bastardkb/charybdis/3x5/v2/stemcell | bastardkb/charybdis/3x5/elitec |
|
||||
| bastardkb/charybdis/3x6/v2/elitec | bastardkb/charybdis/3x6/elitec |
|
||||
| bastardkb/charybdis/3x6/v2/splinky_2 | bastardkb/charybdis/3x6/elitec |
|
||||
| bastardkb/charybdis/3x6/v2/splinky_3 | bastardkb/charybdis/3x6/elitec |
|
||||
| bastardkb/charybdis/3x6/v2/stemcell | bastardkb/charybdis/3x6/elitec |
|
||||
| bastardkb/charybdis/4x6/v2/elitec | bastardkb/charybdis/4x6/elitec |
|
||||
| bastardkb/charybdis/4x6/v2/splinky_2 | bastardkb/charybdis/4x6/elitec |
|
||||
| bastardkb/charybdis/4x6/v2/splinky_3 | bastardkb/charybdis/4x6/elitec |
|
||||
| bastardkb/charybdis/4x6/v2/stemcell | bastardkb/charybdis/4x6/elitec |
|
||||
| bastardkb/dilemma/3x5_2/splinky | bastardkb/dilemma/3x5_2/promicro |
|
||||
| bastardkb/scylla/v2/elitec | bastardkb/scylla/promicro |
|
||||
| bastardkb/scylla/v2/splinky_2 | bastardkb/scylla/promicro |
|
||||
| bastardkb/scylla/v2/splinky_3 | bastardkb/scylla/promicro |
|
||||
| bastardkb/scylla/v2/stemcell | bastardkb/scylla/promicro |
|
||||
| bastardkb/skeletyl/v2/elitec | bastardkb/skeletyl/promicro |
|
||||
| bastardkb/skeletyl/v2/splinky_2 | bastardkb/skeletyl/promicro |
|
||||
| bastardkb/skeletyl/v2/splinky_3 | bastardkb/skeletyl/promicro |
|
||||
| bastardkb/skeletyl/v2/stemcell | bastardkb/skeletyl/promicro |
|
||||
| bastardkb/tbkmini/v2/elitec | bastardkb/tbkmini/promicro |
|
||||
| bastardkb/tbkmini/v2/splinky_2 | bastardkb/tbkmini/promicro |
|
||||
| bastardkb/tbkmini/v2/splinky_3 | bastardkb/tbkmini/promicro |
|
||||
| bastardkb/tbkmini/v2/stemcell | bastardkb/tbkmini/promicro |
|
||||
| helix/rev2 | helix/beta |
|
||||
| helix/rev3_4rows | helix/rev3 |
|
||||
| helix/rev3_5rows | helix/rev3 |
|
||||
| kprepublic/cstc40/daughterboard | kprepublic/cstc40/rev1 |
|
||||
| kprepublic/cstc40/single_pcb | kprepublic/cstc40/rev2 |
|
||||
| ll3macorn/bongopad | ll3ma/bongopad |
|
||||
| novelkeys/nk65/base | novelkeys/nk65/v1 |
|
||||
| tweetydabird/lotus58/elite_c | tweetydabird/lotus58 |
|
||||
| tweetydabird/lotus58/nanoboot | tweetydabird/lotus58 |
|
||||
| tweetydabird/lotus58/promicro | tweetydabird/lotus58 |
|
||||
| tweetydabird/lotus58/rp2040_ce | tweetydabird/lotus58 |
|
||||
|
||||
### Mitigate VIA keylogger security issues [#25414](https://github.com/qmk/qmk_firmware/pull/25414)
|
||||
|
||||
VIA's keyboard matrix testing functionality, which allows users to identify active key presses, has been identified as a potential security concern by community members and security researchers. This feature has been demonstrated to enable unauthorized keystroke capture, with documented examples showing how malicious scripts could exploit this capability to create keyloggers. A recent security assessment revealed that user credentials could be compromised by exploiting the matrix testing function combined with VIA's keycode assignment queries. In this attack scenario, a script could remain active during a locked session and capture password input when users authenticate upon return.
|
||||
|
||||
The QMK team notified the VIA team of this security vulnerability on May 17, 2022, and made multiple subsequent attempts to coordinate a mitigation strategy. Despite repeated outreach, the VIA team has provided no acknowledgment or response to these security concerns. Given the severity of the potential security implications and the lack of engagement from the VIA team, the QMK team has unilaterally implemented a security enhancement that modifies the keyboard matrix testing functionality to prevent the reporting of key press events. This change prioritizes user security and data protection over potential feature compatibility concerns within VIA.
|
||||
|
||||
## Deprecation Notices
|
||||
|
||||
In line with the [notice period](../support_deprecation_policy#how-much-advance-notice-will-be-given), deprecation notices for larger items are listed here.
|
||||
|
||||
### `DEFAULT_FOLDER` removal ([#23281](https://github.com/qmk/qmk_firmware/pull/23281))
|
||||
|
||||
`DEFAULT_FOLDER` was originally introduced to work around limitations within the build system.
|
||||
Parent folders containing common configuration would create invalid build targets.
|
||||
|
||||
With the introduction of [`keyboard.json`](./20240526#keyboard-json) as a configuration file, the build system now has a consistent method to detect build targets.
|
||||
The `DEFAULT_FOLDER` functionality is now removed with the intent that `rules.mk` is now pure configuration.
|
||||
|
||||
Backwards compatibility of build targets has been maintained where possible.
|
||||
|
||||
### Converter `Pin Compatible` updates ([#20330](https://github.com/qmk/qmk_firmware/pull/20330))
|
||||
|
||||
Converter support has been further limited to only function if a keyboard declares that it is compatible.
|
||||
|
||||
This can be configured in the following ways:
|
||||
|
||||
:::::tabs
|
||||
|
||||
==== keyboard.json
|
||||
|
||||
```json [keyboard.json]
|
||||
{
|
||||
"development_board": "promicro", // [!code focus]
|
||||
}
|
||||
```
|
||||
|
||||
==== rules.mk
|
||||
|
||||
```make [rules.mk]
|
||||
PIN_COMPATIBLE = promicro
|
||||
```
|
||||
|
||||
:::::
|
||||
|
||||
see the [Converters Feature](../feature_converters) documentation for more information.
|
||||
|
||||
### Removal of deprecated RGB and Mouse keycodes ([#25444](https://github.com/qmk/qmk_firmware/pull/25444))
|
||||
|
||||
Backwards compatibility of deprecated RGB and Mouse keycodes has been removed.
|
||||
|
||||
See the following documentation for the list of currently supported keycodes:
|
||||
|
||||
* [RGB Lighting](../features/rgblight#keycodes)
|
||||
* [RGB Matrix](../features/rgb_matrix#keycodes)
|
||||
* [Mouse keys](../features/mouse_keys#mapping-mouse-actions)
|
||||
|
||||
## Full changelist
|
||||
|
||||
Core:
|
||||
* Remove converter assumption that everything is a promicro ([#20330](https://github.com/qmk/qmk_firmware/pull/20330))
|
||||
* Remove `DEFAULT_FOLDER` handling ([#23281](https://github.com/qmk/qmk_firmware/pull/23281))
|
||||
* Add core handling for pointing device failures. ([#25315](https://github.com/qmk/qmk_firmware/pull/25315))
|
||||
* Relocate remaining `process_record_quantum` keycodes ([#25328](https://github.com/qmk/qmk_firmware/pull/25328))
|
||||
* Remove `process_action_kb` callback ([#25331](https://github.com/qmk/qmk_firmware/pull/25331))
|
||||
* Add `{rgb|led}_matrix_get_mode_name()`. ([#25344](https://github.com/qmk/qmk_firmware/pull/25344))
|
||||
* Align sleep_led logic ([#25395](https://github.com/qmk/qmk_firmware/pull/25395))
|
||||
* Mitigate VIA keylogger security issues ([#25414](https://github.com/qmk/qmk_firmware/pull/25414))
|
||||
* Deprecate some nonstandard mod & mod-tap keycode aliases ([#25437](https://github.com/qmk/qmk_firmware/pull/25437))
|
||||
* Refactor Starlight Smooth matrix effect ([#25442](https://github.com/qmk/qmk_firmware/pull/25442))
|
||||
* Remove deprecated `RGB_` and Mouse keycodes ([#25444](https://github.com/qmk/qmk_firmware/pull/25444))
|
||||
* Configure SPI for `QMK_PM2040` board ([#25481](https://github.com/qmk/qmk_firmware/pull/25481))
|
||||
* Configure SPI for `STEMCELL` board ([#25486](https://github.com/qmk/qmk_firmware/pull/25486))
|
||||
* Configure SPI for `QMK_BLOK` board ([#25487](https://github.com/qmk/qmk_firmware/pull/25487))
|
||||
* Clamp reactive offset value ([#25489](https://github.com/qmk/qmk_firmware/pull/25489))
|
||||
* Relocate `AUDIO_INIT_DELAY` implementation ([#25491](https://github.com/qmk/qmk_firmware/pull/25491))
|
||||
* Add MATRIX_ROWS_PER_HAND definition ([#25513](https://github.com/qmk/qmk_firmware/pull/25513))
|
||||
* Refactor battery driver ([#25550](https://github.com/qmk/qmk_firmware/pull/25550))
|
||||
* Add cachyos as pattern when installing dependencies ([#25580](https://github.com/qmk/qmk_firmware/pull/25580))
|
||||
|
||||
CLI:
|
||||
* Add MATRIX_MASKED DD config ([#25383](https://github.com/qmk/qmk_firmware/pull/25383))
|
||||
* Ensure keyboard aliases do not point to themselves ([#25500](https://github.com/qmk/qmk_firmware/pull/25500))
|
||||
|
||||
Keyboards:
|
||||
* [Update] E8ghtyNeo caps indicator ([#25009](https://github.com/qmk/qmk_firmware/pull/25009))
|
||||
* Keychron C3 Pro `c3_pro.c` corrections ([#25049](https://github.com/qmk/qmk_firmware/pull/25049))
|
||||
* Update franky36 pid and vid ([#25160](https://github.com/qmk/qmk_firmware/pull/25160))
|
||||
* Added Encoder support for Soyuz ([#25279](https://github.com/qmk/qmk_firmware/pull/25279))
|
||||
* CSTC40 rev3 (FXTWINK) ([#25285](https://github.com/qmk/qmk_firmware/pull/25285))
|
||||
* Migrate remaining `DEFAULT_FOLDER` to keyboard aliases ([#25291](https://github.com/qmk/qmk_firmware/pull/25291))
|
||||
* Configure boards to use development_board - R ([#25316](https://github.com/qmk/qmk_firmware/pull/25316))
|
||||
* Configure boards to use development_board - P ([#25317](https://github.com/qmk/qmk_firmware/pull/25317))
|
||||
* Configure boards to use development_board - NO ([#25338](https://github.com/qmk/qmk_firmware/pull/25338))
|
||||
* Configure boards to use development_board - LM ([#25341](https://github.com/qmk/qmk_firmware/pull/25341))
|
||||
* maple_computing/launchpad - Remove broken `default_rgb` keymap ([#25342](https://github.com/qmk/qmk_firmware/pull/25342))
|
||||
* update winry25 VID and PID ([#25351](https://github.com/qmk/qmk_firmware/pull/25351))
|
||||
* Configure boards to use development_board - DE ([#25369](https://github.com/qmk/qmk_firmware/pull/25369))
|
||||
* Configure boards to use development_board - FGHIJ ([#25370](https://github.com/qmk/qmk_firmware/pull/25370))
|
||||
* refactor(mercutio): layouts & reformatting ([#25408](https://github.com/qmk/qmk_firmware/pull/25408))
|
||||
* Configure boards to use development_board - ABC ([#25417](https://github.com/qmk/qmk_firmware/pull/25417))
|
||||
* Configure boards to use development_board - K ([#25421](https://github.com/qmk/qmk_firmware/pull/25421))
|
||||
* Refactor `helix/pico` ([#25428](https://github.com/qmk/qmk_firmware/pull/25428))
|
||||
* Refactor `helix/rev2` ([#25429](https://github.com/qmk/qmk_firmware/pull/25429))
|
||||
* Refactor `helix/rev3_{4,5}rows` ([#25430](https://github.com/qmk/qmk_firmware/pull/25430))
|
||||
* Migrate `helix` common configuration ([#25433](https://github.com/qmk/qmk_firmware/pull/25433))
|
||||
* Refactor `bastardkb/tbkmini` ([#25438](https://github.com/qmk/qmk_firmware/pull/25438))
|
||||
* Convert `novelkeys/nk65` to use RGB Matrix ([#25450](https://github.com/qmk/qmk_firmware/pull/25450))
|
||||
* Convert moon to lite custom matrix ([#25452](https://github.com/qmk/qmk_firmware/pull/25452))
|
||||
* Refactor `bastardkb/skeletyl` ([#25456](https://github.com/qmk/qmk_firmware/pull/25456))
|
||||
* Refactor `bastardkb/scylla` ([#25459](https://github.com/qmk/qmk_firmware/pull/25459))
|
||||
* Refactor `bastardkb/dilemma/3x5_2` ([#25462](https://github.com/qmk/qmk_firmware/pull/25462))
|
||||
* Migrate `usb.force_nkro` to `host.default.nkro` ([#25468](https://github.com/qmk/qmk_firmware/pull/25468))
|
||||
* Give mouse report to pointing_device_task_user first in ploopyco devices ([#25475](https://github.com/qmk/qmk_firmware/pull/25475))
|
||||
* Refactor `bastardkb/charybdis/3x5` ([#25488](https://github.com/qmk/qmk_firmware/pull/25488))
|
||||
* Refactor `bastardkb/charybdis/3x6` ([#25493](https://github.com/qmk/qmk_firmware/pull/25493))
|
||||
* Refactor `bastardkb/charybdis/4x6` ([#25494](https://github.com/qmk/qmk_firmware/pull/25494))
|
||||
* Rebrand For Ll3ma Keyboards ([#25498](https://github.com/qmk/qmk_firmware/pull/25498))
|
||||
* Remove some encoder resolution that duplicate defaults ([#25517](https://github.com/qmk/qmk_firmware/pull/25517))
|
||||
* Remove overriding of `DF()` within keyboards ([#25541](https://github.com/qmk/qmk_firmware/pull/25541))
|
||||
* Refactor inland/kb83 ([#25542](https://github.com/qmk/qmk_firmware/pull/25542))
|
||||
* Refactor `tweetydabird/lotus58` ([#25547](https://github.com/qmk/qmk_firmware/pull/25547))
|
||||
* Swap spleeb to default GENERIC_PROMICRO_RP2040 board files ([#25564](https://github.com/qmk/qmk_firmware/pull/25564))
|
||||
|
||||
Keyboard fixes:
|
||||
* Fix `keebio/quefrency/rev1:default60` ([#25423](https://github.com/qmk/qmk_firmware/pull/25423))
|
||||
* Fixup `bastardkb/tbkmini` keymap's build target ([#25458](https://github.com/qmk/qmk_firmware/pull/25458))
|
||||
* Miscellaneous fixes for lint warnings ([#25469](https://github.com/qmk/qmk_firmware/pull/25469))
|
||||
* Fix pytest/has_community default keymap location ([#25471](https://github.com/qmk/qmk_firmware/pull/25471))
|
||||
* Fix serial speed DD configuration & migrate keyboards ([#25546](https://github.com/qmk/qmk_firmware/pull/25546))
|
||||
* Update rgb x coordinate of rightmost column ([#25556](https://github.com/qmk/qmk_firmware/pull/25556))
|
||||
|
||||
Bugs:
|
||||
* Fix buggy switch statement in quantum.c ([#25322](https://github.com/qmk/qmk_firmware/pull/25322))
|
||||
* Compilation fixes for `-fno-common` ([#25436](https://github.com/qmk/qmk_firmware/pull/25436))
|
||||
* Only userspace should be searched for keyboard aliases when locating keymaps ([#25477](https://github.com/qmk/qmk_firmware/pull/25477))
|
||||
* Allow `qmk flash <filename>` to flash AT32 boards ([#25497](https://github.com/qmk/qmk_firmware/pull/25497))
|
||||
@@ -21,8 +21,14 @@
|
||||
{ "text": "Debugging QMK", "link": "/faq_debug" },
|
||||
{ "text": "Keymap FAQ", "link": "/faq_keymap" },
|
||||
{ "text": "Squeezing Space from AVR", "link": "/squeezing_avr" },
|
||||
{ "text": "Glossary", "link": "/reference_glossary" },
|
||||
{ "text": "License Violations", "link": "/license_violations" }
|
||||
{ "text": "Glossary", "link": "/reference_glossary" }
|
||||
]
|
||||
},
|
||||
{
|
||||
"text": "Licensing",
|
||||
"items": [
|
||||
{ "text": "License Violations", "link": "/license_violations" },
|
||||
{ "text": "Proprietary Libraries", "link": "/proprietary_libs" }
|
||||
]
|
||||
},
|
||||
{
|
||||
@@ -169,6 +175,7 @@
|
||||
]
|
||||
},
|
||||
{ "text": "Audio", "link": "/features/audio" },
|
||||
{ "text": "Battery", "link": "/features/battery" },
|
||||
{ "text": "Bootmagic", "link": "/features/bootmagic" },
|
||||
{ "text": "Converters", "link": "/feature_converters" },
|
||||
{ "text": "Custom Matrix", "link": "/custom_matrix" },
|
||||
@@ -207,7 +214,7 @@
|
||||
{ "text": "My Pull Request Was Flagged", "link": "/breaking_changes_instructions" },
|
||||
{
|
||||
"text": "Most Recent ChangeLog",
|
||||
"link": "/ChangeLog/20250525"
|
||||
"link": "/ChangeLog/20250831"
|
||||
},
|
||||
{ "text": "Past Breaking Changes", "link": "/breaking_changes_history" },
|
||||
{ "text": "Deprecation Policy", "link": "/support_deprecation_policy" }
|
||||
|
||||
@@ -10,25 +10,25 @@ Practically, this means QMK merges the `develop` branch into the `master` branch
|
||||
|
||||
## What has been included in past Breaking Changes?
|
||||
|
||||
* [2025 Aug 31](ChangeLog/20250831)
|
||||
* [2025 May 25](ChangeLog/20250525)
|
||||
* [2025 Feb 23](ChangeLog/20250223)
|
||||
* [2024 Nov 24](ChangeLog/20241124)
|
||||
* [Older Breaking Changes](breaking_changes_history)
|
||||
|
||||
## When is the next Breaking Change?
|
||||
|
||||
The next Breaking Change is scheduled for Aug 31, 2025.
|
||||
The next Breaking Change is scheduled for November 30, 2025.
|
||||
|
||||
### Important Dates
|
||||
|
||||
* 2025 May 25 - `develop` is tagged with a new release version. Each push to `master` is subsequently merged to `develop` by GitHub actions.
|
||||
* 2025 Aug 3 - `develop` closed to new PRs.
|
||||
* 2025 Aug 3 - Call for testers.
|
||||
* 2025 Aug 17 - Last day for merges -- after this point `develop` is locked for testing and accepts only bugfixes
|
||||
* 2025 Aug 24 - `develop` is locked, only critical bugfix PRs merged.
|
||||
* 2025 Aug 29 - `master` is locked, no PRs merged.
|
||||
* 2025 Aug 31 - Merge `develop` to `master`.
|
||||
* 2025 Aug 31 - `master` is unlocked. PRs can be merged again.
|
||||
* 2025 Aug 31 - `develop` is tagged with a new release version. Each push to `master` is subsequently merged to `develop` by GitHub actions.
|
||||
* 2025 Nov 2 - `develop` closed to new PRs.
|
||||
* 2025 Nov 2 - Call for testers.
|
||||
* 2025 Nov 16 - Last day for merges -- after this point `develop` is locked for testing and accepts only bugfixes
|
||||
* 2025 Nov 23 - `develop` is locked, only critical bugfix PRs merged.
|
||||
* 2025 Nov 28 - `master` is locked, no PRs merged.
|
||||
* 2025 Nov 30 - Merge `develop` to `master`.
|
||||
* 2025 Nov 30 - `master` is unlocked. PRs can be merged again.
|
||||
|
||||
## What changes will be included?
|
||||
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
|
||||
This page links to all previous changelogs from the QMK Breaking Changes process.
|
||||
|
||||
* [2025 Aug 31](ChangeLog/20250831) - version 0.30.0
|
||||
* [2025 May 25](ChangeLog/20250525) - version 0.29.0
|
||||
* [2025 Feb 23](ChangeLog/20250223) - version 0.28.0
|
||||
* [2024 Nov 24](ChangeLog/20241124) - version 0.27.0
|
||||
|
||||
@@ -17,12 +17,12 @@ qmk compile [-c] <configuratorExport.json>
|
||||
**Usage for Keymaps**:
|
||||
|
||||
```
|
||||
qmk compile [-c] [-e <var>=<value>] [-j <num_jobs>] [--compiledb] -kb <keyboard_name> -km <keymap_name>
|
||||
qmk compile [-c] [-e <var>=<value>] [-j <num_jobs>] [--compiledb] -kb <keyboard> -km <keymap>
|
||||
```
|
||||
|
||||
**Usage in Keyboard Directory**:
|
||||
|
||||
Must be in keyboard directory with a default keymap, or in keymap directory for keyboard, or supply one with `--keymap <keymap_name>`
|
||||
Must be in keyboard directory with a default keymap, or in keymap directory for keyboard, or supply one with `--keymap <keymap>`
|
||||
```
|
||||
qmk compile
|
||||
```
|
||||
@@ -30,7 +30,7 @@ qmk compile
|
||||
**Usage for building all keyboards that support a specific keymap**:
|
||||
|
||||
```
|
||||
qmk compile -kb all -km <keymap_name>
|
||||
qmk compile -kb all -km <keymap>
|
||||
```
|
||||
|
||||
**Example**:
|
||||
@@ -62,7 +62,7 @@ $ qmk compile
|
||||
|
||||
Must be under `qmk_firmware/layouts/`, and in a keymap folder.
|
||||
```
|
||||
qmk compile -kb <keyboard_name>
|
||||
qmk compile -kb <keyboard>
|
||||
```
|
||||
|
||||
**Example**:
|
||||
@@ -77,11 +77,11 @@ $ qmk compile -kb dz60
|
||||
|
||||
It is possible to speed up compilation by adding the `-j`/`--parallel` flag.
|
||||
```
|
||||
qmk compile -j <num_jobs> -kb <keyboard_name>
|
||||
qmk compile -j <num_jobs> -kb <keyboard>
|
||||
```
|
||||
The `num_jobs` argument determines the maximum number of jobs that can be used. Setting it to zero will enable parallel compilation without limiting the maximum number of jobs.
|
||||
```
|
||||
qmk compile -j 0 -kb <keyboard_name>
|
||||
qmk compile -j 0 -kb <keyboard>
|
||||
```
|
||||
|
||||
**Compilation Database**:
|
||||
@@ -120,7 +120,7 @@ qmk flash [-bl <bootloader>] [-c] [-e <var>=<value>] [-j <num_jobs>] <configurat
|
||||
**Usage for Keymaps**:
|
||||
|
||||
```
|
||||
qmk flash -kb <keyboard_name> -km <keymap_name> [-bl <bootloader>] [-c] [-e <var>=<value>] [-j <num_jobs>]
|
||||
qmk flash -kb <keyboard> -km <keymap_name> [-bl <bootloader>] [-c] [-e <var>=<value>] [-j <num_jobs>]
|
||||
```
|
||||
|
||||
**Usage for pre-compiled firmwares**:
|
||||
|
||||
@@ -364,8 +364,6 @@ This is a [make](https://www.gnu.org/software/make/manual/make.html) file that i
|
||||
|
||||
## Build Options
|
||||
|
||||
* `DEFAULT_FOLDER`
|
||||
* Used to specify a default folder when a keyboard has more than one sub-folder.
|
||||
* `FIRMWARE_FORMAT`
|
||||
* Defines which format (bin, hex) is copied to the root `qmk_firmware` folder after building.
|
||||
* `SRC`
|
||||
|
||||
@@ -4,7 +4,7 @@ QMK presents itself to the host as a regular HID keyboard device, and as such re
|
||||
|
||||
There are two notable exceptions: the Caterina bootloader, usually seen on Pro Micros, and the HalfKay bootloader shipped with PJRC Teensys, appear as a serial port and a generic HID device respectively, and so do not require a driver.
|
||||
|
||||
We recommend the use of the [Zadig](https://zadig.akeo.ie/) utility. If you have set up the development environment with MSYS2, the `qmk_install.sh` script will have already installed the drivers for you.
|
||||
We recommend the use of the [Zadig](https://zadig.akeo.ie/) utility. If you have set up the development environment with MSYS2, the QMK CLI installation script will have already installed the drivers for you.
|
||||
|
||||
## Installation
|
||||
|
||||
|
||||
@@ -44,7 +44,7 @@ Depending on the ChibiOS board configuration, you may need to [enable and config
|
||||
|
||||
## LED Mapping {#led-mapping}
|
||||
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboardname>.c`:
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboard>.c`:
|
||||
|
||||
```c
|
||||
const aw20216s_led_t PROGMEM g_aw20216s_leds[AW20216S_LED_COUNT] = {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# Battery Driver
|
||||
|
||||
This driver provides support for sampling battery level.
|
||||
This driver provides support for directly sampling battery level.
|
||||
|
||||
## Usage
|
||||
|
||||
@@ -10,21 +10,17 @@ To use this driver, add the following to your `rules.mk`:
|
||||
BATTERY_DRIVER_REQUIRED = yes
|
||||
```
|
||||
|
||||
## Basic Configuration {#basic-configuration}
|
||||
|
||||
Add the following to your `config.h`:
|
||||
|
||||
|Define |Default |Description |
|
||||
|--------------------------|--------|--------------------------------------------------|
|
||||
|`BATTERY_SAMPLE_INTERVAL` |`30000` |The time between battery samples in milliseconds. |
|
||||
::::info Note
|
||||
This is already configured for you if you are using the [Battery](../features/battery) feature.
|
||||
::::
|
||||
|
||||
## Driver Configuration {#driver-configuration}
|
||||
|
||||
Driver selection can be configured in `rules.mk` as `BATTERY_DRIVER`. Valid values are `adc` (default), `vendor`, or `custom`. See below for information on individual drivers.
|
||||
Driver selection can be configured in `rules.mk` as `BATTERY_DRIVER`. Valid values are `adc`, `vendor`, or `custom`. See below for information on individual drivers.
|
||||
|
||||
### ADC Driver {#adc-driver}
|
||||
|
||||
This is the default battery driver. The default configuration assumes the battery is connected to a ADC capable pin through a voltage divider.
|
||||
The default configuration assumes the battery is connected to a ADC capable pin through a voltage divider.
|
||||
|
||||
```make
|
||||
BATTERY_DRIVER = adc
|
||||
@@ -32,42 +28,25 @@ BATTERY_DRIVER = adc
|
||||
|
||||
The following `#define`s apply only to the `adc` driver:
|
||||
|
||||
|Define |Default |Description |
|
||||
|-----------------------------|--------------|--------------------------------------------------------------|
|
||||
|`BATTERY_PIN` |*Not defined* |The GPIO pin connected to the voltage divider. |
|
||||
|`BATTERY_REF_VOLTAGE_MV` |`3300` |The ADC reverence voltage, in millivolts. |
|
||||
|`BATTERY_VOLTAGE_DIVIDER_R1` |`100` |The voltage divider resistance, in kOhm. Set to 0 to disable. |
|
||||
|`BATTERY_VOLTAGE_DIVIDER_R2` |`100` |The voltage divider resistance, in kOhm. Set to 0 to disable. |
|
||||
|`BATTERY_ADC_RESOLUTION` |`10` |The ADC resolution configured for the ADC Driver. |
|
||||
|Define |Default |Description |
|
||||
|---------------------------------|--------------|--------------------------------------------------------------|
|
||||
|`BATTERY_ADC_PIN` |*Not defined* |The GPIO pin connected to the voltage divider. |
|
||||
|`BATTERY_ADC_REF_VOLTAGE_MV` |`3300` |The ADC reverence voltage, in millivolts. |
|
||||
|`BATTERY_ADC_VOLTAGE_DIVIDER_R1` |`100` |The voltage divider resistance, in kOhm. Set to 0 to disable. |
|
||||
|`BATTERY_ADC_VOLTAGE_DIVIDER_R2` |`100` |The voltage divider resistance, in kOhm. Set to 0 to disable. |
|
||||
|`BATTERY_ADC_RESOLUTION` |`10` |The ADC resolution configured for the ADC Driver. |
|
||||
|
||||
## Functions
|
||||
### Custom Driver {#custom-driver}
|
||||
|
||||
### `uint8_t battery_get_percent(void)` {#api-battery-get-percent}
|
||||
A custom driver is expected to implement the following interface:
|
||||
|
||||
Sample battery level.
|
||||
```c
|
||||
void battery_driver_init(void) {
|
||||
// Perform any initialisation here
|
||||
}
|
||||
|
||||
#### Return Value {#api-battery-get-percent-return}
|
||||
|
||||
The battery percentage, in the range 0-100.
|
||||
|
||||
## Callbacks
|
||||
|
||||
### `void battery_percent_changed_user(uint8_t level)` {#api-battery-percent-changed-user}
|
||||
|
||||
User hook called when battery level changed.
|
||||
|
||||
### Arguments {#api-battery-percent-changed-user-arguments}
|
||||
|
||||
- `uint8_t level`
|
||||
The battery percentage, in the range 0-100.
|
||||
|
||||
---
|
||||
|
||||
### `void battery_percent_changed_kb(uint8_t level)` {#api-battery-percent-changed-kb}
|
||||
|
||||
Keyboard hook called when battery level changed.
|
||||
|
||||
### Arguments {#api-battery-percent-changed-kb-arguments}
|
||||
|
||||
- `uint8_t level`
|
||||
The battery percentage, in the range 0-100.
|
||||
uint8_t battery_driver_sample_percent(void) {
|
||||
// Read and return current state here
|
||||
return value;
|
||||
}
|
||||
```
|
||||
|
||||
@@ -37,7 +37,7 @@ Depending on the ChibiOS board configuration, you may need to [enable and config
|
||||
|
||||
## LED Mapping {#led-mapping}
|
||||
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboardname>.c`:
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboard>.c`:
|
||||
|
||||
```c
|
||||
const is31fl3218_led_t PROGMEM g_is31fl3218_leds[IS31FL3218_LED_COUNT] = {
|
||||
|
||||
@@ -50,7 +50,7 @@ Depending on the ChibiOS board configuration, you may need to [enable and config
|
||||
|
||||
## LED Mapping {#led-mapping}
|
||||
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboardname>.c`:
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboard>.c`:
|
||||
|
||||
```c
|
||||
const is31fl3236_led_t PROGMEM g_is31fl3236_leds[IS31FL3236_LED_COUNT] = {
|
||||
|
||||
@@ -120,7 +120,7 @@ Depending on the ChibiOS board configuration, you may need to [enable and config
|
||||
|
||||
## LED Mapping {#led-mapping}
|
||||
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboardname>.c`:
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboard>.c`:
|
||||
|
||||
```c
|
||||
const is31fl3729_led_t PROGMEM g_is31fl3729_leds[IS31FL3729_LED_COUNT] = {
|
||||
|
||||
@@ -61,7 +61,7 @@ Depending on the ChibiOS board configuration, you may need to [enable and config
|
||||
|
||||
## LED Mapping {#led-mapping}
|
||||
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboardname>.c`:
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboard>.c`:
|
||||
|
||||
```c
|
||||
const is31fl3731_led_t PROGMEM g_is31fl3731_leds[IS31FL3731_LED_COUNT] = {
|
||||
|
||||
@@ -145,7 +145,7 @@ Depending on the ChibiOS board configuration, you may need to [enable and config
|
||||
|
||||
## LED Mapping {#led-mapping}
|
||||
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboardname>.c`:
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboard>.c`:
|
||||
|
||||
```c
|
||||
const is31fl3733_led_t PROGMEM g_is31fl3733_leds[IS31FL3733_LED_COUNT] = {
|
||||
|
||||
@@ -129,7 +129,7 @@ Depending on the ChibiOS board configuration, you may need to [enable and config
|
||||
|
||||
## LED Mapping {#led-mapping}
|
||||
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboardname>.c`:
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboard>.c`:
|
||||
|
||||
```c
|
||||
const is31fl3736_led_t PROGMEM g_is31fl3736_leds[IS31FL3736_LED_COUNT] = {
|
||||
|
||||
@@ -117,7 +117,7 @@ Depending on the ChibiOS board configuration, you may need to [enable and config
|
||||
|
||||
## LED Mapping {#led-mapping}
|
||||
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboardname>.c`:
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboard>.c`:
|
||||
|
||||
```c
|
||||
const is31fl3737_led_t PROGMEM g_is31fl3737_leds[IS31FL3737_LED_COUNT] = {
|
||||
|
||||
@@ -117,7 +117,7 @@ Depending on the ChibiOS board configuration, you may need to [enable and config
|
||||
|
||||
## LED Mapping {#led-mapping}
|
||||
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboardname>.c`:
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboard>.c`:
|
||||
|
||||
```c
|
||||
const is31fl3741_led_t PROGMEM g_is31fl3741_leds[IS31FL3741_LED_COUNT] = {
|
||||
|
||||
@@ -117,7 +117,7 @@ Depending on the ChibiOS board configuration, you may need to [enable and config
|
||||
|
||||
## LED Mapping {#led-mapping}
|
||||
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboardname>.c`:
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboard>.c`:
|
||||
|
||||
```c
|
||||
const is31fl3742a_led_t PROGMEM g_is31fl3742a_leds[IS31FL3742A_LED_COUNT] = {
|
||||
|
||||
@@ -127,7 +127,7 @@ Depending on the ChibiOS board configuration, you may need to [enable and config
|
||||
|
||||
## LED Mapping {#led-mapping}
|
||||
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboardname>.c`:
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboard>.c`:
|
||||
|
||||
```c
|
||||
const is31fl3743a_led_t PROGMEM g_is31fl3743a_leds[IS31FL3743A_LED_COUNT] = {
|
||||
|
||||
@@ -127,7 +127,7 @@ Depending on the ChibiOS board configuration, you may need to [enable and config
|
||||
|
||||
## LED Mapping {#led-mapping}
|
||||
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboardname>.c`:
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboard>.c`:
|
||||
|
||||
```c
|
||||
const is31fl3745_led_t PROGMEM g_is31fl3745_leds[IS31FL3745_LED_COUNT] = {
|
||||
|
||||
@@ -132,7 +132,7 @@ Depending on the ChibiOS board configuration, you may need to [enable and config
|
||||
|
||||
## LED Mapping {#led-mapping}
|
||||
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboardname>.c`:
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboard>.c`:
|
||||
|
||||
```c
|
||||
const is31fl3746a_led_t PROGMEM g_is31fl3746a_leds[IS31FL3746A_LED_COUNT] = {
|
||||
|
||||
@@ -52,7 +52,7 @@ Depending on the ChibiOS board configuration, you may need to [enable and config
|
||||
|
||||
## LED Mapping {#led-mapping}
|
||||
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboardname>.c`:
|
||||
In order to use this driver, each output must be mapped to an LED index, by adding the following to your `<keyboard>.c`:
|
||||
|
||||
```c
|
||||
const snled27351_led_t PROGMEM g_snled27351_leds[SNLED27351_LED_COUNT] = {
|
||||
|
||||
@@ -144,18 +144,30 @@ The following defines apply only to ARM devices:
|
||||
|`WS2812_T1L`|`(WS2812_TIMING - WS2812_T1H)`|The length of a "1" bit's low phase in nanoseconds (bitbang and PIO drivers only)|
|
||||
|`WS2812_T0L`|`(WS2812_TIMING - WS2812_T0H)`|The length of a "0" bit's low phase in nanoseconds (bitbang and PIO drivers only)|
|
||||
|
||||
### Push-Pull and Open Drain {#push-pull-open-drain}
|
||||
### Logic Levels {#logic-levels}
|
||||
|
||||
By default, the GPIO used for data transmission is configured as a *push-pull* output, meaning the pin is effectively always driven either to VCC or to ground.
|
||||
WS2812 LEDs usually operate at 5V, but some microcontrollers, particularly ARM-based ones, run on 3.3V. This can pose an issue when driving the LED chain as the logic level voltage is lower than the power supply voltage, leading to unreliable data transmission. There are two main workarounds:
|
||||
|
||||
For situations where the logic level voltage is lower than the power supply voltage, however, this can pose an issue. The solution is to configure the pin for *open drain* mode instead, and use a pullup resistor between the DI pin and VCC. In this mode, the MCU can only pull the GPIO *low*, or leave it floating. The pullup resistor is then responsible for pulling the line high, when the MCU is not driving the GPIO.
|
||||
#### 1. Open Drain Circuit {#open-drain-circuit}
|
||||
|
||||
To configure the DI pin for open drain configuration, add the following to your `config.h`:
|
||||
By default, `WS2812_DI_PIN` is configured as a *push-pull* output, meaning the pin is effectively always driven either to VCC or to ground; however, it can be configured in *open drain* mode instead.
|
||||
|
||||
In this mode, the MCU will only pull the GPIO *low*, and leaves it floating otherwise. A pullup resistor (typically around 10kΩ) between DI and 5V is then responsible for pulling the line high when the MCU is not driving the GPIO.
|
||||
|
||||
To use the DI pin in open drain configuration, add the following to your `config.h`:
|
||||
|
||||
```c
|
||||
#define WS2812_EXTERNAL_PULLUP
|
||||
```
|
||||
|
||||
::: warning
|
||||
Because the GPIO is being pulled to 5V in this situation rather than VCC (3.3V), **it must be a 5V tolerant pin**. Consult your MCU's datasheet first – if there are no eligible pins, you must use a level shifter instead.
|
||||
:::
|
||||
|
||||
#### 2. Level Shifter {#level-shifter}
|
||||
|
||||
A level shifter IC, such as the SN74LV1T34, can be placed between the GPIO and the first LED's DI pin to convert the 3.3V logic to 5V. This requires no additional configuration in the firmware, nor a 5V tolerant GPIO, but may be more expensive and is generally less handwire-friendly.
|
||||
|
||||
### SPI Driver {#arm-spi-driver}
|
||||
|
||||
Depending on the ChibiOS board configuration, you may need to enable SPI at the keyboard level. For STM32, this would look like:
|
||||
|
||||
@@ -44,7 +44,7 @@ Pro Micro (Atmega32u4), make sure to include `CONFIG_USB_ACM=y`. Other devices m
|
||||
|
||||
Issues encountered when flashing keyboards on Windows are most often due to having the wrong drivers installed for the bootloader, or none at all.
|
||||
|
||||
Re-running the QMK installation script (`./util/qmk_install.sh` from the `qmk_firmware` directory in MSYS2 or WSL) or reinstalling the QMK Toolbox may fix the issue. Alternatively, you can download and run the [`qmk_driver_installer`](https://github.com/qmk/qmk_driver_installer) package manually.
|
||||
Re-running the QMK installation script (`curl -fsSL https://install.qmk.fm | sh`) or reinstalling the QMK Toolbox may fix the issue. Alternatively, you can download and run the [`qmk_driver_installer`](https://github.com/qmk/qmk_driver_installer) package manually.
|
||||
|
||||
If that doesn't work, then you may need to download and run Zadig. See [Bootloader Driver Installation with Zadig](driver_installation_zadig) for more detailed information.
|
||||
|
||||
|
||||
@@ -2,36 +2,36 @@
|
||||
|
||||
These allow you to combine a modifier with a keycode. When pressed, the keydown event for the modifier, then `kc` will be sent. On release, the keyup event for `kc`, then the modifier will be sent.
|
||||
|
||||
|Key |Aliases |Description |
|
||||
|----------|----------------------------------|-------------------------------------------------------------------------------|
|
||||
|`LCTL(kc)`|`C(kc)` |Hold Left Control and press `kc` |
|
||||
|`LSFT(kc)`|`S(kc)` |Hold Left Shift and press `kc` |
|
||||
|`LALT(kc)`|`A(kc)`, `LOPT(kc)` |Hold Left Alt and press `kc` |
|
||||
|`LGUI(kc)`|`G(kc)`, `LCMD(kc)`, `LWIN(kc)` |Hold Left GUI and press `kc` |
|
||||
|`LCS(kc)` | |Hold Left Control and Left Shift and press `kc` |
|
||||
|`LCA(kc)` | |Hold Left Control and Left Alt and press `kc` |
|
||||
|`LCG(kc)` | |Hold Left Control and Left GUI and press `kc` |
|
||||
|`LSA(kc)` | |Hold Left Shift and Left Alt and press `kc` |
|
||||
|`LSG(kc)` |`SGUI(kc)`, `SCMD(kc)`, `SWIN(kc)`|Hold Left Shift and Left GUI and press `kc` |
|
||||
|`LAG(kc)` | |Hold Left Alt and Left GUI and press `kc` |
|
||||
|`LCSG(kc)`| |Hold Left Control, Left Shift and Left GUI and press `kc` |
|
||||
|`LCAG(kc)`| |Hold Left Control, Left Alt and Left GUI and press `kc` |
|
||||
|`LSAG(kc)`| |Hold Left Shift, Left Alt and Left GUI and press `kc` |
|
||||
|`RCTL(kc)`| |Hold Right Control and press `kc` |
|
||||
|`RSFT(kc)`| |Hold Right Shift and press `kc` |
|
||||
|`RALT(kc)`|`ROPT(kc)`, `ALGR(kc)` |Hold Right Alt and press `kc` |
|
||||
|`RGUI(kc)`|`RCMD(kc)`, `RWIN(kc)` |Hold Right GUI and press `kc` |
|
||||
|`RCA(kc)` | |Hold Right Control and Right Alt and press `kc` |
|
||||
|`RCS(kc)` | |Hold Right Control and Right Shift and press `kc` |
|
||||
|`RCG(kc)` | |Hold Right Control and Right GUI and press `kc` |
|
||||
|`RSA(kc)` |`SAGR(kc)` |Hold Right Shift and Right Alt and press `kc` |
|
||||
|`RSG(kc)` | |Hold Right Shift and Right GUI and press `kc` |
|
||||
|`RAG(kc)` | |Hold Right Alt and Right GUI and press `kc` |
|
||||
|`RCSG(kc)`| |Hold Right Control, Right Shift and Right GUI and press `kc` |
|
||||
|`RCAG(kc)`| |Hold Right Control, Right Alt and Right GUI and press `kc` |
|
||||
|`RSAG(kc)`| |Hold Right Shift, Right Alt and Right GUI and press `kc` |
|
||||
|`MEH(kc)` | |Hold Left Control, Left Shift and Left Alt and press `kc` |
|
||||
|`HYPR(kc)`| |Hold Left Control, Left Shift, Left Alt and Left GUI and press `kc`<sup>1</sup>|
|
||||
|Key |Aliases |Description |
|
||||
|----------|-------------------------------|-------------------------------------------------------------------------------|
|
||||
|`LCTL(kc)`|`C(kc)` |Hold Left Control and press `kc` |
|
||||
|`LSFT(kc)`|`S(kc)` |Hold Left Shift and press `kc` |
|
||||
|`LALT(kc)`|`A(kc)`, `LOPT(kc)` |Hold Left Alt and press `kc` |
|
||||
|`LGUI(kc)`|`G(kc)`, `LCMD(kc)`, `LWIN(kc)`|Hold Left GUI and press `kc` |
|
||||
|`LCS(kc)` | |Hold Left Control and Left Shift and press `kc` |
|
||||
|`LCA(kc)` | |Hold Left Control and Left Alt and press `kc` |
|
||||
|`LCG(kc)` | |Hold Left Control and Left GUI and press `kc` |
|
||||
|`LSA(kc)` | |Hold Left Shift and Left Alt and press `kc` |
|
||||
|`LSG(kc)` | |Hold Left Shift and Left GUI and press `kc` |
|
||||
|`LAG(kc)` | |Hold Left Alt and Left GUI and press `kc` |
|
||||
|`LCSG(kc)`| |Hold Left Control, Left Shift and Left GUI and press `kc` |
|
||||
|`LCAG(kc)`| |Hold Left Control, Left Alt and Left GUI and press `kc` |
|
||||
|`LSAG(kc)`| |Hold Left Shift, Left Alt and Left GUI and press `kc` |
|
||||
|`RCTL(kc)`| |Hold Right Control and press `kc` |
|
||||
|`RSFT(kc)`| |Hold Right Shift and press `kc` |
|
||||
|`RALT(kc)`|`ROPT(kc)`, `ALGR(kc)` |Hold Right Alt and press `kc` |
|
||||
|`RGUI(kc)`|`RCMD(kc)`, `RWIN(kc)` |Hold Right GUI and press `kc` |
|
||||
|`RCA(kc)` | |Hold Right Control and Right Alt and press `kc` |
|
||||
|`RCS(kc)` | |Hold Right Control and Right Shift and press `kc` |
|
||||
|`RCG(kc)` | |Hold Right Control and Right GUI and press `kc` |
|
||||
|`RSA(kc)` | |Hold Right Shift and Right Alt and press `kc` |
|
||||
|`RSG(kc)` | |Hold Right Shift and Right GUI and press `kc` |
|
||||
|`RAG(kc)` | |Hold Right Alt and Right GUI and press `kc` |
|
||||
|`RCSG(kc)`| |Hold Right Control, Right Shift and Right GUI and press `kc` |
|
||||
|`RCAG(kc)`| |Hold Right Control, Right Alt and Right GUI and press `kc` |
|
||||
|`RSAG(kc)`| |Hold Right Shift, Right Alt and Right GUI and press `kc` |
|
||||
|`MEH(kc)` | |Hold Left Control, Left Shift and Left Alt and press `kc` |
|
||||
|`HYPR(kc)`| |Hold Left Control, Left Shift, Left Alt and Left GUI and press `kc`<sup>1</sup>|
|
||||
|
||||
<sup>1. More information on the Hyper key can be found on [this blog post by Brett Terpstra](https://brettterpstra.com/2012/12/08/a-useful-caps-lock-key/).</sup>
|
||||
|
||||
|
||||
55
docs/features/battery.md
Normal file
55
docs/features/battery.md
Normal file
@@ -0,0 +1,55 @@
|
||||
# Battery
|
||||
|
||||
This feature provides the high level abstraction for sampling battery level.
|
||||
|
||||
## Usage
|
||||
|
||||
To use this driver, add the following to your `rules.mk`:
|
||||
|
||||
```make
|
||||
BATTERY_ENABLE = yes
|
||||
```
|
||||
|
||||
## Basic Configuration {#basic-configuration}
|
||||
|
||||
Add the following to your `config.h`:
|
||||
|
||||
|Define |Default |Description |
|
||||
|--------------------------|--------|--------------------------------------------------|
|
||||
|`BATTERY_SAMPLE_INTERVAL` |`30000` |The time between battery samples in milliseconds. |
|
||||
|
||||
## Driver Configuration {#driver-configuration}
|
||||
|
||||
See the [Battery Driver](../drivers/battery) documentation for more information.
|
||||
|
||||
## Functions
|
||||
|
||||
### `uint8_t battery_get_percent(void)` {#api-battery-get-percent}
|
||||
|
||||
Sample battery level.
|
||||
|
||||
#### Return Value {#api-battery-get-percent-return}
|
||||
|
||||
The battery percentage, in the range 0-100.
|
||||
|
||||
## Callbacks
|
||||
|
||||
### `void battery_percent_changed_user(uint8_t level)` {#api-battery-percent-changed-user}
|
||||
|
||||
User hook called when battery level changed.
|
||||
|
||||
### Arguments {#api-battery-percent-changed-user-arguments}
|
||||
|
||||
- `uint8_t level`
|
||||
The battery percentage, in the range 0-100.
|
||||
|
||||
---
|
||||
|
||||
### `void battery_percent_changed_kb(uint8_t level)` {#api-battery-percent-changed-kb}
|
||||
|
||||
Keyboard hook called when battery level changed.
|
||||
|
||||
### Arguments {#api-battery-percent-changed-kb-arguments}
|
||||
|
||||
- `uint8_t level`
|
||||
The battery percentage, in the range 0-100.
|
||||
@@ -214,9 +214,30 @@ led_matrix_mode(LED_MATRIX_CUSTOM_my_cool_effect);
|
||||
For inspiration and examples, check out the built-in effects under `quantum/led_matrix/animations/`.
|
||||
|
||||
|
||||
## Naming
|
||||
|
||||
If you wish to be able to use the name of an effect in your code -- say for a display indicator -- then you can enable the function `led_matrix_get_mode_name` in the following manner:
|
||||
|
||||
In your keymap's `config.h`:
|
||||
```c
|
||||
#define LED_MATRIX_MODE_NAME_ENABLE
|
||||
```
|
||||
|
||||
In your `keymap.c`
|
||||
```c
|
||||
const char* effect_name = led_matrix_get_mode_name(led_matrix_get_mode());
|
||||
// do something with `effect_name`, like `oled_write_ln(effect_name, false);`
|
||||
```
|
||||
|
||||
::: info
|
||||
`led_matrix_get_mode_name()` is not enabled by default as it increases the amount of flash memory used by the firmware based on the number of effects enabled.
|
||||
:::
|
||||
|
||||
|
||||
## Additional `config.h` Options {#additional-configh-options}
|
||||
|
||||
```c
|
||||
#define LED_MATRIX_MODE_NAME_ENABLE // enables led_matrix_get_mode_name()
|
||||
#define LED_MATRIX_KEYRELEASES // reactive effects respond to keyreleases (instead of keypresses)
|
||||
#define LED_MATRIX_TIMEOUT 0 // number of milliseconds to wait until led automatically turns off
|
||||
#define LED_MATRIX_SLEEP // turn off effects when suspended
|
||||
|
||||
@@ -379,7 +379,7 @@ POINTING_DEVICE_DRIVER = custom
|
||||
Using the custom driver will require implementing the following functions:
|
||||
|
||||
```c
|
||||
void pointing_device_driver_init(void) {}
|
||||
bool pointing_device_driver_init(void) { return true; }
|
||||
report_mouse_t pointing_device_driver_get_report(report_mouse_t mouse_report) { return mouse_report; }
|
||||
uint16_t pointing_device_driver_get_cpi(void) { return 0; }
|
||||
void pointing_device_driver_set_cpi(uint16_t cpi) {}
|
||||
@@ -467,20 +467,22 @@ If there is a `_RIGHT` configuration option or callback, the [common configurati
|
||||
|
||||
## Callbacks and Functions
|
||||
|
||||
| Function | Description |
|
||||
| ---------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------- |
|
||||
| `pointing_device_init_kb(void)` | Callback to allow for keyboard level initialization. Useful for additional hardware sensors. |
|
||||
| `pointing_device_init_user(void)` | Callback to allow for user level initialization. Useful for additional hardware sensors. |
|
||||
| `pointing_device_task_kb(mouse_report)` | Callback that sends sensor data, so keyboard code can intercept and modify the data. Returns a mouse report. |
|
||||
| `pointing_device_task_user(mouse_report)` | Callback that sends sensor data, so user code can intercept and modify the data. Returns a mouse report. |
|
||||
| `pointing_device_handle_buttons(buttons, pressed, button)` | Callback to handle hardware button presses. Returns a `uint8_t`. |
|
||||
| `pointing_device_get_cpi(void)` | Gets the current CPI/DPI setting from the sensor, if supported. |
|
||||
| `pointing_device_set_cpi(uint16_t)` | Sets the CPI/DPI, if supported. |
|
||||
| `pointing_device_get_report(void)` | Returns the current mouse report (as a `report_mouse_t` data structure). |
|
||||
| `pointing_device_set_report(mouse_report)` | Sets the mouse report to the assigned `report_mouse_t` data structured passed to the function. |
|
||||
| `pointing_device_send(void)` | Sends the current mouse report to the host system. Function can be replaced. |
|
||||
| `has_mouse_report_changed(new_report, old_report)` | Compares the old and new `report_mouse_t` data and returns true only if it has changed. |
|
||||
| `pointing_device_adjust_by_defines(mouse_report)` | Applies rotations and invert configurations to a raw mouse report. |
|
||||
| Function | Description |
|
||||
| ------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------- |
|
||||
| `pointing_device_init_kb(void)` | Callback to allow for keyboard level initialization. Useful for additional hardware sensors. |
|
||||
| `pointing_device_init_user(void)` | Callback to allow for user level initialization. Useful for additional hardware sensors. |
|
||||
| `pointing_device_task_kb(mouse_report)` | Callback that sends sensor data, so keyboard code can intercept and modify the data. Returns a mouse report. |
|
||||
| `pointing_device_task_user(mouse_report)` | Callback that sends sensor data, so user code can intercept and modify the data. Returns a mouse report. |
|
||||
| `pointing_device_handle_buttons(buttons, pressed, button)` | Callback to handle hardware button presses. Returns a `uint8_t`. |
|
||||
| `pointing_device_get_cpi(void)` | Gets the current CPI/DPI setting from the sensor, if supported. |
|
||||
| `pointing_device_set_cpi(uint16_t)` | Sets the CPI/DPI, if supported. |
|
||||
| `pointing_device_get_report(void)` | Returns the current mouse report (as a `report_mouse_t` data structure). |
|
||||
| `pointing_device_set_report(mouse_report)` | Sets the mouse report to the assigned `report_mouse_t` data structured passed to the function. |
|
||||
| `pointing_device_send(void)` | Sends the current mouse report to the host system. Function can be replaced. |
|
||||
| `has_mouse_report_changed(new_report, old_report)` | Compares the old and new `report_mouse_t` data and returns true only if it has changed. |
|
||||
| `pointing_device_adjust_by_defines(mouse_report)` | Applies rotations and invert configurations to a raw mouse report. |
|
||||
| `pointing_device_get_status(void)` | Returns device status as `pointing_device_status_t` a good return is `POINTING_DEVICE_STATUS_SUCCESS`. |
|
||||
| `pointing_device_set_status(pointing_device_status_t status)` | Sets device status, anything other than `POINTING_DEVICE_STATUS_SUCCESS` will disable reports from the device.|
|
||||
|
||||
|
||||
## Split Keyboard Callbacks and Functions
|
||||
|
||||
@@ -365,9 +365,30 @@ These are shorthands to popular colors. The `RGB` ones can be passed to the `set
|
||||
These are defined in [`color.h`](https://github.com/qmk/qmk_firmware/blob/master/quantum/color.h). Feel free to add to this list!
|
||||
|
||||
|
||||
## Naming
|
||||
|
||||
If you wish to be able to use the name of an effect in your code -- say for a display indicator -- then you can enable the function `rgb_matrix_get_mode_name` in the following manner:
|
||||
|
||||
In your keymap's `config.h`:
|
||||
```c
|
||||
#define RGB_MATRIX_MODE_NAME_ENABLE
|
||||
```
|
||||
|
||||
In your `keymap.c`
|
||||
```c
|
||||
const char* effect_name = rgb_matrix_get_mode_name(rgb_matrix_get_mode());
|
||||
// do something with `effect_name`, like `oled_write_ln(effect_name, false);`
|
||||
```
|
||||
|
||||
::: info
|
||||
`rgb_matrix_get_mode_name()` is not enabled by default as it increases the amount of flash memory used by the firmware based on the number of effects enabled.
|
||||
:::
|
||||
|
||||
|
||||
## Additional `config.h` Options {#additional-configh-options}
|
||||
|
||||
```c
|
||||
#define RGB_MATRIX_MODE_NAME_ENABLE // enables rgb_matrix_get_mode_name()
|
||||
#define RGB_MATRIX_KEYRELEASES // reactive effects respond to keyreleases (instead of keypresses)
|
||||
#define RGB_MATRIX_TIMEOUT 0 // number of milliseconds to wait until rgb automatically turns off
|
||||
#define RGB_MATRIX_SLEEP // turn off effects when suspended
|
||||
|
||||
@@ -4,6 +4,14 @@
|
||||
|
||||
The [Open Steno Project](https://www.openstenoproject.org/) has built an open-source program called Plover that provides real-time translation of steno strokes into words and commands. It has an established dictionary and supports
|
||||
|
||||
## Steno Support in QMK
|
||||
|
||||
There are three ways that QMK keyboards can support steno, with varying degrees of configuration required:
|
||||
|
||||
1. Plover with [Arpeggiation](https://plover.wiki/index.php/Glossary#Arpeggiate) requires no changes to any keyboard and is supported by QMK as well as any other QWERTY keyboard.
|
||||
2. Plover with [NKRO](https://plover.wiki/index.php/Using_a_standard_keyboard_with_Plover#NKRO). If your keyboard supports NKRO in hardware and you have NKRO enabled as a USB endpoint, you can chord with the keyboard. Many devices will arrive stock like this and will require no changes.
|
||||
3. Steno Machine Protocols. This requires the most configuration, but this has the advantage of allowing you to use your keyboard keys normally (either on another layer or another piece of hardware) without enabling and disabling your steno software.
|
||||
|
||||
## Plover with QWERTY Keyboard {#plover-with-qwerty-keyboard}
|
||||
|
||||
Plover can work with any standard QWERTY keyboard, although it is more efficient if the keyboard supports NKRO (n-key rollover) to allow Plover to see all the pressed keys at once. An example keymap for Plover can be found in `planck/keymaps/default`. Switching to the `PLOVER` layer adjusts the position of the keyboard to support the number bar.
|
||||
@@ -14,14 +22,14 @@ You may also need to adjust your layout, either in QMK or in Plover, if you have
|
||||
|
||||
## Plover with Steno Protocol {#plover-with-steno-protocol}
|
||||
|
||||
Plover also understands the language of several steno machines. QMK can speak a couple of these languages: TX Bolt and GeminiPR. An example layout can be found in `planck/keymaps/steno`.
|
||||
Plover also understands the language of several steno machines. QMK can speak a couple of these languages: TX Bolt and GeminiPR. An example layout can be found in `splitography/keymaps/default`.
|
||||
|
||||
When QMK speaks to Plover over a steno protocol, Plover will not use the keyboard as input. This means that you can switch back and forth between a standard keyboard and your steno keyboard, or even switch layers from Plover to standard and back without needing to activate/deactivate Plover.
|
||||
|
||||
In this mode, Plover expects to speak with a steno machine over a serial port so QMK will present itself to the operating system as a virtual serial port in addition to a keyboard.
|
||||
|
||||
::: info
|
||||
Note: Due to hardware limitations, you might not be able to run both a virtual serial port and mouse emulation at the same time.
|
||||
Due to hardware limitations, you might not be able to run both a virtual serial port and other features (mouse keys, NKRO, or MIDI support) at the same time. You will likely encounter a compile time error if this is the case. Disable those other features as necessary.
|
||||
:::
|
||||
|
||||
::: warning
|
||||
@@ -156,7 +164,7 @@ At the end of this scenario given as an example, `chord` would have five bits se
|
||||
## Keycode Reference {#keycode-reference}
|
||||
|
||||
::: info
|
||||
Note: TX Bolt does not support the full set of keys. The TX Bolt implementation in QMK will map the GeminiPR keys to the nearest TX Bolt key so that one key map will work for both.
|
||||
TX Bolt does not support the full set of keys. The TX Bolt implementation in QMK will map the GeminiPR keys to the nearest TX Bolt key so that one key map will work for both.
|
||||
:::
|
||||
|
||||
|GeminiPR|TX Bolt|Steno Key|
|
||||
|
||||
@@ -19,8 +19,8 @@ Within the folder `keyboards`, its subfolder `handwired` and its vendor and manu
|
||||
* `config.h`: The file that sets the default compile time options. Do not edit this file directly, instead use a keymap specific `config.h`.
|
||||
* `info.json`: The file used for setting layout for QMK Configurator. See [Configurator Support](reference_configurator_support) for more information.
|
||||
* `readme.md`: A brief overview of the keyboard.
|
||||
* `<keyboardName>.h`: This file is where the keyboard layout is defined against the keyboard's switch matrix.
|
||||
* `<keyboardName>.c`: This file is where you can find custom code for the keyboard.
|
||||
* `<keyboard>.h`: This file is where the keyboard layout is defined against the keyboard's switch matrix.
|
||||
* `<keyboard>.c`: This file is where you can find custom code for the keyboard.
|
||||
|
||||
For more information on project structure, see [QMK Keyboard Guidelines](hardware_keyboard_guidelines).
|
||||
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
# More Detailed `make` Instructions
|
||||
|
||||
The full syntax of the `make` command is `<keyboard_folder>:<keymap>:<target>`, where:
|
||||
The full syntax of the `make` command is `<keyboard>:<keymap>:<target>`, where:
|
||||
|
||||
* `<keyboard_folder>` is the path of the keyboard, for example `planck`
|
||||
* `<keyboard>` is the path of the keyboard, for example `planck`
|
||||
* Use `all` to compile all keyboards
|
||||
* Specify the path to compile a revision, for example `planck/rev4` or `planck/rev3`
|
||||
* If the keyboard doesn't have any folders, it can be left out
|
||||
|
||||
@@ -44,7 +44,11 @@ QMK uses sub-folders both for organization and to share code between revisions o
|
||||
qmk_firmware/keyboards/top_folder/sub_1/sub_2/sub_3/sub_4
|
||||
```
|
||||
|
||||
If a sub-folder has a `rules.mk` file it will be considered a compilable keyboard. It will be available in QMK Configurator and tested with `make all`. If you are using a folder to organize several keyboards from the same maker you should not have a `rules.mk` file.
|
||||
If a sub-folder has a `keyboard.json` file it will be considered a compilable keyboard. It will be available in QMK Configurator and tested with `make all`. If you are using a folder to organize several keyboards from the same maker you should not have a `keyboard.json` file.
|
||||
|
||||
::: tip
|
||||
When configuring a keyboard with multiple revisions (like the `clueboard/66` example below), an `info.json` file at the top keyboard level (eg. `clueboard/66`) should be used for configuration shared between revisions. Then `keyboard.json` in each revision directory containing revision-specific configuration, and indicating a buildable keyboard.
|
||||
:::
|
||||
|
||||
Example:
|
||||
|
||||
@@ -52,35 +56,49 @@ Clueboard uses sub-folders for both purposes, organization and keyboard revision
|
||||
|
||||
* [`qmk_firmware`](https://github.com/qmk/qmk_firmware/tree/master)
|
||||
* [`keyboards`](https://github.com/qmk/qmk_firmware/tree/master/keyboards)
|
||||
* [`clueboard`](https://github.com/qmk/qmk_firmware/tree/master/keyboards/clueboard) ← This is the organization folder, there's no `rules.mk` file
|
||||
* [`60`](https://github.com/qmk/qmk_firmware/tree/master/keyboards/clueboard/60) ← This is a compilable keyboard, it has a `rules.mk` file
|
||||
* [`66`](https://github.com/qmk/qmk_firmware/tree/master/keyboards/clueboard/66) ← This is also compilable- it uses `DEFAULT_FOLDER` to specify `rev3` as the default revision
|
||||
* [`clueboard`](https://github.com/qmk/qmk_firmware/tree/master/keyboards/clueboard) ← This is the organization folder, there's no `keyboard.json` file
|
||||
* [`60`](https://github.com/qmk/qmk_firmware/tree/master/keyboards/clueboard/60) ← This is a compilable keyboard - it has a `keyboard.json` file
|
||||
* [`66`](https://github.com/qmk/qmk_firmware/tree/master/keyboards/clueboard/66) ← This is not a compilable keyboard - a revision must be specified
|
||||
* [`rev1`](https://github.com/qmk/qmk_firmware/tree/master/keyboards/clueboard/66/rev1) ← compilable: `make clueboard/66/rev1`
|
||||
* [`rev2`](https://github.com/qmk/qmk_firmware/tree/master/keyboards/clueboard/66/rev2) ← compilable: `make clueboard/66/rev2`
|
||||
* [`rev3`](https://github.com/qmk/qmk_firmware/tree/master/keyboards/clueboard/66/rev3) ← compilable: `make clueboard/66/rev3` or `make clueboard/66`
|
||||
* [`rev3`](https://github.com/qmk/qmk_firmware/tree/master/keyboards/clueboard/66/rev3) ← compilable: `make clueboard/66/rev3`
|
||||
|
||||
## Keyboard Folder Structure
|
||||
|
||||
Your keyboard should be located in `qmk_firmware/keyboards/` and the folder name should be your keyboard's name as described in the previous section. Inside this folder should be several files:
|
||||
Your keyboard should be located in `qmk_firmware/keyboards/` and the folder name should be your keyboard's name as described in the previous section. Inside this folder should be several files, some of which are optional:
|
||||
|
||||
* `readme.md`
|
||||
* `info.json`
|
||||
* `keyboard.json` (or `info.json`)
|
||||
* `config.h`
|
||||
* `rules.mk`
|
||||
* `<keyboard_name>.c`
|
||||
* `<keyboard_name>.h`
|
||||
* `<keyboard>.c`
|
||||
* `<keyboard>.h`
|
||||
|
||||
### `readme.md`
|
||||
|
||||
All projects need to have a `readme.md` file that explains what the keyboard is, who made it and where it's available. If applicable, it should also contain links to more information, such as the maker's website. Please follow the [published template](documentation_templates#keyboard-readmemd-template).
|
||||
|
||||
### `info.json`
|
||||
### `keyboard.json`/`info.json`
|
||||
|
||||
This file is used by the [QMK API](https://github.com/qmk/qmk_api). It contains the information [QMK Configurator](https://config.qmk.fm/) needs to display a representation of your keyboard. You can also set metadata here. For more information see the [reference page](reference_info_json).
|
||||
The `keyboard.json` file is necessary for your keyboard (or keyboard revision) to be considered a buildable keyboard. The same content is valid in both `info.json` and `keyboard.json`. For the available configuration options of this file, see the [reference page](reference_info_json). This file is also used by the [QMK API](https://github.com/qmk/qmk_api), and by the [QMK Configurator](https://config.qmk.fm/) to display a representation of the available layouts of your keyboard.
|
||||
|
||||
Additionally, this is where layouts available on your keyboard are defined. If you only have a single layout, it should be named `LAYOUT`. When defining multiple layouts, you should have a base layout, named `LAYOUT_all`, that supports all possible switch positions in your matrix, even if that layout is impossible to build physically. This is the layout that should be used in the `default` keymap. You should then have additional keymaps named `default_<layout>` that configure keymaps for the other layouts. Layout macro names are entirely lowercase, except for the prefix of `LAYOUT`.
|
||||
|
||||
As an example, if you have a 60% PCB that supports ANSI and ISO, you might define the following layouts and keymaps:
|
||||
|
||||
| Layout Name | Keymap Name | Description |
|
||||
|-------------|--------------|------------------------------------------|
|
||||
| LAYOUT_all | default | A layout that supports both ISO and ANSI |
|
||||
| LAYOUT_ansi | default_ansi | An ANSI layout |
|
||||
| LAYOUT_iso | default_iso | An ISO layout |
|
||||
|
||||
::: tip
|
||||
Providing only `LAYOUT_all` is invalid, as is providing a `LAYOUT` when multiple layouts are present.
|
||||
:::
|
||||
|
||||
### `config.h`
|
||||
|
||||
All projects need to have a `config.h` file that sets things like the matrix size, product name, USB VID/PID, description and other settings. In general, use this file to set essential information and defaults for your keyboard that will always work.
|
||||
Some projects will need to have a `config.h` that configures parameters that are not possible to be set in `keyboard.json`. This is not a required file.
|
||||
|
||||
The `config.h` files can also be placed in sub-folders, and the order in which they are read is as follows:
|
||||
|
||||
@@ -138,7 +156,7 @@ If you define options using `post_config.h` as in the above example, you should
|
||||
|
||||
### `rules.mk`
|
||||
|
||||
The presence of this file means that the folder is a keyboard target and can be used in `make` commands. This is where you setup the build environment for your keyboard and configure the default set of features.
|
||||
This file is typically used to configure hardware drivers (eg. pointing device), or to include additional C files in compilation. This is not a required file.
|
||||
|
||||
The `rules.mk` file can also be placed in a sub-folder, and its reading order is as follows:
|
||||
|
||||
@@ -185,9 +203,9 @@ The `post_rules.mk` file can interpret `features` of a keyboard-level before `co
|
||||
See `build_keyboard.mk` and `common_features.mk` for more details.
|
||||
:::
|
||||
|
||||
### `<keyboard_name.c>`
|
||||
### `<keyboard>.c`
|
||||
|
||||
This is where you will write custom code for your keyboard. Typically you will write code to initialize and interface with the hardware in your keyboard. If your keyboard consists of only a key matrix with no LEDs, speakers, or other auxiliary hardware this file can be blank.
|
||||
This file should contain C code required for the functionality of your keyboard, for example hardware initialisation code, OLED display code, and so on. This file should only contain code necessary for the keyboard to work, and *not* things that should be left to the end user to configure in their keymap. This file is automatically included in compilation if it exists. This is not a required file.
|
||||
|
||||
The following functions are typically defined in this file:
|
||||
|
||||
@@ -196,33 +214,13 @@ The following functions are typically defined in this file:
|
||||
* `bool process_record_kb(uint16_t keycode, keyrecord_t *record)`
|
||||
* `bool led_update_kb(led_t led_state)`
|
||||
|
||||
### `<keyboard_name.h>`
|
||||
### `<keyboard>.h`
|
||||
|
||||
This file is used to define the matrix for your keyboard. You should define at least one C macro which translates an array into a matrix representing the physical switch matrix for your keyboard. If it's possible to build your keyboard with multiple layouts you should define additional macros.
|
||||
|
||||
If you have only a single layout you should call this macro `LAYOUT`.
|
||||
|
||||
When defining multiple layouts you should have a base layout, named `LAYOUT_all`, that supports all possible switch positions on your matrix, even if that layout is impossible to build physically. This is the macro you should use in your `default` keymap. You should then have additional keymaps named `default_<layout>` that use your other layout macros. This will make it easier for people to use the layouts you define.
|
||||
|
||||
Layout macro names are entirely lowercase, except for the word `LAYOUT` at the front.
|
||||
|
||||
As an example, if you have a 60% PCB that supports ANSI and ISO you might define the following layouts and keymaps:
|
||||
|
||||
| Layout Name | Keymap Name | Description |
|
||||
|-------------|-------------|-------------|
|
||||
| LAYOUT_all | default | A layout that supports both ISO and ANSI |
|
||||
| LAYOUT_ansi | default_ansi | An ANSI layout |
|
||||
| LAYOUT_iso | default_iso | An ISO layout |
|
||||
|
||||
::: tip
|
||||
Providing only `LAYOUT_all` is invalid - especially when implementing the additional layouts within 3rd party tooling.
|
||||
:::
|
||||
This file can contain function prototypes for custom functions and other header file code utilised by `<keyboard>.c`. The `<keyboard>.c` file should include this file. This is not a required file.
|
||||
|
||||
## Image/Hardware Files
|
||||
|
||||
In an effort to keep the repo size down we're no longer accepting binary files of any format, with few exceptions. Hosting them elsewhere (such as <https://imgur.com>) and linking them in the `readme.md` is preferred.
|
||||
|
||||
Hardware files (such as plates, cases, pcb) can be contributed to the [qmk.fm repo](https://github.com/qmk/qmk.fm) and they will be made available on [qmk.fm](https://qmk.fm). Downloadable files are stored in `/<keyboard>/` (name follows the same format as above) which are served at `https://qmk.fm/<keyboard>/`, and pages are generated from `/_pages/<keyboard>/` which are served at the same location (.md files are generated into .html files through Jekyll). Check out the `lets_split` folder for an example.
|
||||
In an effort to keep the repo size down we do not accept binary files of any format, with few exceptions. Hosting them elsewhere (such as <https://imgur.com>) and linking them in the `readme.md` is preferred. Hardware files such as plates, cases, and PCBs can be published in a personal repository or elsewhere, and linked to by your keyboard's `readme.md` file.
|
||||
|
||||
## Keyboard Defaults
|
||||
|
||||
@@ -232,8 +230,6 @@ Given the amount of functionality that QMK exposes it's very easy to confuse new
|
||||
|
||||
[Magic Keycodes](keycodes_magic) and [Command](features/command) are two related features that allow a user to control their keyboard in non-obvious ways. We recommend you think long and hard about if you're going to enable either feature, and how you will expose this functionality. Keep in mind that users who want this functionality can enable it in their personal keymaps without affecting all the novice users who may be using your keyboard as their first programmable board.
|
||||
|
||||
By far the most common problem new users encounter is accidentally triggering Bootmagic while they're plugging in their keyboard. They're holding the keyboard by the bottom, unknowingly pressing in alt and spacebar, and then they find that these keys have been swapped on them. We recommend leaving this feature disabled by default, but if you do turn it on consider setting `BOOTMAGIC_KEY_SALT` to a key that is hard to press while plugging your keyboard in.
|
||||
|
||||
If your keyboard does not have 2 shift keys you should provide a working default for `IS_COMMAND`, even when you have set `COMMAND_ENABLE = no`. This will give your users a default to conform to if they do enable Command.
|
||||
|
||||
## Custom Keyboard Programming
|
||||
@@ -242,7 +238,7 @@ As documented on [Customizing Functionality](custom_quantum_functions) you can d
|
||||
|
||||
## Non-Production/Handwired Projects
|
||||
|
||||
We're happy to accept any project that uses QMK, including prototypes and handwired ones, but we have a separate `/keyboards/handwired/` folder for them, so the main `/keyboards/` folder doesn't get overcrowded. If a prototype project becomes a production project at some point in the future, we'd be happy to move it to the main `/keyboards/` folder!
|
||||
We're happy to accept any project that uses QMK, including handwired ones, but we have a separate `/keyboards/handwired/` folder for them, so the main `/keyboards/` folder doesn't get overcrowded. If a prototype project becomes a production project at some point in the future, we'd be happy to move it to the main `/keyboards/` folder!
|
||||
|
||||
## Warnings as Errors
|
||||
|
||||
|
||||
113
docs/keycodes.md
113
docs/keycodes.md
@@ -404,7 +404,6 @@ See also: [Layer Switching](feature_layers#switching-and-toggling-layers)
|
||||
|`DF(layer)` |Set the base (default) layer until the keyboard loses power |
|
||||
|`PDF(layer)` |Set the base (default) layer in EEPROM |
|
||||
|`MO(layer)` |Momentarily turn on `layer` when pressed (requires `KC_TRNS` on destination layer)|
|
||||
|`OSL(layer)` |Momentarily activates `layer` until a key is pressed. See [One Shot Keys](one_shot_keys) for details. |
|
||||
|`LM(layer, mod)`|Momentarily turn on `layer` (like MO) with `mod` active as well. Where `mod` is a mods_bit. Mods can be viewed [here](mod_tap). Example Implementation: `LM(LAYER_1, MOD_LALT)`|
|
||||
|`LT(layer, kc)` |Turn on `layer` when held, `kc` when tapped |
|
||||
|`TG(layer)` |Toggle `layer` on or off |
|
||||
@@ -658,38 +657,38 @@ See also: [Mouse Keys](features/mouse_keys)
|
||||
|
||||
See also: [Modifier Keys](feature_advanced_keycodes#modifier-keys)
|
||||
|
||||
|Key |Aliases |Description |
|
||||
|----------|----------------------------------|-------------------------------------------------------------------|
|
||||
|`LCTL(kc)`|`C(kc)` |Hold Left Control and press `kc` |
|
||||
|`LSFT(kc)`|`S(kc)` |Hold Left Shift and press `kc` |
|
||||
|`LALT(kc)`|`A(kc)`, `LOPT(kc)` |Hold Left Alt and press `kc` |
|
||||
|`LGUI(kc)`|`G(kc)`, `LCMD(kc)`, `LWIN(kc)` |Hold Left GUI and press `kc` |
|
||||
|`LCS(kc)` | |Hold Left Control and Left Shift and press `kc` |
|
||||
|`LCA(kc)` | |Hold Left Control and Left Alt and press `kc` |
|
||||
|`LCG(kc)` | |Hold Left Control and Left GUI and press `kc` |
|
||||
|`LSA(kc)` | |Hold Left Shift and Left Alt and press `kc` |
|
||||
|`LSG(kc)` |`SGUI(kc)`, `SCMD(kc)`, `SWIN(kc)`|Hold Left Shift and Left GUI and press `kc` |
|
||||
|`LAG(kc)` | |Hold Left Alt and Left GUI and press `kc` |
|
||||
|`LCSG(kc)`| |Hold Left Control, Left Shift and Left GUI and press `kc` |
|
||||
|`LCAG(kc)`| |Hold Left Control, Left Alt and Left GUI and press `kc` |
|
||||
|`LSAG(kc)`| |Hold Left Shift, Left Alt and Left GUI and press `kc` |
|
||||
|`RCTL(kc)`| |Hold Right Control and press `kc` |
|
||||
|`RSFT(kc)`| |Hold Right Shift and press `kc` |
|
||||
|`RALT(kc)`|`ROPT(kc)`, `ALGR(kc)` |Hold Right Alt and press `kc` |
|
||||
|`RGUI(kc)`|`RCMD(kc)`, `RWIN(kc)` |Hold Right GUI and press `kc` |
|
||||
|`RCS(kc)` | |Hold Right Control and Right Shift and press `kc` |
|
||||
|`RCA(kc)` | |Hold Right Control and Right Alt and press `kc` |
|
||||
|`RCG(kc)` | |Hold Right Control and Right GUI and press `kc` |
|
||||
|`RSA(kc)` |`SAGR(kc)` |Hold Right Shift and Right Alt and press `kc` |
|
||||
|`RSG(kc)` | |Hold Right Shift and Right GUI and press `kc` |
|
||||
|`RAG(kc)` | |Hold Right Alt and Right GUI and press `kc` |
|
||||
|`RCSG(kc)`| |Hold Right Control, Right Shift and Right GUI and press `kc` |
|
||||
|`RCAG(kc)`| |Hold Right Control, Right Alt and Right GUI and press `kc` |
|
||||
|`RSAG(kc)`| |Hold Right Shift, Right Alt and Right GUI and press `kc` |
|
||||
|`MEH(kc)` | |Hold Left Control, Left Shift and Left Alt and press `kc` |
|
||||
|`HYPR(kc)`| |Hold Left Control, Left Shift, Left Alt and Left GUI and press `kc`|
|
||||
|`KC_MEH` | |Left Control, Left Shift and Left Alt |
|
||||
|`KC_HYPR` | |Left Control, Left Shift, Left Alt and Left GUI |
|
||||
|Key |Aliases |Description |
|
||||
|----------|-------------------------------|-------------------------------------------------------------------|
|
||||
|`LCTL(kc)`|`C(kc)` |Hold Left Control and press `kc` |
|
||||
|`LSFT(kc)`|`S(kc)` |Hold Left Shift and press `kc` |
|
||||
|`LALT(kc)`|`A(kc)`, `LOPT(kc)` |Hold Left Alt and press `kc` |
|
||||
|`LGUI(kc)`|`G(kc)`, `LCMD(kc)`, `LWIN(kc)`|Hold Left GUI and press `kc` |
|
||||
|`LCS(kc)` | |Hold Left Control and Left Shift and press `kc` |
|
||||
|`LCA(kc)` | |Hold Left Control and Left Alt and press `kc` |
|
||||
|`LCG(kc)` | |Hold Left Control and Left GUI and press `kc` |
|
||||
|`LSA(kc)` | |Hold Left Shift and Left Alt and press `kc` |
|
||||
|`LSG(kc)` | |Hold Left Shift and Left GUI and press `kc` |
|
||||
|`LAG(kc)` | |Hold Left Alt and Left GUI and press `kc` |
|
||||
|`LCSG(kc)`| |Hold Left Control, Left Shift and Left GUI and press `kc` |
|
||||
|`LCAG(kc)`| |Hold Left Control, Left Alt and Left GUI and press `kc` |
|
||||
|`LSAG(kc)`| |Hold Left Shift, Left Alt and Left GUI and press `kc` |
|
||||
|`RCTL(kc)`| |Hold Right Control and press `kc` |
|
||||
|`RSFT(kc)`| |Hold Right Shift and press `kc` |
|
||||
|`RALT(kc)`|`ROPT(kc)`, `ALGR(kc)` |Hold Right Alt and press `kc` |
|
||||
|`RGUI(kc)`|`RCMD(kc)`, `RWIN(kc)` |Hold Right GUI and press `kc` |
|
||||
|`RCS(kc)` | |Hold Right Control and Right Shift and press `kc` |
|
||||
|`RCA(kc)` | |Hold Right Control and Right Alt and press `kc` |
|
||||
|`RCG(kc)` | |Hold Right Control and Right GUI and press `kc` |
|
||||
|`RSA(kc)` | |Hold Right Shift and Right Alt and press `kc` |
|
||||
|`RSG(kc)` | |Hold Right Shift and Right GUI and press `kc` |
|
||||
|`RAG(kc)` | |Hold Right Alt and Right GUI and press `kc` |
|
||||
|`RCSG(kc)`| |Hold Right Control, Right Shift and Right GUI and press `kc` |
|
||||
|`RCAG(kc)`| |Hold Right Control, Right Alt and Right GUI and press `kc` |
|
||||
|`RSAG(kc)`| |Hold Right Shift, Right Alt and Right GUI and press `kc` |
|
||||
|`MEH(kc)` | |Hold Left Control, Left Shift and Left Alt and press `kc` |
|
||||
|`HYPR(kc)`| |Hold Left Control, Left Shift, Left Alt and Left GUI and press `kc`|
|
||||
|`KC_MEH` | |Left Control, Left Shift and Left Alt |
|
||||
|`KC_HYPR` | |Left Control, Left Shift, Left Alt and Left GUI |
|
||||
|
||||
## Mod-Tap Keys {#mod-tap-keys}
|
||||
|
||||
@@ -706,7 +705,7 @@ See also: [Mod-Tap](mod_tap)
|
||||
|`LCA_T(kc)` | |Left Control and Left Alt when held, `kc` when tapped |
|
||||
|`LCG_T(kc)` | |Left Control and Left GUI when held, `kc` when tapped |
|
||||
|`LSA_T(kc)` | |Left Shift and Left Alt when held, `kc` when tapped |
|
||||
|`LSG_T(kc)` |`SGUI_T(kc)`, `SCMD_T(kc)`, `SWIN_T(kc)` |Left Shift and Left GUI when held, `kc` when tapped |
|
||||
|`LSG_T(kc)` | |Left Shift and Left GUI when held, `kc` when tapped |
|
||||
|`LAG_T(kc)` | |Left Alt and Left GUI when held, `kc` when tapped |
|
||||
|`LCSG_T(kc)` | |Left Control, Left Shift and Left GUI when held, `kc` when tapped |
|
||||
|`LCAG_T(kc)` | |Left Control, Left Alt and Left GUI when held, `kc` when tapped |
|
||||
@@ -718,14 +717,14 @@ See also: [Mod-Tap](mod_tap)
|
||||
|`RCS_T(kc)` | |Right Control and Right Shift when held, `kc` when tapped |
|
||||
|`RCA_T(kc)` | |Right Control and Right Alt when held, `kc` when tapped |
|
||||
|`RCG_T(kc)` | |Right Control and Right GUI when held, `kc` when tapped |
|
||||
|`RSA_T(kc)` |`SAGR_T(kc)` |Right Shift and Right Alt when held, `kc` when tapped |
|
||||
|`RSA_T(kc)` | |Right Shift and Right Alt when held, `kc` when tapped |
|
||||
|`RSG_T(kc)` | |Right Shift and Right GUI when held, `kc` when tapped |
|
||||
|`RAG_T(kc)` | |Right Alt and Right GUI when held, `kc` when tapped |
|
||||
|`RCSG_T(kc)` | |Right Control, Right Shift and Right GUI when held, `kc` when tapped |
|
||||
|`RCAG_T(kc)` | |Right Control, Right Alt and Right GUI when held, `kc` when tapped |
|
||||
|`RSAG_T(kc)` | |Right Shift, Right Alt and Right GUI when held, `kc` when tapped |
|
||||
|`MEH_T(kc)` | |Left Control, Left Shift and Left Alt when held, `kc` when tapped |
|
||||
|`HYPR_T(kc)` |`ALL_T(kc)` |Left Control, Left Shift, Left Alt and Left GUI when held, `kc` when tapped|
|
||||
|`HYPR_T(kc)` | |Left Control, Left Shift, Left Alt and Left GUI when held, `kc` when tapped|
|
||||
|
||||
## Tapping Term Keys {#tapping-term-keys}
|
||||
|
||||
@@ -817,13 +816,41 @@ See also: [US ANSI Shifted Symbols](keycodes_us_ansi_shifted)
|
||||
|
||||
See also: [One Shot Keys](one_shot_keys)
|
||||
|
||||
|Key |Aliases |Description |
|
||||
|--------------------|---------|----------------------------------|
|
||||
|`OSM(mod)` | |Hold `mod` for one keypress |
|
||||
|`OSL(layer)` | |Switch to `layer` for one keypress|
|
||||
|`QK_ONE_SHOT_TOGGLE`|`OS_TOGG`|Toggles One Shot keys status |
|
||||
|`QK_ONE_SHOT_ON` |`OS_ON` |Turns One Shot keys on |
|
||||
|`QK_ONE_SHOT_OFF` |`OS_OFF` |Turns One Shot keys off |
|
||||
|Key |Aliases |Description |
|
||||
|--------------------|---------|---------------------------------------------------------------------|
|
||||
|`QK_ONE_SHOT_TOGGLE`|`OS_TOGG`|Toggles One Shot keys status |
|
||||
|`QK_ONE_SHOT_ON` |`OS_ON` |Turns One Shot keys on |
|
||||
|`QK_ONE_SHOT_OFF` |`OS_OFF` |Turns One Shot keys off |
|
||||
|`OSL(layer)` | |Switch to `layer` for one keypress |
|
||||
|`OSM(mod)` | |Hold `mod` for one keypress |
|
||||
|`OS_LCTL` | |Hold Left Control for one keypress |
|
||||
|`OS_LSFT` | |Hold Left Shift for one keypress |
|
||||
|`OS_LALT` | |Hold Left Alt for one keypress |
|
||||
|`OS_LGUI` | |Hold Left GUI for one keypress |
|
||||
|`OS_LCS` | |Hold Left Control and Left Shift for one keypress |
|
||||
|`OS_LCA` | |Hold Left Control and left Alt for one keypress |
|
||||
|`OS_LCG` | |Hold Left Control and Left GUI for one keypress |
|
||||
|`OS_LSA` | |Hold Left Shift and Left Alt for one keypress |
|
||||
|`OS_LSG` | |Hold Left Shift and Left GUI for one keypress |
|
||||
|`OS_LAG` | |Hold Left Alt and Left GUI for one keypress |
|
||||
|`OS_LCSG` | |Hold Left Control, Left Shift and Left GUI for one keypress |
|
||||
|`OS_LCAG` | |Hold Left Control, Left Alt and Left GUI for one keypress |
|
||||
|`OS_LSAG` | |Hold Left Shift, Left Alt and Left GUI for one keypress |
|
||||
|`OS_RCTL` | |Hold Right Control for one keypress |
|
||||
|`OS_RSFT` | |Hold Right Shift for one keypress |
|
||||
|`OS_RALT` | |Hold Right Alt for one keypress |
|
||||
|`OS_RGUI` | |Hold Right GUI for one keypress |
|
||||
|`OS_RCS` | |Hold Right Control and Right Shift for one keypress |
|
||||
|`OS_RCA` | |Hold Right Control and Right Alt for one keypress |
|
||||
|`OS_RCG` | |Hold Right Control and Right GUI for one keypress |
|
||||
|`OS_RSA` | |Hold Right Shift and Right Alt for one keypress |
|
||||
|`OS_RSG` | |Hold Right Shift and Right GUI for one keypress |
|
||||
|`OS_RAG` | |Hold Right Alt and Right GUI for one keypress |
|
||||
|`OS_RCSG` | |Hold Right Control, Right Shift and Right GUI for one keypress |
|
||||
|`OS_RCAG` | |Hold Right Control, Right Alt and Right GUI for one keypress |
|
||||
|`OS_RSAG` | |Hold Right Shift, Right Alt and Right GUI for one keypress |
|
||||
|`OS_MEH` | |Hold Left Control, Left Shift and Left Alt for one keypress |
|
||||
|`OS_HYPR` | |Hold Left Control, Left Shift, Left Alt and Left GUI for one keypress|
|
||||
|
||||
## Programmable Button Support {#programmable-button}
|
||||
|
||||
|
||||
@@ -37,7 +37,7 @@ For convenience, QMK includes some Mod-Tap shortcuts to make common combinations
|
||||
|`LCA_T(kc)` | |Left Control and Left Alt when held, `kc` when tapped |
|
||||
|`LCG_T(kc)` | |Left Control and Left GUI when held, `kc` when tapped |
|
||||
|`LSA_T(kc)` | |Left Shift and Left Alt when held, `kc` when tapped |
|
||||
|`LSG_T(kc)` |`SGUI_T(kc)`, `SCMD_T(kc)`, `SWIN_T(kc)` |Left Shift and Left GUI when held, `kc` when tapped |
|
||||
|`LSG_T(kc)` | |Left Shift and Left GUI when held, `kc` when tapped |
|
||||
|`LAG_T(kc)` | |Left Alt and Left GUI when held, `kc` when tapped |
|
||||
|`LCSG_T(kc)`| |Left Control, Left Shift and Left GUI when held, `kc` when tapped |
|
||||
|`LCAG_T(kc)`| |Left Control, Left Alt and Left GUI when held, `kc` when tapped |
|
||||
@@ -49,14 +49,14 @@ For convenience, QMK includes some Mod-Tap shortcuts to make common combinations
|
||||
|`RCS_T(kc)` | |Right Control and Right Shift when held, `kc` when tapped |
|
||||
|`RCA_T(kc)` | |Right Control and Right Alt when held, `kc` when tapped |
|
||||
|`RCG_T(kc)` | |Right Control and Right GUI when held, `kc` when tapped |
|
||||
|`RSA_T(kc)` |`SAGR_T(kc)` |Right Shift and Right Alt when held, `kc` when tapped |
|
||||
|`RSA_T(kc)` | |Right Shift and Right Alt when held, `kc` when tapped |
|
||||
|`RSG_T(kc)` | |Right Shift and Right GUI when held, `kc` when tapped |
|
||||
|`RAG_T(kc)` | |Right Alt and Right GUI when held, `kc` when tapped |
|
||||
|`RCSG_T(kc)`| |Right Control, Right Shift and Right GUI when held, `kc` when tapped |
|
||||
|`RCAG_T(kc)`| |Right Control, Right Alt and Right GUI when held, `kc` when tapped |
|
||||
|`RSAG_T(kc)`| |Right Shift, Right Alt and Right GUI when held, `kc` when tapped |
|
||||
|`MEH_T(kc)` | |Left Control, Left Shift and Left Alt when held, `kc` when tapped |
|
||||
|`HYPR_T(kc)`|`ALL_T(kc)` |Left Control, Left Shift, Left Alt and Left GUI when held, `kc` when tapped<sup>1</sup>|
|
||||
|`HYPR_T(kc)`| |Left Control, Left Shift, Left Alt and Left GUI when held, `kc` when tapped<sup>1</sup>|
|
||||
|
||||
<sup>1. More information on the Hyper key can be found on [this blog post by Brett Terpstra](https://brettterpstra.com/2012/12/08/a-useful-caps-lock-key/).</sup>
|
||||
|
||||
|
||||
@@ -33,7 +33,7 @@ qmk new-keymap
|
||||
If you did not configure your environment, or you have multiple keyboards, you can specify a keyboard name:
|
||||
|
||||
```sh
|
||||
qmk new-keymap -kb <keyboard_name>
|
||||
qmk new-keymap -kb <keyboard>
|
||||
```
|
||||
|
||||
Look at the output from that command, you should see something like this:
|
||||
|
||||
@@ -60,7 +60,7 @@ open .
|
||||
The firmware file always follows this naming format:
|
||||
|
||||
```
|
||||
<keyboard_name>_<keymap_name>.{bin,hex}
|
||||
<keyboard>_<keymap>.{bin,hex}
|
||||
```
|
||||
|
||||
For example, the `planck/rev5` with a `default` keymap will have this filename:
|
||||
|
||||
@@ -50,90 +50,64 @@ You will need to install [MSYS2](https://www.msys2.org). Once installed, close a
|
||||
Install the QMK CLI by running:
|
||||
|
||||
```sh
|
||||
pacman --needed --noconfirm --disable-download-timeout -S git mingw-w64-x86_64-python-qmk
|
||||
curl -fsSL https://install.qmk.fm | sh
|
||||
```
|
||||
|
||||
::::
|
||||
|
||||
==== macOS
|
||||
|
||||
QMK maintains a Homebrew tap and formula which will automatically install the CLI and all necessary dependencies.
|
||||
|
||||
#### Prerequisites
|
||||
|
||||
You will need to install Homebrew. Follow the instructions on https://brew.sh.
|
||||
|
||||
::: tip
|
||||
If you are using an Apple Silicon machine, the installation process will take significantly longer because GitHub actions do not have native runners to build binary packages for the ARM and AVR toolchains.
|
||||
:::
|
||||
|
||||
#### Installation
|
||||
|
||||
Install the QMK CLI by running:
|
||||
|
||||
```sh
|
||||
brew install qmk/qmk/qmk
|
||||
curl -fsSL https://install.qmk.fm | sh
|
||||
```
|
||||
|
||||
==== Linux/WSL
|
||||
|
||||
#### Installation
|
||||
|
||||
::: info
|
||||
Many Linux distributions are supported, but not all. Mainstream distributions will have best success -- if possible, choose either Debian or its derivatives (such as Ubuntu, or Mint), CentOS or its derivatives (such as Fedora, or Rocky Linux), and Arch or its derivatives (such as Manjaro, or CachyOS).
|
||||
:::
|
||||
|
||||
Install the QMK CLI by running:
|
||||
|
||||
```sh
|
||||
curl -fsSL https://install.qmk.fm | sh
|
||||
```
|
||||
|
||||
::: tip
|
||||
**Note for WSL users**: By default, the installation process will clone the QMK repository into your WSL home directory, but if you have cloned manually, ensure that it is located inside the WSL instance instead of the Windows filesystem (ie. not in `/mnt`), as accessing it is currently [extremely slow](https://github.com/microsoft/WSL/issues/4197).
|
||||
:::
|
||||
|
||||
#### Prerequisites
|
||||
|
||||
You will need to install Git and Python. It's very likely that you already have both, but if not, one of the following commands should install them:
|
||||
|
||||
* Debian / Ubuntu / Devuan: `sudo apt install -y git python3-pip`
|
||||
* Fedora / Red Hat / CentOS: `sudo yum -y install git python3-pip`
|
||||
* Arch / Manjaro: `sudo pacman --needed --noconfirm -S git python-pip libffi`
|
||||
* Void: `sudo xbps-install -y git python3-pip`
|
||||
* Solus: `sudo eopkg -y install git python3`
|
||||
* Sabayon: `sudo equo install dev-vcs/git dev-python/pip`
|
||||
* Gentoo: `sudo emerge dev-vcs/git dev-python/pip`
|
||||
|
||||
#### Installation
|
||||
|
||||
Install the QMK CLI by running:
|
||||
|
||||
```sh
|
||||
python3 -m pip install --user qmk
|
||||
```
|
||||
|
||||
Alternatively, install the QMK CLI as a [uv](https://docs.astral.sh/uv/) managed tool, kept isolated in a virtual environment (requires uv to be installed):
|
||||
|
||||
```sh
|
||||
uv tool install qmk
|
||||
```
|
||||
|
||||
#### Community Packages
|
||||
|
||||
These packages are maintained by community members, so may not be up to date or completely functional. If you encounter problems, please report them to their respective maintainers.
|
||||
|
||||
On Arch-based distros you can install the CLI from the official repositories (NOTE: at the time of writing this package marks some dependencies as optional that should not be):
|
||||
|
||||
```sh
|
||||
sudo pacman -S qmk
|
||||
```
|
||||
|
||||
You can also try the `qmk-git` package from AUR:
|
||||
|
||||
```sh
|
||||
yay -S qmk-git
|
||||
```
|
||||
::: warning
|
||||
Any QMK packages provided by your distribution's package manager are almost certainly out of date. It is strongly suggested the installation script above is used instead.
|
||||
:::
|
||||
|
||||
==== FreeBSD
|
||||
|
||||
#### Installation
|
||||
|
||||
::: warning
|
||||
FreeBSD support is provided on a best-effort basis by the community instead of the QMK maintainers. It is strongly suggested that you use either Windows, macOS, or a supported distribution of Linux instead.
|
||||
:::
|
||||
|
||||
Install the FreeBSD package for QMK CLI by running:
|
||||
|
||||
```sh
|
||||
pkg install -g "py*-qmk"
|
||||
```
|
||||
|
||||
NOTE: remember to follow the instructions printed at the end of installation (use `pkg info -Dg "py*-qmk"` to show them again).
|
||||
::: info NOTE
|
||||
Remember to follow the instructions printed at the end of installation (use `pkg info -Dg "py*-qmk"` to show them again).
|
||||
:::
|
||||
|
||||
:::::
|
||||
|
||||
|
||||
@@ -15,11 +15,49 @@ You can control the behavior of one shot keys by defining these in `config.h`:
|
||||
#define ONESHOT_TIMEOUT 5000 /* Time (in ms) before the one shot key is released */
|
||||
```
|
||||
|
||||
* `OSM(mod)` - Momentarily hold down *mod*. You must use the `MOD_*` keycodes as shown in [Mod Tap](mod_tap), not the `KC_*` codes.
|
||||
* `OSL(layer)` - momentary switch to *layer*.
|
||||
* `OS_ON` - Turns on One Shot keys.
|
||||
* `OS_OFF` - Turns off One Shot keys. OSM act as regular mod keys, OSL act like `MO`.
|
||||
* `OS_TOGG` - Toggles the one shot key status.
|
||||
## Keycodes {#keycodes}
|
||||
|
||||
|Key |Aliases |Description |
|
||||
|--------------------|---------|---------------------------------------------------------------------|
|
||||
|`QK_ONE_SHOT_TOGGLE`|`OS_TOGG`|Toggles One Shot keys status |
|
||||
|`QK_ONE_SHOT_ON` |`OS_ON` |Turns One Shot keys on |
|
||||
|`QK_ONE_SHOT_OFF` |`OS_OFF` |Turns One Shot keys off |
|
||||
|`OSL(layer)` | |Switch to `layer` for one keypress |
|
||||
|`OSM(mod)` | |Hold `mod` for one keypress |
|
||||
|`OS_LCTL` | |Hold Left Control for one keypress |
|
||||
|`OS_LSFT` | |Hold Left Shift for one keypress |
|
||||
|`OS_LALT` | |Hold Left Alt for one keypress |
|
||||
|`OS_LGUI` | |Hold Left GUI for one keypress |
|
||||
|`OS_LCS` | |Hold Left Control and Left Shift for one keypress |
|
||||
|`OS_LCA` | |Hold Left Control and left Alt for one keypress |
|
||||
|`OS_LCG` | |Hold Left Control and Left GUI for one keypress |
|
||||
|`OS_LSA` | |Hold Left Shift and Left Alt for one keypress |
|
||||
|`OS_LSG` | |Hold Left Shift and Left GUI for one keypress |
|
||||
|`OS_LAG` | |Hold Left Alt and Left GUI for one keypress |
|
||||
|`OS_LCSG` | |Hold Left Control, Left Shift and Left GUI for one keypress |
|
||||
|`OS_LCAG` | |Hold Left Control, Left Alt and Left GUI for one keypress |
|
||||
|`OS_LSAG` | |Hold Left Shift, Left Alt and Left GUI for one keypress |
|
||||
|`OS_RCTL` | |Hold Right Control for one keypress |
|
||||
|`OS_RSFT` | |Hold Right Shift for one keypress |
|
||||
|`OS_RALT` | |Hold Right Alt for one keypress |
|
||||
|`OS_RGUI` | |Hold Right GUI for one keypress |
|
||||
|`OS_RCS` | |Hold Right Control and Right Shift for one keypress |
|
||||
|`OS_RCA` | |Hold Right Control and Right Alt for one keypress |
|
||||
|`OS_RCG` | |Hold Right Control and Right GUI for one keypress |
|
||||
|`OS_RSA` | |Hold Right Shift and Right Alt for one keypress |
|
||||
|`OS_RSG` | |Hold Right Shift and Right GUI for one keypress |
|
||||
|`OS_RAG` | |Hold Right Alt and Right GUI for one keypress |
|
||||
|`OS_RCSG` | |Hold Right Control, Right Shift and Right GUI for one keypress |
|
||||
|`OS_RCAG` | |Hold Right Control, Right Alt and Right GUI for one keypress |
|
||||
|`OS_RSAG` | |Hold Right Shift, Right Alt and Right GUI for one keypress |
|
||||
|`OS_MEH` | |Hold Left Control, Left Shift and Left Alt for one keypress |
|
||||
|`OS_HYPR` | |Hold Left Control, Left Shift, Left Alt and Left GUI for one keypress|
|
||||
|
||||
When One Shot keys are turned off, `OSM()` and `OSL()` will behave like normal modifier keys and `MO()`, respectively.
|
||||
|
||||
::: info
|
||||
The `mod` parameter to the `OSM()` keycode must use the `MOD_*` prefix, rather than `KC_*`, eg. `OSM(MOD_LCTL | MOD_LSFT)`.
|
||||
:::
|
||||
|
||||
Sometimes, you want to activate a one-shot key as part of a macro or tap dance routine.
|
||||
|
||||
|
||||
171
docs/proprietary_libs.md
Normal file
171
docs/proprietary_libs.md
Normal file
@@ -0,0 +1,171 @@
|
||||
# Proprietary Vendor Libraries
|
||||
|
||||
QMK Firmware cannot include support for any proprietary vendor libraries that impose additional restrictions beyond those in the GPL. This includes binary-only distributions, hardware-locked libraries, and code with redistribution limitations. This document explains why such libraries are incompatible with the GPL-based QMK Firmware and addresses commonly proposed workarounds.
|
||||
|
||||
## Architecture Constraints
|
||||
|
||||
Firmware presents unique licensing challenges:
|
||||
|
||||
- **Monolithic binary**: All code compiles into a single executable image
|
||||
- **No OS isolation**: No operating system provides process or memory separation
|
||||
- **Shared resources**: All code shares the same memory space, peripherals, and execution context
|
||||
- **Static linking**: Everything is statically linked at compile time
|
||||
|
||||
This monolithic nature means any proprietary code becomes inseparable from GPL code, creating immediate license violations.
|
||||
|
||||
## Common Vendor Library Restrictions
|
||||
|
||||
Proprietary vendor libraries typically impose restrictions incompatible with GPL freedoms:
|
||||
|
||||
**Hardware Lock-in:**
|
||||
- Library only licensed for specific vendor's chips
|
||||
- Cannot port firmware to alternative hardware
|
||||
- Examples: Nordic's and ST's chip-only clauses in their respective licenses
|
||||
|
||||
**No Source Distribution:**
|
||||
- Binary-only libraries without corresponding source
|
||||
- Precompiled static libraries (.a/.lib files)
|
||||
- No ability to modify or fix bugs
|
||||
- Examples: WCH CH582 precompiled libraries, Nordic SoftDevice
|
||||
|
||||
**Redistribution Limitations:**
|
||||
- Restrictions on who can distribute
|
||||
- Limitations on commercial use
|
||||
- Required permissions or fees
|
||||
|
||||
**Additional Legal Terms:**
|
||||
- Patent assertions beyond GPL's scope
|
||||
- Indemnification requirements
|
||||
- Jurisdiction restrictions
|
||||
- Explicit anti-GPL clauses
|
||||
|
||||
## Bluetooth Stack Licensing Examples
|
||||
|
||||
Both Nordic and ST provide Bluetooth stacks under restrictive licenses:
|
||||
|
||||
**Nordic SoftDevice (under Nordic 5-clause license):**
|
||||
- Binary-only Bluetooth/radio stack
|
||||
- License restricts to Nordic hardware
|
||||
- No source code available
|
||||
- Communicates via SVC interface (still not GPL-compatible)
|
||||
|
||||
**ST's Bluetooth Stack (under SLA0044 license):**
|
||||
- Explicitly forbids being subject to "Open Source Terms", specifically mentioning incompatibility with the GPL
|
||||
- Restricted to ST microcontrollers only
|
||||
- Similar functional role to Nordic's SoftDevice
|
||||
|
||||
Both represent the same fundamental problem: critical wireless functionality locked behind proprietary licenses.
|
||||
|
||||
## Why the System Library Exception Doesn't Apply
|
||||
|
||||
The GPL's System Library exception **cannot** rescue proprietary vendor libraries.
|
||||
|
||||
### System Library Requirements
|
||||
|
||||
The exception only covers libraries that:
|
||||
1. Are part of the "normal form of packaging a Major Component"
|
||||
2. The Major Component is an OS kernel, compiler, or similar system software
|
||||
3. Are not distributed with the application
|
||||
4. Are not part of the application itself
|
||||
|
||||
### Why Vendor Libraries Fail These Requirements
|
||||
|
||||
1. **No operating system**: Bare-metal firmware has no OS to provide system libraries
|
||||
2. **Not Major Components**: Hardware drivers and HALs aren't kernels or compilers
|
||||
3. **Distributed together**: Vendor code becomes part of the firmware binary
|
||||
4. **Application-level code**: Peripheral drivers are application functionality
|
||||
|
||||
The exception covers things like Windows system DLLs or Linux glibc, not microcontroller vendor libraries or Bluetooth stacks.
|
||||
|
||||
## Attempted Workarounds
|
||||
|
||||
### Architectural Separation Attempts
|
||||
|
||||
**Supervisor Call (SVC) Interfaces:**
|
||||
|
||||
Nordic's SoftDevice uses supervisor call based APIs instead of direct linking:
|
||||
- Fixed memory regions for proprietary code
|
||||
- Communication through CPU exception mechanisms
|
||||
- Claims of "no linking" between components
|
||||
|
||||
**Why this fails:** The GPL considers functional integration, not just linking methods. In Bluetooth-capable boards, these would require the proprietary component to function, thus they form a single work regardless of the communication mechanism. This applies equally to Nordic's SoftDevice and any similar architecture ST provides.
|
||||
|
||||
**Binary-Only Distributions:**
|
||||
|
||||
Multiple vendors provide precompiled libraries:
|
||||
- WCH: Precompiled BLE stack
|
||||
- Nordic: Binary-only SoftDevice library
|
||||
- ST: Same solution as Nordic
|
||||
|
||||
**Why this fails:** This is classic static linking of proprietary code into GPL code. The inability to modify these libraries violates GPL's fundamental requirements.
|
||||
|
||||
### Loader-Based Separation
|
||||
|
||||
- Write a GPL bootloader/loader
|
||||
- Load proprietary firmware (such as Nordic/ST Bluetooth) from external storage
|
||||
- Claim they're separate works
|
||||
|
||||
**Problems:**
|
||||
- If designed as a system, courts view as single work
|
||||
- Distribution patterns matter (shipped together?)
|
||||
- Functional interdependence suggests unity
|
||||
- Appears designed to circumvent GPL
|
||||
|
||||
## Real-World Examples
|
||||
|
||||
### Bluetooth/Wireless Stacks
|
||||
- **Nordic SoftDevice**: Binary-only, SVC-interface, hardware-locked
|
||||
- **ST Bluetooth**: Binary-only, license explicitly GPL-incompatible
|
||||
- **WCH CH582**: Precompiled Bluetooth libraries
|
||||
|
||||
### HAL and Driver Libraries
|
||||
- **ST HAL/LL drivers**: Source available but SLA0044 restricted
|
||||
- **Nordic SDK**: Source visible but 5-Clause restricted
|
||||
- **Various vendor HALs**: Platform-locked licenses
|
||||
|
||||
### Mixed Proprietary/Open
|
||||
- Open peripheral drivers with closed protocol stacks
|
||||
- Basic HAL with proprietary performance libraries
|
||||
- Partially documented systems requiring binary supplements
|
||||
|
||||
## Legal and Practical Consequences
|
||||
|
||||
Including any proprietary vendor library means:
|
||||
|
||||
1. **License Violation**: Immediate GPL non-compliance
|
||||
2. **Distribution Ban**: Users cannot legally share modified firmware
|
||||
3. **Commercial Risk**: Products using the firmware face legal liability
|
||||
4. **Contributor Tainting**: All GPL contributions become legally problematic
|
||||
5. **Update Restrictions**: Cannot fix bugs in proprietary components
|
||||
|
||||
## Evaluation Criteria for Libraries
|
||||
|
||||
Before including any library, QMK needs to verify:
|
||||
- Complete source code available
|
||||
- GPL-compatible license (GPL, LGPL, MIT, BSD, Apache)
|
||||
- No hardware restrictions
|
||||
- No redistribution limitations
|
||||
- No additional legal terms
|
||||
- No anti-GPL clauses
|
||||
|
||||
## Policy Implementation
|
||||
|
||||
QMK Firmware maintains a strict policy:
|
||||
|
||||
1. **No proprietary libraries**: Regardless of technical workarounds
|
||||
2. **No binary blobs**: All code must have source available
|
||||
3. **No platform restrictions**: Must allow porting to any hardware
|
||||
4. **No additional terms**: Only GPL restrictions permitted
|
||||
|
||||
## Summary
|
||||
|
||||
There is no legally safe way to include proprietary vendor libraries in GPL firmware. This applies whether they're:
|
||||
- Bluetooth stacks (Nordic SoftDevice, ST Bluetooth)
|
||||
- Precompiled static libraries
|
||||
- Binary blobs with SVC interfaces
|
||||
- Source code with restrictive licenses
|
||||
- Mixed open/closed systems
|
||||
|
||||
**Technical architectures cannot overcome license obligations.**
|
||||
|
||||
QMK chooses GPL compliance, ensuring users receive all freedoms the GPL promises.
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
The information contained in `info.json` is combined with the `config.h` and `rules.mk` files, dynamically generating the necessary configuration for your keyboard at compile time. It is also used by the [QMK API](https://github.com/qmk/qmk_api), and contains the information [QMK Configurator](https://config.qmk.fm/) needs to display a representation of your keyboard. Its key/value pairs are ruled by the [`data/schemas/keyboard.jsonschema`](https://github.com/qmk/qmk_firmware/blob/master/data/schemas/keyboard.jsonschema) file. To learn more about the why and how of the schema file see the [Data Driven Configuration](data_driven_config) page.
|
||||
|
||||
You can create `info.json` files at every level under `qmk_firmware/keyboards/<keyboard_name>`. These files are combined, with more specific files overriding keys in less specific files. This means you do not need to duplicate your metadata information. For example, `qmk_firmware/keyboards/clueboard/info.json` specifies information common to all Clueboard products, such as `manufacturer` and `maintainer`, while `qmk_firmware/keyboards/clueboard/66/info.json` contains more specific information about Clueboard 66%.
|
||||
You can create `info.json` files at every level under `qmk_firmware/keyboards/<keyboard>`. These files are combined, with more specific files overriding keys in less specific files. This means you do not need to duplicate your metadata information. For example, `qmk_firmware/keyboards/clueboard/info.json` specifies information common to all Clueboard products, such as `manufacturer` and `maintainer`, while `qmk_firmware/keyboards/clueboard/66/info.json` contains more specific information about Clueboard 66%.
|
||||
|
||||
## General Metadata {#general-metadata}
|
||||
|
||||
@@ -179,6 +179,32 @@ Configures the [Backlight](features/backlight) feature.
|
||||
* `pins` <Badge type="info">Array: Pin</Badge>
|
||||
* A list of GPIO pins connected to the backlight LEDs (`software` and `timer` drivers only).
|
||||
|
||||
## Battery
|
||||
|
||||
Configures the [Battery](features/battery) feature.
|
||||
|
||||
* `battery`
|
||||
* `adc`
|
||||
* `pin` <Badge type="info">Pin</Badge> <Badge>Required</Badge>
|
||||
* The GPIO pin connected to the voltage divider.
|
||||
* `reference_voltage` <Badge type="info">Number</Badge>
|
||||
* The ADC reverence voltage, in millivolts.
|
||||
* Default: `3300`
|
||||
* `divider_r1` <Badge type="info">Number</Badge>
|
||||
* The voltage divider resistance, in kOhm. Set to 0 to disable.
|
||||
* Default: `100`
|
||||
* `divider_r2` <Badge type="info">Number</Badge>
|
||||
* The voltage divider resistance, in kOhm. Set to 0 to disable.
|
||||
* Default: `100`
|
||||
* `resolution` <Badge type="info">Number</Badge>
|
||||
* The ADC resolution configured for the ADC Driver.
|
||||
* Default: `10`
|
||||
* `driver` <Badge type="info">String</Badge> <Badge>Required</Badge>
|
||||
* The driver to use. Must be one of `adc`, `custom`, `vendor`.
|
||||
* `sample_interval` <Badge type="info">Number</Badge>
|
||||
* The delay between sampling the battery in milliseconds.
|
||||
* Default: `30000` (30 s)
|
||||
|
||||
## Wireless/Bluetooth {#bluetooth}
|
||||
|
||||
Configures the [Wireless](features/wireless) feature.
|
||||
@@ -480,6 +506,9 @@ Configures the [LED Matrix](features/led_matrix) feature.
|
||||
* `io_delay` <Badge type="info">Number</Badge>
|
||||
* The amount of time to wait between row/col selection and col/row pin reading, in microseconds.
|
||||
* Default: `30` (30 µs)
|
||||
* `masked` <Badge type="info">Boolean</Badge>
|
||||
* Whether configured intersections should be ignored.
|
||||
* Default: `false`
|
||||
* `rows` <Badge type="info">Array: Pin</Badge>
|
||||
* A list of GPIO pins connected to the matrix rows.
|
||||
* Example: `["B0", "B1", "B2"]`
|
||||
@@ -750,9 +779,9 @@ Configures the [Split Keyboard](features/split_keyboard) feature.
|
||||
* Default: `"bitbang"`
|
||||
* `pin` <Badge type="info">Pin</Badge>
|
||||
* The GPIO pin to use for transmit and receive.
|
||||
* `soft_serial_speed` <Badge type="info">Number</Badge>
|
||||
* The protocol speed, from `0` to `5` (`serial` transport protocol only).
|
||||
* Default: `1`
|
||||
* `speed` <Badge type="info">Number</Badge>
|
||||
* The protocol speed, from `0` to `5` (fastest to slowest).
|
||||
* Default: `1`
|
||||
* `transport`
|
||||
* `protocol` <Badge type="info">String</Badge>
|
||||
* The split transport protocol to use. Must be one of `custom`, `i2c`, `serial`.
|
||||
|
||||
@@ -1,23 +1,24 @@
|
||||
// Copyright 2025 QMK
|
||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||
|
||||
#include "battery_driver.h"
|
||||
#include "analog.h"
|
||||
#include "gpio.h"
|
||||
|
||||
#ifndef BATTERY_PIN
|
||||
# error("BATTERY_PIN not configured!")
|
||||
#ifndef BATTERY_ADC_PIN
|
||||
# error("BATTERY_ADC_PIN not configured!")
|
||||
#endif
|
||||
|
||||
#ifndef BATTERY_REF_VOLTAGE_MV
|
||||
# define BATTERY_REF_VOLTAGE_MV 3300
|
||||
#ifndef BATTERY_ADC_REF_VOLTAGE_MV
|
||||
# define BATTERY_ADC_REF_VOLTAGE_MV 3300
|
||||
#endif
|
||||
|
||||
#ifndef BATTERY_VOLTAGE_DIVIDER_R1
|
||||
#ifndef BATTERY_ADC_VOLTAGE_DIVIDER_R1
|
||||
# define BATTERY_VOLTAGE_DIVIDER_R1 100
|
||||
#endif
|
||||
|
||||
#ifndef BATTERY_VOLTAGE_DIVIDER_R2
|
||||
# define BATTERY_VOLTAGE_DIVIDER_R2 100
|
||||
#ifndef BATTERY_ADC_VOLTAGE_DIVIDER_R2
|
||||
# define BATTERY_ADC_VOLTAGE_DIVIDER_R2 100
|
||||
#endif
|
||||
|
||||
// TODO: infer from adc config?
|
||||
@@ -26,16 +27,16 @@
|
||||
#endif
|
||||
|
||||
void battery_driver_init(void) {
|
||||
gpio_set_pin_input(BATTERY_PIN);
|
||||
gpio_set_pin_input(BATTERY_ADC_PIN);
|
||||
}
|
||||
|
||||
uint16_t battery_driver_get_mv(void) {
|
||||
uint32_t raw = analogReadPin(BATTERY_PIN);
|
||||
uint32_t raw = analogReadPin(BATTERY_ADC_PIN);
|
||||
|
||||
uint32_t bat_mv = raw * BATTERY_REF_VOLTAGE_MV / (1 << BATTERY_ADC_RESOLUTION);
|
||||
uint32_t bat_mv = raw * BATTERY_ADC_REF_VOLTAGE_MV / (1 << BATTERY_ADC_RESOLUTION);
|
||||
|
||||
#if BATTERY_VOLTAGE_DIVIDER_R1 > 0 && BATTERY_VOLTAGE_DIVIDER_R2 > 0
|
||||
bat_mv = bat_mv * (BATTERY_VOLTAGE_DIVIDER_R1 + BATTERY_VOLTAGE_DIVIDER_R2) / BATTERY_VOLTAGE_DIVIDER_R2;
|
||||
#if BATTERY_VOLTAGE_DIVIDER_R1 > 0 && BATTERY_ADC_VOLTAGE_DIVIDER_R2 > 0
|
||||
bat_mv = bat_mv * (BATTERY_VOLTAGE_DIVIDER_R1 + BATTERY_ADC_VOLTAGE_DIVIDER_R2) / BATTERY_ADC_VOLTAGE_DIVIDER_R2;
|
||||
#endif
|
||||
|
||||
return bat_mv;
|
||||
|
||||
@@ -55,7 +55,7 @@ const pointing_device_driver_t adns5050_pointing_device_driver = {
|
||||
|
||||
static bool powered_down = false;
|
||||
|
||||
void adns5050_init(void) {
|
||||
bool adns5050_init(void) {
|
||||
// Initialize the ADNS serial pins.
|
||||
gpio_set_pin_output(ADNS5050_SCLK_PIN);
|
||||
gpio_set_pin_output(ADNS5050_SDIO_PIN);
|
||||
@@ -75,6 +75,8 @@ void adns5050_init(void) {
|
||||
// gets the adns ready for write commands
|
||||
// (for example, setting the dpi).
|
||||
adns5050_read_burst();
|
||||
|
||||
return adns5050_check_signature();
|
||||
}
|
||||
|
||||
// Perform a synchronization with the ADNS.
|
||||
@@ -220,7 +222,7 @@ uint16_t adns5050_get_cpi(void) {
|
||||
return (uint16_t)((cpival & 0b10000) * 125);
|
||||
}
|
||||
|
||||
bool adns5050_check_signature(void) {
|
||||
bool __attribute__((weak)) adns5050_check_signature(void) {
|
||||
uint8_t pid = adns5050_read_reg(REG_PRODUCT_ID);
|
||||
uint8_t rid = adns5050_read_reg(REG_REVISION_ID);
|
||||
uint8_t pid2 = adns5050_read_reg(REG_PRODUCT_ID2);
|
||||
|
||||
@@ -70,12 +70,12 @@ typedef struct {
|
||||
int8_t dy;
|
||||
} report_adns5050_t;
|
||||
|
||||
const pointing_device_driver_t adns5050_pointing_device_driver;
|
||||
extern const pointing_device_driver_t adns5050_pointing_device_driver;
|
||||
|
||||
// A bunch of functions to implement the ADNS5050-specific serial protocol.
|
||||
// Note that the "serial.h" driver is insufficient, because it does not
|
||||
// manually manipulate a serial clock signal.
|
||||
void adns5050_init(void);
|
||||
bool adns5050_init(void);
|
||||
void adns5050_sync(void);
|
||||
uint8_t adns5050_serial_read(void);
|
||||
void adns5050_serial_write(uint8_t data);
|
||||
|
||||
@@ -115,7 +115,14 @@ uint8_t adns9800_read(uint8_t reg_addr) {
|
||||
return data;
|
||||
}
|
||||
|
||||
void adns9800_init(void) {
|
||||
bool __attribute__((weak)) adns9800_check_signature(void) {
|
||||
if (adns9800_read(REG_Product_ID) != 0x33) {
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
bool adns9800_init(void) {
|
||||
gpio_set_pin_output(ADNS9800_CS_PIN);
|
||||
|
||||
spi_init();
|
||||
@@ -178,6 +185,8 @@ void adns9800_init(void) {
|
||||
adns9800_write(REG_LASER_CTRL0, laser_ctrl0 & 0xf0);
|
||||
|
||||
adns9800_set_cpi(ADNS9800_CPI);
|
||||
|
||||
return adns9800_check_signature();
|
||||
}
|
||||
|
||||
config_adns9800_t adns9800_get_config(void) {
|
||||
|
||||
@@ -61,9 +61,9 @@ typedef struct {
|
||||
int16_t y;
|
||||
} report_adns9800_t;
|
||||
|
||||
const pointing_device_driver_t adns9800_pointing_device_driver;
|
||||
extern const pointing_device_driver_t adns9800_pointing_device_driver;
|
||||
|
||||
void adns9800_init(void);
|
||||
bool adns9800_init(void);
|
||||
config_adns9800_t adns9800_get_config(void);
|
||||
void adns9800_set_config(config_adns9800_t);
|
||||
uint16_t adns9800_get_cpi(void);
|
||||
|
||||
@@ -135,7 +135,7 @@ report_analog_joystick_t analog_joystick_read(void) {
|
||||
return report;
|
||||
}
|
||||
|
||||
void analog_joystick_init(void) {
|
||||
bool analog_joystick_init(void) {
|
||||
gpio_set_pin_input_high(ANALOG_JOYSTICK_X_AXIS_PIN);
|
||||
gpio_set_pin_input_high(ANALOG_JOYSTICK_Y_AXIS_PIN);
|
||||
|
||||
@@ -152,6 +152,8 @@ void analog_joystick_init(void) {
|
||||
maxAxisValues[0] = xOrigin + 100;
|
||||
maxAxisValues[1] = yOrigin + 100;
|
||||
#endif
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
report_mouse_t analog_joystick_get_report(report_mouse_t mouse_report) {
|
||||
|
||||
@@ -43,7 +43,7 @@
|
||||
# define ANALOG_JOYSTICK_SPEED_MAX 2
|
||||
#endif
|
||||
|
||||
const pointing_device_driver_t analog_joystick_pointing_device_driver;
|
||||
extern const pointing_device_driver_t analog_joystick_pointing_device_driver;
|
||||
|
||||
typedef struct {
|
||||
int8_t x;
|
||||
@@ -51,5 +51,5 @@ typedef struct {
|
||||
bool button;
|
||||
} report_analog_joystick_t;
|
||||
report_analog_joystick_t analog_joystick_read(void);
|
||||
void analog_joystick_init(void);
|
||||
bool analog_joystick_init(void);
|
||||
report_mouse_t analog_joystick_get_report(report_mouse_t mouse_report);
|
||||
|
||||
@@ -321,7 +321,7 @@ void azoteq_iqs5xx_setup_resolution(void) {
|
||||
|
||||
static i2c_status_t azoteq_iqs5xx_init_status = 1;
|
||||
|
||||
void azoteq_iqs5xx_init(void) {
|
||||
bool azoteq_iqs5xx_init(void) {
|
||||
i2c_init();
|
||||
i2c_ping_address(AZOTEQ_IQS5XX_ADDRESS, 1); // wake
|
||||
azoteq_iqs5xx_reset_suspend(true, false, true);
|
||||
@@ -349,67 +349,65 @@ void azoteq_iqs5xx_init(void) {
|
||||
azoteq_iqs5xx_init_status |= azoteq_iqs5xx_set_gesture_config(true);
|
||||
wait_ms(AZOTEQ_IQS5XX_REPORT_RATE + 1);
|
||||
}
|
||||
|
||||
return azoteq_iqs5xx_init_status == I2C_STATUS_SUCCESS;
|
||||
};
|
||||
|
||||
report_mouse_t azoteq_iqs5xx_get_report(report_mouse_t mouse_report) {
|
||||
report_mouse_t temp_report = {0};
|
||||
|
||||
if (azoteq_iqs5xx_init_status == I2C_STATUS_SUCCESS) {
|
||||
azoteq_iqs5xx_base_data_t base_data = {0};
|
||||
i2c_status_t status = azoteq_iqs5xx_get_base_data(&base_data);
|
||||
bool ignore_movement = false;
|
||||
azoteq_iqs5xx_base_data_t base_data = {0};
|
||||
i2c_status_t status = azoteq_iqs5xx_get_base_data(&base_data);
|
||||
bool ignore_movement = false;
|
||||
|
||||
if (status == I2C_STATUS_SUCCESS) {
|
||||
if (status == I2C_STATUS_SUCCESS) {
|
||||
#ifdef POINTING_DEVICE_DEBUG
|
||||
if (base_data.previous_cycle_time > AZOTEQ_IQS5XX_REPORT_RATE) {
|
||||
pd_dprintf("IQS5XX - previous cycle time missed, took: %dms\n", base_data.previous_cycle_time);
|
||||
}
|
||||
#endif
|
||||
if (base_data.gesture_events_0.single_tap || base_data.gesture_events_0.press_and_hold) {
|
||||
pd_dprintf("IQS5XX - Single tap/hold.\n");
|
||||
temp_report.buttons = pointing_device_handle_buttons(temp_report.buttons, true, POINTING_DEVICE_BUTTON1);
|
||||
} else if (base_data.gesture_events_1.two_finger_tap) {
|
||||
pd_dprintf("IQS5XX - Two finger tap.\n");
|
||||
temp_report.buttons = pointing_device_handle_buttons(temp_report.buttons, true, POINTING_DEVICE_BUTTON2);
|
||||
} else if (base_data.gesture_events_0.swipe_x_neg) {
|
||||
pd_dprintf("IQS5XX - X-.\n");
|
||||
temp_report.buttons = pointing_device_handle_buttons(temp_report.buttons, true, POINTING_DEVICE_BUTTON4);
|
||||
ignore_movement = true;
|
||||
} else if (base_data.gesture_events_0.swipe_x_pos) {
|
||||
pd_dprintf("IQS5XX - X+.\n");
|
||||
temp_report.buttons = pointing_device_handle_buttons(temp_report.buttons, true, POINTING_DEVICE_BUTTON5);
|
||||
ignore_movement = true;
|
||||
} else if (base_data.gesture_events_0.swipe_y_neg) {
|
||||
pd_dprintf("IQS5XX - Y-.\n");
|
||||
temp_report.buttons = pointing_device_handle_buttons(temp_report.buttons, true, POINTING_DEVICE_BUTTON6);
|
||||
ignore_movement = true;
|
||||
} else if (base_data.gesture_events_0.swipe_y_pos) {
|
||||
pd_dprintf("IQS5XX - Y+.\n");
|
||||
temp_report.buttons = pointing_device_handle_buttons(temp_report.buttons, true, POINTING_DEVICE_BUTTON3);
|
||||
ignore_movement = true;
|
||||
} else if (base_data.gesture_events_1.zoom) {
|
||||
if (AZOTEQ_IQS5XX_COMBINE_H_L_BYTES(base_data.x.h, base_data.x.l) < 0) {
|
||||
pd_dprintf("IQS5XX - Zoom out.\n");
|
||||
temp_report.buttons = pointing_device_handle_buttons(temp_report.buttons, true, POINTING_DEVICE_BUTTON7);
|
||||
} else if (AZOTEQ_IQS5XX_COMBINE_H_L_BYTES(base_data.x.h, base_data.x.l) > 0) {
|
||||
pd_dprintf("IQS5XX - Zoom in.\n");
|
||||
temp_report.buttons = pointing_device_handle_buttons(temp_report.buttons, true, POINTING_DEVICE_BUTTON8);
|
||||
}
|
||||
} else if (base_data.gesture_events_1.scroll) {
|
||||
pd_dprintf("IQS5XX - Scroll.\n");
|
||||
temp_report.h = CONSTRAIN_HID(AZOTEQ_IQS5XX_COMBINE_H_L_BYTES(base_data.x.h, base_data.x.l));
|
||||
temp_report.v = CONSTRAIN_HID(AZOTEQ_IQS5XX_COMBINE_H_L_BYTES(base_data.y.h, base_data.y.l));
|
||||
}
|
||||
if (base_data.number_of_fingers == 1 && !ignore_movement) {
|
||||
temp_report.x = CONSTRAIN_HID_XY(AZOTEQ_IQS5XX_COMBINE_H_L_BYTES(base_data.x.h, base_data.x.l));
|
||||
temp_report.y = CONSTRAIN_HID_XY(AZOTEQ_IQS5XX_COMBINE_H_L_BYTES(base_data.y.h, base_data.y.l));
|
||||
}
|
||||
|
||||
} else {
|
||||
pd_dprintf("IQS5XX - get report failed, i2c status: %d \n", status);
|
||||
if (base_data.previous_cycle_time > AZOTEQ_IQS5XX_REPORT_RATE) {
|
||||
pd_dprintf("IQS5XX - previous cycle time missed, took: %dms\n", base_data.previous_cycle_time);
|
||||
}
|
||||
#endif
|
||||
if (base_data.gesture_events_0.single_tap || base_data.gesture_events_0.press_and_hold) {
|
||||
pd_dprintf("IQS5XX - Single tap/hold.\n");
|
||||
temp_report.buttons = pointing_device_handle_buttons(temp_report.buttons, true, POINTING_DEVICE_BUTTON1);
|
||||
} else if (base_data.gesture_events_1.two_finger_tap) {
|
||||
pd_dprintf("IQS5XX - Two finger tap.\n");
|
||||
temp_report.buttons = pointing_device_handle_buttons(temp_report.buttons, true, POINTING_DEVICE_BUTTON2);
|
||||
} else if (base_data.gesture_events_0.swipe_x_neg) {
|
||||
pd_dprintf("IQS5XX - X-.\n");
|
||||
temp_report.buttons = pointing_device_handle_buttons(temp_report.buttons, true, POINTING_DEVICE_BUTTON4);
|
||||
ignore_movement = true;
|
||||
} else if (base_data.gesture_events_0.swipe_x_pos) {
|
||||
pd_dprintf("IQS5XX - X+.\n");
|
||||
temp_report.buttons = pointing_device_handle_buttons(temp_report.buttons, true, POINTING_DEVICE_BUTTON5);
|
||||
ignore_movement = true;
|
||||
} else if (base_data.gesture_events_0.swipe_y_neg) {
|
||||
pd_dprintf("IQS5XX - Y-.\n");
|
||||
temp_report.buttons = pointing_device_handle_buttons(temp_report.buttons, true, POINTING_DEVICE_BUTTON6);
|
||||
ignore_movement = true;
|
||||
} else if (base_data.gesture_events_0.swipe_y_pos) {
|
||||
pd_dprintf("IQS5XX - Y+.\n");
|
||||
temp_report.buttons = pointing_device_handle_buttons(temp_report.buttons, true, POINTING_DEVICE_BUTTON3);
|
||||
ignore_movement = true;
|
||||
} else if (base_data.gesture_events_1.zoom) {
|
||||
if (AZOTEQ_IQS5XX_COMBINE_H_L_BYTES(base_data.x.h, base_data.x.l) < 0) {
|
||||
pd_dprintf("IQS5XX - Zoom out.\n");
|
||||
temp_report.buttons = pointing_device_handle_buttons(temp_report.buttons, true, POINTING_DEVICE_BUTTON7);
|
||||
} else if (AZOTEQ_IQS5XX_COMBINE_H_L_BYTES(base_data.x.h, base_data.x.l) > 0) {
|
||||
pd_dprintf("IQS5XX - Zoom in.\n");
|
||||
temp_report.buttons = pointing_device_handle_buttons(temp_report.buttons, true, POINTING_DEVICE_BUTTON8);
|
||||
}
|
||||
} else if (base_data.gesture_events_1.scroll) {
|
||||
pd_dprintf("IQS5XX - Scroll.\n");
|
||||
temp_report.h = CONSTRAIN_HID(AZOTEQ_IQS5XX_COMBINE_H_L_BYTES(base_data.x.h, base_data.x.l));
|
||||
temp_report.v = CONSTRAIN_HID(AZOTEQ_IQS5XX_COMBINE_H_L_BYTES(base_data.y.h, base_data.y.l));
|
||||
}
|
||||
if (base_data.number_of_fingers == 1 && !ignore_movement) {
|
||||
temp_report.x = CONSTRAIN_HID_XY(AZOTEQ_IQS5XX_COMBINE_H_L_BYTES(base_data.x.h, base_data.x.l));
|
||||
temp_report.y = CONSTRAIN_HID_XY(AZOTEQ_IQS5XX_COMBINE_H_L_BYTES(base_data.y.h, base_data.y.l));
|
||||
}
|
||||
|
||||
} else {
|
||||
pd_dprintf("IQS5XX - Init failed, i2c status: %d \n", azoteq_iqs5xx_init_status);
|
||||
pd_dprintf("IQS5XX - get report failed, i2c status: %d \n", status);
|
||||
}
|
||||
|
||||
return temp_report;
|
||||
|
||||
@@ -178,9 +178,9 @@ typedef struct {
|
||||
# define POINTING_DEVICE_TASK_THROTTLE_MS AZOTEQ_IQS5XX_REPORT_RATE + 1
|
||||
#endif
|
||||
|
||||
const pointing_device_driver_t azoteq_iqs5xx_pointing_device_driver;
|
||||
extern const pointing_device_driver_t azoteq_iqs5xx_pointing_device_driver;
|
||||
|
||||
void azoteq_iqs5xx_init(void);
|
||||
bool azoteq_iqs5xx_init(void);
|
||||
i2c_status_t azoteq_iqs5xx_wake(void);
|
||||
report_mouse_t azoteq_iqs5xx_get_report(report_mouse_t mouse_report);
|
||||
i2c_status_t azoteq_iqs5xx_get_report_rate(azoteq_iqs5xx_report_rate_t *report_rate, azoteq_iqs5xx_charging_modes_t mode, bool end_session);
|
||||
|
||||
@@ -18,7 +18,6 @@
|
||||
# endif
|
||||
#endif
|
||||
|
||||
bool touchpad_init;
|
||||
uint16_t scale_data = CIRQUE_PINNACLE_DEFAULT_SCALE;
|
||||
|
||||
void cirque_pinnacle_clear_flags(void);
|
||||
@@ -232,14 +231,14 @@ bool cirque_pinnacle_connected(void) {
|
||||
}
|
||||
|
||||
/* Pinnacle-based TM040040/TM035035/TM023023 Functions */
|
||||
void cirque_pinnacle_init(void) {
|
||||
bool cirque_pinnacle_init(void) {
|
||||
#if defined(POINTING_DEVICE_DRIVER_cirque_pinnacle_spi)
|
||||
spi_init();
|
||||
#elif defined(POINTING_DEVICE_DRIVER_cirque_pinnacle_i2c)
|
||||
i2c_init();
|
||||
#endif
|
||||
|
||||
touchpad_init = true;
|
||||
bool touchpad_init = true;
|
||||
|
||||
// send a RESET command now, in case QMK had a soft-reset without a power cycle
|
||||
RAP_Write(HOSTREG__SYSCONFIG1, HOSTREG__SYSCONFIG1__RESET);
|
||||
@@ -293,6 +292,8 @@ void cirque_pinnacle_init(void) {
|
||||
#ifndef CIRQUE_PINNACLE_SKIP_SENSOR_CHECK
|
||||
touchpad_init = cirque_pinnacle_connected();
|
||||
#endif
|
||||
|
||||
return touchpad_init;
|
||||
}
|
||||
|
||||
pinnacle_data_t cirque_pinnacle_read_data(void) {
|
||||
|
||||
@@ -112,9 +112,9 @@ typedef struct {
|
||||
|
||||
#define cirque_pinnacle_i2c_pointing_device_driver cirque_pinnacle_pointing_device_driver
|
||||
#define cirque_pinnacle_spi_pointing_device_driver cirque_pinnacle_pointing_device_driver
|
||||
const pointing_device_driver_t cirque_pinnacle_pointing_device_driver;
|
||||
extern const pointing_device_driver_t cirque_pinnacle_pointing_device_driver;
|
||||
|
||||
void cirque_pinnacle_init(void);
|
||||
bool cirque_pinnacle_init(void);
|
||||
void cirque_pinnacle_calibrate(void);
|
||||
void cirque_pinnacle_cursor_smoothing(bool enable);
|
||||
pinnacle_data_t cirque_pinnacle_read_data(void);
|
||||
|
||||
@@ -7,29 +7,22 @@
|
||||
#define WRITE_MASK 0x80
|
||||
#define READ_MASK 0xA0
|
||||
|
||||
extern bool touchpad_init;
|
||||
|
||||
/* RAP Functions */
|
||||
// Reads <count> Pinnacle registers starting at <address>
|
||||
void RAP_ReadBytes(uint8_t address, uint8_t* data, uint8_t count) {
|
||||
uint8_t cmdByte = READ_MASK | address; // Form the READ command byte
|
||||
if (touchpad_init) {
|
||||
i2c_write_register(CIRQUE_PINNACLE_ADDR << 1, cmdByte, NULL, 0, CIRQUE_PINNACLE_TIMEOUT);
|
||||
if (i2c_read_register(CIRQUE_PINNACLE_ADDR << 1, cmdByte, data, count, CIRQUE_PINNACLE_TIMEOUT) != I2C_STATUS_SUCCESS) {
|
||||
pd_dprintf("error cirque_pinnacle i2c_read_register\n");
|
||||
touchpad_init = false;
|
||||
}
|
||||
i2c_write_register(CIRQUE_PINNACLE_ADDR << 1, cmdByte, NULL, 0, CIRQUE_PINNACLE_TIMEOUT);
|
||||
if (i2c_read_register(CIRQUE_PINNACLE_ADDR << 1, cmdByte, data, count, CIRQUE_PINNACLE_TIMEOUT) != I2C_STATUS_SUCCESS) {
|
||||
pd_dprintf("error cirque_pinnacle i2c_read_register\n");
|
||||
pointing_device_set_status(POINTING_DEVICE_STATUS_FAILED);
|
||||
}
|
||||
}
|
||||
|
||||
// Writes single-byte <data> to <address>
|
||||
void RAP_Write(uint8_t address, uint8_t data) {
|
||||
uint8_t cmdByte = WRITE_MASK | address; // Form the WRITE command byte
|
||||
|
||||
if (touchpad_init) {
|
||||
if (i2c_write_register(CIRQUE_PINNACLE_ADDR << 1, cmdByte, &data, sizeof(data), CIRQUE_PINNACLE_TIMEOUT) != I2C_STATUS_SUCCESS) {
|
||||
pd_dprintf("error cirque_pinnacle i2c_write_register\n");
|
||||
touchpad_init = false;
|
||||
}
|
||||
if (i2c_write_register(CIRQUE_PINNACLE_ADDR << 1, cmdByte, &data, sizeof(data), CIRQUE_PINNACLE_TIMEOUT) != I2C_STATUS_SUCCESS) {
|
||||
pd_dprintf("error cirque_pinnacle i2c_write_register\n");
|
||||
pointing_device_set_status(POINTING_DEVICE_STATUS_FAILED);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7,40 +7,35 @@
|
||||
#define READ_MASK 0xA0
|
||||
#define FILLER_BYTE 0xFC
|
||||
|
||||
extern bool touchpad_init;
|
||||
|
||||
/* RAP Functions */
|
||||
// Reads <count> Pinnacle registers starting at <address>
|
||||
void RAP_ReadBytes(uint8_t address, uint8_t* data, uint8_t count) {
|
||||
uint8_t cmdByte = READ_MASK | address; // Form the READ command byte
|
||||
if (touchpad_init) {
|
||||
if (spi_start(CIRQUE_PINNACLE_SPI_CS_PIN, CIRQUE_PINNACLE_SPI_LSBFIRST, CIRQUE_PINNACLE_SPI_MODE, CIRQUE_PINNACLE_SPI_DIVISOR)) {
|
||||
spi_write(cmdByte); // write command byte, receive filler
|
||||
spi_write(FILLER_BYTE); // write & receive filler
|
||||
spi_write(FILLER_BYTE); // write & receive filler
|
||||
for (uint8_t i = 0; i < count; i++) {
|
||||
data[i] = spi_write(FILLER_BYTE); // write filler, receive data on the third filler send
|
||||
}
|
||||
} else {
|
||||
pd_dprintf("error cirque_pinnacle spi_start read\n");
|
||||
touchpad_init = false;
|
||||
|
||||
if (spi_start(CIRQUE_PINNACLE_SPI_CS_PIN, CIRQUE_PINNACLE_SPI_LSBFIRST, CIRQUE_PINNACLE_SPI_MODE, CIRQUE_PINNACLE_SPI_DIVISOR)) {
|
||||
spi_write(cmdByte); // write command byte, receive filler
|
||||
spi_write(FILLER_BYTE); // write & receive filler
|
||||
spi_write(FILLER_BYTE); // write & receive filler
|
||||
for (uint8_t i = 0; i < count; i++) {
|
||||
data[i] = spi_write(FILLER_BYTE); // write filler, receive data on the third filler send
|
||||
}
|
||||
spi_stop();
|
||||
} else {
|
||||
pd_dprintf("error cirque_pinnacle spi_start read\n");
|
||||
pointing_device_set_status(POINTING_DEVICE_STATUS_FAILED);
|
||||
}
|
||||
spi_stop();
|
||||
}
|
||||
|
||||
// Writes single-byte <data> to <address>
|
||||
void RAP_Write(uint8_t address, uint8_t data) {
|
||||
uint8_t cmdByte = WRITE_MASK | address; // Form the WRITE command byte
|
||||
|
||||
if (touchpad_init) {
|
||||
if (spi_start(CIRQUE_PINNACLE_SPI_CS_PIN, CIRQUE_PINNACLE_SPI_LSBFIRST, CIRQUE_PINNACLE_SPI_MODE, CIRQUE_PINNACLE_SPI_DIVISOR)) {
|
||||
spi_write(cmdByte);
|
||||
spi_write(data);
|
||||
} else {
|
||||
pd_dprintf("error cirque_pinnacle spi_start write\n");
|
||||
touchpad_init = false;
|
||||
}
|
||||
spi_stop();
|
||||
if (spi_start(CIRQUE_PINNACLE_SPI_CS_PIN, CIRQUE_PINNACLE_SPI_LSBFIRST, CIRQUE_PINNACLE_SPI_MODE, CIRQUE_PINNACLE_SPI_DIVISOR)) {
|
||||
spi_write(cmdByte);
|
||||
spi_write(data);
|
||||
} else {
|
||||
pd_dprintf("error cirque_pinnacle spi_start write\n");
|
||||
pointing_device_set_status(POINTING_DEVICE_STATUS_FAILED);
|
||||
}
|
||||
spi_stop();
|
||||
}
|
||||
|
||||
@@ -58,7 +58,15 @@ const pointing_device_driver_t paw3204_pointing_device_driver = {
|
||||
.get_cpi = paw3204_get_cpi,
|
||||
};
|
||||
|
||||
void paw3204_init(void) {
|
||||
uint8_t read_pid_paw3204(void) {
|
||||
return paw3204_read_reg(REG_PID1);
|
||||
}
|
||||
|
||||
bool __attribute__((weak)) paw3204_check_signature(void) {
|
||||
return (read_pid_paw3204() == 0x30);
|
||||
}
|
||||
|
||||
bool paw3204_init(void) {
|
||||
gpio_set_pin_output(PAW3204_SCLK_PIN); // setclockpin to output
|
||||
gpio_set_pin_input_high(PAW3204_SDIO_PIN); // set datapin input high
|
||||
|
||||
@@ -69,6 +77,8 @@ void paw3204_init(void) {
|
||||
paw3204_read_reg(0x01); // read id2
|
||||
// PAW3204_write_reg(REG_SETUP,0x06); // dont reset sensor and set cpi 1600
|
||||
paw3204_write_reg(REG_IMGTRASH, 0x32); // write image trashhold
|
||||
|
||||
return paw3204_check_signature();
|
||||
}
|
||||
|
||||
uint8_t paw3204_serial_read(void) {
|
||||
@@ -175,10 +185,6 @@ uint16_t paw3204_get_cpi(void) {
|
||||
return cpival;
|
||||
}
|
||||
|
||||
uint8_t read_pid_paw3204(void) {
|
||||
return paw3204_read_reg(REG_PID1);
|
||||
}
|
||||
|
||||
report_mouse_t paw3204_get_report(report_mouse_t mouse_report) {
|
||||
report_paw3204_t data = paw3204_read();
|
||||
if (data.isMotion) {
|
||||
|
||||
@@ -41,7 +41,7 @@ typedef struct {
|
||||
bool isMotion;
|
||||
} report_paw3204_t;
|
||||
|
||||
const pointing_device_driver_t paw3204_pointing_device_driver;
|
||||
extern const pointing_device_driver_t paw3204_pointing_device_driver;
|
||||
|
||||
/**
|
||||
* @brief Initializes the sensor so it is in a working state and ready to
|
||||
@@ -50,7 +50,7 @@ const pointing_device_driver_t paw3204_pointing_device_driver;
|
||||
* @return true Initialization was a success
|
||||
* @return false Initialization failed, do not proceed operation
|
||||
*/
|
||||
void paw3204_init(void);
|
||||
bool paw3204_init(void);
|
||||
|
||||
/**
|
||||
* @brief Reads and clears the current delta, and motion register values on the
|
||||
|
||||
@@ -82,9 +82,12 @@ i2c_status_t read_pimoroni_trackball(pimoroni_data_t *data) {
|
||||
return status;
|
||||
}
|
||||
|
||||
__attribute__((weak)) void pimoroni_trackball_device_init(void) {
|
||||
__attribute__((weak)) bool pimoroni_trackball_device_init(void) {
|
||||
i2c_init();
|
||||
pimoroni_trackball_set_rgbw(0x00, 0x00, 0x00, 0x00);
|
||||
uint8_t rgbw_data[4] = {0};
|
||||
i2c_status_t status = i2c_write_register(PIMORONI_TRACKBALL_ADDRESS << 1, PIMORONI_TRACKBALL_REG_LED_RED, rgbw_data, sizeof(rgbw_data), PIMORONI_TRACKBALL_TIMEOUT);
|
||||
|
||||
return (status == I2C_STATUS_SUCCESS);
|
||||
}
|
||||
|
||||
int16_t pimoroni_trackball_get_offsets(uint8_t negative_dir, uint8_t positive_dir, uint8_t scale) {
|
||||
|
||||
@@ -50,9 +50,9 @@ typedef struct {
|
||||
uint8_t click;
|
||||
} pimoroni_data_t;
|
||||
|
||||
const pointing_device_driver_t pimoroni_trackball_pointing_device_driver;
|
||||
extern const pointing_device_driver_t pimoroni_trackball_pointing_device_driver;
|
||||
|
||||
void pimoroni_trackball_device_init(void);
|
||||
bool pimoroni_trackball_device_init(void);
|
||||
void pimoroni_trackball_set_rgbw(uint8_t red, uint8_t green, uint8_t blue, uint8_t white);
|
||||
int16_t pimoroni_trackball_get_offsets(uint8_t negative_dir, uint8_t positive_dir, uint8_t scale);
|
||||
uint16_t pimoroni_trackball_get_cpi(void);
|
||||
|
||||
@@ -30,7 +30,7 @@ const pointing_device_driver_t pmw3320_pointing_device_drivera = {
|
||||
.get_cpi = pmw3320_get_cpi,
|
||||
};
|
||||
|
||||
void pmw3320_init(void) {
|
||||
bool pmw3320_init(void) {
|
||||
// Initialize sensor serial pins.
|
||||
gpio_set_pin_output(PMW3320_SCLK_PIN);
|
||||
gpio_set_pin_output(PMW3320_SDIO_PIN);
|
||||
@@ -56,6 +56,8 @@ void pmw3320_init(void) {
|
||||
pmw3320_write_reg(REG_Led_Control, 0x4);
|
||||
// Disable rest mode
|
||||
pmw3320_write_reg(REG_Performance, 0x80);
|
||||
|
||||
return pmw3320_check_signature();
|
||||
}
|
||||
|
||||
// Perform a synchronization with sensor.
|
||||
@@ -192,7 +194,7 @@ void pmw3320_set_cpi(uint16_t cpi) {
|
||||
pmw3320_write_reg(REG_Resolution, 0x20 | cpival);
|
||||
}
|
||||
|
||||
bool pmw3320_check_signature(void) {
|
||||
bool __attribute__((weak)) pmw3320_check_signature(void) {
|
||||
uint8_t pid = pmw3320_read_reg(REG_Product_ID);
|
||||
uint8_t pid2 = pmw3320_read_reg(REG_Inverse_Product_ID);
|
||||
|
||||
|
||||
@@ -55,13 +55,13 @@ typedef struct {
|
||||
int8_t dy;
|
||||
} report_pmw3320_t;
|
||||
|
||||
const pointing_device_driver_t pmw3320_pointing_device_driver;
|
||||
extern const pointing_device_driver_t pmw3320_pointing_device_driver;
|
||||
|
||||
// A bunch of functions to implement the PMW3320-specific serial protocol.
|
||||
// Mostly taken from ADNS5050 driver.
|
||||
// Note that the "serial.h" driver is insufficient, because it does not
|
||||
// manually manipulate a serial clock signal.
|
||||
void pmw3320_init(void);
|
||||
bool pmw3320_init(void);
|
||||
void pmw3320_sync(void);
|
||||
uint8_t pmw3320_serial_read(void);
|
||||
void pmw3320_serial_write(uint8_t data);
|
||||
|
||||
@@ -29,4 +29,4 @@ void pmw33xx_set_cpi(uint8_t sensor, uint16_t cpi) {
|
||||
}
|
||||
|
||||
// PID, Inverse PID
|
||||
const uint8_t pmw33xx_firmware_signature[2] PROGMEM = {0x42, 0xBD};
|
||||
const uint8_t pmw33xx_firmware_signature[2] PROGMEM = {0x47, 0xB8};
|
||||
|
||||
@@ -102,7 +102,7 @@ uint8_t pmw33xx_read(uint8_t sensor, uint8_t reg_addr) {
|
||||
return data;
|
||||
}
|
||||
|
||||
bool pmw33xx_check_signature(uint8_t sensor) {
|
||||
__attribute__((weak)) bool pmw33xx_check_signature(uint8_t sensor) {
|
||||
uint8_t signature_dump[2] = {
|
||||
pmw33xx_read(sensor, REG_Product_ID),
|
||||
pmw33xx_read(sensor, REG_Inverse_Product_ID),
|
||||
@@ -236,8 +236,8 @@ pmw33xx_report_t pmw33xx_read_burst(uint8_t sensor) {
|
||||
return report;
|
||||
}
|
||||
|
||||
void pmw33xx_init_wrapper(void) {
|
||||
pmw33xx_init(0);
|
||||
bool pmw33xx_init_wrapper(void) {
|
||||
return pmw33xx_init(0);
|
||||
}
|
||||
|
||||
void pmw33xx_set_cpi_wrapper(uint16_t cpi) {
|
||||
|
||||
@@ -106,7 +106,7 @@ STATIC_ASSERT(sizeof((pmw33xx_report_t){0}.motion) == 1, "pmw33xx_report_t.motio
|
||||
|
||||
#define pmw3360_pointing_device_driver pmw33xx_pointing_device_driver;
|
||||
#define pmw3389_pointing_device_driver pmw33xx_pointing_device_driver;
|
||||
const pointing_device_driver_t pmw33xx_pointing_device_driver;
|
||||
extern const pointing_device_driver_t pmw33xx_pointing_device_driver;
|
||||
|
||||
/**
|
||||
* @brief Initializes the given sensor so it is in a working state and ready to
|
||||
@@ -177,7 +177,7 @@ uint8_t pmw33xx_read(uint8_t sensor, uint8_t reg_addr);
|
||||
*/
|
||||
bool pmw33xx_write(uint8_t sensor, uint8_t reg_addr, uint8_t data);
|
||||
|
||||
void pmw33xx_init_wrapper(void);
|
||||
bool pmw33xx_init_wrapper(void);
|
||||
void pmw33xx_set_cpi_wrapper(uint16_t cpi);
|
||||
uint16_t pmw33xx_get_cpi_wrapper(void);
|
||||
report_mouse_t pmw33xx_get_report(report_mouse_t mouse_report);
|
||||
|
||||
@@ -8,3 +8,4 @@
|
||||
#define I2C_DRIVER I2CD1
|
||||
#define OLED_BRIGHTNESS 128
|
||||
#define OLED_FONT_H "keyboards/1upkeyboards/pi50/lib/glcdfont.c"
|
||||
#define RGB_MATRIX_MODE_NAME_ENABLE
|
||||
|
||||
@@ -18,49 +18,6 @@
|
||||
#include <ctype.h>
|
||||
#include <stdio.h>
|
||||
|
||||
#if defined(RGB_MATRIX_EFFECT)
|
||||
# undef RGB_MATRIX_EFFECT
|
||||
#endif // defined(RGB_MATRIX_EFFECT)
|
||||
|
||||
#define RGB_MATRIX_EFFECT(x) RGB_MATRIX_EFFECT_##x,
|
||||
enum {
|
||||
RGB_MATRIX_EFFECT_NONE,
|
||||
#include "rgb_matrix_effects.inc"
|
||||
#undef RGB_MATRIX_EFFECT
|
||||
#ifdef RGB_MATRIX_CUSTOM_KB
|
||||
# include "rgb_matrix_kb.inc"
|
||||
#endif
|
||||
#ifdef RGB_MATRIX_CUSTOM_USER
|
||||
# include "rgb_matrix_user.inc"
|
||||
#endif
|
||||
#if defined(COMMUNITY_MODULES_ENABLE) && __has_include("rgb_matrix_community_modules.inc")
|
||||
# include "rgb_matrix_community_modules.inc"
|
||||
#endif
|
||||
};
|
||||
|
||||
#define RGB_MATRIX_EFFECT(x) \
|
||||
case RGB_MATRIX_EFFECT_##x: \
|
||||
return #x;
|
||||
const char* rgb_matrix_name(uint8_t effect) {
|
||||
switch (effect) {
|
||||
case RGB_MATRIX_EFFECT_NONE:
|
||||
return "NONE";
|
||||
#include "rgb_matrix_effects.inc"
|
||||
#undef RGB_MATRIX_EFFECT
|
||||
#ifdef RGB_MATRIX_CUSTOM_KB
|
||||
# include "rgb_matrix_kb.inc"
|
||||
#endif
|
||||
#ifdef RGB_MATRIX_CUSTOM_USER
|
||||
# include "rgb_matrix_user.inc"
|
||||
#endif
|
||||
#if defined(COMMUNITY_MODULES_ENABLE) && __has_include("rgb_matrix_community_modules.inc")
|
||||
# include "rgb_matrix_community_modules.inc"
|
||||
#endif
|
||||
default:
|
||||
return "UNKNOWN";
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef OLED_ENABLE
|
||||
|
||||
static uint32_t oled_logo_timer = 0;
|
||||
@@ -154,7 +111,7 @@ void user_oled_magic(void) {
|
||||
oled_write_P(led_state.num_lock ? PSTR("Num(x) ") : PSTR("Num( ) "), false);
|
||||
oled_write_P(led_state.scroll_lock ? PSTR("Scrl(x)") : PSTR("Scrl( )"), false);
|
||||
|
||||
char *mode_name = strdup(rgb_matrix_name(rgb_matrix_get_mode()));
|
||||
char *mode_name = strdup(rgb_matrix_get_mode_name(rgb_matrix_get_mode()));
|
||||
if (mode_name != NULL) {
|
||||
int len = strlen(mode_name);
|
||||
bool capitalize_next = true;
|
||||
|
||||
@@ -89,9 +89,9 @@ bool process_record_kb(uint16_t keycode, keyrecord_t* record) {
|
||||
if (IS_MOUSEKEY_BUTTON(keycode)) {
|
||||
report_mouse_t currentReport = pointing_device_get_report();
|
||||
if (record->event.pressed) {
|
||||
currentReport.buttons |= 1 << (keycode - KC_MS_BTN1);
|
||||
currentReport.buttons |= 1 << (keycode - QK_MOUSE_BUTTON_1);
|
||||
} else {
|
||||
currentReport.buttons &= ~(1 << (keycode - KC_MS_BTN1));
|
||||
currentReport.buttons &= ~(1 << (keycode - QK_MOUSE_BUTTON_1));
|
||||
}
|
||||
pointing_device_set_report(currentReport);
|
||||
pointing_device_send();
|
||||
|
||||
@@ -101,7 +101,7 @@ LAYOUT( /* Tab */
|
||||
KC_ESC, KC_CALC, KC_WHOM, KC_MAIL, KC_MYCM, _______, _______, _______, _______, _______, KC_PSCR, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
_______, LED_TOG, LED_CHG, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, KC_MS_L, KC_MS_D, KC_MS_U, KC_MS_R
|
||||
_______, _______, _______, _______, _______, _______, _______, MS_LEFT, MS_DOWN, MS_UP, MS_RGHT
|
||||
),
|
||||
};
|
||||
|
||||
|
||||
@@ -53,7 +53,7 @@ LAYOUT( /* Tab */
|
||||
KC_ESC, KC_CALC, KC_WHOM, KC_MAIL, KC_MYCM, _______, _______, _______, _______, _______, KC_PSCR, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
_______, UG_TOGG, UG_NEXT, UG_HUEU, UG_HUED, UG_SATU, UG_SATD, UG_VALU, UG_VALD, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, KC_MS_L, KC_MS_D, KC_MS_U, KC_MS_R
|
||||
_______, _______, _______, _______, _______, _______, _______, MS_LEFT, MS_DOWN, MS_UP, MS_RGHT
|
||||
),
|
||||
};
|
||||
|
||||
|
||||
@@ -42,8 +42,7 @@
|
||||
"qmk": {
|
||||
"tap_keycode_delay": 10
|
||||
},
|
||||
"processor": "atmega32u4",
|
||||
"bootloader": "caterina",
|
||||
"development_board": "promicro",
|
||||
"layouts": {
|
||||
"LAYOUT_all": {
|
||||
"layout": [
|
||||
|
||||
@@ -29,13 +29,13 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
[_MAIN] = LAYOUT(
|
||||
//┌────────┬────────┬────────┐┌────────┬────────┬────────┬────────┬────────┬────────┐ ┌────────┬────────┬────────┬────────┬────────┬────────┐┌────────┬────────┬────────┐
|
||||
_______, KC_WH_U, _______, KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, KC_MINS, KC_EQL, KC_GRV,
|
||||
_______, MS_WHLU, _______, KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, KC_MINS, KC_EQL, KC_GRV,
|
||||
//├────────┼────────┼────────┤├────────┼────────┼────────┼────────┼────────┼────────┤ ├────────┼────────┼────────┼────────┼────────┼────────┤├────────┼────────┼────────┤
|
||||
KC_BTN1, KC_WH_D, KC_BTN2, KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_DEL, KC_LBRC, KC_RBRC, KC_BSLS,
|
||||
MS_BTN1, MS_WHLD, MS_BTN2, KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_DEL, KC_LBRC, KC_RBRC, KC_BSLS,
|
||||
//├────────┼────────┼────────┤├────────┼────────┼────────┼────────┼────────┼────────┤ ├────────┼────────┼────────┼────────┼────────┼────────┤├────────┼────────┼────────┤
|
||||
KC_MS_U, KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_UP,
|
||||
MS_UP, KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_UP,
|
||||
//├────────┼────────┼────────┤├────────┼────────┼────────┼────────┼────────┼────────┤ ├────────┼────────┼────────┼────────┼────────┼────────┤├────────┼────────┼────────┤
|
||||
KC_MS_L, KC_MS_D, KC_MS_R, KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_LEFT, KC_DOWN, KC_RIGHT,
|
||||
MS_LEFT, MS_DOWN, MS_RGHT, KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_LEFT, KC_DOWN, KC_RIGHT,
|
||||
//└────────┴────────┴────────┘└────────┴────────┼────────┼────────┼────────┼────────┼────────┐ ┌────────┼────────┼────────┼────────┴────────┴────────┴────────┘└────────┴────────┴────────┘
|
||||
KC_LCTL, KC_LALT, KC_LGUI, KC_SPC, KC_ENT, RAISE, LOWER, XXXXXXX
|
||||
// └────────┴────────┴────────┴────────┘ └────────┴────────┴────────┴────────┘
|
||||
@@ -45,7 +45,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
//┌────────┬────────┬────────┐┌────────┬────────┬────────┬────────┬────────┬────────┐ ┌────────┬────────┬────────┬────────┬────────┬────────┐┌────────┬────────┬────────┐
|
||||
_______, _______, _______, QK_BOOT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_MUTE, KC_VOLD, KC_VOLU,
|
||||
//├────────┼────────┼────────┤├────────┼────────┼────────┼────────┼────────┼────────┤ ├────────┼────────┼────────┼────────┼────────┼────────┤├────────┼────────┼────────┤
|
||||
_______, KC_BTN3, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
_______, MS_BTN3, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
//├────────┼────────┼────────┤├────────┼────────┼────────┼────────┼────────┼────────┤ ├────────┼────────┼────────┼────────┼────────┼────────┤├────────┼────────┼────────┤
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
//├────────┼────────┼────────┤├────────┼────────┼────────┼────────┼────────┼────────┤ ├────────┼────────┼────────┼────────┼────────┼────────┤├────────┼────────┼────────┤
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
"manufacturer": "Louis Dalibard",
|
||||
"keyboard_name": "ai",
|
||||
"maintainer": "make42",
|
||||
"bootloader": "caterina",
|
||||
"development_board": "promicro",
|
||||
"diode_direction": "COL2ROW",
|
||||
"features": {
|
||||
"bootmagic": true,
|
||||
@@ -14,7 +14,6 @@
|
||||
"cols": ["F5", "F6", "F7", "B1"],
|
||||
"rows": ["D0", "D4", "C6", "D7", "D1"]
|
||||
},
|
||||
"processor": "atmega32u4",
|
||||
"usb": {
|
||||
"device_version": "1.0.0",
|
||||
"pid": "0x0000",
|
||||
|
||||
@@ -38,9 +38,9 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
),
|
||||
[2] = LAYOUT( /* Mousekeys and Numpad */
|
||||
KC_NO, _______, _______, _______, _______, _______, _______, KC_NUM, KC_P7, KC_P8, KC_P9, KC_PSLS, _______, _______,
|
||||
KC_NO, _______, KC_BTN1, KC_MS_U, KC_BTN2, KC_WH_U, _______, _______, KC_P4, KC_P5, KC_P6, KC_PAST, _______, _______,
|
||||
TO(1), _______, KC_MS_L, KC_MS_D, KC_MS_R, KC_WH_D, _______, _______, KC_P1, KC_P2, KC_P3, KC_PMNS, _______, _______,
|
||||
TO(1), _______, KC_ACL0, KC_ACL1, KC_ACL2, KC_BTN3, _______, DBLZERO, KC_P0, KC_PDOT, KC_PENT, KC_PPLS, _______, MANUAL,
|
||||
KC_NO, _______, MS_BTN1, MS_UP, MS_BTN2, MS_WHLU, _______, _______, KC_P4, KC_P5, KC_P6, KC_PAST, _______, _______,
|
||||
TO(1), _______, MS_LEFT, MS_DOWN, MS_RGHT, MS_WHLD, _______, _______, KC_P1, KC_P2, KC_P3, KC_PMNS, _______, _______,
|
||||
TO(1), _______, MS_ACL0, MS_ACL1, MS_ACL2, MS_BTN3, _______, DBLZERO, KC_P0, KC_PDOT, KC_PENT, KC_PPLS, _______, MANUAL,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
|
||||
)
|
||||
};
|
||||
|
||||
@@ -38,7 +38,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
KC_ESC , QK_BOOT, _______ , _______ , _______ , _______ , _______ , _______ , _______ , _______ , _______ , _______ ,
|
||||
_______ , KC_F11 , KC_F12 , KC_F13 , KC_F14 , KC_F15 , KC_F16 , KC_F17 , KC_F18 , KC_F19 , KC_F20 , _______ ,
|
||||
_______ , KC_F1 , KC_F2 , KC_F3 , KC_F4 , KC_F5 , KC_F6 , KC_F7 , KC_F8 , KC_F9 , KC_F10 , _______ ,
|
||||
_______ , _______ , _______ , _______ , _______ , _______ , _______ , KC_MS_L , KC_MS_D , KC_MS_U , KC_MS_R , _______
|
||||
_______ , _______ , _______ , _______ , _______ , _______ , _______ , MS_LEFT , MS_DOWN , MS_UP , MS_RGHT , _______
|
||||
),
|
||||
};
|
||||
|
||||
|
||||
@@ -125,24 +125,15 @@ const snled27351_led_t PROGMEM g_snled27351_leds[SNLED27351_LED_COUNT] = {
|
||||
};
|
||||
#endif // RGB_MATRIX_ENABLE
|
||||
|
||||
enum __layers {
|
||||
WIN_B,
|
||||
WIN_W,
|
||||
WIN_FN,
|
||||
MAC_B,
|
||||
MAC_W,
|
||||
MAC_FN,
|
||||
};
|
||||
|
||||
// clang-format on
|
||||
|
||||
void matrix_init_kb(void) {
|
||||
void keyboard_post_init_kb(void) {
|
||||
gpio_set_pin_output(LED_MAC_OS_PIN); // LDE2 MAC\WIN
|
||||
gpio_write_pin_low(LED_MAC_OS_PIN);
|
||||
gpio_set_pin_output(LED_WIN_LOCK_PIN); // LED3 Win Lock
|
||||
gpio_write_pin_low(LED_WIN_LOCK_PIN);
|
||||
|
||||
matrix_init_user();
|
||||
keyboard_post_init_user();
|
||||
}
|
||||
|
||||
void housekeeping_task_kb(void){
|
||||
@@ -155,18 +146,6 @@ bool process_record_kb(uint16_t keycode, keyrecord_t* record) {
|
||||
return false;
|
||||
}
|
||||
switch (keycode) {
|
||||
case DF(WIN_B):
|
||||
if (record->event.pressed) {
|
||||
set_single_persistent_default_layer(WIN_B);
|
||||
}
|
||||
return false;
|
||||
case DF(MAC_B):
|
||||
if (record->event.pressed) {
|
||||
set_single_persistent_default_layer(MAC_B);
|
||||
keymap_config.no_gui = 0;
|
||||
eeconfig_update_keymap(&keymap_config);
|
||||
}
|
||||
return false;
|
||||
case QK_RGB_MATRIX_TOGGLE:
|
||||
if (record->event.pressed) {
|
||||
switch (rgb_matrix_get_flags()) {
|
||||
|
||||
@@ -7,8 +7,12 @@
|
||||
"vid": "0xFFFE",
|
||||
"pid": "0x000C",
|
||||
"device_version": "1.0.4",
|
||||
"suspend_wakeup_delay": 400,
|
||||
"force_nkro": true
|
||||
"suspend_wakeup_delay": 400
|
||||
},
|
||||
"host": {
|
||||
"default": {
|
||||
"nkro": true
|
||||
}
|
||||
},
|
||||
"processor": "WB32FQ95",
|
||||
"bootloader": "wb32-dfu",
|
||||
|
||||
@@ -48,7 +48,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
[WIN_FN] = LAYOUT_tkl_ansi( /* FN */
|
||||
_______, KC_MYCM, KC_MAIL, KC_WSCH, KC_WHOM, KC_MSEL, KC_MPLY, KC_MPRV, KC_MNXT, _______,_______, _______, _______, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, RM_SPDD, RM_SPDU, _______, _______, _______, _______,
|
||||
_______, _______,TG(WIN_W),_______, _______, _______, _______, _______, _______, DF(MAC_B),_______,_______, _______, RM_NEXT, _______, _______, _______,
|
||||
_______, _______,TG(WIN_W),_______, _______, _______, _______, _______, _______, PDF(MAC_B),_______,_______, _______, RM_NEXT, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, RM_TOGG, _______, _______, RM_HUEU,
|
||||
_______, _______, _______, KC_CALC, _______, _______, _______, KC_MUTE, KC_VOLD, KC_VOLU, _______, _______, RM_VALU,
|
||||
_______, GU_TOGG, _______, _______, _______, _______, _______, _______, RM_SATD, RM_VALD, RM_SATU),
|
||||
@@ -71,7 +71,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
[MAC_FN] = LAYOUT_tkl_ansi( /* FN */
|
||||
KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, _______, _______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, RM_SPDD, RM_SPDU, _______, _______, _______, _______,
|
||||
_______, _______,TG(MAC_W),_______, _______, _______, _______, _______, _______, DF(WIN_B),_______,_______, _______, RM_NEXT, _______, _______, _______,
|
||||
_______, _______,TG(MAC_W),_______, _______, _______, _______, _______, _______, PDF(WIN_B),_______,_______, _______, RM_NEXT, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, RM_TOGG, _______, _______, RM_HUEU,
|
||||
_______, _______, _______, KC_CALC, _______, _______, _______, KC_MUTE, KC_VOLD, KC_VOLU, _______, _______, RM_VALU,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, RM_SATD, RM_VALD, RM_SATU)
|
||||
|
||||
@@ -7,8 +7,12 @@
|
||||
"vid": "0xFFFE",
|
||||
"pid": "0x000D",
|
||||
"device_version": "1.0.3",
|
||||
"suspend_wakeup_delay": 400,
|
||||
"force_nkro": true
|
||||
"suspend_wakeup_delay": 400
|
||||
},
|
||||
"host": {
|
||||
"default": {
|
||||
"nkro": true
|
||||
}
|
||||
},
|
||||
"processor": "WB32FQ95",
|
||||
"bootloader": "wb32-dfu",
|
||||
|
||||
@@ -7,8 +7,12 @@
|
||||
"vid": "0xFFFE",
|
||||
"pid": "0x0010",
|
||||
"device_version": "1.0.1",
|
||||
"suspend_wakeup_delay": 400,
|
||||
"force_nkro": true
|
||||
"suspend_wakeup_delay": 400
|
||||
},
|
||||
"host": {
|
||||
"default": {
|
||||
"nkro": true
|
||||
}
|
||||
},
|
||||
"processor": "WB32FQ95",
|
||||
"bootloader": "wb32-dfu",
|
||||
|
||||
@@ -7,8 +7,12 @@
|
||||
"vid": "0xFFFE",
|
||||
"pid": "0x000E",
|
||||
"device_version": "1.0.2",
|
||||
"suspend_wakeup_delay": 400,
|
||||
"force_nkro": true
|
||||
"suspend_wakeup_delay": 400
|
||||
},
|
||||
"host": {
|
||||
"default": {
|
||||
"nkro": true
|
||||
}
|
||||
},
|
||||
"processor": "WB32FQ95",
|
||||
"bootloader": "wb32-dfu",
|
||||
|
||||
@@ -1,19 +0,0 @@
|
||||
/*
|
||||
Copyright 2021 Spencer Deven <splitlogicdesign@gmail.com>
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
#define SELECT_SOFT_SERIAL_SPEED 1
|
||||
@@ -71,8 +71,7 @@
|
||||
"pin": "D3"
|
||||
}
|
||||
},
|
||||
"processor": "atmega32u4",
|
||||
"bootloader": "caterina",
|
||||
"development_board": "promicro",
|
||||
"layouts": {
|
||||
"LAYOUT": {
|
||||
"layout": [
|
||||
|
||||
@@ -45,8 +45,7 @@
|
||||
"rows": ["D4", "B4", "B5"]
|
||||
},
|
||||
"diode_direction": "COL2ROW",
|
||||
"processor": "atmega32u4",
|
||||
"bootloader": "caterina",
|
||||
"development_board": "promicro",
|
||||
"layouts": {
|
||||
"LAYOUT": {
|
||||
"layout": [
|
||||
|
||||
@@ -5,8 +5,12 @@
|
||||
"usb": {
|
||||
"vid": "0x00D8",
|
||||
"pid": "0x6068",
|
||||
"device_version": "0.0.1",
|
||||
"force_nkro": true
|
||||
"device_version": "0.0.1"
|
||||
},
|
||||
"host": {
|
||||
"default": {
|
||||
"nkro": true
|
||||
}
|
||||
},
|
||||
"features": {
|
||||
"backlight": true,
|
||||
|
||||
@@ -15,8 +15,7 @@
|
||||
"rows": ["E6", "B3"]
|
||||
},
|
||||
"diode_direction": "COL2ROW",
|
||||
"processor": "atmega32u4",
|
||||
"bootloader": "caterina",
|
||||
"development_board": "promicro",
|
||||
"layouts": {
|
||||
"LAYOUT": {
|
||||
"layout": [
|
||||
|
||||
@@ -25,8 +25,7 @@
|
||||
"qmk": {
|
||||
"tap_keycode_delay": 50
|
||||
},
|
||||
"processor": "atmega32u4",
|
||||
"bootloader": "caterina",
|
||||
"development_board": "promicro",
|
||||
"layouts": {
|
||||
"LAYOUT": {
|
||||
"layout": [
|
||||
|
||||
@@ -31,8 +31,7 @@
|
||||
"ws2812": {
|
||||
"pin": "D3"
|
||||
},
|
||||
"processor": "atmega32u4",
|
||||
"bootloader": "caterina",
|
||||
"development_board": "promicro",
|
||||
"layouts": {
|
||||
"LAYOUT": {
|
||||
"layout": [
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user