forked from mirror/qmk_firmware
Compare commits
203 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2e68ddc826 | ||
|
|
c1fedab457 | ||
|
|
2929448605 | ||
|
|
b39661de96 | ||
|
|
ff75bce86a | ||
|
|
0881e0867b | ||
|
|
e6e66a9f2e | ||
|
|
e2d19eda57 | ||
|
|
73a6496516 | ||
|
|
c8f6e6a936 | ||
|
|
a86322e4a7 | ||
|
|
505e5c7033 | ||
|
|
107812ceef | ||
|
|
de8f05b4c3 | ||
|
|
08e5fcfdf4 | ||
|
|
1322922c42 | ||
|
|
16dde871d7 | ||
|
|
d39015a401 | ||
|
|
bf0b88c423 | ||
|
|
d4f04fe850 | ||
|
|
b315b707e6 | ||
|
|
e10429baae | ||
|
|
0e6b73c9ff | ||
|
|
d45b967cf2 | ||
|
|
e2bf515df4 | ||
|
|
2cac8b587f | ||
|
|
d383e93526 | ||
|
|
83b42ea9dc | ||
|
|
43bbb5e99a | ||
|
|
ee60542bd6 | ||
|
|
6ed61c65dd | ||
|
|
b5dfb2bd1e | ||
|
|
ee44cbdedb | ||
|
|
330a8597f8 | ||
|
|
9acd127cc1 | ||
|
|
9c2ca00074 | ||
|
|
9ab8e4cd5a | ||
|
|
594558ec7b | ||
|
|
5e1b1f5023 | ||
|
|
bbccd8f9cc | ||
|
|
cc567c917b | ||
|
|
1a954e8da5 | ||
|
|
c7e17538ee | ||
|
|
b321789d7b | ||
|
|
4015c40ba4 | ||
|
|
53de903fb8 | ||
|
|
fd65390496 | ||
|
|
28a11ff6f7 | ||
|
|
1a7f544e0d | ||
|
|
3e0b22af68 | ||
|
|
7edb4d2ed8 | ||
|
|
81cc69c2dd | ||
|
|
93274019a9 | ||
|
|
0fde9c9cac | ||
|
|
b708a43730 | ||
|
|
5bb7476400 | ||
|
|
8eebc613cf | ||
|
|
a2adc92066 | ||
|
|
6242c09f7d | ||
|
|
224ea2eb18 | ||
|
|
eb5703d12e | ||
|
|
921c0039f4 | ||
|
|
bb2ca21647 | ||
|
|
1a4af3adf9 | ||
|
|
99b1dc84da | ||
|
|
98504424b1 | ||
|
|
8ec3de0f92 | ||
|
|
c68e4dec10 | ||
|
|
1ddcf57382 | ||
|
|
e06d79e9c6 | ||
|
|
ed343ddad4 | ||
|
|
019cba746d | ||
|
|
e7ad19bb95 | ||
|
|
28eeb92f8e | ||
|
|
efc5d63383 | ||
|
|
2af9aac61c | ||
|
|
024c4ef853 | ||
|
|
fb6d7762b9 | ||
|
|
6e35013bc2 | ||
|
|
cf05c7d1e4 | ||
|
|
4b393a1ff5 | ||
|
|
01952bf39a | ||
|
|
1a991ffd24 | ||
|
|
01d81b9550 | ||
|
|
a00177d172 | ||
|
|
b905c246b5 | ||
|
|
547d75145b | ||
|
|
f1ec600fac | ||
|
|
c67e4c2cae | ||
|
|
5ba424ca17 | ||
|
|
e7012f4d9e | ||
|
|
8c93a33cd3 | ||
|
|
6aade0ecdc | ||
|
|
ce43c98b65 | ||
|
|
acd7ad37e6 | ||
|
|
cbd55b7890 | ||
|
|
dadbec4d46 | ||
|
|
cb3149b7f2 | ||
|
|
64c84e64c7 | ||
|
|
a05306d153 | ||
|
|
946d651f57 | ||
|
|
7ea7930b8c | ||
|
|
e91938088a | ||
|
|
81df543086 | ||
|
|
4f21beb715 | ||
|
|
18051f1723 | ||
|
|
3eb8d3bea3 | ||
|
|
f4068dbfb0 | ||
|
|
08405df150 | ||
|
|
3c751f217a | ||
|
|
9f1a7380ab | ||
|
|
7dca4e8bda | ||
|
|
0aae222ab6 | ||
|
|
475cbd24cf | ||
|
|
81a3249e2c | ||
|
|
0550830909 | ||
|
|
8f86f9794e | ||
|
|
e7d861aea7 | ||
|
|
02cf2b56fd | ||
|
|
5d26dcefa0 | ||
|
|
c7ed9038d7 | ||
|
|
7a69c714b4 | ||
|
|
074c49ee1c | ||
|
|
466e0856f5 | ||
|
|
60cf3c22f7 | ||
|
|
05355bc49d | ||
|
|
74ac4120db | ||
|
|
9a77ad69e6 | ||
|
|
187119ed7f | ||
|
|
fecfc0f7da | ||
|
|
36fd2437b0 | ||
|
|
bbd6e8ab34 | ||
|
|
24bc4aef03 | ||
|
|
532fb2f960 | ||
|
|
6f93a86e6e | ||
|
|
0a4c1caf20 | ||
|
|
883465d9fb | ||
|
|
115bf771a8 | ||
|
|
a4b112b1ef | ||
|
|
d1b0397d2f | ||
|
|
46231df62d | ||
|
|
b6310b5a15 | ||
|
|
d34cade5ab | ||
|
|
cf58a8733d | ||
|
|
3320e98ccf | ||
|
|
319da7bfdb | ||
|
|
4a4e4aa083 | ||
|
|
74b0f054c1 | ||
|
|
6eee1940e8 | ||
|
|
626cf94653 | ||
|
|
494a691f4c | ||
|
|
f8d677af88 | ||
|
|
461a1afe57 | ||
|
|
d4fb67fd5b | ||
|
|
3cd8dd6b25 | ||
|
|
a4d10e9f64 | ||
|
|
286947b6fa | ||
|
|
f12902eb16 | ||
|
|
0351b598f9 | ||
|
|
c113250c4e | ||
|
|
633479ced5 | ||
|
|
a91de72246 | ||
|
|
50edd425f7 | ||
|
|
514175848e | ||
|
|
7caef16edd | ||
|
|
ff8db0449e | ||
|
|
7772f47f04 | ||
|
|
ab61d9cb51 | ||
|
|
649bbdeaba | ||
|
|
eda39f4356 | ||
|
|
c3ba5de928 | ||
|
|
592ee1b57f | ||
|
|
db9b295aa7 | ||
|
|
3934a7f3c8 | ||
|
|
ed2de21603 | ||
|
|
04978d490a | ||
|
|
7186a63172 | ||
|
|
ff1900190c | ||
|
|
2818085d3f | ||
|
|
d17671cd23 | ||
|
|
8f22831f01 | ||
|
|
6c96bb5a5a | ||
|
|
177ff71d0c | ||
|
|
c1b428bb4e | ||
|
|
0828fc4b6f | ||
|
|
1e8de37aa0 | ||
|
|
9cd3080e22 | ||
|
|
ceefde5ec8 | ||
|
|
3a29cdbd7d | ||
|
|
2d5cb23503 | ||
|
|
6aa85699a5 | ||
|
|
330d195f9a | ||
|
|
4b1b83f42f | ||
|
|
f749dedb0d | ||
|
|
e01313e7d0 | ||
|
|
4bd5c033c3 | ||
|
|
5830b1b5e3 | ||
|
|
bcc546aa3f | ||
|
|
19527e8399 | ||
|
|
d8ce8cd204 | ||
|
|
248d7c1d6d | ||
|
|
9455c6adec | ||
|
|
6619ea4441 |
2
.github/workflows/api.yml
vendored
2
.github/workflows/api.yml
vendored
@@ -25,7 +25,7 @@ jobs:
|
||||
if: github.repository == 'qmk/qmk_firmware'
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v5
|
||||
- uses: actions/checkout@v6
|
||||
with:
|
||||
fetch-depth: 1
|
||||
persist-credentials: false
|
||||
|
||||
2
.github/workflows/auto_tag.yml
vendored
2
.github/workflows/auto_tag.yml
vendored
@@ -28,7 +28,7 @@ jobs:
|
||||
if: github.repository == 'qmk/qmk_firmware'
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v5
|
||||
- uses: actions/checkout@v6
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
|
||||
247
.github/workflows/bootstrap_testing.yml
vendored
Normal file
247
.github/workflows/bootstrap_testing.yml
vendored
Normal file
@@ -0,0 +1,247 @@
|
||||
name: Bootstrap Script Testing
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [master, develop, xap]
|
||||
paths:
|
||||
- "util/env-bootstrap.sh"
|
||||
- ".github/workflows/bootstrap_testing.yml"
|
||||
pull_request:
|
||||
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
|
||||
- debian:13
|
||||
- ubuntu:20.04
|
||||
- ubuntu:22.04
|
||||
- ubuntu:24.04
|
||||
|
||||
# RHEL/CentOS/Fedora based
|
||||
- fedora:41
|
||||
- fedora:42
|
||||
- fedora:43
|
||||
- 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
|
||||
|
||||
# Gentoo-based
|
||||
- gentoo/stage3:latest
|
||||
|
||||
# Arch based
|
||||
- archlinux:latest
|
||||
- cachyos/cachyos:latest
|
||||
- manjarolinux/base:latest
|
||||
|
||||
container:
|
||||
image: ${{ matrix.distribution }}
|
||||
options: --privileged
|
||||
|
||||
steps:
|
||||
- name: Install base dependencies
|
||||
run: |
|
||||
# Attempt to run the package installation up to 10 times to mitigate transient network issues
|
||||
for n in $(seq 1 10); do
|
||||
{
|
||||
echo "Attempt #$n of 10 to install base dependencies:"
|
||||
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
|
||||
;;
|
||||
*gentoo*)
|
||||
emerge-webrsync
|
||||
emerge --noreplace --ask=n sudo dev-vcs/git shadow findutils # findutils=xargs
|
||||
;;
|
||||
*archlinux*|*cachyos*|*manjaro*)
|
||||
pacman -Syu --noconfirm
|
||||
pacman -S --noconfirm sudo git
|
||||
;;
|
||||
esac
|
||||
} && break || sleep 10
|
||||
done
|
||||
|
||||
# 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@v6
|
||||
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 || true
|
||||
|
||||
# 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
|
||||
cd /home/testuser/qmk_firmware
|
||||
qmk mass-compile -j $(nproc) -e DUMP_CI_METADATA=yes -f 'keyboard_name==*onekey*' -km reset -p || 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-14 # Apple Silicon ARM64
|
||||
- macos-15 # Apple Silicon ARM64
|
||||
- macos-15-intel # Intel x64
|
||||
- macos-26 # Apple Silicon ARM64
|
||||
|
||||
runs-on: ${{ matrix.os }}
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v6
|
||||
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@v6
|
||||
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
|
||||
|
||||
4
.github/workflows/ci_build_major_branch.yml
vendored
4
.github/workflows/ci_build_major_branch.yml
vendored
@@ -45,7 +45,7 @@ jobs:
|
||||
git config --global --add safe.directory '*'
|
||||
|
||||
- name: Checkout QMK Firmware
|
||||
uses: actions/checkout@v5
|
||||
uses: actions/checkout@v6
|
||||
|
||||
- name: Determine concurrency
|
||||
id: generate_slice_length
|
||||
@@ -82,7 +82,7 @@ jobs:
|
||||
git config --global --add safe.directory '*'
|
||||
|
||||
- name: Checkout QMK Firmware
|
||||
uses: actions/checkout@v5
|
||||
uses: actions/checkout@v6
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
|
||||
@@ -37,7 +37,7 @@ jobs:
|
||||
git config --global --add safe.directory '*'
|
||||
|
||||
- name: Checkout QMK Firmware
|
||||
uses: actions/checkout@v5
|
||||
uses: actions/checkout@v6
|
||||
|
||||
- name: Generate build targets
|
||||
id: generate_targets
|
||||
@@ -89,7 +89,7 @@ jobs:
|
||||
git config --global --add safe.directory '*'
|
||||
|
||||
- name: Checkout QMK Firmware
|
||||
uses: actions/checkout@v5
|
||||
uses: actions/checkout@v6
|
||||
|
||||
- name: Get target definitions
|
||||
uses: actions/download-artifact@v6
|
||||
@@ -136,7 +136,7 @@ jobs:
|
||||
|
||||
steps:
|
||||
- name: Checkout QMK Firmware
|
||||
uses: actions/checkout@v5
|
||||
uses: actions/checkout@v6
|
||||
|
||||
- name: Download firmwares
|
||||
uses: actions/download-artifact@v6
|
||||
|
||||
2
.github/workflows/cli.yml
vendored
2
.github/workflows/cli.yml
vendored
@@ -24,7 +24,7 @@ jobs:
|
||||
- name: Disable safe.directory check
|
||||
run : git config --global --add safe.directory '*'
|
||||
|
||||
- uses: actions/checkout@v5
|
||||
- uses: actions/checkout@v6
|
||||
with:
|
||||
submodules: recursive
|
||||
|
||||
|
||||
34
.github/workflows/develop_docs.yml
vendored
Normal file
34
.github/workflows/develop_docs.yml
vendored
Normal file
@@ -0,0 +1,34 @@
|
||||
name: Generate Develop Docs
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- develop
|
||||
paths:
|
||||
- 'builddefs/docsgen/**'
|
||||
- 'tmk_core/**'
|
||||
- 'quantum/**'
|
||||
- 'platforms/**'
|
||||
- 'docs/**'
|
||||
- '.github/workflows/docs.yml'
|
||||
|
||||
jobs:
|
||||
generate:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Deploy Develop
|
||||
if: ${{ github.repository == 'qmk/qmk_firmware' }}
|
||||
uses: actions/github-script@v8
|
||||
with:
|
||||
github-token: ${{ secrets.QMK_BOT_TOKEN }}
|
||||
script: |
|
||||
const result = await github.rest.actions.createWorkflowDispatch({
|
||||
owner: 'qmk',
|
||||
repo: 'qmk_docs_devel',
|
||||
workflow_id: 'develop.yml',
|
||||
ref: 'main',
|
||||
})
|
||||
2
.github/workflows/develop_update.yml
vendored
2
.github/workflows/develop_update.yml
vendored
@@ -15,7 +15,7 @@ jobs:
|
||||
if: github.repository == 'qmk/qmk_firmware'
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v5
|
||||
- uses: actions/checkout@v6
|
||||
with:
|
||||
token: ${{ secrets.QMK_BOT_TOKEN }}
|
||||
fetch-depth: 0
|
||||
|
||||
4
.github/workflows/docs.yml
vendored
4
.github/workflows/docs.yml
vendored
@@ -30,7 +30,7 @@ jobs:
|
||||
container: ghcr.io/qmk/qmk_cli
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v5
|
||||
- uses: actions/checkout@v6
|
||||
with:
|
||||
fetch-depth: 1
|
||||
|
||||
@@ -56,7 +56,7 @@ jobs:
|
||||
|
||||
- name: Deploy
|
||||
if: ${{ github.event_name == 'push' && github.repository == 'qmk/qmk_firmware' }}
|
||||
uses: JamesIves/github-pages-deploy-action@v4.7.4
|
||||
uses: JamesIves/github-pages-deploy-action@v4.7.6
|
||||
with:
|
||||
token: ${{ secrets.GITHUB_TOKEN }}
|
||||
branch: gh-pages
|
||||
|
||||
2
.github/workflows/feature_branch_update.yml
vendored
2
.github/workflows/feature_branch_update.yml
vendored
@@ -21,7 +21,7 @@ jobs:
|
||||
- riot
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v5
|
||||
- uses: actions/checkout@v6
|
||||
with:
|
||||
token: ${{ secrets.QMK_BOT_TOKEN }}
|
||||
fetch-depth: 0
|
||||
|
||||
2
.github/workflows/format.yml
vendored
2
.github/workflows/format.yml
vendored
@@ -26,7 +26,7 @@ jobs:
|
||||
- name: Disable safe.directory check
|
||||
run : git config --global --add safe.directory '*'
|
||||
|
||||
- uses: actions/checkout@v5
|
||||
- uses: actions/checkout@v6
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
|
||||
4
.github/workflows/format_push.yml
vendored
4
.github/workflows/format_push.yml
vendored
@@ -19,7 +19,7 @@ jobs:
|
||||
- name: Disable safe.directory check
|
||||
run : git config --global --add safe.directory '*'
|
||||
|
||||
- uses: actions/checkout@v5
|
||||
- uses: actions/checkout@v6
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
@@ -47,7 +47,7 @@ jobs:
|
||||
git config user.email 'hello@qmk.fm'
|
||||
|
||||
- name: Create Pull Request
|
||||
uses: peter-evans/create-pull-request@v7
|
||||
uses: peter-evans/create-pull-request@v8
|
||||
if: ${{ github.repository == 'qmk/qmk_firmware'}}
|
||||
with:
|
||||
token: ${{ secrets.QMK_BOT_TOKEN }}
|
||||
|
||||
2
.github/workflows/lint.yml
vendored
2
.github/workflows/lint.yml
vendored
@@ -18,7 +18,7 @@ jobs:
|
||||
- name: Disable safe.directory check
|
||||
run : git config --global --add safe.directory '*'
|
||||
|
||||
- uses: actions/checkout@v5
|
||||
- uses: actions/checkout@v6
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
|
||||
2
.github/workflows/regen.yml
vendored
2
.github/workflows/regen.yml
vendored
@@ -19,7 +19,7 @@ jobs:
|
||||
- name: Disable safe.directory check
|
||||
run : git config --global --add safe.directory '*'
|
||||
|
||||
- uses: actions/checkout@v5
|
||||
- uses: actions/checkout@v6
|
||||
|
||||
- name: Run qmk generators
|
||||
run: |
|
||||
|
||||
4
.github/workflows/regen_push.yml
vendored
4
.github/workflows/regen_push.yml
vendored
@@ -19,7 +19,7 @@ jobs:
|
||||
- name: Disable safe.directory check
|
||||
run : git config --global --add safe.directory '*'
|
||||
|
||||
- uses: actions/checkout@v5
|
||||
- uses: actions/checkout@v6
|
||||
|
||||
- name: Run qmk generators
|
||||
run: |
|
||||
@@ -34,7 +34,7 @@ jobs:
|
||||
git config user.email 'hello@qmk.fm'
|
||||
|
||||
- name: Create Pull Request
|
||||
uses: peter-evans/create-pull-request@v7
|
||||
uses: peter-evans/create-pull-request@v8
|
||||
if: ${{ github.repository == 'qmk/qmk_firmware'}}
|
||||
with:
|
||||
token: ${{ secrets.QMK_BOT_TOKEN }}
|
||||
|
||||
2
.github/workflows/unit_test.yml
vendored
2
.github/workflows/unit_test.yml
vendored
@@ -26,7 +26,7 @@ jobs:
|
||||
container: ghcr.io/qmk/qmk_cli
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v5
|
||||
- uses: actions/checkout@v6
|
||||
with:
|
||||
submodules: recursive
|
||||
- name: Install dependencies
|
||||
|
||||
@@ -19,18 +19,18 @@ endif
|
||||
ifneq ($(QMK_USERSPACE),)
|
||||
ifneq ("$(wildcard $(QMK_USERSPACE)/$(MAIN_KEYMAP_PATH_5)/keymap.json)","")
|
||||
KEYMAP_JSON := $(QMK_USERSPACE)/$(MAIN_KEYMAP_PATH_5)/keymap.json
|
||||
KEYMAP_PATH := $(QMK_USERSPACE)/$(MAIN_KEYMAP_PATH_5)
|
||||
KEYMAP_JSON_PATH := $(QMK_USERSPACE)/$(MAIN_KEYMAP_PATH_5)
|
||||
else ifneq ("$(wildcard $(QMK_USERSPACE)/$(MAIN_KEYMAP_PATH_4)/keymap.json)","")
|
||||
KEYMAP_JSON := $(QMK_USERSPACE)/$(MAIN_KEYMAP_PATH_4)/keymap.json
|
||||
KEYMAP_PATH := $(QMK_USERSPACE)/$(MAIN_KEYMAP_PATH_4)
|
||||
KEYMAP_JSON_PATH := $(QMK_USERSPACE)/$(MAIN_KEYMAP_PATH_4)
|
||||
else ifneq ("$(wildcard $(QMK_USERSPACE)/$(MAIN_KEYMAP_PATH_3)/keymap.json)","")
|
||||
KEYMAP_JSON := $(QMK_USERSPACE)/$(MAIN_KEYMAP_PATH_3)/keymap.json
|
||||
KEYMAP_PATH := $(QMK_USERSPACE)/$(MAIN_KEYMAP_PATH_3)
|
||||
KEYMAP_JSON_PATH := $(QMK_USERSPACE)/$(MAIN_KEYMAP_PATH_3)
|
||||
else ifneq ("$(wildcard $(QMK_USERSPACE)/$(MAIN_KEYMAP_PATH_2)/keymap.json)","")
|
||||
KEYMAP_JSON := $(QMK_USERSPACE)/$(MAIN_KEYMAP_PATH_2)/keymap.json
|
||||
KEYMAP_PATH := $(QMK_USERSPACE)/$(MAIN_KEYMAP_PATH_2)
|
||||
KEYMAP_JSON_PATH := $(QMK_USERSPACE)/$(MAIN_KEYMAP_PATH_2)
|
||||
else ifneq ("$(wildcard $(QMK_USERSPACE)/$(MAIN_KEYMAP_PATH_1)/keymap.json)","")
|
||||
KEYMAP_JSON := $(QMK_USERSPACE)/$(MAIN_KEYMAP_PATH_1)/keymap.json
|
||||
KEYMAP_PATH := $(QMK_USERSPACE)/$(MAIN_KEYMAP_PATH_1)
|
||||
KEYMAP_JSON_PATH := $(QMK_USERSPACE)/$(MAIN_KEYMAP_PATH_1)
|
||||
endif
|
||||
endif
|
||||
|
||||
@@ -255,6 +255,8 @@ endif
|
||||
COMMUNITY_RULES_MK = $(shell $(QMK_BIN) generate-community-modules-rules-mk -kb $(KEYBOARD) --quiet --escape --output $(INTERMEDIATE_OUTPUT)/src/community_rules.mk $(KEYMAP_JSON))
|
||||
include $(COMMUNITY_RULES_MK)
|
||||
|
||||
ifneq ($(COMMUNITY_MODULES),)
|
||||
|
||||
$(INTERMEDIATE_OUTPUT)/src/community_modules.h: $(KEYMAP_JSON) $(DD_CONFIG_FILES)
|
||||
@$(SILENT) || printf "$(MSG_GENERATING) $@" | $(AWK_CMD)
|
||||
$(eval CMD=$(QMK_BIN) generate-community-modules-h -kb $(KEYBOARD) --quiet --output $(INTERMEDIATE_OUTPUT)/src/community_modules.h $(KEYMAP_JSON))
|
||||
@@ -289,6 +291,8 @@ SRC += $(INTERMEDIATE_OUTPUT)/src/community_modules.c
|
||||
|
||||
generated-files: $(INTERMEDIATE_OUTPUT)/src/community_modules.h $(INTERMEDIATE_OUTPUT)/src/community_modules.c $(INTERMEDIATE_OUTPUT)/src/community_modules_introspection.c $(INTERMEDIATE_OUTPUT)/src/community_modules_introspection.h $(INTERMEDIATE_OUTPUT)/src/led_matrix_community_modules.inc $(INTERMEDIATE_OUTPUT)/src/rgb_matrix_community_modules.inc
|
||||
|
||||
endif
|
||||
|
||||
include $(BUILDDEFS_PATH)/converters.mk
|
||||
|
||||
# Generate the board's version.h file.
|
||||
@@ -470,8 +474,10 @@ ifneq ($(wildcard $(QMK_USERSPACE)),)
|
||||
endif
|
||||
|
||||
# If the equivalent users directory exists in userspace, use that in preference to anything currently in the main repo
|
||||
ifneq ($(wildcard $(QMK_USERSPACE)/$(USER_PATH)),)
|
||||
USER_PATH := $(QMK_USERSPACE)/$(USER_PATH)
|
||||
ifneq ($(QMK_USERSPACE),)
|
||||
ifneq ($(wildcard $(QMK_USERSPACE)/$(USER_PATH)),)
|
||||
USER_PATH := $(QMK_USERSPACE)/$(USER_PATH)
|
||||
endif
|
||||
endif
|
||||
|
||||
# Pull in user level rules.mk
|
||||
|
||||
@@ -10,10 +10,10 @@ define SEARCH_LAYOUTS_REPO
|
||||
LAYOUT_KEYMAP_JSON := $$(LAYOUT_KEYMAP_PATH)/keymap.json
|
||||
LAYOUT_KEYMAP_C := $$(LAYOUT_KEYMAP_PATH)/keymap.c
|
||||
ifneq ("$$(wildcard $$(LAYOUT_KEYMAP_JSON))","")
|
||||
-include $$(LAYOUT_KEYMAP_PATH)/rules.mk
|
||||
KEYMAP_JSON := $$(LAYOUT_KEYMAP_JSON)
|
||||
KEYMAP_PATH := $$(LAYOUT_KEYMAP_PATH)
|
||||
else ifneq ("$$(wildcard $$(LAYOUT_KEYMAP_C))","")
|
||||
KEYMAP_JSON_PATH := $$(LAYOUT_KEYMAP_PATH)
|
||||
endif
|
||||
ifneq ("$$(wildcard $$(LAYOUT_KEYMAP_C))","")
|
||||
-include $$(LAYOUT_KEYMAP_PATH)/rules.mk
|
||||
KEYMAP_C := $$(LAYOUT_KEYMAP_C)
|
||||
KEYMAP_PATH := $$(LAYOUT_KEYMAP_PATH)
|
||||
|
||||
@@ -125,7 +125,7 @@ ifeq ($(strip $(MOUSEKEY_ENABLE)), yes)
|
||||
MOUSE_ENABLE := yes
|
||||
endif
|
||||
|
||||
VALID_POINTING_DEVICE_DRIVER_TYPES := adns5050 adns9800 analog_joystick azoteq_iqs5xx cirque_pinnacle_i2c cirque_pinnacle_spi paw3204 pmw3320 pmw3360 pmw3389 pimoroni_trackball custom
|
||||
VALID_POINTING_DEVICE_DRIVER_TYPES := adns5050 adns9800 analog_joystick azoteq_iqs5xx cirque_pinnacle_i2c cirque_pinnacle_spi paw3204 paw3222 pmw3320 pmw3360 pmw3389 pimoroni_trackball custom
|
||||
ifeq ($(strip $(POINTING_DEVICE_ENABLE)), yes)
|
||||
ifeq ($(filter $(POINTING_DEVICE_DRIVER),$(VALID_POINTING_DEVICE_DRIVER_TYPES)),)
|
||||
$(call CATASTROPHIC_ERROR,Invalid POINTING_DEVICE_DRIVER,POINTING_DEVICE_DRIVER="$(POINTING_DEVICE_DRIVER)" is not a valid pointing device type)
|
||||
@@ -157,6 +157,8 @@ ifeq ($(strip $(POINTING_DEVICE_ENABLE)), yes)
|
||||
SRC += drivers/sensors/cirque_pinnacle.c
|
||||
SRC += drivers/sensors/cirque_pinnacle_gestures.c
|
||||
SRC += $(QUANTUM_DIR)/pointing_device/pointing_device_gestures.c
|
||||
else ifeq ($(strip $(POINTING_DEVICE_DRIVER)), paw3222)
|
||||
SPI_DRIVER_REQUIRED = yes
|
||||
else ifeq ($(strip $(POINTING_DEVICE_DRIVER)), pimoroni_trackball)
|
||||
I2C_DRIVER_REQUIRED = yes
|
||||
else ifneq ($(filter $(strip $(POINTING_DEVICE_DRIVER)),pmw3360 pmw3389),)
|
||||
|
||||
0
data/constants/keycodes/keycodes_0.0.8.hjson
Normal file
0
data/constants/keycodes/keycodes_0.0.8.hjson
Normal file
37
data/constants/keycodes/keycodes_0.0.8_lighting.hjson
Normal file
37
data/constants/keycodes/keycodes_0.0.8_lighting.hjson
Normal file
@@ -0,0 +1,37 @@
|
||||
{
|
||||
"keycodes": {
|
||||
"0x7819": {
|
||||
"group": "led_matrix",
|
||||
"key": "QK_LED_MATRIX_FLAG_NEXT",
|
||||
"label": "LED Matrix Flag Next",
|
||||
"aliases": [
|
||||
"LM_FLGN"
|
||||
]
|
||||
},
|
||||
"0x781A": {
|
||||
"group": "led_matrix",
|
||||
"key": "QK_LED_MATRIX_FLAG_PREVIOUS",
|
||||
"label": "LED Matrix Flag Previous",
|
||||
"aliases": [
|
||||
"LM_FLGP"
|
||||
]
|
||||
},
|
||||
|
||||
"0x784D": {
|
||||
"group": "rgb_matrix",
|
||||
"key": "QK_RGB_MATRIX_FLAG_NEXT",
|
||||
"label": "RGB Matrix Flag Next",
|
||||
"aliases": [
|
||||
"RM_FLGN"
|
||||
]
|
||||
},
|
||||
"0x784E": {
|
||||
"group": "rgb_matrix",
|
||||
"key": "QK_RGB_MATRIX_FLAG_PREVIOUS",
|
||||
"label": "RGB Matrix Flag Previous",
|
||||
"aliases": [
|
||||
"RM_FLGP"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -98,6 +98,7 @@
|
||||
|
||||
// LED Matrix
|
||||
"LED_MATRIX_CENTER": {"info_key": "led_matrix.center_point", "value_type": "array.int"},
|
||||
"LED_MATRIX_FLAG_STEPS": {"info_key": "led_matrix.flag_steps", "value_type": "array.int"},
|
||||
"LED_MATRIX_KEYRELEASES": {"info_key": "led_matrix.react_on_keyup", "value_type": "flag"},
|
||||
"LED_MATRIX_LED_FLUSH_LIMIT": {"info_key": "led_matrix.led_flush_limit", "value_type": "int"},
|
||||
"LED_MATRIX_LED_PROCESS_LIMIT": {"info_key": "led_matrix.led_process_limit", "value_type": "int", "to_json": false},
|
||||
@@ -111,6 +112,7 @@
|
||||
"LED_MATRIX_DEFAULT_ON": {"info_key": "led_matrix.default.on", "value_type": "bool"},
|
||||
"LED_MATRIX_DEFAULT_VAL": {"info_key": "led_matrix.default.val", "value_type": "int"},
|
||||
"LED_MATRIX_DEFAULT_SPD": {"info_key": "led_matrix.default.speed", "value_type": "int"},
|
||||
"LED_MATRIX_DEFAULT_FLAGS": {"info_key": "led_matrix.default.flags", "value_type": "int"},
|
||||
|
||||
// Locking Switch
|
||||
"LOCKING_SUPPORT_ENABLE": {"info_key": "qmk.locking.enabled", "value_type": "flag"},
|
||||
@@ -147,6 +149,7 @@
|
||||
|
||||
// RGB Matrix
|
||||
"RGB_MATRIX_CENTER": {"info_key": "rgb_matrix.center_point", "value_type": "array.int"},
|
||||
"RGB_MATRIX_FLAG_STEPS": {"info_key": "rgb_matrix.flag_steps", "value_type": "array.int"},
|
||||
"RGB_MATRIX_HUE_STEP": {"info_key": "rgb_matrix.hue_steps", "value_type": "int"},
|
||||
"RGB_MATRIX_KEYRELEASES": {"info_key": "rgb_matrix.react_on_keyup", "value_type": "flag"},
|
||||
"RGB_MATRIX_LED_FLUSH_LIMIT": {"info_key": "rgb_matrix.led_flush_limit", "value_type": "int"},
|
||||
@@ -164,6 +167,7 @@
|
||||
"RGB_MATRIX_DEFAULT_SAT": {"info_key": "rgb_matrix.default.sat", "value_type": "int"},
|
||||
"RGB_MATRIX_DEFAULT_VAL": {"info_key": "rgb_matrix.default.val", "value_type": "int"},
|
||||
"RGB_MATRIX_DEFAULT_SPD": {"info_key": "rgb_matrix.default.speed", "value_type": "int"},
|
||||
"RGB_MATRIX_DEFAULT_FLAGS": {"info_key": "rgb_matrix.default.flags", "value_type": "int"},
|
||||
|
||||
// RGBLight
|
||||
"RGBLED_SPLIT": {"info_key": "rgblight.split_count", "value_type": "array.int"},
|
||||
@@ -220,6 +224,7 @@
|
||||
"PERMISSIVE_HOLD_PER_KEY": {"info_key": "tapping.permissive_hold_per_key", "value_type": "flag"},
|
||||
"RETRO_TAPPING": {"info_key": "tapping.retro", "value_type": "flag"},
|
||||
"RETRO_TAPPING_PER_KEY": {"info_key": "tapping.retro_per_key", "value_type": "flag"},
|
||||
"SPECULATIVE_HOLD": {"info_key": "tapping.speculative_hold", "value_type": "flag"},
|
||||
"TAP_CODE_DELAY": {"info_key": "qmk.tap_keycode_delay", "value_type": "int"},
|
||||
"TAP_HOLD_CAPS_DELAY": {"info_key": "qmk.tap_capslock_delay", "value_type": "int"},
|
||||
"TAPPING_TERM": {"info_key": "tapping.term", "value_type": "int"},
|
||||
|
||||
@@ -23,7 +23,8 @@
|
||||
"animation": "solid",
|
||||
"on": true,
|
||||
"val": 255,
|
||||
"speed": 128
|
||||
"speed": 128,
|
||||
"flags": 255
|
||||
},
|
||||
"led_flush_limit": 16,
|
||||
"max_brightness": 255,
|
||||
@@ -53,7 +54,8 @@
|
||||
"hue": 0,
|
||||
"sat": 255,
|
||||
"val": 255,
|
||||
"speed": 128
|
||||
"speed": 128,
|
||||
"flags": 255
|
||||
},
|
||||
"hue_steps": 8,
|
||||
"led_flush_limit": 16,
|
||||
|
||||
@@ -1620,8 +1620,11 @@
|
||||
"0_sixty": {
|
||||
"target": "0_sixty/base"
|
||||
},
|
||||
"0xcb/splaytoraid": {
|
||||
"target": "0xcb/splaytoraid/rp2040_ce"
|
||||
"0xcb/splaytoraid/32u4": {
|
||||
"target": "0xcb/splaytoraid"
|
||||
},
|
||||
"0xcb/splaytoraid/rp2040_ce": {
|
||||
"target": "0xcb/splaytoraid"
|
||||
},
|
||||
"1upkeyboards/pi40": {
|
||||
"target": "1upkeyboards/pi40/mit_v1_0"
|
||||
@@ -1632,12 +1635,24 @@
|
||||
"1upkeyboards/sweet16": {
|
||||
"target": "1upkeyboards/sweet16/v1"
|
||||
},
|
||||
"1upkeyboards/sweet16v2/kb2040": {
|
||||
"target": "1upkeyboards/sweet16v2"
|
||||
},
|
||||
"1upkeyboards/sweet16v2/pro_micro": {
|
||||
"target": "1upkeyboards/sweet16v2"
|
||||
},
|
||||
"25keys/aleth42": {
|
||||
"target": "25keys/aleth42/rev1"
|
||||
},
|
||||
"25keys/zinc": {
|
||||
"target": "25keys/zinc/rev1"
|
||||
},
|
||||
"40percentclub/gherkin/kb2040": {
|
||||
"target": "40percentclub/gherkin"
|
||||
},
|
||||
"40percentclub/gherkin/pro_micro": {
|
||||
"target": "40percentclub/gherkin"
|
||||
},
|
||||
"40percentclub/i75": {
|
||||
"target": "40percentclub/i75/promicro"
|
||||
},
|
||||
@@ -1735,7 +1750,7 @@
|
||||
"target": "durgod/dgk6x/galaxy"
|
||||
},
|
||||
"durgod/venus": {
|
||||
"target": "durgod/dgk6x/venus"
|
||||
"target": "durgod/dgk6x/venus_ansi"
|
||||
},
|
||||
"dztech/tofu/ii": {
|
||||
"target": "dztech/tofu/ii/v1"
|
||||
|
||||
@@ -543,7 +543,8 @@
|
||||
"on": {"type": "boolean"},
|
||||
"animation": {"type": "string"},
|
||||
"val": {"$ref": "./definitions.jsonschema#/unsigned_int_8"},
|
||||
"speed": {"$ref": "./definitions.jsonschema#/unsigned_int_8"}
|
||||
"speed": {"$ref": "./definitions.jsonschema#/unsigned_int_8"},
|
||||
"flags": {"$ref": "./definitions.jsonschema#/unsigned_int_8"}
|
||||
}
|
||||
},
|
||||
"driver": {
|
||||
@@ -571,6 +572,11 @@
|
||||
"maxItems": 2,
|
||||
"items": {"$ref": "./definitions.jsonschema#/unsigned_int_8"}
|
||||
},
|
||||
"flag_steps": {
|
||||
"type": "array",
|
||||
"minItems": 1,
|
||||
"items": {"$ref": "./definitions.jsonschema#/unsigned_int_8"}
|
||||
},
|
||||
"max_brightness": {"$ref": "./definitions.jsonschema#/unsigned_int_8"},
|
||||
"timeout": {"$ref": "./definitions.jsonschema#/unsigned_int"},
|
||||
"val_steps": {"$ref": "./definitions.jsonschema#/unsigned_int"},
|
||||
@@ -626,7 +632,8 @@
|
||||
"hue": {"$ref": "./definitions.jsonschema#/unsigned_int_8"},
|
||||
"sat": {"$ref": "./definitions.jsonschema#/unsigned_int_8"},
|
||||
"val": {"$ref": "./definitions.jsonschema#/unsigned_int_8"},
|
||||
"speed": {"$ref": "./definitions.jsonschema#/unsigned_int_8"}
|
||||
"speed": {"$ref": "./definitions.jsonschema#/unsigned_int_8"},
|
||||
"flags": {"$ref": "./definitions.jsonschema#/unsigned_int_8"}
|
||||
}
|
||||
},
|
||||
"driver": {
|
||||
@@ -656,6 +663,11 @@
|
||||
"maxItems": 2,
|
||||
"items": {"$ref": "./definitions.jsonschema#/unsigned_int_8"}
|
||||
},
|
||||
"flag_steps": {
|
||||
"type": "array",
|
||||
"minItems": 1,
|
||||
"items": {"$ref": "./definitions.jsonschema#/unsigned_int_8"}
|
||||
},
|
||||
"max_brightness": {"$ref": "./definitions.jsonschema#/unsigned_int_8"},
|
||||
"timeout": {"$ref": "./definitions.jsonschema#/unsigned_int"},
|
||||
"hue_steps": {"$ref": "./definitions.jsonschema#/unsigned_int"},
|
||||
|
||||
@@ -35,6 +35,17 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"dip_switches": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"required": ["on", "off"],
|
||||
"properties": {
|
||||
"on": {"type": "string"},
|
||||
"off": {"type": "string"}
|
||||
}
|
||||
}
|
||||
},
|
||||
"macros": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
|
||||
190
docs/ChangeLog/20251130.md
Normal file
190
docs/ChangeLog/20251130.md
Normal file
@@ -0,0 +1,190 @@
|
||||
# QMK Breaking Changes - 2025 Nov 30 Changelog
|
||||
|
||||
## Notable Features {#notable-features}
|
||||
|
||||
### Speculative Hold option for mod-taps: hold mods instantly while unsettled [#25572](https://github.com/qmk/qmk_firmware/pull/25572)
|
||||
|
||||
Speculative Hold makes mod-tap keys more responsive by applying the modifier instantly on keydown, before the tap-hold decision is made. This is especially useful for actions like Shift+click and Ctrl+scroll wheel with an external mouse, which can feel laggy with standard mod-taps.
|
||||
|
||||
The firmware holds the modifier speculatively. Once the key's behavior is settled:
|
||||
|
||||
* If held, the modifier remains active as expected until the key is released.
|
||||
* If tapped, the speculative modifier is canceled just before the tapping keycode is sent.
|
||||
|
||||
Speculative Hold applies the modifier early but does not change the underlying tap-hold decision logic. Speculative Hold is compatible to use in combination with any other tap-hold options.
|
||||
|
||||
see the [Speculative Hold](../tap_hold#speculative-hold) documentation for more information.
|
||||
|
||||
## Changes Requiring User Action
|
||||
|
||||
### Updated Keyboard Codebases
|
||||
|
||||
| Old Keyboard Name | New Keyboard Name |
|
||||
|----------------------------------|-------------------------|
|
||||
| 0xcb/splaytoraid/32u4 | 0xcb/splaytoraid |
|
||||
| 0xcb/splaytoraid/rp2040_ce | 0xcb/splaytoraid |
|
||||
| 1upkeyboards/sweet16v2/kb2040 | 1upkeyboards/sweet16v2 |
|
||||
| 1upkeyboards/sweet16v2/pro_micro | 1upkeyboards/sweet16v2 |
|
||||
| 40percentclub/gherkin/kb2040 | 40percentclub/gherkin |
|
||||
| 40percentclub/gherkin/pro_micro | 40percentclub/gherkin |
|
||||
| durgod/dgk6x/venus | durgod/dgk6x/venus_ansi |
|
||||
|
||||
### Reduce tap dance memory usage, move state out of data [#25415](https://github.com/qmk/qmk_firmware/pull/25415)
|
||||
|
||||
The tap dance state has been separated from the action structure. Custom tap dance functions now receive the state as a separate parameter instead of accessing it through `action->state`.
|
||||
|
||||
If your keymap uses custom tap dance functions that access the tap dance state, you need to update your code.
|
||||
|
||||
* You can't use `action->state`. Instead you need to call `tap_dance_state_t *tap_dance_get_state(uint8_t tap_dance_idx)` to get the state.
|
||||
* You now get a pointer to the state, so use `->` notation rather than `.` notation to get fields from it.
|
||||
|
||||
### Before:
|
||||
```c
|
||||
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
tap_dance_action_t *action;
|
||||
|
||||
switch (keycode) {
|
||||
case TD(CT_CLN):
|
||||
action = tap_dance_get(QK_TAP_DANCE_GET_INDEX(keycode));
|
||||
if (!record->event.pressed && action->state.count && !action->state.finished) {
|
||||
tap_dance_tap_hold_t *tap_hold = (tap_dance_tap_hold_t *)action->user_data;
|
||||
tap_code16(tap_hold->tap);
|
||||
}
|
||||
|
||||
}
|
||||
return true;
|
||||
}
|
||||
```
|
||||
### After:
|
||||
```c
|
||||
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
tap_dance_action_t *action;
|
||||
tap_dance_state_t* state;
|
||||
switch (keycode) {
|
||||
case TD(CT_CLN):
|
||||
action = tap_dance_get(QK_TAP_DANCE_GET_INDEX(keycode));
|
||||
state = tap_dance_get_state(QK_TAP_DANCE_GET_INDEX(keycode));
|
||||
if (!record->event.pressed && state != NULL && state->count && !state->finished) {
|
||||
tap_dance_tap_hold_t *tap_hold = (tap_dance_tap_hold_t *)action->user_data;
|
||||
tap_code16(tap_hold->tap);
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
```
|
||||
|
||||
## 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.
|
||||
|
||||
### Remove override of QK_{LED,RGB}_MATRIX_TOGGLE keycode [#25672](https://github.com/qmk/qmk_firmware/pull/25672)
|
||||
|
||||
[#24649](https://github.com/qmk/qmk_firmware/pull/24649) implemented genetic behavior, including keycodes, to cycle flags.
|
||||
|
||||
Any overriding of existing keycodes that duplicate this behavior will be removed to ensure consistency with core functionality.
|
||||
|
||||
## Full changelist
|
||||
|
||||
Core:
|
||||
* suspend: suppress wake up keypress ([#23389](https://github.com/qmk/qmk_firmware/pull/23389))
|
||||
* [Feature Improvement]add option to keep layer state when recording dynamic macros ([#24418](https://github.com/qmk/qmk_firmware/pull/24418))
|
||||
* Add generic handling to cycle LED/RGB Matrix flags ([#24649](https://github.com/qmk/qmk_firmware/pull/24649))
|
||||
* Implement `mod_t` packed struct ([#25168](https://github.com/qmk/qmk_firmware/pull/25168))
|
||||
* Implement minimal connection update logic ([#25334](https://github.com/qmk/qmk_firmware/pull/25334))
|
||||
* Reduce tap dance memory usage, move state out of data ([#25415](https://github.com/qmk/qmk_firmware/pull/25415))
|
||||
* Refactor debounce algorithm with static allocation ([#25515](https://github.com/qmk/qmk_firmware/pull/25515))
|
||||
* Restructure Pixel Rain interval code ([#25516](https://github.com/qmk/qmk_firmware/pull/25516))
|
||||
* Guard remapping logic with MAGIC_ENABLE ([#25537](https://github.com/qmk/qmk_firmware/pull/25537))
|
||||
* Update default OLED font ([#25565](https://github.com/qmk/qmk_firmware/pull/25565))
|
||||
* Speculative Hold option for mod-taps: hold mods instantly while unsettled. ([#25572](https://github.com/qmk/qmk_firmware/pull/25572))
|
||||
* Simplify hue calculation in raindrops animation ([#25587](https://github.com/qmk/qmk_firmware/pull/25587))
|
||||
* Simplify tap_code16_delay ([#25595](https://github.com/qmk/qmk_firmware/pull/25595))
|
||||
* Debounce: Deprecate num_rows parameter ([#25632](https://github.com/qmk/qmk_firmware/pull/25632))
|
||||
* Add I2C Transmit and Receive function ([#25637](https://github.com/qmk/qmk_firmware/pull/25637))
|
||||
* [QP] Minor cleanup and support for RGB888 surface ([#25706](https://github.com/qmk/qmk_firmware/pull/25706))
|
||||
* Restrict mouse timer activation to movement keycodes ([#25716](https://github.com/qmk/qmk_firmware/pull/25716))
|
||||
* Update STM32F446 default HSE to 8MHz ([#25717](https://github.com/qmk/qmk_firmware/pull/25717))
|
||||
* making flowtap timer public so it can be used easily with combos ([#25731](https://github.com/qmk/qmk_firmware/pull/25731))
|
||||
* Add PixArt PAW-3222 mouse sensor driver ([#25763](https://github.com/qmk/qmk_firmware/pull/25763))
|
||||
* Merge upstream uf2conv changes ([#25786](https://github.com/qmk/qmk_firmware/pull/25786))
|
||||
* Partially skip generating community modules when none enabled ([#25819](https://github.com/qmk/qmk_firmware/pull/25819))
|
||||
|
||||
CLI:
|
||||
* Generate default encoder resolution for sparse config ([#25247](https://github.com/qmk/qmk_firmware/pull/25247))
|
||||
* Add DIP Switch map support to keymap.json ([#25431](https://github.com/qmk/qmk_firmware/pull/25431))
|
||||
* Add return code to `qmk userspace-doctor` ([#25775](https://github.com/qmk/qmk_firmware/pull/25775))
|
||||
* Better defaulting of `{RGB,LED}_MATRIX_DEFAULT_FLAGS` ([#25785](https://github.com/qmk/qmk_firmware/pull/25785))
|
||||
* add BCD versions of QMK Version ([#25804](https://github.com/qmk/qmk_firmware/pull/25804))
|
||||
* Lint error on missing keyboard readme ([#25814](https://github.com/qmk/qmk_firmware/pull/25814))
|
||||
|
||||
Submodule updates:
|
||||
* Update ChibiOS-Contrib. ([#25751](https://github.com/qmk/qmk_firmware/pull/25751))
|
||||
|
||||
Keyboards:
|
||||
* `atreus`: restore intended matrix implementations ([#24082](https://github.com/qmk/qmk_firmware/pull/24082))
|
||||
* add SteelSeries prime, a stripped down prime+ ([#24719](https://github.com/qmk/qmk_firmware/pull/24719))
|
||||
* Add new macropad Sharkropad ([#24961](https://github.com/qmk/qmk_firmware/pull/24961))
|
||||
* Addition of the D60B tsangan pcb ([#25245](https://github.com/qmk/qmk_firmware/pull/25245))
|
||||
* Migrate `eeconfig_init_kb` implementations to config ([#25422](https://github.com/qmk/qmk_firmware/pull/25422))
|
||||
* Generate `CUSTOM_MATRIX = lite` without `matrix_pins.custom` ([#25453](https://github.com/qmk/qmk_firmware/pull/25453))
|
||||
* Add classic48 keyboard ([#25492](https://github.com/qmk/qmk_firmware/pull/25492))
|
||||
* add durgod venus iso support ([#25526](https://github.com/qmk/qmk_firmware/pull/25526))
|
||||
* Migrate `g_led_config` to DD (0-9, A) ([#25558](https://github.com/qmk/qmk_firmware/pull/25558))
|
||||
* Migrate `g_led_config` to DD (B, C) ([#25559](https://github.com/qmk/qmk_firmware/pull/25559))
|
||||
* Migrate `g_led_config` to DD (D) ([#25560](https://github.com/qmk/qmk_firmware/pull/25560))
|
||||
* Migrate `g_led_config` to DD (E, F) ([#25561](https://github.com/qmk/qmk_firmware/pull/25561))
|
||||
* Remove duplication of RP2040 config defaults ([#25563](https://github.com/qmk/qmk_firmware/pull/25563))
|
||||
* Refactor 40percentclub/ut47 ([#25571](https://github.com/qmk/qmk_firmware/pull/25571))
|
||||
* E7-V2 Implementation ([#25594](https://github.com/qmk/qmk_firmware/pull/25594))
|
||||
* Migrate `g_led_config` to DD (G) ([#25598](https://github.com/qmk/qmk_firmware/pull/25598))
|
||||
* Migrate `g_led_config` to DD (H) ([#25599](https://github.com/qmk/qmk_firmware/pull/25599))
|
||||
* Migrate `g_led_config` to DD (I) ([#25600](https://github.com/qmk/qmk_firmware/pull/25600))
|
||||
* Migrate `g_led_config` to DD (JK1) ([#25601](https://github.com/qmk/qmk_firmware/pull/25601))
|
||||
* Migrate `g_led_config` to DD (K2) ([#25602](https://github.com/qmk/qmk_firmware/pull/25602))
|
||||
* Migrate `g_led_config` to DD (K3) ([#25603](https://github.com/qmk/qmk_firmware/pull/25603))
|
||||
* Migrate `g_led_config` to DD (K4) ([#25605](https://github.com/qmk/qmk_firmware/pull/25605))
|
||||
* Migrate `g_led_config` to DD (K5) ([#25606](https://github.com/qmk/qmk_firmware/pull/25606))
|
||||
* Migrate `g_led_config` to DD (K6) ([#25607](https://github.com/qmk/qmk_firmware/pull/25607))
|
||||
* Refactor `40percentclub/gherkin` ([#25608](https://github.com/qmk/qmk_firmware/pull/25608))
|
||||
* Refactor `0xcb/splaytoraid` ([#25609](https://github.com/qmk/qmk_firmware/pull/25609))
|
||||
* Refactor `1upkeyboards/sweet16v2` ([#25610](https://github.com/qmk/qmk_firmware/pull/25610))
|
||||
* Migrate `g_led_config` to DD (K7) ([#25616](https://github.com/qmk/qmk_firmware/pull/25616))
|
||||
* Migrate `g_led_config` to DD (L) ([#25617](https://github.com/qmk/qmk_firmware/pull/25617))
|
||||
* Migrate `g_led_config` to DD (M1) ([#25618](https://github.com/qmk/qmk_firmware/pull/25618))
|
||||
* Migrate `g_led_config` to DD (M2) ([#25619](https://github.com/qmk/qmk_firmware/pull/25619))
|
||||
* Migrate `g_led_config` to DD (M3) ([#25620](https://github.com/qmk/qmk_firmware/pull/25620))
|
||||
* Migrate `g_led_config` to DD (NO) ([#25621](https://github.com/qmk/qmk_firmware/pull/25621))
|
||||
* Migrate `g_led_config` to DD (P) ([#25622](https://github.com/qmk/qmk_firmware/pull/25622))
|
||||
* Migrate `g_led_config` to DD (QR) ([#25623](https://github.com/qmk/qmk_firmware/pull/25623))
|
||||
* Migrate `g_led_config` to DD (S) ([#25624](https://github.com/qmk/qmk_firmware/pull/25624))
|
||||
* Migrate `g_led_config` to DD (TUW) ([#25625](https://github.com/qmk/qmk_firmware/pull/25625))
|
||||
* Remove idobao *_DISABLE_UNDERGLOW behaviour ([#25638](https://github.com/qmk/qmk_firmware/pull/25638))
|
||||
* Migrate `g_led_config` to DD (YZ) ([#25650](https://github.com/qmk/qmk_firmware/pull/25650))
|
||||
* Tidy Keebio keyboards ([#25653](https://github.com/qmk/qmk_firmware/pull/25653))
|
||||
* Remove encoder resolution where duplicating defaults ([#25654](https://github.com/qmk/qmk_firmware/pull/25654))
|
||||
* Custom oled fonts cleanup ([#25665](https://github.com/qmk/qmk_firmware/pull/25665))
|
||||
* Binepad KnobX1 - refactor `x1_layer_led` function as weak ([#25668](https://github.com/qmk/qmk_firmware/pull/25668))
|
||||
* Add DD {LED,RGB}_MATRIX_DEFAULT_FLAGS support ([#25671](https://github.com/qmk/qmk_firmware/pull/25671))
|
||||
* keyboards: Add Royal Kludge RK61 ([#25694](https://github.com/qmk/qmk_firmware/pull/25694))
|
||||
* Add TRKeyboard TRK2 keyboard ([#25754](https://github.com/qmk/qmk_firmware/pull/25754))
|
||||
|
||||
Keyboard fixes:
|
||||
* Fixup `kprepublic/bm60hsrgb/rev2` ([#25644](https://github.com/qmk/qmk_firmware/pull/25644))
|
||||
* Fixup `kprepublic/bm60hsrgb_iso/rev2` ([#25648](https://github.com/qmk/qmk_firmware/pull/25648))
|
||||
* Fixup `kprepublic/bm60hsrgb_poker/rev2` ([#25649](https://github.com/qmk/qmk_firmware/pull/25649))
|
||||
* Fixup `rgbkb/pan` ([#25678](https://github.com/qmk/qmk_firmware/pull/25678))
|
||||
* Align use of keymap level `_kb` callbacks ([#25774](https://github.com/qmk/qmk_firmware/pull/25774))
|
||||
|
||||
Others:
|
||||
* Rework converter docs ([#18314](https://github.com/qmk/qmk_firmware/pull/18314))
|
||||
* Update USBaspLoader ISP instructions ([#25590](https://github.com/qmk/qmk_firmware/pull/25590))
|
||||
* Add LED/RGB Matrix flags API docs ([#25673](https://github.com/qmk/qmk_firmware/pull/25673))
|
||||
|
||||
Bugs:
|
||||
* Fix single key combos activating only once ([#25198](https://github.com/qmk/qmk_firmware/pull/25198))
|
||||
* Fix RGB matrix not syncing and turning off properly on timeout ([#25467](https://github.com/qmk/qmk_firmware/pull/25467))
|
||||
* Fix drv haptics docs by using the correct function name ([#25733](https://github.com/qmk/qmk_firmware/pull/25733))
|
||||
* Fix Magic GUI masking logic ([#25780](https://github.com/qmk/qmk_firmware/pull/25780))
|
||||
* Fix Speculative Hold to enable also right-handed RSFT, RCTL by default. ([#25797](https://github.com/qmk/qmk_firmware/pull/25797))
|
||||
* Fix community layout keymap discovery ([#25802](https://github.com/qmk/qmk_firmware/pull/25802))
|
||||
* Fix preference of output file for 'qmk generate-autocorrect-data' ([#25818](https://github.com/qmk/qmk_firmware/pull/25818))
|
||||
@@ -214,7 +214,7 @@
|
||||
{ "text": "My Pull Request Was Flagged", "link": "/breaking_changes_instructions" },
|
||||
{
|
||||
"text": "Most Recent ChangeLog",
|
||||
"link": "/ChangeLog/20250831"
|
||||
"link": "/ChangeLog/20251130"
|
||||
},
|
||||
{ "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 Nov 30](ChangeLog/20251130)
|
||||
* [2025 Aug 31](ChangeLog/20250831)
|
||||
* [2025 May 25](ChangeLog/20250525)
|
||||
* [2025 Feb 23](ChangeLog/20250223)
|
||||
* [Older Breaking Changes](breaking_changes_history)
|
||||
|
||||
## When is the next Breaking Change?
|
||||
|
||||
The next Breaking Change is scheduled for November 30, 2025.
|
||||
The next Breaking Change is scheduled for February 22, 2026.
|
||||
|
||||
### Important Dates
|
||||
|
||||
* 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.
|
||||
* 2025 Nov 30 - `develop` is tagged with a new release version. Each push to `master` is subsequently merged to `develop` by GitHub actions.
|
||||
* 2026 Jan 25 - `develop` closed to new PRs.
|
||||
* 2026 Jan 25 - Call for testers.
|
||||
* 2026 Feb 8 - Last day for merges -- after this point `develop` is locked for testing and accepts only bugfixes
|
||||
* 2026 Feb 15 - `develop` is locked, only critical bugfix PRs merged.
|
||||
* 2026 Feb 20 - `master` is locked, no PRs merged.
|
||||
* 2026 Feb 22 - Merge `develop` to `master`.
|
||||
* 2026 Feb 22 - `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 Nov 30](ChangeLog/20251130) - version 0.31.0
|
||||
* [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
|
||||
|
||||
@@ -74,7 +74,7 @@ void matrix_init(void) {
|
||||
// TODO: initialize hardware and global matrix state here
|
||||
|
||||
// Unless hardware debouncing - Init the configured debounce routine
|
||||
debounce_init(MATRIX_ROWS);
|
||||
debounce_init();
|
||||
|
||||
// This *must* be called for correct keyboard behavior
|
||||
matrix_init_kb();
|
||||
@@ -86,7 +86,7 @@ uint8_t matrix_scan(void) {
|
||||
// TODO: add matrix scanning routine here
|
||||
|
||||
// Unless hardware debouncing - use the configured debounce routine
|
||||
changed = debounce(raw_matrix, matrix, MATRIX_ROWS, changed);
|
||||
changed = debounce(raw_matrix, matrix, changed);
|
||||
|
||||
// This *must* be called for correct keyboard behavior
|
||||
matrix_scan_kb();
|
||||
|
||||
@@ -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
|
||||
|
||||
|
||||
@@ -221,6 +221,31 @@ Receive multiple bytes from the selected I2C device.
|
||||
|
||||
---
|
||||
|
||||
### `i2c_status_t i2c_transmit_and_receive(uint8_t address, const uint8_t* tx_data, uint16_t tx_length, uint8_t* rx_data, uint16_t rx_length, uint16_t timeout)` {#api-i2c-transmit-and-receive}
|
||||
|
||||
Send and receive multiple bytes from the selected I2C device.
|
||||
|
||||
#### Arguments {#api-i2c-transmit-and-receive-arguments}
|
||||
|
||||
- `uint8_t address`
|
||||
The 7-bit I2C address of the device.
|
||||
- `const uint8_t* tx_data`
|
||||
A pointer to the data to transmit.
|
||||
- `uint16_t tx_length`
|
||||
The number of bytes to write. Take care not to overrun the length of `tx_data`.
|
||||
- `uint8_t* rx_data`
|
||||
A pointer to a buffer to read into.
|
||||
- `uint16_t rx_length`
|
||||
The number of bytes to read. Take care not to overrun the length of `data`.
|
||||
- `uint16_t timeout`
|
||||
The time in milliseconds to wait for a response from the target device.
|
||||
|
||||
#### Return Value {#api-i2c-transmit-and-receive-return}
|
||||
|
||||
`I2C_STATUS_TIMEOUT` if the timeout period elapses, `I2C_STATUS_ERROR` if some other error occurs, otherwise `I2C_STATUS_SUCCESS`.
|
||||
|
||||
---
|
||||
|
||||
### `i2c_status_t i2c_write_register(uint8_t devaddr, uint8_t regaddr, const uint8_t* data, uint16_t length, uint16_t timeout)` {#api-i2c-write-register}
|
||||
|
||||
Write to a register with an 8-bit address on the I2C device.
|
||||
|
||||
@@ -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,8 +2,22 @@
|
||||
|
||||
This page documents the automated process for converting keyboards to use drop-in replacement controllers. This process is designed to be easy to use and can be completed in a few simple steps.
|
||||
|
||||
You can generate the firmware by appending `-e CONVERT_TO=<target>` to your compile/flash command. For example:
|
||||
|
||||
```sh
|
||||
qmk flash -c -kb keebio/bdn9/rev1 -km default -e CONVERT_TO=proton_c
|
||||
```
|
||||
|
||||
You can also configure this within your [keymap](#keymap) to accomplish the same thing.
|
||||
|
||||
::: tip
|
||||
If you get build errors, you will need to convert the keyboard's code to be [compatible](#keyboard-req) with the converter feature, or provide additional [keymap](#keymap-add) configuration.
|
||||
:::
|
||||
|
||||
## Supported Converters
|
||||
|
||||
Each converter category is broken down by its declared `pin compatibility`. This ensures that only valid combinations are attempted.
|
||||
|
||||
The following converters are available at this time:
|
||||
|
||||
| From | To |
|
||||
@@ -28,86 +42,56 @@ The following converters are available at this time:
|
||||
| `elite_c` | `helios` |
|
||||
| `elite_c` | `liatris` |
|
||||
|
||||
## Configuration
|
||||
|
||||
## Overview
|
||||
Configuring a converter to use can be done by adding one of the following lines to your keymaps's configuration:
|
||||
|
||||
Each converter category is broken down by its declared `pin compatibility`. This ensures that only valid combinations are attempted. You can generate the firmware by appending `-e CONVERT_TO=<target>` to your compile/flash command. For example:
|
||||
:::::tabs
|
||||
|
||||
```sh
|
||||
qmk flash -c -kb keebio/bdn9/rev1 -km default -e CONVERT_TO=proton_c
|
||||
==== keymap.json
|
||||
|
||||
```json [keymap.json]
|
||||
{
|
||||
"version": 1,
|
||||
"keyboard": "keebio/bdn9/rev1",
|
||||
"keymap": "keebio_bdn9_rev1_layout_2025-05-20",
|
||||
"converter": "proton_c", // [!code focus]
|
||||
"layout": "LAYOUT",
|
||||
}
|
||||
```
|
||||
|
||||
You can also add the same `CONVERT_TO=<target>` to your keymap's `rules.mk`, which will accomplish the same thing.
|
||||
|
||||
::: tip
|
||||
If you get errors about `PORTB/DDRB`, etc not being defined, you'll need to convert the keyboard's code to use the [GPIO Controls](drivers/gpio) that will work for both ARM and AVR. This shouldn't affect the AVR builds at all.
|
||||
:::
|
||||
|
||||
### Conditional Configuration
|
||||
|
||||
Once a converter is enabled, it exposes the `CONVERT_TO_<target_uppercase>` flag that you can use in your code with `#ifdef`s, For example:
|
||||
|
||||
```c
|
||||
#ifdef CONVERT_TO_PROTON_C
|
||||
// Proton C code
|
||||
#else
|
||||
// Pro Micro code
|
||||
#endif
|
||||
```
|
||||
|
||||
### Pin Compatibility
|
||||
|
||||
To ensure compatibility, provide validation, and enable future workflows, a keyboard should declare its `pin compatibility`. For legacy reasons, this is currently assumed to be `promicro`. The following pin compatibility interfaces are currently defined:
|
||||
|
||||
| Pin Compatibility | Notes |
|
||||
|-------------------|-----------------------------------|
|
||||
| `promicro` | Includes RX/TX LEDs |
|
||||
| `elite_c` | Includes bottom row pins, no LEDs |
|
||||
|
||||
To declare the base for conversions, add this line to your keyboard's `rules.mk`:
|
||||
==== rules.mk
|
||||
|
||||
```makefile
|
||||
PIN_COMPATIBLE = elite_c
|
||||
CONVERT_TO = proton_c
|
||||
```
|
||||
|
||||
## Pro Micro
|
||||
:::::
|
||||
|
||||
If a board currently supported in QMK uses a [Pro Micro](https://www.sparkfun.com/products/12640) (or compatible board), the supported alternative controllers are:
|
||||
::: tip
|
||||
If you get build errors, you will need to convert the keyboard's code to be [compatible](#keyboard-req) with the converter feature, or provide additional [keymap](#keymap-add) configuration.
|
||||
:::
|
||||
|
||||
| Device | Target |
|
||||
|------------------------------------------------------------------------------------------|-------------------|
|
||||
| [Proton C](https://qmk.fm/proton-c/) | `proton_c` |
|
||||
| [Adafruit KB2040](https://learn.adafruit.com/adafruit-kb2040) | `kb2040` |
|
||||
| [SparkFun Pro Micro - RP2040](https://www.sparkfun.com/products/18288) | `sparkfun_pm2040` |
|
||||
| [Blok](https://boardsource.xyz/store/628b95b494dfa308a6581622) | `blok` |
|
||||
| [Bit-C PRO](https://nullbits.co/bit-c-pro) | `bit_c_pro` |
|
||||
| [STeMCell](https://github.com/megamind4089/STeMCell) | `stemcell` |
|
||||
| [customMK Bonsai C4](https://shop.custommk.com/products/bonsai-c4-microcontroller-board) | `bonsai_c4` |
|
||||
| [Elite-Pi](https://keeb.io/products/elite-pi-usb-c-pro-micro-replacement-rp2040) | `elite_pi` |
|
||||
| [0xCB Helios](https://keeb.supply/products/0xcb-helios) | `helios` |
|
||||
| [Liatris](https://splitkb.com/products/liatris) | `liatris` |
|
||||
| [Imera](https://splitkb.com/products/imera) | `imera` |
|
||||
| [Michi](https://github.com/ci-bus/michi-promicro-rp2040) | `michi` |
|
||||
| [Svlinky](https://github.com/sadekbaroudi/svlinky) | `svlinky` |
|
||||
## Pro Micro Converters
|
||||
|
||||
Converter summary:
|
||||
If a board currently supported by QMK uses a [Pro Micro](https://www.sparkfun.com/products/12640) (or compatible board), the supported alternative controllers are:
|
||||
|
||||
| Target | Argument | `rules.mk` | Condition |
|
||||
|-------------------|---------------------------------|------------------------------|-------------------------------------|
|
||||
| `proton_c` | `-e CONVERT_TO=proton_c` | `CONVERT_TO=proton_c` | `#ifdef CONVERT_TO_PROTON_C` |
|
||||
| `kb2040` | `-e CONVERT_TO=kb2040` | `CONVERT_TO=kb2040` | `#ifdef CONVERT_TO_KB2040` |
|
||||
| `sparkfun_pm2040` | `-e CONVERT_TO=sparkfun_pm2040` | `CONVERT_TO=sparkfun_pm2040` | `#ifdef CONVERT_TO_SPARKFUN_PM2040` |
|
||||
| `blok` | `-e CONVERT_TO=blok` | `CONVERT_TO=blok` | `#ifdef CONVERT_TO_BLOK` |
|
||||
| `bit_c_pro` | `-e CONVERT_TO=bit_c_pro` | `CONVERT_TO=bit_c_pro` | `#ifdef CONVERT_TO_BIT_C_PRO` |
|
||||
| `stemcell` | `-e CONVERT_TO=stemcell` | `CONVERT_TO=stemcell` | `#ifdef CONVERT_TO_STEMCELL` |
|
||||
| `bonsai_c4` | `-e CONVERT_TO=bonsai_c4` | `CONVERT_TO=bonsai_c4` | `#ifdef CONVERT_TO_BONSAI_C4` |
|
||||
| `rp2040_ce` | `-e CONVERT_TO=rp2040_ce` | `CONVERT_TO=rp2040_ce` | `#ifdef CONVERT_TO_RP2040_CE` |
|
||||
| `elite_pi` | `-e CONVERT_TO=elite_pi` | `CONVERT_TO=elite_pi` | `#ifdef CONVERT_TO_ELITE_PI` |
|
||||
| `helios` | `-e CONVERT_TO=helios` | `CONVERT_TO=helios` | `#ifdef CONVERT_TO_HELIOS` |
|
||||
| `liatris` | `-e CONVERT_TO=liatris` | `CONVERT_TO=liatris` | `#ifdef CONVERT_TO_LIATRIS` |
|
||||
| `imera` | `-e CONVERT_TO=imera` | `CONVERT_TO=imera` | `#ifdef CONVERT_TO_IMERA` |
|
||||
| `michi` | `-e CONVERT_TO=michi` | `CONVERT_TO=michi` | `#ifdef CONVERT_TO_MICHI` |
|
||||
| `svlinky` | `-e CONVERT_TO=svlinky` | `CONVERT_TO=svlinky` | `#ifdef CONVERT_TO_SVLINKY` |
|
||||
| Device | Target | CLI Argument | `rules.mk` | Condition |
|
||||
|------------------------------------------------------------------------------------------|-------------------|---------------------------------|------------------------------|-------------------------------------|
|
||||
| [Proton C](https://qmk.fm/proton-c/) | `proton_c` | `-e CONVERT_TO=proton_c` | `CONVERT_TO=proton_c` | `#ifdef CONVERT_TO_PROTON_C` |
|
||||
| [Adafruit KB2040](https://learn.adafruit.com/adafruit-kb2040) | `kb2040` | `-e CONVERT_TO=kb2040` | `CONVERT_TO=kb2040` | `#ifdef CONVERT_TO_KB2040` |
|
||||
| [SparkFun Pro Micro - RP2040](https://www.sparkfun.com/products/18288) | `sparkfun_pm2040` | `-e CONVERT_TO=sparkfun_pm2040` | `CONVERT_TO=sparkfun_pm2040` | `#ifdef CONVERT_TO_SPARKFUN_PM2040` |
|
||||
| [Blok](https://boardsource.xyz/store/628b95b494dfa308a6581622) | `blok` | `-e CONVERT_TO=blok` | `CONVERT_TO=blok` | `#ifdef CONVERT_TO_BLOK` |
|
||||
| [Bit-C PRO](https://nullbits.co/bit-c-pro) | `bit_c_pro` | `-e CONVERT_TO=bit_c_pro` | `CONVERT_TO=bit_c_pro` | `#ifdef CONVERT_TO_BIT_C_PRO` |
|
||||
| [STeMCell](https://github.com/megamind4089/STeMCell) | `stemcell` | `-e CONVERT_TO=stemcell` | `CONVERT_TO=stemcell` | `#ifdef CONVERT_TO_STEMCELL` |
|
||||
| [customMK Bonsai C4](https://shop.custommk.com/products/bonsai-c4-microcontroller-board) | `bonsai_c4` | `-e CONVERT_TO=bonsai_c4` | `CONVERT_TO=bonsai_c4` | `#ifdef CONVERT_TO_BONSAI_C4` |
|
||||
| [RP2040 Community Edition](#rp2040_ce) | `rp2040_ce` | `-e CONVERT_TO=rp2040_ce` | `CONVERT_TO=rp2040_ce` | `#ifdef CONVERT_TO_RP2040_CE` |
|
||||
| [Elite-Pi](https://keeb.io/products/elite-pi-usb-c-pro-micro-replacement-rp2040) | `elite_pi` | `-e CONVERT_TO=elite_pi` | `CONVERT_TO=elite_pi` | `#ifdef CONVERT_TO_ELITE_PI` |
|
||||
| [0xCB Helios](https://keeb.supply/products/0xcb-helios) | `helios` | `-e CONVERT_TO=helios` | `CONVERT_TO=helios` | `#ifdef CONVERT_TO_HELIOS` |
|
||||
| [Liatris](https://splitkb.com/products/liatris) | `liatris` | `-e CONVERT_TO=liatris` | `CONVERT_TO=liatris` | `#ifdef CONVERT_TO_LIATRIS` |
|
||||
| [Imera](https://splitkb.com/products/imera) | `imera` | `-e CONVERT_TO=imera` | `CONVERT_TO=imera` | `#ifdef CONVERT_TO_IMERA` |
|
||||
| [Michi](https://github.com/ci-bus/michi-promicro-rp2040) | `michi` | `-e CONVERT_TO=michi` | `CONVERT_TO=michi` | `#ifdef CONVERT_TO_MICHI` |
|
||||
| [Svlinky](https://github.com/sadekbaroudi/svlinky) | `svlinky` | `-e CONVERT_TO=svlinky` | `CONVERT_TO=svlinky` | `#ifdef CONVERT_TO_SVLINKY` |
|
||||
|
||||
### Proton C {#proton_c}
|
||||
|
||||
@@ -119,26 +103,26 @@ The Proton C only has one on-board LED (C13), and by default, the TXLED (D5) is
|
||||
|
||||
The following defaults are based on what has been implemented for STM32 boards.
|
||||
|
||||
| Feature | Notes |
|
||||
|----------------------------------------------|------------------------------------------------------------------------------------------------------------------|
|
||||
| [Audio](features/audio) | Enabled |
|
||||
| [RGB Lighting](features/rgblight) | Disabled |
|
||||
| Feature | Notes |
|
||||
|--------------------------------------------|----------------------------------------------------------------------------------------------------------------|
|
||||
| [Audio](features/audio) | Enabled |
|
||||
| [RGB Lighting](features/rgblight) | Disabled |
|
||||
| [Backlight](features/backlight) | Forces [task driven PWM](features/backlight#software-pwm-driver) until ARM can provide automatic configuration |
|
||||
| USB Host (e.g. USB-USB converter) | Not supported (USB host code is AVR specific and is not currently supported on ARM) |
|
||||
| [Split keyboards](features/split_keyboard) | Partial - heavily dependent on enabled features |
|
||||
| USB Host (e.g. USB-USB converter) | Not supported (USB host code is AVR specific and is not currently supported on ARM) |
|
||||
| [Split keyboards](features/split_keyboard) | Partial - heavily dependent on enabled features |
|
||||
|
||||
### Adafruit KB2040 {#kb2040}
|
||||
|
||||
The following defaults are based on what has been implemented for [RP2040](platformdev_rp2040) boards.
|
||||
|
||||
| Feature | Notes |
|
||||
|----------------------------------------------|------------------------------------------------------------------------------------------------------------------|
|
||||
| [RGB Lighting](features/rgblight) | Enabled via `PIO` vendor driver |
|
||||
| Feature | Notes |
|
||||
|--------------------------------------------|----------------------------------------------------------------------------------------------------------------|
|
||||
| [RGB Lighting](features/rgblight) | Enabled via `PIO` vendor driver |
|
||||
| [Backlight](features/backlight) | Forces [task driven PWM](features/backlight#software-pwm-driver) until ARM can provide automatic configuration |
|
||||
| USB Host (e.g. USB-USB converter) | Not supported (USB host code is AVR specific and is not currently supported on ARM) |
|
||||
| [Split keyboards](features/split_keyboard) | Partial via `PIO` vendor driver - heavily dependent on enabled features |
|
||||
| USB Host (e.g. USB-USB converter) | Not supported (USB host code is AVR specific and is not currently supported on ARM) |
|
||||
| [Split keyboards](features/split_keyboard) | Partial via `PIO` vendor driver - heavily dependent on enabled features |
|
||||
|
||||
### SparkFun Pro Micro - RP2040, Blok, Bit-C PRO and Michi {#sparkfun_pm2040 }
|
||||
### SparkFun Pro Micro - RP2040, Blok, Bit-C PRO and Michi {#sparkfun_pm2040}
|
||||
|
||||
Feature set is identical to [Adafruit KB2040](#kb2040).
|
||||
|
||||
@@ -177,31 +161,193 @@ Feature set is identical to [Adafruit KB2040](#kb2040). VBUS detection is enable
|
||||
|
||||
Feature set is a pro micro equivalent of the [RP2040 Community Edition](#rp2040_ce), except that two of the analog GPIO have been replaced with digital only GPIO. These two were moved to the FPC connector to support the [VIK specification](https://github.com/sadekbaroudi/vik). This means that if you are expecting analog support on all 4 pins as provided on a RP2040 Community Edition pinout, you will not have that. Please see the [Svlinky github page](https://github.com/sadekbaroudi/svlinky) for more details.
|
||||
|
||||
## Elite-C
|
||||
## Elite-C Converters
|
||||
|
||||
If a board currently supported in QMK uses an [Elite-C](https://keeb.io/products/elite-c-low-profile-version-usb-c-pro-micro-replacement-atmega32u4), the supported alternative controllers are:
|
||||
If a board currently supported by QMK uses an [Elite-C](https://keeb.io/products/elite-c-low-profile-version-usb-c-pro-micro-replacement-atmega32u4), the supported alternative controllers are:
|
||||
|
||||
| Device | Target |
|
||||
|----------------------------------------------------------------------------------|-------------------|
|
||||
| [STeMCell](https://github.com/megamind4089/STeMCell) | `stemcell` |
|
||||
| [Elite-Pi](https://keeb.io/products/elite-pi-usb-c-pro-micro-replacement-rp2040) | `elite_pi` |
|
||||
| [0xCB Helios](https://keeb.supply/products/0xcb-helios) | `helios` |
|
||||
| [Liatris](https://splitkb.com/products/liatris) | `liatris` |
|
||||
| Device | Target | CLI Argument | `rules.mk` | Condition |
|
||||
|----------------------------------------------------------------------------------|-------------|---------------------------|------------------------|-------------------------------|
|
||||
| [STeMCell](https://github.com/megamind4089/STeMCell) | `stemcell` | `-e CONVERT_TO=stemcell` | `CONVERT_TO=stemcell` | `#ifdef CONVERT_TO_STEMCELL` |
|
||||
| [RP2040 Community Edition](#rp2040_ce_elite) | `rp2040_ce` | `-e CONVERT_TO=rp2040_ce` | `CONVERT_TO=rp2040_ce` | `#ifdef CONVERT_TO_RP2040_CE` |
|
||||
| [Elite-Pi](https://keeb.io/products/elite-pi-usb-c-pro-micro-replacement-rp2040) | `elite_pi` | `-e CONVERT_TO=elite_pi` | `CONVERT_TO=elite_pi` | `#ifdef CONVERT_TO_ELITE_PI` |
|
||||
| [0xCB Helios](https://keeb.supply/products/0xcb-helios) | `helios` | `-e CONVERT_TO=helios` | `CONVERT_TO=helios` | `#ifdef CONVERT_TO_HELIOS` |
|
||||
| [Liatris](https://splitkb.com/products/liatris) | `liatris` | `-e CONVERT_TO=liatris` | `CONVERT_TO=liatris` | `#ifdef CONVERT_TO_LIATRIS` |
|
||||
|
||||
Converter summary:
|
||||
|
||||
| Target | Argument | `rules.mk` | Condition |
|
||||
|-------------------|---------------------------------|------------------------------|-------------------------------------|
|
||||
| `stemcell` | `-e CONVERT_TO=stemcell` | `CONVERT_TO=stemcell` | `#ifdef CONVERT_TO_STEMCELL` |
|
||||
| `rp2040_ce` | `-e CONVERT_TO=rp2040_ce` | `CONVERT_TO=rp2040_ce` | `#ifdef CONVERT_TO_RP2040_CE` |
|
||||
| `elite_pi` | `-e CONVERT_TO=elite_pi` | `CONVERT_TO=elite_pi` | `#ifdef CONVERT_TO_ELITE_PI` |
|
||||
| `helios` | `-e CONVERT_TO=helios` | `CONVERT_TO=helios` | `#ifdef CONVERT_TO_HELIOS` |
|
||||
| `liatris` | `-e CONVERT_TO=liatris` | `CONVERT_TO=liatris` | `#ifdef CONVERT_TO_LIATRIS` |
|
||||
|
||||
### STeMCell {#stemcell}_elite
|
||||
### STeMCell {#stemcell_elite}
|
||||
|
||||
Identical to [Pro Micro - STeMCell](#stemcell) with support for the additional bottom row of pins.
|
||||
|
||||
### RP2040 Community Edition {#rp2040_ce_elite}
|
||||
|
||||
Identical to [Pro Micro - RP2040 Community Edition](#rp2040_ce) with support for the additional bottom row of pins.
|
||||
|
||||
## Advanced Topics
|
||||
|
||||
### Keyboard Configuration
|
||||
|
||||
To configure a keyboard to allow the converter feature, add the following line to your keyboard's `.json` configuration:
|
||||
|
||||
```json [keyboard.json]
|
||||
{
|
||||
"maintainer": "QMK",
|
||||
"development_board": "promicro", // [!code focus]
|
||||
"diode_direction": "COL2ROW",
|
||||
}
|
||||
```
|
||||
|
||||
See the [pin compatibility](#pin_compatible) for more information.
|
||||
|
||||
#### Additional Requirements {#keyboard-req}
|
||||
|
||||
Keyboards must use the platform agnostic abstractions provided by QMK. This includes:
|
||||
|
||||
* Use of [GPIO Controls](drivers/gpio).
|
||||
|
||||
### Additional Keymap Configuration {#keymap-add}
|
||||
|
||||
While effort has been made to make converters as compatible as possible, sometimes additional platform specific configuration is required.
|
||||
|
||||
For example, enabling hardware peripherals by adding a keymap level `mcuconf.h` with something like the following:
|
||||
```c
|
||||
#pragma once
|
||||
|
||||
#include_next <mcuconf.h>
|
||||
|
||||
#undef RP_SIO_USE_UART0
|
||||
#define RP_SIO_USE_UART0 TRUE
|
||||
```
|
||||
|
||||
You can find details on how to configure drivers on their respective pages.
|
||||
|
||||
Alternatively, you may have to disable incompatible features. For example:
|
||||
|
||||
:::::tabs
|
||||
|
||||
==== keymap.json
|
||||
|
||||
```json [keymap.json]
|
||||
{
|
||||
"version": 1,
|
||||
"keyboard": "keebio/bdn9/rev1",
|
||||
"keymap": "keebio_bdn9_rev1_layout_2025-05-20",
|
||||
"converter": "proton_c",
|
||||
"config": { // [!code focus]
|
||||
"features": { // [!code focus]
|
||||
"audio": false // [!code focus]
|
||||
}
|
||||
}
|
||||
"layout": "LAYOUT",
|
||||
}
|
||||
```
|
||||
|
||||
==== rules.mk
|
||||
|
||||
```makefile
|
||||
AUDIO_ENABLE = no
|
||||
```
|
||||
|
||||
:::::
|
||||
|
||||
### Conditional Configuration
|
||||
|
||||
Once a converter is enabled, it exposes the `CONVERT_TO_<target_uppercase>` flag that you can use in your code with `#ifdef`s, For example:
|
||||
|
||||
```c
|
||||
#ifdef CONVERT_TO_PROTON_C
|
||||
// Proton C code
|
||||
#else
|
||||
// Pro Micro code
|
||||
#endif
|
||||
```
|
||||
|
||||
### Pin Compatibility {#pin_compatible}
|
||||
|
||||
To ensure compatibility, provide validation, and power future workflows, a keyboard should declare its `pin compatibility`. This ensures that only valid combinations are attempted.
|
||||
|
||||
::: tip Note
|
||||
This will already be configured for you if are using the `promicro` development board preset.
|
||||
:::
|
||||
|
||||
To declare the base interface for conversions, add the following line to your keyboard's configuration:
|
||||
|
||||
```json [keyboard.json]
|
||||
{
|
||||
"maintainer": "QMK",
|
||||
"development_board": "elite_c", // [!code focus]
|
||||
"pin_compatible": "elite_c", // [!code focus]
|
||||
"diode_direction": "COL2ROW",
|
||||
}
|
||||
```
|
||||
|
||||
The above example, configures a keyboard for a default of `elite_c` while allowing any of the `elite_c` converter targets.
|
||||
|
||||
The framework then allows mapping of pins from `<PIN_COMPATIBLE>` to converter `<target>`.
|
||||
|
||||
::: warning
|
||||
Mapped pins should adhere strictly to the defined interface, any extras present on the hardware should be ignored.
|
||||
:::
|
||||
|
||||
#### Available Pin Compatibility
|
||||
|
||||
:::::tabs
|
||||
|
||||
==== promicro
|
||||
|
||||

|
||||
|
||||
<!-- ```svgbob
|
||||
pins
|
||||
.-------------. LEDs
|
||||
| | _|_ _|_
|
||||
D3 -+-O | \ /B0 \ /D5
|
||||
D2 -+-O | -+- -+-
|
||||
| | | |
|
||||
| |
|
||||
D1 -+-O O-+- F4
|
||||
D0 -+-O O-+- F5
|
||||
D4 -+-O O-+- F6
|
||||
C6 -+-O O-+- F7
|
||||
D7 -+-O O-+- B1
|
||||
E6 -+-O O-+- B3
|
||||
B4 -+-O O-+- B2
|
||||
B5 -+-O O-+- B6
|
||||
| |
|
||||
'---+-+-+-+-+---'
|
||||
``` -->
|
||||
|
||||
::: info Notes:
|
||||
Includes LEDs - these may be mapped to unused/unavailable pins when not present.
|
||||
:::
|
||||
|
||||
==== elite_c
|
||||
|
||||

|
||||
|
||||
<!-- ```svgbob
|
||||
pins
|
||||
.-------------.
|
||||
| |
|
||||
D3 -+-O |
|
||||
D2 -+-O |
|
||||
| |
|
||||
| |
|
||||
D1 -+-O O-+- F4
|
||||
D0 -+-O O-+- F5
|
||||
D4 -+-O O-+- F6
|
||||
C6 -+-O O-+- F7
|
||||
D7 -+-O O-+- B1
|
||||
E6 -+-O O-+- B3
|
||||
B4 -+-O O-+- B2
|
||||
B5 -+-O O O O O O O-+- B6
|
||||
| | | | | | |
|
||||
'---+-+-+-+-+---'
|
||||
+ + + + +
|
||||
B D C F F
|
||||
7 5 7 1 0
|
||||
``` -->
|
||||
|
||||
::: info Notes:
|
||||
Includes bottom row pins, no LEDs.
|
||||
:::
|
||||
|
||||
:::::
|
||||
|
||||
@@ -32,12 +32,13 @@ For the details about the internals of the dynamic macros, please read the comme
|
||||
|
||||
There are a number of options added that should allow some additional degree of customization
|
||||
|
||||
|Define |Default |Description |
|
||||
|----------------------------|----------------|-----------------------------------------------------------------------------------------------------------------|
|
||||
|`DYNAMIC_MACRO_SIZE` |128 |Sets the amount of memory that Dynamic Macros can use. This is a limited resource, dependent on the controller. |
|
||||
|`DYNAMIC_MACRO_USER_CALL` |*Not defined* |Defining this falls back to using the user `keymap.c` file to trigger the macro behavior. |
|
||||
|`DYNAMIC_MACRO_NO_NESTING` |*Not Defined* |Defining this disables the ability to call a macro from another macro (nested macros). |
|
||||
|`DYNAMIC_MACRO_DELAY` |*Not Defined* |Sets the waiting time (ms unit) when sending each key. |
|
||||
|Define |Default |Description |
|
||||
|------------------------------------------|----------------|-----------------------------------------------------------------------------------------------------------------|
|
||||
|`DYNAMIC_MACRO_SIZE` |128 |Sets the amount of memory that Dynamic Macros can use. This is a limited resource, dependent on the controller. |
|
||||
|`DYNAMIC_MACRO_USER_CALL` |*Not defined* |Defining this falls back to using the user `keymap.c` file to trigger the macro behavior. |
|
||||
|`DYNAMIC_MACRO_NO_NESTING` |*Not Defined* |Defining this disables the ability to call a macro from another macro (nested macros). |
|
||||
|`DYNAMIC_MACRO_DELAY` |*Not Defined* |Sets the waiting time (ms unit) when sending each key. |
|
||||
|`DYNAMIC_MACRO_KEEP_ORIGINAL_LAYER_STATE` |*Not Defined* |Defining this keeps the layer state when starting to record a macro |
|
||||
|
||||
|
||||
If the LEDs start blinking during the recording with each keypress, it means there is no more space for the macro in the macro buffer. To fit the macro in, either make the other macro shorter (they share the same buffer) or increase the buffer size by adding the `DYNAMIC_MACRO_SIZE` define in your `config.h` (default value: 128; please read the comments for it in the header).
|
||||
|
||||
@@ -121,7 +121,7 @@ Linear resonant actuators (LRA, also know as a linear vibrator) works different
|
||||
|
||||
#### DRV2605L waveform library
|
||||
|
||||
DRV2605L comes with preloaded library of various waveform sequences that can be called and played. If writing a macro, these waveforms can be played using `DRV_pulse(*sequence name or number*)`
|
||||
DRV2605L comes with preloaded library of various waveform sequences that can be called and played. If writing a macro, these waveforms can be played using `drv2605l_pulse(*sequence name or number*)` after adding `#include "drv2605l.h"`.
|
||||
|
||||
List of waveform sequences from the datasheet:
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@ You can use key overrides in a similar way to momentary layer/fn keys to activat
|
||||
|
||||
To enable this feature, you need to add `KEY_OVERRIDE_ENABLE = yes` to your `rules.mk`.
|
||||
|
||||
Then, in your `keymap.c` file, you'll need to define the array `key_overrides`, which defines all key overrides to be used. Each override is a value of type `key_override_t`. The array `key_overrides`contains pointers to `key_override_t` values (`const key_override_t **`).
|
||||
Then, in your `keymap.c` file, you'll need to define the `key_overrides` config. See below for more details.
|
||||
|
||||
## Creating Key Overrides {#creating-key-overrides}
|
||||
|
||||
|
||||
@@ -88,6 +88,8 @@ As mentioned earlier, the center of the keyboard by default is expected to be `{
|
||||
|`QK_LED_MATRIX_BRIGHTNESS_DOWN`|`LM_BRID`|Decrease the brightness level |
|
||||
|`QK_LED_MATRIX_SPEED_UP` |`LM_SPDU`|Increase the animation speed |
|
||||
|`QK_LED_MATRIX_SPEED_DOWN` |`LM_SPDD`|Decrease the animation speed |
|
||||
|`QK_LED_MATRIX_FLAG_NEXT` |`LM_FLGN`|Cycle through flags |
|
||||
|`QK_LED_MATRIX_FLAG_PREVIOUS` |`LM_FLGP`|Cycle through flags in reverse |
|
||||
|
||||
## LED Matrix Effects {#led-matrix-effects}
|
||||
|
||||
@@ -253,6 +255,7 @@ const char* effect_name = led_matrix_get_mode_name(led_matrix_get_mode());
|
||||
#define LED_MATRIX_DEFAULT_FLAGS LED_FLAG_ALL // Sets the default LED flags, if none has been set
|
||||
#define LED_MATRIX_SPLIT { X, Y } // (Optional) For split keyboards, the number of LEDs connected on each half. X = left, Y = Right.
|
||||
// If reactive effects are enabled, you also will want to enable SPLIT_TRANSPORT_MIRROR
|
||||
#define LED_MATRIX_FLAG_STEPS { LED_FLAG_ALL, LED_FLAG_KEYLIGHT | LED_FLAG_MODIFIER, LED_FLAG_NONE } // Sets the flags which can be cycled through.
|
||||
```
|
||||
|
||||
## EEPROM storage {#eeprom-storage}
|
||||
@@ -505,6 +508,62 @@ The current effect speed, from 0 to 255.
|
||||
|
||||
---
|
||||
|
||||
### `void led_matrix_set_flags(led_flags_t flags)` {#api-led-matrix-set-flags}
|
||||
|
||||
Set the global effect flags.
|
||||
|
||||
#### Arguments {#api-led-matrix-set-flags-arguments}
|
||||
|
||||
- `led_flags_t flags`
|
||||
The [flags](#flags) value to set.
|
||||
|
||||
---
|
||||
|
||||
### `void led_matrix_set_flags_noeeprom(led_flags_t flags)` {#api-led-matrix-set-flags-noeeprom}
|
||||
|
||||
Set the global effect flags. New state is not written to EEPROM.
|
||||
|
||||
#### Arguments {#api-led-matrix-set-flags-noeeprom-arguments}
|
||||
|
||||
- `led_flags_t flags`
|
||||
The [flags](#flags) value to set.
|
||||
|
||||
---
|
||||
|
||||
### `void led_matrix_flags_step(void)` {#api-led-matrix-flags-step}
|
||||
|
||||
Move to the next flag combination.
|
||||
|
||||
---
|
||||
|
||||
### `void led_matrix_flags_step_noeeprom(void)` {#api-led-matrix-flags-step-noeeprom}
|
||||
|
||||
Move to the next flag combination. New state is not written to EEPROM.
|
||||
|
||||
---
|
||||
|
||||
### `void led_matrix_flags_step_reverse(void)` {#api-led-matrix-flags-step-reverse}
|
||||
|
||||
Move to the previous flag combination.
|
||||
|
||||
---
|
||||
|
||||
### `void led_matrix_flags_step_reverse_noeeprom(void)` {#api-led-matrix-flags-step-reverse-noeeprom}
|
||||
|
||||
Move to the previous flag combination. New state is not written to EEPROM.
|
||||
|
||||
---
|
||||
|
||||
### `uint8_t led_matrix_get_flags(void)` {#api-led-matrix-get-flags}
|
||||
|
||||
Get the current global effect flags.
|
||||
|
||||
#### Return Value {#api-led-matrix-get-flags-return}
|
||||
|
||||
The current effect [flags](#flags).
|
||||
|
||||
---
|
||||
|
||||
### `void led_matrix_reload_from_eeprom(void)` {#api-led-matrix-reload-from-eeprom}
|
||||
|
||||
Reload the effect configuration (enabled, mode and brightness) from EEPROM.
|
||||
|
||||
@@ -267,6 +267,23 @@ The paw 3204 sensor uses a serial type protocol for communication, and requires
|
||||
|
||||
The CPI range is 400-1600, with supported values of (400, 500, 600, 800, 1000, 1200 and 1600). Defaults to 1000 CPI.
|
||||
|
||||
### PAW-3222 Sensor
|
||||
|
||||
To use the PAW-3222 sensor, add this to your `rules.mk`:
|
||||
|
||||
```make
|
||||
POINTING_DEVICE_DRIVER = paw3222
|
||||
```
|
||||
|
||||
The following pins must be defined in `config.h`:
|
||||
|
||||
| Setting (`config.h`) | Description | Default |
|
||||
| --------------------- | ------------------------------------------------------------------ | ---------------------------- |
|
||||
| `PAW3222_CS_PIN` | (Required) The pin connected to the chip select pin of the sensor. | `POINTING_DEVICE_CS_PIN` |
|
||||
| `PAW3222_SPI_DIVISOR` | (Required) The SPI clock divisor. This is dependent on your MCU. | _not defined_ |
|
||||
|
||||
The CPI range is up to 4,000. Defaults to 1,000 CPI.
|
||||
|
||||
### Pimoroni Trackball
|
||||
|
||||
To use the Pimoroni Trackball module, add this to your `rules.mk`:
|
||||
|
||||
@@ -96,6 +96,8 @@ As mentioned earlier, the center of the keyboard by default is expected to be `{
|
||||
|`QK_RGB_MATRIX_VALUE_DOWN` |`RM_VALD`|Decrease the brightness level |
|
||||
|`QK_RGB_MATRIX_SPEED_UP` |`RM_SPDU`|Increase the animation speed |
|
||||
|`QK_RGB_MATRIX_SPEED_DOWN` |`RM_SPDD`|Decrease the animation speed |
|
||||
|`QK_RGB_MATRIX_FLAG_NEXT` |`RM_FLGN`|Cycle through flags |
|
||||
|`QK_RGB_MATRIX_FLAG_PREVIOUS` |`RM_FLGP`|Cycle through flags in reverse |
|
||||
|
||||
## RGB Matrix Effects {#rgb-matrix-effects}
|
||||
|
||||
@@ -409,6 +411,7 @@ const char* effect_name = rgb_matrix_get_mode_name(rgb_matrix_get_mode());
|
||||
#define RGB_MATRIX_SPLIT { X, Y } // (Optional) For split keyboards, the number of LEDs connected on each half. X = left, Y = Right.
|
||||
// If reactive effects are enabled, you also will want to enable SPLIT_TRANSPORT_MIRROR
|
||||
#define RGB_TRIGGER_ON_KEYDOWN // Triggers RGB keypress events on key down. This makes RGB control feel more responsive. This may cause RGB to not function properly on some boards
|
||||
#define RGB_MATRIX_FLAG_STEPS { LED_FLAG_ALL, LED_FLAG_KEYLIGHT | LED_FLAG_MODIFIER, LED_FLAG_UNDERGLOW, LED_FLAG_NONE } // Sets the flags which can be cycled through.
|
||||
```
|
||||
|
||||
## EEPROM storage {#eeprom-storage}
|
||||
@@ -852,6 +855,62 @@ The current effect speed, from 0 to 255.
|
||||
|
||||
---
|
||||
|
||||
### `void rgb_matrix_set_flags(led_flags_t flags)` {#api-rgb-matrix-set-flags}
|
||||
|
||||
Set the global effect flags.
|
||||
|
||||
#### Arguments {#api-rgb-matrix-set-flags-arguments}
|
||||
|
||||
- `led_flags_t flags`
|
||||
The [flags](#flags) value to set.
|
||||
|
||||
---
|
||||
|
||||
### `void rgb_matrix_set_flags_noeeprom(led_flags_t flags)` {#api-rgb-matrix-set-flags-noeeprom}
|
||||
|
||||
Set the global effect flags. New state is not written to EEPROM.
|
||||
|
||||
#### Arguments {#api-rgb-matrix-set-flags-noeeprom-arguments}
|
||||
|
||||
- `led_flags_t flags`
|
||||
The [flags](#flags) value to set.
|
||||
|
||||
---
|
||||
|
||||
### `void rgb_matrix_flags_step(void)` {#api-rgb-matrix-flags-step}
|
||||
|
||||
Move to the next flag combination.
|
||||
|
||||
---
|
||||
|
||||
### `void rgb_matrix_flags_step_noeeprom(void)` {#api-rgb-matrix-flags-step-noeeprom}
|
||||
|
||||
Move to the next flag combination. New state is not written to EEPROM.
|
||||
|
||||
---
|
||||
|
||||
### `void rgb_matrix_flags_step_reverse(void)` {#api-rgb-matrix-flags-step-reverse}
|
||||
|
||||
Move to the previous flag combination.
|
||||
|
||||
---
|
||||
|
||||
### `void rgb_matrix_flags_step_reverse_noeeprom(void)` {#api-rgb-matrix-flags-step-reverse-noeeprom}
|
||||
|
||||
Move to the previous flag combination. New state is not written to EEPROM.
|
||||
|
||||
---
|
||||
|
||||
### `uint8_t rgb_matrix_get_flags(void)` {#api-rgb-matrix-get-flags}
|
||||
|
||||
Get the current global effect flags.
|
||||
|
||||
#### Return Value {#api-rgb-matrix-get-flags-return}
|
||||
|
||||
The current effect [flags](#flags).
|
||||
|
||||
---
|
||||
|
||||
### `void rgb_matrix_sethsv(uint8_t h, uint8_t s, uint8_t v)` {#api-rgb-matrix-sethsv}
|
||||
|
||||
Set the global effect hue, saturation, and value (brightness).
|
||||
|
||||
@@ -40,6 +40,10 @@ Similar to the first option, the second and third option are good for simple lay
|
||||
|
||||
For more complicated cases, like blink the LEDs, fiddle with the backlighting, and so on, use the fourth or fifth option. Examples of each are listed below.
|
||||
|
||||
::: tip
|
||||
If too many tap dances are active at the same time, later ones won't have any effect. You need to increase `TAP_DANCE_MAX_SIMULTANEOUS` by adding `#define TAP_DANCE_MAX_SIMULTANEOUS 5` (or higher) to your keymap's `config.h` file if you expect that users may hold down many tap dance keys simultaneously. By default, only 3 tap dance keys can be used together at the same time.
|
||||
:::
|
||||
|
||||
## Implementation Details {#implementation}
|
||||
|
||||
Well, that's the bulk of it! You should now be able to work through the examples below, and to develop your own Tap Dance functionality. But if you want a deeper understanding of what's going on behind the scenes, then read on for the explanation of how it all works!
|
||||
@@ -209,11 +213,13 @@ tap_dance_action_t tap_dance_actions[] = {
|
||||
|
||||
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
tap_dance_action_t *action;
|
||||
tap_dance_state_t* state;
|
||||
|
||||
switch (keycode) {
|
||||
case TD(CT_CLN): // list all tap dance keycodes with tap-hold configurations
|
||||
action = &tap_dance_actions[QK_TAP_DANCE_GET_INDEX(keycode)];
|
||||
if (!record->event.pressed && action->state.count && !action->state.finished) {
|
||||
case TD(CT_CLN):
|
||||
action = tap_dance_get(QK_TAP_DANCE_GET_INDEX(keycode));
|
||||
state = tap_dance_get_state(QK_TAP_DANCE_GET_INDEX(keycode));
|
||||
if (!record->event.pressed && state != NULL && state->count && !state->finished) {
|
||||
tap_dance_tap_hold_t *tap_hold = (tap_dance_tap_hold_t *)action->user_data;
|
||||
tap_code16(tap_hold->tap);
|
||||
}
|
||||
|
||||
@@ -220,14 +220,18 @@ This bootloader is primarily for keyboards originally designed for the PS2AVRGB
|
||||
|
||||
USBaspLoader is a bootloader based on V-USB that emulates a hardware USBasp device. It runs on ATmega32A and ATmega328P MCUs.
|
||||
|
||||
Precompiled `.hex` files are generally not available, but you can compile it yourself by setting up the QMK environment and following Coseyfannitutti's guide for the appropriate MCU:
|
||||
Precompiled `.hex` files are generally not available, but you can compile it yourself by setting up the QMK environment and cloning the appropriate branch of Coseyfannitutti's USBaspLoader fork:
|
||||
|
||||
|MCU |Low |High |Extended|USB ID |
|
||||
|-------------------------------------------------------------------------------------|------|------|--------|-----------|
|
||||
|[ATmega32A](https://github.com/coseyfannitutti/discipline/tree/master/doc/bootloader)|`0x1F`|`0xC0`|*n/a* |`16C0:05DC`|
|
||||
|[ATmega328P](https://github.com/coseyfannitutti/discipad/tree/master/doc/bootloader) |`0xD7`|`0xD0`|`0x04` |`16C0:05DC`|
|
||||
|MCU |Low |High |Extended|USB ID |
|
||||
|-----------------------------------------------------------------------------|------|------|--------|-----------|
|
||||
|[ATmega32A](https://github.com/coseyfannitutti/USBaspLoader/tree/atmega32a) |`0x1F`|`0xC0`|*n/a* |`16C0:05DC`|
|
||||
|[ATmega328P](https://github.com/coseyfannitutti/USBaspLoader/tree/atmega328p)|`0xD7`|`0xD0`|`0x04` |`16C0:05DC`|
|
||||
|
||||
Note that some boards may have their own specialized build of this bootloader in a separate repository. This will usually be linked to in the board's readme.
|
||||
From there, simply `cd` to the `firmware/` directory and run `make`, which should produce a file called `main.hex`.
|
||||
|
||||
:::tip
|
||||
Some boards may have their own specialized build of this bootloader in a separate repository. This will usually be linked to in the board's readme.
|
||||
:::
|
||||
|
||||
## Flashing the Bootloader
|
||||
|
||||
|
||||
@@ -433,6 +433,8 @@ See also: [LED Matrix](features/led_matrix)
|
||||
|`QK_LED_MATRIX_BRIGHTNESS_DOWN`|`LM_BRID`|Decrease the brightness level |
|
||||
|`QK_LED_MATRIX_SPEED_UP` |`LM_SPDU`|Increase the animation speed |
|
||||
|`QK_LED_MATRIX_SPEED_DOWN` |`LM_SPDD`|Decrease the animation speed |
|
||||
|`QK_LED_MATRIX_FLAG_NEXT` |`LM_FLGN`|Cycle through flags |
|
||||
|`QK_LED_MATRIX_FLAG_PREVIOUS` |`LM_FLGP`|Cycle through flags in reverse |
|
||||
|
||||
## Magic Keycodes {#magic-keycodes}
|
||||
|
||||
@@ -783,6 +785,8 @@ See also: [RGB Matrix](features/rgb_matrix)
|
||||
|`QK_RGB_MATRIX_VALUE_DOWN` |`RM_VALD`|Decrease the brightness level |
|
||||
|`QK_RGB_MATRIX_SPEED_UP` |`RM_SPDU`|Increase the animation speed |
|
||||
|`QK_RGB_MATRIX_SPEED_DOWN` |`RM_SPDD`|Decrease the animation speed |
|
||||
|`QK_RGB_MATRIX_FLAG_NEXT` |`RM_FLGN`|Cycle through flags |
|
||||
|`QK_RGB_MATRIX_FLAG_PREVIOUS` |`RM_FLGP`|Cycle through flags in reverse |
|
||||
|
||||
## US ANSI Shifted Symbols {#us-ansi-shifted-symbols}
|
||||
|
||||
|
||||
@@ -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).
|
||||
:::
|
||||
|
||||
:::::
|
||||
|
||||
|
||||
61
docs/public/pin_compatible_elite_c.svg
Normal file
61
docs/public/pin_compatible_elite_c.svg
Normal file
File diff suppressed because one or more lines are too long
|
After Width: | Height: | Size: 6.4 KiB |
61
docs/public/pin_compatible_promicro.svg
Normal file
61
docs/public/pin_compatible_promicro.svg
Normal file
File diff suppressed because one or more lines are too long
|
After Width: | Height: | Size: 6.2 KiB |
@@ -534,6 +534,8 @@ QUANTUM_PAINTER_DRIVERS += surface
|
||||
Creating a surface in firmware can then be done with the following APIs:
|
||||
|
||||
```c
|
||||
// 24bpp RGB888 surface:
|
||||
painter_device_t qp_make_rgb888_surface(uint16_t panel_width, uint16_t panel_height, void *buffer);
|
||||
// 16bpp RGB565 surface:
|
||||
painter_device_t qp_make_rgb565_surface(uint16_t panel_width, uint16_t panel_height, void *buffer);
|
||||
// 1bpp monochrome surface:
|
||||
|
||||
@@ -327,6 +327,21 @@ Configures the [LED Indicators](features/led_indicators) feature.
|
||||
* `scroll_lock` <Badge type="info">Pin</Badge>
|
||||
* The GPIO pin connected to the Scroll Lock LED.
|
||||
|
||||
## (Custom) Keycodes {#keycodes}
|
||||
|
||||
Defines [custom keycodes](custom_quantum_functions#definining-a-new-keycode) for use within keymaps.
|
||||
|
||||
* `keycodes` <Badge type="info">Array: Object</Badge>
|
||||
* A list of keycode objects.
|
||||
* `key` <Badge type="info">String</Badge> <Badge>Required</Badge>
|
||||
* The enum name of the custom keycode.
|
||||
* Example: `LAYER_CHANGE_BEEP_ON`
|
||||
* `label` <Badge type="info">String</Badge>
|
||||
* A short description of the custom keycode.
|
||||
* `aliases` <Badge type="info">Array: String</Badge>
|
||||
* A list of shortened names for the custom keycode.
|
||||
* Example: `["LCBON", "LCB_ON"]`
|
||||
|
||||
## Layouts {#layouts}
|
||||
|
||||
The `layouts` portion of the dictionary contains several nested dictionaries. The outer layer consists of QMK layout names, for example `LAYOUT_60_ansi` or `LAYOUT_60_iso`.
|
||||
@@ -415,6 +430,9 @@ Configures the [LED Matrix](features/led_matrix) feature.
|
||||
* `center_point` <Badge type="info">Array: Number</Badge>
|
||||
* The centroid (geometric center) of the LEDs. Used for certain effects.
|
||||
* Default: `[112, 32]`
|
||||
* `flag_steps` <Badge type="info">Array: Number</Badge>
|
||||
* A list of flag bitfields that can be cycled through.
|
||||
* Default: `[255, 5, 0]`
|
||||
* `default`
|
||||
* `animation` <Badge type="info">String</Badge>
|
||||
* The default effect. Must be one of `led_matrix.animations`
|
||||
@@ -428,6 +446,9 @@ Configures the [LED Matrix](features/led_matrix) feature.
|
||||
* `speed` <Badge type="info">Number</Badge>
|
||||
* The default animation speed.
|
||||
* Default: `128`
|
||||
* `flags` <Badge type="info">Number</Badge>
|
||||
* The default LED flags.
|
||||
* Default: `255`
|
||||
* `driver` <Badge type="info">String</Badge> <Badge>Required</Badge>
|
||||
* The driver to use. Must be one of `custom`, `is31fl3218`, `is31fl3731`, `is31fl3733`, `is31fl3736`, `is31fl3737`, `is31fl3741`, `is31fl3742a`, `is31fl3743a`, `is31fl3745`, `is31fl3746a`, `snled27351`.
|
||||
* `layout` <Badge type="info">Array: Object</Badge> <Badge>Required</Badge>
|
||||
@@ -507,7 +528,7 @@ Configures the [LED Matrix](features/led_matrix) feature.
|
||||
* 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.
|
||||
* Whether unconfigured intersections should be ignored.
|
||||
* Default: `false`
|
||||
* `rows` <Badge type="info">Array: Pin</Badge>
|
||||
* A list of GPIO pins connected to the matrix rows.
|
||||
@@ -660,6 +681,9 @@ Configures the [RGB Matrix](features/rgb_matrix) feature.
|
||||
* `center_point` <Badge type="info">Array: Number</Badge>
|
||||
* The centroid (geometric center) of the LEDs. Used for certain effects.
|
||||
* Default: `[112, 32]`
|
||||
* `flag_steps` <Badge type="info">Array: Number</Badge>
|
||||
* A list of flag bitfields that can be cycled through.
|
||||
* Default: `[255, 5, 2, 0]`
|
||||
* `default`
|
||||
* `animation` <Badge type="info">String</Badge>
|
||||
* The default effect. Must be one of `rgb_matrix.animations`
|
||||
@@ -679,6 +703,9 @@ Configures the [RGB Matrix](features/rgb_matrix) feature.
|
||||
* `speed` <Badge type="info">Number</Badge>
|
||||
* The default animation speed.
|
||||
* Default: `128`
|
||||
* `flags` <Badge type="info">Number</Badge>
|
||||
* The default LED flags.
|
||||
* Default: `255`
|
||||
* `driver` <Badge type="info">String</Badge> <Badge>Required</Badge>
|
||||
* The driver to use. Must be one of `aw20216s`, `custom`, `is31fl3218`, `is31fl3236`, `is31fl3729`, `is31fl3731`, `is31fl3733`, `is31fl3736`, `is31fl3737`, `is31fl3741`, `is31fl3742a`, `is31fl3743a`, `is31fl3745`, `is31fl3746a`, `snled27351`, `ws2812`.
|
||||
* `hue_steps` <Badge type="info">Number</Badge>
|
||||
|
||||
@@ -87,26 +87,6 @@ Or if you're not using layers at all, you can outright remove the functionality
|
||||
#define NO_ACTION_LAYER
|
||||
```
|
||||
|
||||
## Magic Functions
|
||||
|
||||
There are two `__attribute__ ((weak))` placeholder functions available to customize magic keycodes. If you are not using that feature to swap keycodes, such as backslash with backspace, add the following to your `keymap.c` or user space code:
|
||||
```c
|
||||
#ifndef MAGIC_ENABLE
|
||||
uint16_t keycode_config(uint16_t keycode) {
|
||||
return keycode;
|
||||
}
|
||||
#endif
|
||||
```
|
||||
Likewise, if you are not using magic keycodes to swap modifiers, such as Control with GUI, add the following to your `keymap.c` or user space code:
|
||||
```c
|
||||
#ifndef MAGIC_ENABLE
|
||||
uint8_t mod_config(uint8_t mod) {
|
||||
return mod;
|
||||
}
|
||||
#endif
|
||||
```
|
||||
Both of them will overwrite the placeholder functions with a simple return statement to reduce firmware size.
|
||||
|
||||
## OLED tweaks
|
||||
|
||||
One place you can save a bunch of space here is by not using `sprintf` or `snprintf`. This function call takes up ~1.5kB of firmware space, and can be rewritten. For instance, WPM uses this a lot.
|
||||
|
||||
@@ -779,6 +779,39 @@ Do not use `MOD_xxx` constants like `MOD_LSFT` or `MOD_RALT`, since they're 5-bi
|
||||
|
||||
[Auto Shift](features/auto_shift) has its own version of `retro tapping` called `retro shift`. It is extremely similar to `retro tapping`, but holding the key past `AUTO_SHIFT_TIMEOUT` results in the value it sends being shifted. Other configurations also affect it differently; see [here](features/auto_shift#retro-shift) for more information.
|
||||
|
||||
### Speculative Hold
|
||||
|
||||
Speculative Hold makes mod-tap keys more responsive by applying the modifier instantly on keydown, before the tap-hold decision is made. This is especially useful for actions like Shift+Click with a mouse, which can feel laggy with standard mod-taps.
|
||||
|
||||
The firmware holds the modifier speculatively. Once the key's behavior is settled:
|
||||
|
||||
* If held, the modifier remains active as expected until the key is released.
|
||||
* If tapped, the speculative modifier is canceled just before the tapping keycode is sent.
|
||||
|
||||
Speculative Hold applies the modifier early but does not change the underlying tap-hold decision logic. Speculative Hold is compatible to use in combination with any other tap-hold options.
|
||||
|
||||
To enable Speculative Hold, add the following to your `config.h`:
|
||||
|
||||
```c
|
||||
#define SPECULATIVE_HOLD
|
||||
```
|
||||
|
||||
By default, Speculative Hold applies to mod-taps using Shift, Ctrl, or Shift + Ctrl. You can override this behavior by defining the `get_speculative_hold()` callback in your keymap, for instance:
|
||||
|
||||
```c
|
||||
bool get_speculative_hold(uint16_t keycode, keyrecord_t* record) {
|
||||
switch (keycode) { // These keys may be speculatively held.
|
||||
case LCTL_T(KC_ESC):
|
||||
case LSFT_T(KC_Z):
|
||||
case RSFT_T(KC_SLSH):
|
||||
return true;
|
||||
}
|
||||
return false; // Disable otherwise.
|
||||
}
|
||||
```
|
||||
|
||||
Some operating systems or applications assign actions to tapping a modifier key by itself, e.g., tapping GUI to open a start menu. Because Speculative Hold sends a lone modifier key press in some cases, it can falsely trigger these actions. To prevent this, set `DUMMY_MOD_NEUTRALIZER_KEYCODE` (and optionally `MODS_TO_NEUTRALIZE`) in your `config.h` in the same way as described above for [Retro Tapping](#retro-tapping).
|
||||
|
||||
## Why do we include the key record for the per key functions?
|
||||
|
||||
One thing that you may notice is that we include the key record for all of the "per key" functions, and may be wondering why we do that.
|
||||
|
||||
@@ -364,7 +364,7 @@ static bool read_response(char *resp, uint16_t resplen, bool verbose) {
|
||||
}
|
||||
|
||||
static bool at_command(const char *cmd, char *resp, uint16_t resplen, bool verbose, uint16_t timeout) {
|
||||
const char * end = cmd + strlen(cmd);
|
||||
const char *end = cmd + strlen(cmd);
|
||||
struct sdep_msg msg;
|
||||
|
||||
if (verbose) {
|
||||
|
||||
@@ -104,7 +104,7 @@ void eeprom_read_block(void *buf, const void *addr, size_t len) {
|
||||
|
||||
void eeprom_write_block(const void *buf, void *addr, size_t len) {
|
||||
uint8_t complete_packet[EXTERNAL_EEPROM_ADDRESS_SIZE + EXTERNAL_EEPROM_PAGE_SIZE];
|
||||
uint8_t * read_buf = (uint8_t *)buf;
|
||||
uint8_t *read_buf = (uint8_t *)buf;
|
||||
uintptr_t target_addr = (uintptr_t)addr;
|
||||
|
||||
#if defined(EXTERNAL_EEPROM_WP_PIN)
|
||||
|
||||
@@ -154,7 +154,7 @@ void eeprom_read_block(void *buf, const void *addr, size_t len) {
|
||||
|
||||
void eeprom_write_block(const void *buf, void *addr, size_t len) {
|
||||
bool res;
|
||||
uint8_t * read_buf = (uint8_t *)buf;
|
||||
uint8_t *read_buf = (uint8_t *)buf;
|
||||
uintptr_t target_addr = (uintptr_t)addr;
|
||||
|
||||
while (len > 0) {
|
||||
|
||||
@@ -113,7 +113,7 @@ void encoder_driver_init(void) {
|
||||
thisCount = isLeftHand ? NUM_ENCODERS_LEFT : NUM_ENCODERS_RIGHT;
|
||||
thatCount = isLeftHand ? NUM_ENCODERS_RIGHT : NUM_ENCODERS_LEFT;
|
||||
#else // SPLIT_KEYBOARD
|
||||
thisCount = NUM_ENCODERS;
|
||||
thisCount = NUM_ENCODERS;
|
||||
#endif
|
||||
|
||||
#ifdef ENCODER_TESTS
|
||||
|
||||
@@ -291,7 +291,7 @@ flash_status_t flash_erase_block(uint32_t addr) {
|
||||
|
||||
flash_status_t flash_read_range(uint32_t addr, void *buf, size_t len) {
|
||||
flash_status_t response = FLASH_STATUS_SUCCESS;
|
||||
uint8_t * read_buf = (uint8_t *)buf;
|
||||
uint8_t *read_buf = (uint8_t *)buf;
|
||||
|
||||
/* Wait for the write-in-progress bit to be cleared. */
|
||||
response = spi_flash_wait_while_busy();
|
||||
@@ -322,7 +322,7 @@ flash_status_t flash_read_range(uint32_t addr, void *buf, size_t len) {
|
||||
|
||||
flash_status_t flash_write_range(uint32_t addr, const void *buf, size_t len) {
|
||||
flash_status_t response = FLASH_STATUS_SUCCESS;
|
||||
uint8_t * write_buf = (uint8_t *)buf;
|
||||
uint8_t *write_buf = (uint8_t *)buf;
|
||||
|
||||
while (len > 0) {
|
||||
uint32_t page_offset = addr % EXTERNAL_FLASH_PAGE_SIZE;
|
||||
|
||||
@@ -47,8 +47,7 @@
|
||||
|
||||
#ifndef SOLENOID_PINS
|
||||
# ifdef SOLENOID_PIN
|
||||
# define SOLENOID_PINS \
|
||||
{ SOLENOID_PIN }
|
||||
# define SOLENOID_PINS {SOLENOID_PIN}
|
||||
# else
|
||||
# error SOLENOID_PINS array not defined
|
||||
# endif
|
||||
|
||||
@@ -72,6 +72,21 @@ i2c_status_t i2c_transmit_P(uint8_t address, const uint8_t* data, uint16_t lengt
|
||||
*/
|
||||
i2c_status_t i2c_receive(uint8_t address, uint8_t* data, uint16_t length, uint16_t timeout);
|
||||
|
||||
/**
|
||||
* \brief Send multiple bytes and then receive multiple bytes from the selected I2C device.
|
||||
*
|
||||
* \param address The 7-bit I2C address of the device.
|
||||
* \param tx_data A pointer to the data to transmit.
|
||||
* \param tx_length The number of bytes to write. Take care not to overrun the length of `tx_data`.
|
||||
* \param rx_data A pointer to a buffer to read into.
|
||||
* \param rx_length The number of bytes to read. Take care not to overrun the length of `rx_data`.
|
||||
* \param timeout The time in milliseconds to wait for a response from the target device.
|
||||
*
|
||||
* \return `I2C_STATUS_TIMEOUT` if the timeout period elapses, `I2C_STATUS_ERROR` if some other error occurs, otherwise `I2C_STATUS_SUCCESS`.
|
||||
*/
|
||||
|
||||
i2c_status_t i2c_transmit_and_receive(uint8_t address, const uint8_t* tx_data, uint16_t tx_length, uint8_t* rx_data, uint16_t rx_length, uint16_t timeout);
|
||||
|
||||
/**
|
||||
* \brief Write to a register with an 8-bit address on the I2C device.
|
||||
*
|
||||
|
||||
@@ -70,7 +70,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
// parts of the display unusable or don't get cleared correctly
|
||||
// and also allows for drawing & inverting
|
||||
uint8_t st7565_buffer[ST7565_MATRIX_SIZE];
|
||||
uint8_t * st7565_cursor;
|
||||
uint8_t *st7565_cursor;
|
||||
ST7565_BLOCK_TYPE st7565_dirty = 0;
|
||||
bool st7565_initialized = false;
|
||||
bool st7565_active = false;
|
||||
|
||||
@@ -34,8 +34,7 @@
|
||||
#endif
|
||||
|
||||
#ifndef SNLED27351_CURRENT_TUNE
|
||||
# define SNLED27351_CURRENT_TUNE \
|
||||
{ 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF }
|
||||
# define SNLED27351_CURRENT_TUNE {0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF}
|
||||
#endif
|
||||
|
||||
const uint8_t i2c_addresses[SNLED27351_DRIVER_COUNT] = {
|
||||
|
||||
@@ -34,8 +34,7 @@
|
||||
#endif
|
||||
|
||||
#ifndef SNLED27351_CURRENT_TUNE
|
||||
# define SNLED27351_CURRENT_TUNE \
|
||||
{ 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF }
|
||||
# define SNLED27351_CURRENT_TUNE {0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF}
|
||||
#endif
|
||||
|
||||
const uint8_t i2c_addresses[SNLED27351_DRIVER_COUNT] = {
|
||||
|
||||
@@ -1,16 +1,256 @@
|
||||
// Copyright 2025 QMK
|
||||
// SPDX-License-Identifier: GPL-2.0-or-later WITH BSD-2-Clause
|
||||
|
||||
#include "progmem.h"
|
||||
|
||||
// Helidox 8x6 font with QMK Firmware Logo
|
||||
// Online editor: http://teripom.x0.com/
|
||||
|
||||
/**
|
||||
* QMK 6x8 Font for LCD and OLED displays
|
||||
*
|
||||
* Derived from the first half of the Adafruit GFX Library font:
|
||||
* https://github.com/adafruit/Adafruit-GFX-Library
|
||||
*
|
||||
* The first 128 characters match that of code page 437, the character set used by the original IBM PC, which includes all printable ASCII characters.
|
||||
* Each byte represents a column of 8 pixels, with the least significant bit being the top of the glyph.
|
||||
*
|
||||
* A large 21x3 character QMK Firmware logo is encoded from 0x80-0x94, 0xA0-0xB4, and 0xC0-0xD4.
|
||||
* 2x2 character OS logos for Apple, Windows, Linux and Android are encoded from 0x95-0x9C and 0xB5-0xBC.
|
||||
*/
|
||||
static const unsigned char font[] PROGMEM = {
|
||||
0x07, 0x08, 0x7F, 0x08, 0x07, 0x00, 0x3E, 0x5B, 0x4F, 0x5B, 0x3E, 0x00, 0x3E, 0x6B, 0x4F, 0x6B, 0x3E, 0x00, 0x1C, 0x3E, 0x7C, 0x3E, 0x1C, 0x00, 0x18, 0x3C, 0x7E, 0x3C, 0x18, 0x00, 0x1C, 0x57, 0x7D, 0x57, 0x1C, 0x00, 0x1C, 0x5E, 0x7F, 0x5E, 0x1C, 0x00, 0x00, 0x18, 0x3C, 0x18, 0x00, 0x00, 0xFF, 0xE7, 0xC3, 0xE7, 0xFF, 0x00, 0x00, 0x18, 0x24, 0x18, 0x00, 0x00, 0xFF, 0xE7, 0xDB, 0xE7, 0xFF, 0x00, 0x30, 0x48, 0x3A, 0x06, 0x0E, 0x00, 0x26, 0x29, 0x79, 0x29, 0x26, 0x00, 0x40, 0x7F, 0x05, 0x05, 0x07, 0x00, 0x40, 0x7F, 0x05, 0x25, 0x3F, 0x00, 0x5A, 0x3C, 0xE7, 0x3C, 0x5A, 0x00, 0x7F, 0x3E, 0x1C, 0x1C, 0x08, 0x00, 0x08, 0x1C, 0x1C, 0x3E, 0x7F, 0x00, 0x14, 0x22, 0x7F, 0x22, 0x14, 0x00, 0x5F, 0x5F, 0x00, 0x5F, 0x5F, 0x00, 0x06, 0x09, 0x7F, 0x01, 0x7F, 0x00, 0x00, 0x66, 0x89, 0x95, 0x6A, 0x00, 0x60, 0x60, 0x60, 0x60, 0x60, 0x00, 0x94, 0xA2, 0xFF, 0xA2, 0x94, 0x00, 0x08, 0x04, 0x7E, 0x04, 0x08, 0x00,
|
||||
0x10, 0x20, 0x7E, 0x20, 0x10, 0x00, 0x08, 0x08, 0x2A, 0x1C, 0x08, 0x00, 0x08, 0x1C, 0x2A, 0x08, 0x08, 0x00, 0x1E, 0x10, 0x10, 0x10, 0x10, 0x00, 0x0C, 0x1E, 0x0C, 0x1E, 0x0C, 0x00, 0x30, 0x38, 0x3E, 0x38, 0x30, 0x00, 0x06, 0x0E, 0x3E, 0x0E, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x5F, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x07, 0x00, 0x00, 0x14, 0x7F, 0x14, 0x7F, 0x14, 0x00, 0x24, 0x2A, 0x7F, 0x2A, 0x12, 0x00, 0x23, 0x13, 0x08, 0x64, 0x62, 0x00, 0x36, 0x49, 0x56, 0x20, 0x50, 0x00, 0x00, 0x08, 0x07, 0x03, 0x00, 0x00, 0x00, 0x1C, 0x22, 0x41, 0x00, 0x00, 0x00, 0x41, 0x22, 0x1C, 0x00, 0x00, 0x2A, 0x1C, 0x7F, 0x1C, 0x2A, 0x00, 0x08, 0x08, 0x3E, 0x08, 0x08, 0x00, 0x00, 0x80, 0x70, 0x30, 0x00, 0x00, 0x08, 0x08, 0x08, 0x08, 0x08, 0x00, 0x00, 0x00, 0x60, 0x60, 0x00, 0x00, 0x20, 0x10, 0x08, 0x04, 0x02, 0x00, 0x3E, 0x51, 0x49, 0x45, 0x3E, 0x00, 0x00, 0x42, 0x7F, 0x40, 0x00, 0x00,
|
||||
0x72, 0x49, 0x49, 0x49, 0x46, 0x00, 0x21, 0x41, 0x49, 0x4D, 0x33, 0x00, 0x18, 0x14, 0x12, 0x7F, 0x10, 0x00, 0x27, 0x45, 0x45, 0x45, 0x39, 0x00, 0x3C, 0x4A, 0x49, 0x49, 0x31, 0x00, 0x41, 0x21, 0x11, 0x09, 0x07, 0x00, 0x36, 0x49, 0x49, 0x49, 0x36, 0x00, 0x46, 0x49, 0x49, 0x29, 0x1E, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, 0x00, 0x40, 0x34, 0x00, 0x00, 0x00, 0x00, 0x08, 0x14, 0x22, 0x41, 0x00, 0x14, 0x14, 0x14, 0x14, 0x14, 0x00, 0x00, 0x41, 0x22, 0x14, 0x08, 0x00, 0x02, 0x01, 0x59, 0x09, 0x06, 0x00, 0x3E, 0x41, 0x5D, 0x59, 0x4E, 0x00, 0x7C, 0x12, 0x11, 0x12, 0x7C, 0x00, 0x7F, 0x49, 0x49, 0x49, 0x36, 0x00, 0x3E, 0x41, 0x41, 0x41, 0x22, 0x00, 0x7F, 0x41, 0x41, 0x41, 0x3E, 0x00, 0x7F, 0x49, 0x49, 0x49, 0x41, 0x00, 0x7F, 0x09, 0x09, 0x09, 0x01, 0x00, 0x3E, 0x41, 0x41, 0x51, 0x73, 0x00, 0x7F, 0x08, 0x08, 0x08, 0x7F, 0x00, 0x00, 0x41, 0x7F, 0x41, 0x00, 0x00, 0x20, 0x40, 0x41, 0x3F, 0x01, 0x00,
|
||||
0x7F, 0x08, 0x14, 0x22, 0x41, 0x00, 0x7F, 0x40, 0x40, 0x40, 0x40, 0x00, 0x7F, 0x02, 0x1C, 0x02, 0x7F, 0x00, 0x7F, 0x04, 0x08, 0x10, 0x7F, 0x00, 0x3E, 0x41, 0x41, 0x41, 0x3E, 0x00, 0x7F, 0x09, 0x09, 0x09, 0x06, 0x00, 0x3E, 0x41, 0x51, 0x21, 0x5E, 0x00, 0x7F, 0x09, 0x19, 0x29, 0x46, 0x00, 0x26, 0x49, 0x49, 0x49, 0x32, 0x00, 0x03, 0x01, 0x7F, 0x01, 0x03, 0x00, 0x3F, 0x40, 0x40, 0x40, 0x3F, 0x00, 0x1F, 0x20, 0x40, 0x20, 0x1F, 0x00, 0x3F, 0x40, 0x38, 0x40, 0x3F, 0x00, 0x63, 0x14, 0x08, 0x14, 0x63, 0x00, 0x03, 0x04, 0x78, 0x04, 0x03, 0x00, 0x61, 0x59, 0x49, 0x4D, 0x43, 0x00, 0x00, 0x7F, 0x41, 0x41, 0x41, 0x00, 0x02, 0x04, 0x08, 0x10, 0x20, 0x00, 0x00, 0x41, 0x41, 0x41, 0x7F, 0x00, 0x04, 0x02, 0x01, 0x02, 0x04, 0x00, 0x40, 0x40, 0x40, 0x40, 0x40, 0x00, 0x00, 0x03, 0x07, 0x08, 0x00, 0x00, 0x20, 0x54, 0x54, 0x78, 0x40, 0x00, 0x7F, 0x28, 0x44, 0x44, 0x38, 0x00, 0x38, 0x44, 0x44, 0x44, 0x28, 0x00,
|
||||
0x38, 0x44, 0x44, 0x28, 0x7F, 0x00, 0x38, 0x54, 0x54, 0x54, 0x18, 0x00, 0x00, 0x08, 0x7E, 0x09, 0x02, 0x00, 0x18, 0xA4, 0xA4, 0x9C, 0x78, 0x00, 0x7F, 0x08, 0x04, 0x04, 0x78, 0x00, 0x00, 0x44, 0x7D, 0x40, 0x00, 0x00, 0x20, 0x40, 0x40, 0x3D, 0x00, 0x00, 0x7F, 0x10, 0x28, 0x44, 0x00, 0x00, 0x00, 0x41, 0x7F, 0x40, 0x00, 0x00, 0x7C, 0x04, 0x78, 0x04, 0x78, 0x00, 0x7C, 0x08, 0x04, 0x04, 0x78, 0x00, 0x38, 0x44, 0x44, 0x44, 0x38, 0x00, 0xFC, 0x18, 0x24, 0x24, 0x18, 0x00, 0x18, 0x24, 0x24, 0x18, 0xFC, 0x00, 0x7C, 0x08, 0x04, 0x04, 0x08, 0x00, 0x48, 0x54, 0x54, 0x54, 0x24, 0x00, 0x04, 0x04, 0x3F, 0x44, 0x24, 0x00, 0x3C, 0x40, 0x40, 0x20, 0x7C, 0x00, 0x1C, 0x20, 0x40, 0x20, 0x1C, 0x00, 0x3C, 0x40, 0x30, 0x40, 0x3C, 0x00, 0x44, 0x28, 0x10, 0x28, 0x44, 0x00, 0x4C, 0x90, 0x90, 0x90, 0x7C, 0x00, 0x44, 0x64, 0x54, 0x4C, 0x44, 0x00, 0x00, 0x08, 0x36, 0x41, 0x00, 0x00, 0x00, 0x00, 0x77, 0x00, 0x00, 0x00,
|
||||
0x00, 0x41, 0x36, 0x08, 0x00, 0x00, 0x02, 0x01, 0x02, 0x04, 0x02, 0x00, 0x3C, 0x26, 0x23, 0x26, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x40, 0x40, 0xF0, 0xF8, 0xF8, 0xFF, 0x38, 0xFF, 0xF8, 0xF8, 0x3F, 0xF8, 0xF8, 0xFF, 0x38, 0xFF, 0xF8, 0xF8, 0xF0, 0x40, 0x40, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xC0, 0xC0, 0xC0, 0x80, 0x00, 0x00, 0xC0, 0xC0, 0x80, 0x00, 0x00, 0x00, 0x80, 0xC0, 0xC0, 0x00, 0xC0, 0xC0, 0x00, 0x00, 0x80, 0xC0, 0xC0, 0x00, 0x00, 0x00, 0x00, 0x00, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0x00, 0xC0, 0xC0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xC0, 0xF0, 0xF8, 0xFC, 0x3E,
|
||||
0x1E, 0x06, 0x01, 0x00, 0x00, 0x00, 0x7F, 0x41, 0x41, 0x41, 0x7F, 0x00, 0x7F, 0x41, 0x41, 0x41, 0x7F, 0x00, 0x00, 0x80, 0xC0, 0xE0, 0x7E, 0x5B, 0x4F, 0x5B, 0xFE, 0xC0, 0x00, 0x00, 0xC0, 0x00, 0xDC, 0xD7, 0xDE, 0xDE, 0xDE, 0xD7, 0xDC, 0x00, 0xC0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x49, 0x49, 0x49, 0xFF, 0xFF, 0xFF, 0xFF, 0xE0, 0xDF, 0xBF, 0xBF, 0x00, 0xBF, 0xBF, 0xDF, 0xE0, 0xFF, 0xFF, 0xFF, 0xFF, 0x49, 0x49, 0x49, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1F, 0x3F, 0x60, 0x60, 0xE0, 0xBF, 0x1F, 0x00, 0x7F, 0x7F, 0x07, 0x1E, 0x38, 0x1E, 0x07, 0x7F, 0x7F, 0x00, 0x7F, 0x7F, 0x0E, 0x1F, 0x3B, 0x71, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7F, 0x7F, 0x0C, 0x0C, 0x0C, 0x00, 0x7E, 0x7E, 0x00, 0x7F, 0x7E, 0x03, 0x03, 0x00, 0x7F, 0x7E, 0x03, 0x03, 0x7E, 0x7E, 0x03, 0x03, 0x7F, 0x7E, 0x00, 0x0F,
|
||||
0x3E, 0x70, 0x3C, 0x06, 0x3C, 0x70, 0x3E, 0x0F, 0x00, 0x32, 0x7B, 0x49, 0x49, 0x3F, 0x7E, 0x00, 0x7F, 0x7E, 0x03, 0x03, 0x00, 0x1E, 0x3F, 0x69, 0x69, 0x6F, 0x26, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x0F, 0x1F, 0x3F, 0x3C, 0x78, 0x70, 0x60, 0x00, 0x00, 0x00, 0x7F, 0x41, 0x41, 0x41, 0x7F, 0x00, 0x7F, 0x41, 0x41, 0x41, 0x7F, 0x00, 0x30, 0x7B, 0x7F, 0x78, 0x30, 0x20, 0x20, 0x30, 0x78, 0x7F, 0x3B, 0x00, 0x03, 0x00, 0x0F, 0x7F, 0x0F, 0x0F, 0x0F, 0x7F, 0x0F, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x07, 0x0F, 0x0F, 0x7F, 0x0F, 0x7F, 0x0F, 0x0F, 0x7E, 0x0F, 0x0F, 0x7F, 0x0F, 0x7F, 0x0F, 0x0F, 0x07, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x07, 0x08, 0x7F, 0x08, 0x07, 0x00, // 0x00 NUL / Ψ
|
||||
0x3E, 0x6B, 0x4F, 0x6B, 0x3E, 0x00, // 0x01 SOH / ☺︎
|
||||
0xC1, 0x94, 0xB0, 0x94, 0xC1, 0x00, // 0x02 STX / ☻
|
||||
0x1C, 0x3E, 0x7C, 0x3E, 0x1C, 0x00, // 0x03 ETX / ♥︎
|
||||
0x18, 0x3C, 0x7E, 0x3C, 0x18, 0x00, // 0x04 EOT / ♦︎
|
||||
0x1C, 0x57, 0x7D, 0x57, 0x1C, 0x00, // 0x05 ENQ / ♣︎
|
||||
0x1C, 0x5E, 0x7F, 0x5E, 0x1C, 0x00, // 0x06 ACK / ♠︎
|
||||
0x00, 0x18, 0x3C, 0x18, 0x00, 0x00, // 0x07 BEL / •
|
||||
0xFF, 0xE7, 0xC3, 0xE7, 0xFF, 0x00, // 0x08 BS / ◘
|
||||
0x00, 0x18, 0x24, 0x18, 0x00, 0x00, // 0x09 HT / ○
|
||||
0xFF, 0xE7, 0xDB, 0xE7, 0xFF, 0x00, // 0x0A LF / ◙
|
||||
0x30, 0x48, 0x3A, 0x06, 0x0E, 0x00, // 0x0B VT / ♂︎
|
||||
0x26, 0x29, 0x79, 0x29, 0x26, 0x00, // 0x0C FF / ♀︎
|
||||
0x40, 0x7F, 0x05, 0x05, 0x07, 0x00, // 0x0D CR / ♪
|
||||
0x40, 0x7F, 0x05, 0x25, 0x3F, 0x00, // 0x0E SO / ♫
|
||||
0x5A, 0x3C, 0xE7, 0x3C, 0x5A, 0x00, // 0x0F SI / ☼
|
||||
|
||||
0x7F, 0x3E, 0x1C, 0x1C, 0x08, 0x00, // 0x10 DLE / ►
|
||||
0x08, 0x1C, 0x1C, 0x3E, 0x7F, 0x00, // 0x11 DC1 / ◄
|
||||
0x14, 0x22, 0x7F, 0x22, 0x14, 0x00, // 0x12 DC2 / ↕︎
|
||||
0x5F, 0x5F, 0x00, 0x5F, 0x5F, 0x00, // 0x13 DC3 / ‼︎
|
||||
0x06, 0x09, 0x7F, 0x01, 0x7F, 0x00, // 0x14 DC4 / ¶
|
||||
0x00, 0x66, 0x89, 0x95, 0x6A, 0x00, // 0x15 NAK / §
|
||||
0x60, 0x60, 0x60, 0x60, 0x60, 0x00, // 0x16 SYN / ▬
|
||||
0x94, 0xA2, 0xFF, 0xA2, 0x94, 0x00, // 0x17 ETB / ↨
|
||||
0x08, 0x04, 0x7E, 0x04, 0x08, 0x00, // 0x18 CAN / ↑
|
||||
0x10, 0x20, 0x7E, 0x20, 0x10, 0x00, // 0x19 EM / ↓
|
||||
0x08, 0x08, 0x2A, 0x1C, 0x08, 0x00, // 0x1A SUB / →
|
||||
0x08, 0x1C, 0x2A, 0x08, 0x08, 0x00, // 0x1B ESC / ←
|
||||
0x1E, 0x10, 0x10, 0x10, 0x10, 0x00, // 0x1C FS / ∟
|
||||
0x0C, 0x1E, 0x0C, 0x1E, 0x0C, 0x00, // 0x1D GS / ↔︎
|
||||
0x30, 0x38, 0x3E, 0x38, 0x30, 0x00, // 0x1E RS / ▲
|
||||
0x06, 0x0E, 0x3E, 0x0E, 0x06, 0x00, // 0x1F US / ▼
|
||||
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0x20 Space
|
||||
0x00, 0x00, 0x5F, 0x00, 0x00, 0x00, // 0x21 !
|
||||
0x00, 0x07, 0x00, 0x07, 0x00, 0x00, // 0x22 "
|
||||
0x14, 0x7F, 0x14, 0x7F, 0x14, 0x00, // 0x23 #
|
||||
0x24, 0x2A, 0x7F, 0x2A, 0x12, 0x00, // 0x24 $
|
||||
0x23, 0x13, 0x08, 0x64, 0x62, 0x00, // 0x25 %
|
||||
0x36, 0x49, 0x56, 0x20, 0x50, 0x00, // 0x26 &
|
||||
0x00, 0x08, 0x07, 0x03, 0x00, 0x00, // 0x27 '
|
||||
0x00, 0x1C, 0x22, 0x41, 0x00, 0x00, // 0x28 (
|
||||
0x00, 0x41, 0x22, 0x1C, 0x00, 0x00, // 0x29 )
|
||||
0x2A, 0x1C, 0x7F, 0x1C, 0x2A, 0x00, // 0x2A *
|
||||
0x08, 0x08, 0x3E, 0x08, 0x08, 0x00, // 0x2B +
|
||||
0x00, 0x80, 0x70, 0x30, 0x00, 0x00, // 0x2C ,
|
||||
0x08, 0x08, 0x08, 0x08, 0x08, 0x00, // 0x2D -
|
||||
0x00, 0x00, 0x60, 0x60, 0x00, 0x00, // 0x2E .
|
||||
0x20, 0x10, 0x08, 0x04, 0x02, 0x00, // 0x2F /
|
||||
|
||||
0x3E, 0x51, 0x49, 0x45, 0x3E, 0x00, // 0x30 0
|
||||
0x00, 0x42, 0x7F, 0x40, 0x00, 0x00, // 0x31 1
|
||||
0x72, 0x49, 0x49, 0x49, 0x46, 0x00, // 0x32 2
|
||||
0x21, 0x41, 0x49, 0x4D, 0x33, 0x00, // 0x33 3
|
||||
0x18, 0x14, 0x12, 0x7F, 0x10, 0x00, // 0x34 4
|
||||
0x27, 0x45, 0x45, 0x45, 0x39, 0x00, // 0x35 5
|
||||
0x3C, 0x4A, 0x49, 0x49, 0x31, 0x00, // 0x36 6
|
||||
0x41, 0x21, 0x11, 0x09, 0x07, 0x00, // 0x37 7
|
||||
0x36, 0x49, 0x49, 0x49, 0x36, 0x00, // 0x38 8
|
||||
0x46, 0x49, 0x49, 0x29, 0x1E, 0x00, // 0x39 9
|
||||
0x00, 0x00, 0x14, 0x00, 0x00, 0x00, // 0x3A :
|
||||
0x00, 0x40, 0x34, 0x00, 0x00, 0x00, // 0x3B ;
|
||||
0x00, 0x08, 0x14, 0x22, 0x41, 0x00, // 0x3C <
|
||||
0x14, 0x14, 0x14, 0x14, 0x14, 0x00, // 0x3D =
|
||||
0x00, 0x41, 0x22, 0x14, 0x08, 0x00, // 0x3E >
|
||||
0x02, 0x01, 0x59, 0x09, 0x06, 0x00, // 0x3F ?
|
||||
|
||||
0x3E, 0x41, 0x5D, 0x59, 0x4E, 0x00, // 0x40 @
|
||||
0x7C, 0x12, 0x11, 0x12, 0x7C, 0x00, // 0x41 A
|
||||
0x7F, 0x49, 0x49, 0x49, 0x36, 0x00, // 0x42 B
|
||||
0x3E, 0x41, 0x41, 0x41, 0x22, 0x00, // 0x43 C
|
||||
0x7F, 0x41, 0x41, 0x41, 0x3E, 0x00, // 0x44 D
|
||||
0x7F, 0x49, 0x49, 0x49, 0x41, 0x00, // 0x45 E
|
||||
0x7F, 0x09, 0x09, 0x09, 0x01, 0x00, // 0x46 F
|
||||
0x3E, 0x41, 0x41, 0x51, 0x73, 0x00, // 0x47 G
|
||||
0x7F, 0x08, 0x08, 0x08, 0x7F, 0x00, // 0x48 H
|
||||
0x00, 0x41, 0x7F, 0x41, 0x00, 0x00, // 0x49 I
|
||||
0x20, 0x40, 0x41, 0x3F, 0x01, 0x00, // 0x4A J
|
||||
0x7F, 0x08, 0x14, 0x22, 0x41, 0x00, // 0x4B K
|
||||
0x7F, 0x40, 0x40, 0x40, 0x40, 0x00, // 0x4C L
|
||||
0x7F, 0x02, 0x1C, 0x02, 0x7F, 0x00, // 0x4D M
|
||||
0x7F, 0x04, 0x08, 0x10, 0x7F, 0x00, // 0x4E N
|
||||
0x3E, 0x41, 0x41, 0x41, 0x3E, 0x00, // 0x4F O
|
||||
|
||||
0x7F, 0x09, 0x09, 0x09, 0x06, 0x00, // 0x50 P
|
||||
0x3E, 0x41, 0x51, 0x21, 0x5E, 0x00, // 0x51 Q
|
||||
0x7F, 0x09, 0x19, 0x29, 0x46, 0x00, // 0x52 R
|
||||
0x26, 0x49, 0x49, 0x49, 0x32, 0x00, // 0x53 S
|
||||
0x03, 0x01, 0x7F, 0x01, 0x03, 0x00, // 0x54 T
|
||||
0x3F, 0x40, 0x40, 0x40, 0x3F, 0x00, // 0x55 U
|
||||
0x1F, 0x20, 0x40, 0x20, 0x1F, 0x00, // 0x56 V
|
||||
0x3F, 0x40, 0x38, 0x40, 0x3F, 0x00, // 0x57 W
|
||||
0x63, 0x14, 0x08, 0x14, 0x63, 0x00, // 0x58 X
|
||||
0x03, 0x04, 0x78, 0x04, 0x03, 0x00, // 0x59 Y
|
||||
0x61, 0x59, 0x49, 0x4D, 0x43, 0x00, // 0x5A Z
|
||||
0x00, 0x7F, 0x41, 0x41, 0x41, 0x00, // 0x5B [
|
||||
0x02, 0x04, 0x08, 0x10, 0x20, 0x00, // 0x5C Backslash
|
||||
0x00, 0x41, 0x41, 0x41, 0x7F, 0x00, // 0x5D ]
|
||||
0x04, 0x02, 0x01, 0x02, 0x04, 0x00, // 0x5E ^
|
||||
0x40, 0x40, 0x40, 0x40, 0x40, 0x00, // 0x5F _
|
||||
|
||||
0x00, 0x03, 0x07, 0x08, 0x00, 0x00, // 0x60 `
|
||||
0x20, 0x54, 0x54, 0x78, 0x40, 0x00, // 0x61 a
|
||||
0x7F, 0x28, 0x44, 0x44, 0x38, 0x00, // 0x62 b
|
||||
0x38, 0x44, 0x44, 0x44, 0x28, 0x00, // 0x63 c
|
||||
0x38, 0x44, 0x44, 0x28, 0x7F, 0x00, // 0x64 d
|
||||
0x38, 0x54, 0x54, 0x54, 0x18, 0x00, // 0x65 e
|
||||
0x00, 0x08, 0x7E, 0x09, 0x02, 0x00, // 0x66 f
|
||||
0x18, 0xA4, 0xA4, 0x9C, 0x78, 0x00, // 0x67 g
|
||||
0x7F, 0x08, 0x04, 0x04, 0x78, 0x00, // 0x68 h
|
||||
0x00, 0x44, 0x7D, 0x40, 0x00, 0x00, // 0x69 i
|
||||
0x20, 0x40, 0x40, 0x3D, 0x00, 0x00, // 0x6A j
|
||||
0x7F, 0x10, 0x28, 0x44, 0x00, 0x00, // 0x6B k
|
||||
0x00, 0x41, 0x7F, 0x40, 0x00, 0x00, // 0x6C l
|
||||
0x7C, 0x04, 0x78, 0x04, 0x78, 0x00, // 0x6D m
|
||||
0x7C, 0x08, 0x04, 0x04, 0x78, 0x00, // 0x6E n
|
||||
0x38, 0x44, 0x44, 0x44, 0x38, 0x00, // 0x6F o
|
||||
|
||||
0xFC, 0x18, 0x24, 0x24, 0x18, 0x00, // 0x70 p
|
||||
0x18, 0x24, 0x24, 0x18, 0xFC, 0x00, // 0x71 q
|
||||
0x7C, 0x08, 0x04, 0x04, 0x08, 0x00, // 0x72 r
|
||||
0x48, 0x54, 0x54, 0x54, 0x24, 0x00, // 0x73 s
|
||||
0x04, 0x04, 0x3F, 0x44, 0x24, 0x00, // 0x74 t
|
||||
0x3C, 0x40, 0x40, 0x20, 0x7C, 0x00, // 0x75 u
|
||||
0x1C, 0x20, 0x40, 0x20, 0x1C, 0x00, // 0x76 v
|
||||
0x3C, 0x40, 0x30, 0x40, 0x3C, 0x00, // 0x77 w
|
||||
0x44, 0x28, 0x10, 0x28, 0x44, 0x00, // 0x78 x
|
||||
0x4C, 0x90, 0x90, 0x90, 0x7C, 0x00, // 0x79 y
|
||||
0x44, 0x64, 0x54, 0x4C, 0x44, 0x00, // 0x7A z
|
||||
0x00, 0x08, 0x36, 0x41, 0x00, 0x00, // 0x7B {
|
||||
0x00, 0x00, 0x77, 0x00, 0x00, 0x00, // 0x7C |
|
||||
0x00, 0x41, 0x36, 0x08, 0x00, 0x00, // 0x7D }
|
||||
0x02, 0x01, 0x02, 0x04, 0x02, 0x00, // 0x7E ~
|
||||
0x3C, 0x26, 0x23, 0x26, 0x3C, 0x00, // 0x7F DEL / ⌂
|
||||
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0x80 QMK Logo Top 1
|
||||
0x00, 0x00, 0x80, 0x80, 0xE0, 0xF0, // 0x81 QMK Logo Top 2
|
||||
0xF0, 0xFC, 0x70, 0xFC, 0xF0, 0x7C, // 0x82 QMK Logo Top 3
|
||||
0xF0, 0xFC, 0x70, 0xFC, 0xF0, 0xF0, // 0x83 QMK Logo Top 4
|
||||
0xE0, 0x80, 0x80, 0x00, 0x00, 0x00, // 0x84 QMK Logo Top 5
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0x85 QMK Logo Top 6
|
||||
0x80, 0x80, 0x80, 0x00, 0x00, 0x00, // 0x86 QMK Logo Top 7
|
||||
0x80, 0x80, 0x00, 0x00, 0x00, 0x00, // 0x87 QMK Logo Top 8
|
||||
0x00, 0x80, 0x80, 0x00, 0x80, 0x80, // 0x88 QMK Logo Top 9
|
||||
0x00, 0x00, 0x00, 0x80, 0x80, 0x00, // 0x89 QMK Logo Top 10
|
||||
0x00, 0x00, 0x00, 0x00, 0x80, 0x80, // 0x8A QMK Logo Top 11
|
||||
0x80, 0x80, 0x80, 0x00, 0x80, 0x80, // 0x8B QMK Logo Top 12
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0x8C QMK Logo Top 13
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0x8D QMK Logo Top 14
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0x8E QMK Logo Top 15
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0x8F QMK Logo Top 16
|
||||
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0x90 QMK Logo Top 17
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0x91 QMK Logo Top 18
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0x92 QMK Logo Top 19
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0x93 QMK Logo Top 20
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0x94 QMK Logo Top 21
|
||||
0x00, 0xC0, 0xF0, 0xF8, 0xFC, 0x3E, // 0x95 Apple Logo TL
|
||||
0x1E, 0x06, 0x01, 0x00, 0x00, 0x00, // 0x96 Apple Logo TR
|
||||
0x7F, 0x41, 0x41, 0x41, 0x7F, 0x00, // 0x97 Windows Logo TL
|
||||
0x7F, 0x41, 0x41, 0x41, 0x7F, 0x00, // 0x98 Windows Logo TR
|
||||
0x00, 0x80, 0xC0, 0xE0, 0x7E, 0x5B, // 0x99 Linux Logo TL
|
||||
0x4F, 0x5B, 0xFE, 0xC0, 0x00, 0x00, // 0x9A Linux Logo TR
|
||||
0xC0, 0x00, 0xDC, 0xD7, 0xDE, 0xDE, // 0x9B Android Logo TL
|
||||
0xDE, 0xD7, 0xDC, 0x00, 0xC0, 0x00, // 0x9C Android Logo TR
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0x9D
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0x9E
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0x9F
|
||||
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xA0 QMK Logo Middle 1
|
||||
0x00, 0x00, 0xAA, 0xAA, 0xFF, 0xFF, // 0xA1 QMK Logo Middle 2
|
||||
0xFF, 0xFF, 0xE0, 0xDF, 0xDF, 0x00, // 0xA2 QMK Logo Middle 3
|
||||
0xDF, 0xDF, 0xE0, 0xFF, 0xFF, 0xFF, // 0xA3 QMK Logo Middle 4
|
||||
0xFF, 0xAA, 0xAA, 0x00, 0x00, 0x00, // 0xA4 QMK Logo Middle 5
|
||||
0x00, 0x00, 0x00, 0x00, 0x3E, 0x7F, // 0xA5 QMK Logo Middle 6
|
||||
0xC1, 0xC1, 0xC1, 0x7F, 0x3E, 0x00, // 0xA6 QMK Logo Middle 7
|
||||
0xFF, 0xFF, 0x0F, 0x3C, 0x78, 0x3C, // 0xA7 QMK Logo Middle 8
|
||||
0x0F, 0xFF, 0xFF, 0x00, 0xFF, 0xFF, // 0xA8 QMK Logo Middle 9
|
||||
0x1C, 0x3E, 0x77, 0xE3, 0xC1, 0x00, // 0xA9 QMK Logo Middle 10
|
||||
0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, // 0xAA QMK Logo Middle 11
|
||||
0x19, 0x19, 0x19, 0x00, 0xFD, 0xFD, // 0xAB QMK Logo Middle 12
|
||||
0x00, 0xFE, 0xFC, 0x06, 0x06, 0x00, // 0xAC QMK Logo Middle 13
|
||||
0xFE, 0xFC, 0x06, 0x06, 0xFC, 0xFC, // 0xAD QMK Logo Middle 14
|
||||
0x06, 0x06, 0xFE, 0xFC, 0x00, 0x1E, // 0xAE QMK Logo Middle 15
|
||||
0x7C, 0xE0, 0x78, 0x0C, 0x78, 0xE0, // 0xAF QMK Logo Middle 16
|
||||
|
||||
0x7C, 0x1E, 0x00, 0x64, 0xF6, 0x92, // 0xB0 QMK Logo Middle 17
|
||||
0x92, 0x7E, 0xFC, 0x00, 0xFE, 0xFC, // 0xB1 QMK Logo Middle 18
|
||||
0x06, 0x06, 0x00, 0x3C, 0x7E, 0xD2, // 0xB2 QMK Logo Middle 19
|
||||
0xD2, 0xDE, 0x4C, 0x00, 0x00, 0x00, // 0xB3 QMK Logo Middle 20
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xB4 QMK Logo Middle 21
|
||||
0x00, 0x03, 0x0F, 0x1F, 0x3F, 0x3C, // 0xB5 Apple Logo BL
|
||||
0x78, 0x70, 0x60, 0x00, 0x00, 0x00, // 0xB6 Apple Logo BR
|
||||
0x7F, 0x41, 0x41, 0x41, 0x7F, 0x00, // 0xB7 Windows Logo BL
|
||||
0x7F, 0x41, 0x41, 0x41, 0x7F, 0x00, // 0xB8 Windows Logo BR
|
||||
0x30, 0x7B, 0x7F, 0x78, 0x30, 0x20, // 0xB9 Linux Logo BL
|
||||
0x20, 0x30, 0x78, 0x7F, 0x3B, 0x00, // 0xBA Linux Logo BR
|
||||
0x03, 0x00, 0x0F, 0x7F, 0x0F, 0x0F, // 0xBB Android Logo BL
|
||||
0x0F, 0x7F, 0x0F, 0x00, 0x03, 0x00, // 0xBC Android Logo BR
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xBD
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xBE
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xBF
|
||||
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xC0 QMK Logo Bottom 1
|
||||
0x00, 0x00, 0x00, 0x00, 0x03, 0x07, // 0xC1 QMK Logo Bottom 2
|
||||
0x07, 0x1F, 0x07, 0x1F, 0x07, 0x1F, // 0xC2 QMK Logo Bottom 3
|
||||
0x07, 0x1F, 0x07, 0x1F, 0x07, 0x07, // 0xC3 QMK Logo Bottom 4
|
||||
0x03, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xC4 QMK Logo Bottom 5
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xC5 QMK Logo Bottom 6
|
||||
0x00, 0x00, 0x01, 0x03, 0x02, 0x00, // 0xC6 QMK Logo Bottom 7
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xC7 QMK Logo Bottom 8
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xC8 QMK Logo Bottom 9
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xC9 QMK Logo Bottom 10
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xCA QMK Logo Bottom 11
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xCB QMK Logo Bottom 12
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xCC QMK Logo Bottom 13
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xCD QMK Logo Bottom 14
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xCE QMK Logo Bottom 15
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xCF QMK Logo Bottom 16
|
||||
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xD0 QMK Logo Bottom 17
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xD1 QMK Logo Bottom 18
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xD2 QMK Logo Bottom 19
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xD3 QMK Logo Bottom 10
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xD4 QMK Logo Bottom 21
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xD5
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xD6
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xD7
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xD8
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xD9
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xDA
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xDB
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xDC
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xDD
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0xDE
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00 // 0xDF
|
||||
};
|
||||
|
||||
@@ -146,7 +146,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
// parts of the display unusable or don't get cleared correctly
|
||||
// and also allows for drawing & inverting
|
||||
uint8_t oled_buffer[OLED_MATRIX_SIZE];
|
||||
uint8_t * oled_cursor;
|
||||
uint8_t *oled_cursor;
|
||||
OLED_BLOCK_TYPE oled_dirty = 0;
|
||||
bool oled_initialized = false;
|
||||
bool oled_active = false;
|
||||
@@ -301,24 +301,18 @@ bool oled_init(oled_rotation_t rotation) {
|
||||
oled_driver_init();
|
||||
|
||||
static const uint8_t PROGMEM display_setup1[] = {
|
||||
I2C_CMD,
|
||||
DISPLAY_OFF,
|
||||
DISPLAY_CLOCK,
|
||||
OLED_DISPLAY_CLOCK,
|
||||
MULTIPLEX_RATIO,
|
||||
I2C_CMD, DISPLAY_OFF, DISPLAY_CLOCK, OLED_DISPLAY_CLOCK, MULTIPLEX_RATIO,
|
||||
#if OLED_IC_COM_PINS_ARE_COLUMNS
|
||||
OLED_DISPLAY_WIDTH - 1,
|
||||
#else
|
||||
OLED_DISPLAY_HEIGHT - 1,
|
||||
#endif
|
||||
#if OLED_IC == OLED_IC_SH1107
|
||||
SH1107_DISPLAY_START_LINE,
|
||||
0x00,
|
||||
SH1107_DISPLAY_START_LINE, 0x00,
|
||||
#else
|
||||
DISPLAY_START_LINE | 0x00,
|
||||
#endif
|
||||
CHARGE_PUMP,
|
||||
0x14,
|
||||
CHARGE_PUMP, 0x14,
|
||||
#if OLED_IC_HAS_HORIZONTAL_MODE
|
||||
// MEMORY_MODE is unsupported on SH1106 (Page Addressing only)
|
||||
MEMORY_MODE,
|
||||
|
||||
@@ -53,12 +53,10 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
// For 90 degree rotation, we map our internal matrix to oled matrix using fixed arrays
|
||||
// The OLED writes to it's memory horizontally, starting top left, but our memory starts bottom left in this mode
|
||||
# ifndef OLED_SOURCE_MAP
|
||||
# define OLED_SOURCE_MAP \
|
||||
{ 0, 8, 16, 24, 32, 40, 48, 56 }
|
||||
# define OLED_SOURCE_MAP {0, 8, 16, 24, 32, 40, 48, 56}
|
||||
# endif
|
||||
# ifndef OLED_TARGET_MAP
|
||||
# define OLED_TARGET_MAP \
|
||||
{ 56, 48, 40, 32, 24, 16, 8, 0 }
|
||||
# define OLED_TARGET_MAP {56, 48, 40, 32, 24, 16, 8, 0}
|
||||
# endif
|
||||
// If OLED_BLOCK_TYPE is uint32_t, these tables would look like:
|
||||
// #define OLED_SOURCE_MAP { 32, 40, 48, 56 }
|
||||
@@ -97,12 +95,10 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
# endif
|
||||
|
||||
# ifndef OLED_SOURCE_MAP
|
||||
# define OLED_SOURCE_MAP \
|
||||
{ 0, 8, 16, 24 }
|
||||
# define OLED_SOURCE_MAP {0, 8, 16, 24}
|
||||
# endif
|
||||
# ifndef OLED_TARGET_MAP
|
||||
# define OLED_TARGET_MAP \
|
||||
{ 24, 16, 8, 0 }
|
||||
# define OLED_TARGET_MAP {24, 16, 8, 0}
|
||||
# endif
|
||||
|
||||
#elif defined(OLED_DISPLAY_64X48)
|
||||
@@ -132,12 +128,10 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
# endif
|
||||
|
||||
# ifndef OLED_SOURCE_MAP
|
||||
# define OLED_SOURCE_MAP \
|
||||
{ 0, 8 }
|
||||
# define OLED_SOURCE_MAP {0, 8}
|
||||
# endif
|
||||
# ifndef OLED_TARGET_MAP
|
||||
# define OLED_TARGET_MAP \
|
||||
{ 8, 0 }
|
||||
# define OLED_TARGET_MAP {8, 0}
|
||||
# endif
|
||||
|
||||
#elif defined(OLED_DISPLAY_64X128)
|
||||
@@ -170,12 +164,10 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
# endif
|
||||
|
||||
# ifndef OLED_SOURCE_MAP
|
||||
# define OLED_SOURCE_MAP \
|
||||
{ 0, 8, 16, 24, 32, 40, 48, 56 }
|
||||
# define OLED_SOURCE_MAP {0, 8, 16, 24, 32, 40, 48, 56}
|
||||
# endif
|
||||
# ifndef OLED_TARGET_MAP
|
||||
# define OLED_TARGET_MAP \
|
||||
{ 56, 48, 40, 32, 24, 16, 8, 0 }
|
||||
# define OLED_TARGET_MAP {56, 48, 40, 32, 24, 16, 8, 0}
|
||||
# endif
|
||||
|
||||
#elif defined(OLED_DISPLAY_128X128)
|
||||
@@ -208,12 +200,10 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
// For 90 degree rotation, we map our internal matrix to oled matrix using fixed arrays
|
||||
// The OLED writes to it's memory horizontally, starting top left, but our memory starts bottom left in this mode
|
||||
# ifndef OLED_SOURCE_MAP
|
||||
# define OLED_SOURCE_MAP \
|
||||
{ 0, 8, 16, 24, 32, 40, 48, 56 }
|
||||
# define OLED_SOURCE_MAP {0, 8, 16, 24, 32, 40, 48, 56}
|
||||
# endif
|
||||
# ifndef OLED_TARGET_MAP
|
||||
# define OLED_TARGET_MAP \
|
||||
{ 56, 48, 40, 32, 24, 16, 8, 0 }
|
||||
# define OLED_TARGET_MAP {56, 48, 40, 32, 24, 16, 8, 0}
|
||||
# endif
|
||||
#else // defined(OLED_DISPLAY_128X64)
|
||||
// Default 128x32
|
||||
@@ -242,12 +232,10 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
// For 90 degree rotation, we map our internal matrix to oled matrix using fixed arrays
|
||||
// The OLED writes to it's memory horizontally, starting top left, but our memory starts bottom left in this mode
|
||||
# ifndef OLED_SOURCE_MAP
|
||||
# define OLED_SOURCE_MAP \
|
||||
{ 0, 8, 16, 24 }
|
||||
# define OLED_SOURCE_MAP {0, 8, 16, 24}
|
||||
# endif
|
||||
# ifndef OLED_TARGET_MAP
|
||||
# define OLED_TARGET_MAP \
|
||||
{ 24, 16, 8, 0 }
|
||||
# define OLED_TARGET_MAP {24, 16, 8, 0}
|
||||
# endif
|
||||
// If OLED_BLOCK_TYPE is uint8_t, these tables would look like:
|
||||
// #define OLED_SOURCE_MAP { 0, 8, 16, 24, 32, 40, 48, 56 }
|
||||
|
||||
@@ -15,8 +15,9 @@ static bool dummy_comms_start(painter_device_t device) {
|
||||
return true;
|
||||
}
|
||||
|
||||
static void dummy_comms_stop(painter_device_t device) {
|
||||
static bool dummy_comms_stop(painter_device_t device) {
|
||||
// No-op.
|
||||
return true;
|
||||
}
|
||||
|
||||
uint32_t dummy_comms_send(painter_device_t device, const void *data, uint32_t byte_count) {
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
// Helpers
|
||||
|
||||
static uint32_t qp_comms_i2c_send_raw(painter_device_t device, const void *data, uint32_t byte_count) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
qp_comms_i2c_config_t *comms_config = (qp_comms_i2c_config_t *)driver->comms_config;
|
||||
i2c_status_t res = i2c_transmit(comms_config->chip_address << 1, data, byte_count, I2C_TIMEOUT);
|
||||
if (res < 0) {
|
||||
@@ -35,7 +35,9 @@ uint32_t qp_comms_i2c_send_data(painter_device_t device, const void *data, uint3
|
||||
return qp_comms_i2c_send_raw(device, data, byte_count);
|
||||
}
|
||||
|
||||
void qp_comms_i2c_stop(painter_device_t device) {}
|
||||
bool qp_comms_i2c_stop(painter_device_t device) {
|
||||
return true;
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// Command+Data I2C support
|
||||
@@ -43,9 +45,9 @@ void qp_comms_i2c_stop(painter_device_t device) {}
|
||||
static const uint8_t cmd_byte = 0x00;
|
||||
static const uint8_t data_byte = 0x40;
|
||||
|
||||
void qp_comms_i2c_cmddata_send_command(painter_device_t device, uint8_t cmd) {
|
||||
bool qp_comms_i2c_cmddata_send_command(painter_device_t device, uint8_t cmd) {
|
||||
uint8_t buf[2] = {cmd_byte, cmd};
|
||||
qp_comms_i2c_send_raw(device, &buf, 2);
|
||||
return qp_comms_i2c_send_raw(device, &buf, 2);
|
||||
}
|
||||
|
||||
uint32_t qp_comms_i2c_cmddata_send_data(painter_device_t device, const void *data, uint32_t byte_count) {
|
||||
@@ -58,7 +60,7 @@ uint32_t qp_comms_i2c_cmddata_send_data(painter_device_t device, const void *dat
|
||||
return byte_count;
|
||||
}
|
||||
|
||||
void qp_comms_i2c_bulk_command_sequence(painter_device_t device, const uint8_t *sequence, size_t sequence_len) {
|
||||
bool qp_comms_i2c_bulk_command_sequence(painter_device_t device, const uint8_t *sequence, size_t sequence_len) {
|
||||
uint8_t buf[32];
|
||||
for (size_t i = 0; i < sequence_len;) {
|
||||
uint8_t command = sequence[i];
|
||||
@@ -67,12 +69,17 @@ void qp_comms_i2c_bulk_command_sequence(painter_device_t device, const uint8_t *
|
||||
buf[0] = cmd_byte;
|
||||
buf[1] = command;
|
||||
memcpy(&buf[2], &sequence[i + 3], num_bytes);
|
||||
qp_comms_i2c_send_raw(device, buf, num_bytes + 2);
|
||||
if (!qp_comms_i2c_send_raw(device, buf, num_bytes + 2)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (delay > 0) {
|
||||
wait_ms(delay);
|
||||
}
|
||||
i += (3 + num_bytes);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
const painter_comms_with_command_vtable_t i2c_comms_cmddata_vtable = {
|
||||
|
||||
@@ -19,7 +19,7 @@ typedef struct qp_comms_i2c_config_t {
|
||||
bool qp_comms_i2c_init(painter_device_t device);
|
||||
bool qp_comms_i2c_start(painter_device_t device);
|
||||
uint32_t qp_comms_i2c_send_data(painter_device_t device, const void* data, uint32_t byte_count);
|
||||
void qp_comms_i2c_stop(painter_device_t device);
|
||||
bool qp_comms_i2c_stop(painter_device_t device);
|
||||
|
||||
extern const painter_comms_with_command_vtable_t i2c_comms_cmddata_vtable;
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
// Base SPI support
|
||||
|
||||
bool qp_comms_spi_init(painter_device_t device) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
qp_comms_spi_config_t *comms_config = (qp_comms_spi_config_t *)driver->comms_config;
|
||||
|
||||
// Initialize the SPI peripheral
|
||||
@@ -24,7 +24,7 @@ bool qp_comms_spi_init(painter_device_t device) {
|
||||
}
|
||||
|
||||
bool qp_comms_spi_start(painter_device_t device) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
qp_comms_spi_config_t *comms_config = (qp_comms_spi_config_t *)driver->comms_config;
|
||||
|
||||
return spi_start(comms_config->chip_select_pin, comms_config->lsb_first, comms_config->mode, comms_config->divisor);
|
||||
@@ -36,7 +36,7 @@ uint32_t qp_comms_spi_send_data(painter_device_t device, const void *data, uint3
|
||||
const uint32_t max_msg_length = 1024;
|
||||
|
||||
while (bytes_remaining > 0) {
|
||||
uint32_t bytes_this_loop = QP_MIN(bytes_remaining, max_msg_length);
|
||||
uint32_t bytes_this_loop = MIN(bytes_remaining, max_msg_length);
|
||||
spi_transmit(p, bytes_this_loop);
|
||||
p += bytes_this_loop;
|
||||
bytes_remaining -= bytes_this_loop;
|
||||
@@ -45,11 +45,12 @@ uint32_t qp_comms_spi_send_data(painter_device_t device, const void *data, uint3
|
||||
return byte_count - bytes_remaining;
|
||||
}
|
||||
|
||||
void qp_comms_spi_stop(painter_device_t device) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
bool qp_comms_spi_stop(painter_device_t device) {
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
qp_comms_spi_config_t *comms_config = (qp_comms_spi_config_t *)driver->comms_config;
|
||||
spi_stop();
|
||||
gpio_write_pin_high(comms_config->chip_select_pin);
|
||||
return true;
|
||||
}
|
||||
|
||||
const painter_comms_vtable_t spi_comms_vtable = {
|
||||
@@ -69,7 +70,7 @@ bool qp_comms_spi_dc_reset_init(painter_device_t device) {
|
||||
return false;
|
||||
}
|
||||
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
qp_comms_spi_dc_reset_config_t *comms_config = (qp_comms_spi_dc_reset_config_t *)driver->comms_config;
|
||||
|
||||
// Set up D/C as output low, if specified
|
||||
@@ -91,21 +92,22 @@ bool qp_comms_spi_dc_reset_init(painter_device_t device) {
|
||||
}
|
||||
|
||||
uint32_t qp_comms_spi_dc_reset_send_data(painter_device_t device, const void *data, uint32_t byte_count) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
qp_comms_spi_dc_reset_config_t *comms_config = (qp_comms_spi_dc_reset_config_t *)driver->comms_config;
|
||||
gpio_write_pin_high(comms_config->dc_pin);
|
||||
return qp_comms_spi_send_data(device, data, byte_count);
|
||||
}
|
||||
|
||||
void qp_comms_spi_dc_reset_send_command(painter_device_t device, uint8_t cmd) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
bool qp_comms_spi_dc_reset_send_command(painter_device_t device, uint8_t cmd) {
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
qp_comms_spi_dc_reset_config_t *comms_config = (qp_comms_spi_dc_reset_config_t *)driver->comms_config;
|
||||
gpio_write_pin_low(comms_config->dc_pin);
|
||||
spi_write(cmd);
|
||||
return true;
|
||||
}
|
||||
|
||||
void qp_comms_spi_dc_reset_bulk_command_sequence(painter_device_t device, const uint8_t *sequence, size_t sequence_len) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
bool qp_comms_spi_dc_reset_bulk_command_sequence(painter_device_t device, const uint8_t *sequence, size_t sequence_len) {
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
qp_comms_spi_dc_reset_config_t *comms_config = (qp_comms_spi_dc_reset_config_t *)driver->comms_config;
|
||||
for (size_t i = 0; i < sequence_len;) {
|
||||
uint8_t command = sequence[i];
|
||||
@@ -126,6 +128,8 @@ void qp_comms_spi_dc_reset_bulk_command_sequence(painter_device_t device, const
|
||||
}
|
||||
i += (3 + num_bytes);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
const painter_comms_with_command_vtable_t spi_comms_with_dc_vtable = {
|
||||
|
||||
@@ -22,7 +22,7 @@ typedef struct qp_comms_spi_config_t {
|
||||
bool qp_comms_spi_init(painter_device_t device);
|
||||
bool qp_comms_spi_start(painter_device_t device);
|
||||
uint32_t qp_comms_spi_send_data(painter_device_t device, const void* data, uint32_t byte_count);
|
||||
void qp_comms_spi_stop(painter_device_t device);
|
||||
bool qp_comms_spi_stop(painter_device_t device);
|
||||
|
||||
extern const painter_comms_vtable_t spi_comms_vtable;
|
||||
|
||||
@@ -39,9 +39,9 @@ typedef struct qp_comms_spi_dc_reset_config_t {
|
||||
} qp_comms_spi_dc_reset_config_t;
|
||||
|
||||
bool qp_comms_spi_dc_reset_init(painter_device_t device);
|
||||
void qp_comms_spi_dc_reset_send_command(painter_device_t device, uint8_t cmd);
|
||||
bool qp_comms_spi_dc_reset_send_command(painter_device_t device, uint8_t cmd);
|
||||
uint32_t qp_comms_spi_dc_reset_send_data(painter_device_t device, const void* data, uint32_t byte_count);
|
||||
void qp_comms_spi_dc_reset_bulk_command_sequence(painter_device_t device, const uint8_t* sequence, size_t sequence_len);
|
||||
bool qp_comms_spi_dc_reset_bulk_command_sequence(painter_device_t device, const uint8_t* sequence, size_t sequence_len);
|
||||
|
||||
extern const painter_comms_with_command_vtable_t spi_comms_with_dc_vtable;
|
||||
|
||||
|
||||
@@ -32,7 +32,9 @@ __attribute__((weak)) bool qp_gc9107_init(painter_device_t device, painter_rotat
|
||||
};
|
||||
|
||||
// clang-format on
|
||||
qp_comms_bulk_command_sequence(device, gc9107_init_sequence, sizeof(gc9107_init_sequence));
|
||||
if (!qp_comms_bulk_command_sequence(device, gc9107_init_sequence, sizeof(gc9107_init_sequence))) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Configure the rotation (i.e. the ordering and direction of memory writes in GRAM)
|
||||
const uint8_t madctl[] = {
|
||||
@@ -41,9 +43,7 @@ __attribute__((weak)) bool qp_gc9107_init(painter_device_t device, painter_rotat
|
||||
[QP_ROTATION_180] = GC9XXX_MADCTL_BGR | GC9XXX_MADCTL_MX | GC9XXX_MADCTL_MY,
|
||||
[QP_ROTATION_270] = GC9XXX_MADCTL_BGR | GC9XXX_MADCTL_MV | GC9XXX_MADCTL_MY,
|
||||
};
|
||||
qp_comms_command_databyte(device, GC9XXX_SET_MEM_ACS_CTL, madctl[rotation]);
|
||||
|
||||
return true;
|
||||
return qp_comms_command_databyte(device, GC9XXX_SET_MEM_ACS_CTL, madctl[rotation]);
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
@@ -45,7 +45,9 @@ __attribute__((weak)) bool qp_gc9a01_init(painter_device_t device, painter_rotat
|
||||
};
|
||||
// clang-format on
|
||||
|
||||
qp_comms_bulk_command_sequence(device, gc9a01_init_sequence, sizeof(gc9a01_init_sequence));
|
||||
if (!qp_comms_bulk_command_sequence(device, gc9a01_init_sequence, sizeof(gc9a01_init_sequence))) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Configure the rotation (i.e. the ordering and direction of memory writes in GRAM)
|
||||
const uint8_t madctl[] = {
|
||||
@@ -54,9 +56,7 @@ __attribute__((weak)) bool qp_gc9a01_init(painter_device_t device, painter_rotat
|
||||
[QP_ROTATION_180] = GC9XXX_MADCTL_BGR | GC9XXX_MADCTL_MX | GC9XXX_MADCTL_MY,
|
||||
[QP_ROTATION_270] = GC9XXX_MADCTL_BGR | GC9XXX_MADCTL_MV | GC9XXX_MADCTL_MY,
|
||||
};
|
||||
qp_comms_command_databyte(device, GC9XXX_SET_MEM_ACS_CTL, madctl[rotation]);
|
||||
|
||||
return true;
|
||||
return qp_comms_command_databyte(device, GC9XXX_SET_MEM_ACS_CTL, madctl[rotation]);
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
@@ -50,6 +50,16 @@ painter_device_t qp_make_rgb565_surface(uint16_t panel_width, uint16_t panel_hei
|
||||
*/
|
||||
painter_device_t qp_make_mono1bpp_surface(uint16_t panel_width, uint16_t panel_height, void *buffer);
|
||||
|
||||
/**
|
||||
* Factory method for an RGB888 surface (aka framebuffer).
|
||||
*
|
||||
* @param panel_width[in] the width of the display panel
|
||||
* @param panel_height[in] the height of the display panel
|
||||
* @param buffer[in] pointer to a preallocated uint8_t buffer of size `SURFACE_REQUIRED_BUFFER_BYTE_SIZE(panel_width, panel_height, 16)`
|
||||
* @return the device handle used with all drawing routines in Quantum Painter
|
||||
*/
|
||||
painter_device_t qp_make_rgb888_surface(uint16_t panel_width, uint16_t panel_height, void *buffer);
|
||||
|
||||
/**
|
||||
* Helper method to draw the contents of the framebuffer to the target device.
|
||||
*
|
||||
|
||||
@@ -53,7 +53,7 @@ void qp_surface_update_dirty(surface_dirty_data_t *dirty, uint16_t x, uint16_t y
|
||||
// Driver vtable
|
||||
|
||||
bool qp_surface_init(painter_device_t device, painter_rotation_t rotation) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
surface_painter_device_t *surface = (surface_painter_device_t *)driver;
|
||||
memset(surface->buffer, 0, SURFACE_REQUIRED_BUFFER_BYTE_SIZE(driver->panel_width, driver->panel_height, driver->native_bits_per_pixel));
|
||||
|
||||
@@ -78,7 +78,7 @@ bool qp_surface_clear(painter_device_t device) {
|
||||
}
|
||||
|
||||
bool qp_surface_flush(painter_device_t device) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
surface_painter_device_t *surface = (surface_painter_device_t *)driver;
|
||||
surface->dirty.l = surface->dirty.t = UINT16_MAX;
|
||||
surface->dirty.r = surface->dirty.b = 0;
|
||||
@@ -87,7 +87,7 @@ bool qp_surface_flush(painter_device_t device) {
|
||||
}
|
||||
|
||||
bool qp_surface_viewport(painter_device_t device, uint16_t left, uint16_t top, uint16_t right, uint16_t bottom) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
surface_painter_device_t *surface = (surface_painter_device_t *)driver;
|
||||
|
||||
// Set the viewport locations
|
||||
@@ -106,9 +106,9 @@ bool qp_surface_viewport(painter_device_t device, uint16_t left, uint16_t top, u
|
||||
// Drawing routine to copy out the dirty region and send it to another device
|
||||
|
||||
bool qp_surface_draw(painter_device_t surface, painter_device_t target, uint16_t x, uint16_t y, bool entire_surface) {
|
||||
painter_driver_t * surface_driver = (painter_driver_t *)surface;
|
||||
painter_driver_t *surface_driver = (painter_driver_t *)surface;
|
||||
surface_painter_device_t *surface_handle = (surface_painter_device_t *)surface_driver;
|
||||
painter_driver_t * target_driver = (painter_driver_t *)target;
|
||||
painter_driver_t *target_driver = (painter_driver_t *)target;
|
||||
|
||||
// If we're not dirty... we're done.
|
||||
if (!surface_handle->dirty.is_dirty) {
|
||||
|
||||
@@ -42,9 +42,10 @@ typedef struct surface_painter_device_t {
|
||||
|
||||
// The target buffer
|
||||
union {
|
||||
void * buffer;
|
||||
uint8_t * u8buffer;
|
||||
void *buffer;
|
||||
uint8_t *u8buffer;
|
||||
uint16_t *u16buffer;
|
||||
rgb_t *rgbbuffer;
|
||||
};
|
||||
|
||||
// Manually manage the viewport for streaming pixel data to the display
|
||||
|
||||
@@ -55,7 +55,7 @@ static inline void stream_pixdata_mono1bpp(surface_painter_device_t *surface, co
|
||||
|
||||
// Stream pixel data to the current write position in GRAM
|
||||
static bool qp_surface_pixdata_mono1bpp(painter_device_t device, const void *pixel_data, uint32_t native_pixel_count) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
surface_painter_device_t *surface = (surface_painter_device_t *)driver;
|
||||
stream_pixdata_mono1bpp(surface, (const uint8_t *)pixel_data, native_pixel_count);
|
||||
return true;
|
||||
|
||||
@@ -43,7 +43,7 @@ static inline void stream_pixdata_rgb565(surface_painter_device_t *surface, cons
|
||||
|
||||
// Stream pixel data to the current write position in GRAM
|
||||
static bool qp_surface_pixdata_rgb565(painter_device_t device, const void *pixel_data, uint32_t native_pixel_count) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
surface_painter_device_t *surface = (surface_painter_device_t *)driver;
|
||||
stream_pixdata_rgb565(surface, (const uint16_t *)pixel_data, native_pixel_count);
|
||||
return true;
|
||||
@@ -52,7 +52,7 @@ static bool qp_surface_pixdata_rgb565(painter_device_t device, const void *pixel
|
||||
// Pixel colour conversion
|
||||
static bool qp_surface_palette_convert_rgb565_swapped(painter_device_t device, int16_t palette_size, qp_pixel_t *palette) {
|
||||
for (int16_t i = 0; i < palette_size; ++i) {
|
||||
rgb_t rgb = hsv_to_rgb_nocie((hsv_t){palette[i].hsv888.h, palette[i].hsv888.s, palette[i].hsv888.v});
|
||||
rgb_t rgb = hsv_to_rgb_nocie(palette[i].hsv888);
|
||||
uint16_t rgb565 = (((uint16_t)rgb.r) >> 3) << 11 | (((uint16_t)rgb.g) >> 2) << 5 | (((uint16_t)rgb.b) >> 3);
|
||||
palette[i].rgb565 = __builtin_bswap16(rgb565);
|
||||
}
|
||||
|
||||
143
drivers/painter/generic/qp_surface_rgb888.c
Normal file
143
drivers/painter/generic/qp_surface_rgb888.c
Normal file
@@ -0,0 +1,143 @@
|
||||
// Copyright 2022 Nick Brassel (@tzarc)
|
||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||
|
||||
#ifdef QUANTUM_PAINTER_SURFACE_ENABLE
|
||||
|
||||
# include "color.h"
|
||||
# include "qp_draw.h"
|
||||
# include "qp_surface_internal.h"
|
||||
# include "qp_comms_dummy.h"
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// Surface driver impl: rgb888
|
||||
|
||||
static inline void setpixel_rgb888(surface_painter_device_t *surface, uint16_t x, uint16_t y, rgb_t rgb888) {
|
||||
uint16_t w = surface->base.panel_width;
|
||||
uint16_t h = surface->base.panel_height;
|
||||
|
||||
// Drop out if it's off-screen
|
||||
if (x >= w || y >= h) {
|
||||
return;
|
||||
}
|
||||
|
||||
// Skip messing with the dirty info if the original value already matches
|
||||
if (memcmp(&surface->rgbbuffer[y * w + x], &rgb888, sizeof(rgb_t)) != 0) {
|
||||
// Update the dirty region
|
||||
qp_surface_update_dirty(&surface->dirty, x, y);
|
||||
|
||||
// Update the pixel data in the buffer
|
||||
surface->rgbbuffer[y * w + x] = rgb888;
|
||||
}
|
||||
}
|
||||
|
||||
static inline void append_pixel_rgb888(surface_painter_device_t *surface, rgb_t rgb888) {
|
||||
setpixel_rgb888(surface, surface->viewport.pixdata_x, surface->viewport.pixdata_y, rgb888);
|
||||
qp_surface_increment_pixdata_location(&surface->viewport);
|
||||
}
|
||||
|
||||
static inline void stream_pixdata_rgb888(surface_painter_device_t *surface, const rgb_t *data, uint32_t native_pixel_count) {
|
||||
for (uint32_t pixel_counter = 0; pixel_counter < native_pixel_count; ++pixel_counter) {
|
||||
append_pixel_rgb888(surface, data[pixel_counter]);
|
||||
}
|
||||
}
|
||||
|
||||
// Stream pixel data to the current write position in GRAM
|
||||
static bool qp_surface_pixdata_rgb888(painter_device_t device, const void *pixel_data, uint32_t native_pixel_count) {
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
surface_painter_device_t *surface = (surface_painter_device_t *)driver;
|
||||
stream_pixdata_rgb888(surface, (const rgb_t *)pixel_data, native_pixel_count);
|
||||
return true;
|
||||
}
|
||||
|
||||
// Pixel colour conversion
|
||||
static bool qp_surface_palette_convert_rgb888(painter_device_t device, int16_t palette_size, qp_pixel_t *palette) {
|
||||
for (int16_t i = 0; i < palette_size; ++i) {
|
||||
palette[i].rgb888 = hsv_to_rgb_nocie(palette[i].hsv888);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
// Append pixels to the target location, keyed by the pixel index
|
||||
static bool qp_surface_append_pixels_rgb888(painter_device_t device, uint8_t *target_buffer, qp_pixel_t *palette, uint32_t pixel_offset, uint32_t pixel_count, uint8_t *palette_indices) {
|
||||
rgb_t *buf = (rgb_t *)target_buffer;
|
||||
for (uint32_t i = 0; i < pixel_count; ++i) {
|
||||
buf[pixel_offset + i] = palette[palette_indices[i]].rgb888;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
static bool rgb888_target_pixdata_transfer(painter_driver_t *surface_driver, painter_driver_t *target_driver, uint16_t x, uint16_t y, bool entire_surface) {
|
||||
surface_painter_device_t *surface_handle = (surface_painter_device_t *)surface_driver;
|
||||
|
||||
uint16_t l = entire_surface ? 0 : surface_handle->dirty.l;
|
||||
uint16_t t = entire_surface ? 0 : surface_handle->dirty.t;
|
||||
uint16_t r = entire_surface ? (surface_handle->base.panel_width - 1) : surface_handle->dirty.r;
|
||||
uint16_t b = entire_surface ? (surface_handle->base.panel_height - 1) : surface_handle->dirty.b;
|
||||
|
||||
// Set the target drawing area
|
||||
bool ok = qp_viewport((painter_device_t)target_driver, x + l, y + t, x + r, y + b);
|
||||
if (!ok) {
|
||||
qp_dprintf("rgb888_target_pixdata_transfer: fail (could not set target viewport)\n");
|
||||
return false;
|
||||
}
|
||||
|
||||
// Housekeeping of the amount of pixels to transfer
|
||||
uint32_t total_pixel_count = (8 * QUANTUM_PAINTER_PIXDATA_BUFFER_SIZE) / surface_driver->native_bits_per_pixel;
|
||||
uint32_t pixel_counter = 0;
|
||||
rgb_t *target_buffer = (rgb_t *)qp_internal_global_pixdata_buffer;
|
||||
|
||||
// Fill the global pixdata area so that we can start transferring to the panel
|
||||
for (uint16_t y = t; y <= b; ++y) {
|
||||
for (uint16_t x = l; x <= r; ++x) {
|
||||
// Update the target buffer
|
||||
target_buffer[pixel_counter++] = surface_handle->rgbbuffer[y * surface_handle->base.panel_width + x];
|
||||
|
||||
// If we've accumulated enough data, send it
|
||||
if (pixel_counter == total_pixel_count) {
|
||||
ok = qp_pixdata((painter_device_t)target_driver, qp_internal_global_pixdata_buffer, pixel_counter);
|
||||
if (!ok) {
|
||||
qp_dprintf("rgb888_target_pixdata_transfer: fail (could not stream pixdata to target)\n");
|
||||
return false;
|
||||
}
|
||||
// Reset the counter
|
||||
pixel_counter = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// If there's any leftover data, send it
|
||||
if (pixel_counter > 0) {
|
||||
ok = qp_pixdata((painter_device_t)target_driver, qp_internal_global_pixdata_buffer, pixel_counter);
|
||||
if (!ok) {
|
||||
qp_dprintf("rgb888_target_pixdata_transfer: fail (could not stream pixdata to target)\n");
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
static bool qp_surface_append_pixdata_rgb888(painter_device_t device, uint8_t *target_buffer, uint32_t pixdata_offset, uint8_t pixdata_byte) {
|
||||
target_buffer[pixdata_offset] = pixdata_byte;
|
||||
return true;
|
||||
}
|
||||
|
||||
const surface_painter_driver_vtable_t rgb888_surface_driver_vtable = {
|
||||
.base =
|
||||
{
|
||||
.init = qp_surface_init,
|
||||
.power = qp_surface_power,
|
||||
.clear = qp_surface_clear,
|
||||
.flush = qp_surface_flush,
|
||||
.pixdata = qp_surface_pixdata_rgb888,
|
||||
.viewport = qp_surface_viewport,
|
||||
.palette_convert = qp_surface_palette_convert_rgb888,
|
||||
.append_pixels = qp_surface_append_pixels_rgb888,
|
||||
.append_pixdata = qp_surface_append_pixdata_rgb888,
|
||||
},
|
||||
.target_pixdata_transfer = rgb888_target_pixdata_transfer,
|
||||
};
|
||||
|
||||
SURFACE_FACTORY_FUNCTION_IMPL(qp_make_rgb888_surface, rgb888_surface_driver_vtable, 24);
|
||||
|
||||
#endif // QUANTUM_PAINTER_SURFACE_ENABLE
|
||||
@@ -41,7 +41,9 @@ __attribute__((weak)) bool qp_ili9163_init(painter_device_t device, painter_rota
|
||||
ILI9XXX_CMD_DISPLAY_ON, 20, 0
|
||||
};
|
||||
// clang-format on
|
||||
qp_comms_bulk_command_sequence(device, ili9163_init_sequence, sizeof(ili9163_init_sequence));
|
||||
if (!qp_comms_bulk_command_sequence(device, ili9163_init_sequence, sizeof(ili9163_init_sequence))) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Configure the rotation (i.e. the ordering and direction of memory writes in GRAM)
|
||||
const uint8_t madctl[] = {
|
||||
@@ -50,9 +52,7 @@ __attribute__((weak)) bool qp_ili9163_init(painter_device_t device, painter_rota
|
||||
[QP_ROTATION_180] = ILI9XXX_MADCTL_BGR | ILI9XXX_MADCTL_MX | ILI9XXX_MADCTL_MY,
|
||||
[QP_ROTATION_270] = ILI9XXX_MADCTL_BGR | ILI9XXX_MADCTL_MV | ILI9XXX_MADCTL_MY,
|
||||
};
|
||||
qp_comms_command_databyte(device, ILI9XXX_SET_MEM_ACS_CTL, madctl[rotation]);
|
||||
|
||||
return true;
|
||||
return qp_comms_command_databyte(device, ILI9XXX_SET_MEM_ACS_CTL, madctl[rotation]);
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
@@ -48,7 +48,9 @@ __attribute__((weak)) bool qp_ili9341_init(painter_device_t device, painter_rota
|
||||
ILI9XXX_CMD_DISPLAY_ON, 20, 0
|
||||
};
|
||||
// clang-format on
|
||||
qp_comms_bulk_command_sequence(device, ili9341_init_sequence, sizeof(ili9341_init_sequence));
|
||||
if (!qp_comms_bulk_command_sequence(device, ili9341_init_sequence, sizeof(ili9341_init_sequence))) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Configure the rotation (i.e. the ordering and direction of memory writes in GRAM)
|
||||
const uint8_t madctl[] = {
|
||||
@@ -57,9 +59,7 @@ __attribute__((weak)) bool qp_ili9341_init(painter_device_t device, painter_rota
|
||||
[QP_ROTATION_180] = ILI9XXX_MADCTL_BGR | ILI9XXX_MADCTL_MX | ILI9XXX_MADCTL_MY,
|
||||
[QP_ROTATION_270] = ILI9XXX_MADCTL_BGR | ILI9XXX_MADCTL_MV | ILI9XXX_MADCTL_MY,
|
||||
};
|
||||
qp_comms_command_databyte(device, ILI9XXX_SET_MEM_ACS_CTL, madctl[rotation]);
|
||||
|
||||
return true;
|
||||
return qp_comms_command_databyte(device, ILI9XXX_SET_MEM_ACS_CTL, madctl[rotation]);
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
@@ -37,7 +37,9 @@ bool qp_ili9486_init(painter_device_t device, painter_rotation_t rotation) {
|
||||
ILI9XXX_SET_INVERSION_CTL, 0, 1, 0x02,
|
||||
};
|
||||
// clang-format on
|
||||
qp_comms_bulk_command_sequence(device, ili9486_init_sequence, sizeof(ili9486_init_sequence));
|
||||
if (!qp_comms_bulk_command_sequence(device, ili9486_init_sequence, sizeof(ili9486_init_sequence))) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Configure the rotation (i.e. the ordering and direction of memory writes in GRAM)
|
||||
const uint8_t madctl[] = {
|
||||
@@ -62,26 +64,26 @@ bool qp_ili9486_init(painter_device_t device, painter_rotation_t rotation) {
|
||||
ILI9XXX_CMD_DISPLAY_ON, 5, 0,
|
||||
};
|
||||
// clang-format on
|
||||
qp_comms_bulk_command_sequence(device, rotation_sequence, sizeof(rotation_sequence));
|
||||
|
||||
return true;
|
||||
return qp_comms_bulk_command_sequence(device, rotation_sequence, sizeof(rotation_sequence));
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// Driver vtable
|
||||
|
||||
// waveshare variant needs some tweaks due to shift registers
|
||||
static void qp_comms_spi_dc_reset_send_command_odd_cs_pulse(painter_device_t device, uint8_t cmd) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
static bool qp_comms_spi_dc_reset_send_command_odd_cs_pulse(painter_device_t device, uint8_t cmd) {
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
qp_comms_spi_dc_reset_config_t *comms_config = (qp_comms_spi_dc_reset_config_t *)driver->comms_config;
|
||||
|
||||
gpio_write_pin_low(comms_config->spi_config.chip_select_pin);
|
||||
qp_comms_spi_dc_reset_send_command(device, cmd);
|
||||
gpio_write_pin_high(comms_config->spi_config.chip_select_pin);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
static uint32_t qp_comms_spi_send_data_odd_cs_pulse(painter_device_t device, const void *data, uint32_t byte_count) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
qp_comms_spi_dc_reset_config_t *comms_config = (qp_comms_spi_dc_reset_config_t *)driver->comms_config;
|
||||
|
||||
uint32_t bytes_remaining = byte_count;
|
||||
@@ -90,7 +92,7 @@ static uint32_t qp_comms_spi_send_data_odd_cs_pulse(painter_device_t device, con
|
||||
|
||||
gpio_write_pin_high(comms_config->dc_pin);
|
||||
while (bytes_remaining > 0) {
|
||||
uint32_t bytes_this_loop = QP_MIN(bytes_remaining, max_msg_length);
|
||||
uint32_t bytes_this_loop = MIN(bytes_remaining, max_msg_length);
|
||||
bool odd_bytes = bytes_this_loop & 1;
|
||||
|
||||
// send data
|
||||
@@ -111,7 +113,7 @@ static uint32_t qp_comms_spi_send_data_odd_cs_pulse(painter_device_t device, con
|
||||
}
|
||||
|
||||
static uint32_t qp_ili9486_send_data_toggling(painter_device_t device, const uint8_t *data, uint32_t byte_count) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
qp_comms_spi_dc_reset_config_t *comms_config = (qp_comms_spi_dc_reset_config_t *)driver->comms_config;
|
||||
|
||||
uint32_t ret;
|
||||
@@ -124,7 +126,7 @@ static uint32_t qp_ili9486_send_data_toggling(painter_device_t device, const uin
|
||||
return ret;
|
||||
}
|
||||
|
||||
static void qp_comms_spi_send_command_sequence_odd_cs_pulse(painter_device_t device, const uint8_t *sequence, size_t sequence_len) {
|
||||
static bool qp_comms_spi_send_command_sequence_odd_cs_pulse(painter_device_t device, const uint8_t *sequence, size_t sequence_len) {
|
||||
for (size_t i = 0; i < sequence_len;) {
|
||||
uint8_t command = sequence[i];
|
||||
uint8_t delay = sequence[i + 1];
|
||||
@@ -140,10 +142,12 @@ static void qp_comms_spi_send_command_sequence_odd_cs_pulse(painter_device_t dev
|
||||
}
|
||||
i += (3 + num_bytes);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
static bool qp_ili9486_viewport(painter_device_t device, uint16_t left, uint16_t top, uint16_t right, uint16_t bottom) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
tft_panel_dc_reset_painter_driver_vtable_t *vtable = (tft_panel_dc_reset_painter_driver_vtable_t *)driver->driver_vtable;
|
||||
|
||||
// Fix up the drawing location if required
|
||||
|
||||
@@ -41,7 +41,9 @@ __attribute__((weak)) bool qp_ili9488_init(painter_device_t device, painter_rota
|
||||
ILI9XXX_CMD_DISPLAY_ON, 20, 0
|
||||
};
|
||||
// clang-format on
|
||||
qp_comms_bulk_command_sequence(device, ili9488_init_sequence, sizeof(ili9488_init_sequence));
|
||||
if (!qp_comms_bulk_command_sequence(device, ili9488_init_sequence, sizeof(ili9488_init_sequence))) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Configure the rotation (i.e. the ordering and direction of memory writes in GRAM)
|
||||
const uint8_t madctl[] = {
|
||||
@@ -50,9 +52,7 @@ __attribute__((weak)) bool qp_ili9488_init(painter_device_t device, painter_rota
|
||||
[QP_ROTATION_180] = ILI9XXX_MADCTL_BGR | ILI9XXX_MADCTL_MX,
|
||||
[QP_ROTATION_270] = ILI9XXX_MADCTL_BGR | ILI9XXX_MADCTL_MV,
|
||||
};
|
||||
qp_comms_command_databyte(device, ILI9XXX_SET_MEM_ACS_CTL, madctl[rotation]);
|
||||
|
||||
return true;
|
||||
return qp_comms_command_databyte(device, ILI9XXX_SET_MEM_ACS_CTL, madctl[rotation]);
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
#include "qp_surface.h"
|
||||
#include "qp_surface_internal.h"
|
||||
|
||||
typedef void (*ld7032_driver_comms_send_command_and_data_func)(painter_device_t device, uint8_t cmd, uint8_t data);
|
||||
typedef bool (*ld7032_driver_comms_send_command_and_data_func)(painter_device_t device, uint8_t cmd, uint8_t data);
|
||||
typedef uint32_t (*ld7032_driver_comms_send_command_and_databuf_func)(painter_device_t device, uint8_t cmd, const void *data, uint32_t byte_count);
|
||||
|
||||
typedef struct ld7032_comms_with_command_vtable_t {
|
||||
@@ -25,12 +25,13 @@ typedef struct ld7032_comms_with_command_vtable_t {
|
||||
// LD7032 Internal API
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
void ld7032_comms_i2c_send_command_and_data(painter_device_t device, uint8_t cmd, uint8_t data) {
|
||||
#ifdef QUANTUM_PAINTER_LD7032_I2C_ENABLE
|
||||
bool ld7032_comms_i2c_send_command_and_data(painter_device_t device, uint8_t cmd, uint8_t data) {
|
||||
uint8_t buf[2] = {cmd, data};
|
||||
qp_comms_i2c_send_data(device, buf, 2);
|
||||
return qp_comms_i2c_send_data(device, buf, 2);
|
||||
}
|
||||
|
||||
void ld7032_comms_i2c_bulk_command_sequence(painter_device_t device, const uint8_t *sequence, size_t sequence_len) {
|
||||
bool ld7032_comms_i2c_bulk_command_sequence(painter_device_t device, const uint8_t *sequence, size_t sequence_len) {
|
||||
uint8_t buf[32];
|
||||
for (size_t i = 0; i < sequence_len;) {
|
||||
uint8_t command = sequence[i];
|
||||
@@ -38,12 +39,16 @@ void ld7032_comms_i2c_bulk_command_sequence(painter_device_t device, const uint8
|
||||
uint8_t num_bytes = sequence[i + 2];
|
||||
buf[0] = command;
|
||||
memcpy(&buf[1], &sequence[i + 3], num_bytes);
|
||||
qp_comms_i2c_send_data(device, buf, num_bytes + 1);
|
||||
if (!qp_comms_i2c_send_data(device, buf, num_bytes + 1)) {
|
||||
return false;
|
||||
}
|
||||
if (delay > 0) {
|
||||
wait_ms(delay);
|
||||
}
|
||||
i += (3 + num_bytes);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
uint32_t ld7032_comms_i2c_send_command_and_databuf(painter_device_t device, uint8_t cmd, const void *data, uint32_t byte_count) {
|
||||
@@ -53,10 +58,11 @@ uint32_t ld7032_comms_i2c_send_command_and_databuf(painter_device_t device, uint
|
||||
memcpy(&buf[1], data, byte_count);
|
||||
return qp_comms_send(device, buf, byte_count + 1);
|
||||
}
|
||||
#endif // QUANTUM_PAINTER_LD7032_I2C_ENABLE
|
||||
|
||||
// Power control
|
||||
bool qp_ld7032_power(painter_device_t device, bool power_on) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
ld7032_comms_with_command_vtable_t *comms_vtable = (ld7032_comms_with_command_vtable_t *)driver->comms_vtable;
|
||||
|
||||
comms_vtable->send_command_data(device, LD7032_DISP_ON_OFF, power_on ? 0x01 : 0x00);
|
||||
@@ -77,7 +83,7 @@ bool qp_ld7032_clear(painter_device_t device) {
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
void ld7032_flush_0(painter_device_t device, surface_dirty_data_t *dirty, const uint8_t *framebuffer, bool inverted) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
ld7032_comms_with_command_vtable_t *comms_vtable = (ld7032_comms_with_command_vtable_t *)driver->comms_vtable;
|
||||
|
||||
int x_start = dirty->l >> 3;
|
||||
@@ -109,7 +115,7 @@ void ld7032_flush_0(painter_device_t device, surface_dirty_data_t *dirty, const
|
||||
}
|
||||
|
||||
void ld7032_flush_90(painter_device_t device, surface_dirty_data_t *dirty, const uint8_t *framebuffer, bool inverted) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
ld7032_comms_with_command_vtable_t *comms_vtable = (ld7032_comms_with_command_vtable_t *)driver->comms_vtable;
|
||||
|
||||
int x_start = dirty->t >> 3;
|
||||
@@ -201,7 +207,9 @@ __attribute__((weak)) bool qp_ld7032_init(painter_device_t device, painter_rotat
|
||||
};
|
||||
// clang-format on
|
||||
|
||||
qp_comms_bulk_command_sequence(device, ld7032_init_sequence, sizeof(ld7032_init_sequence));
|
||||
if (!qp_comms_bulk_command_sequence(device, ld7032_init_sequence, sizeof(ld7032_init_sequence))) {
|
||||
return false;
|
||||
}
|
||||
|
||||
uint8_t display_y_start = 40 - driver->oled.base.panel_height;
|
||||
uint8_t display_x_start = (128 - driver->oled.base.panel_width) / 2;
|
||||
@@ -223,7 +231,9 @@ __attribute__((weak)) bool qp_ld7032_init(painter_device_t device, painter_rotat
|
||||
ld7032_memory_setup[13] = ld7032_memory_setup[4] + 1;
|
||||
ld7032_memory_setup[17] = driver->oled.base.panel_height;
|
||||
|
||||
qp_comms_bulk_command_sequence(device, ld7032_memory_setup, sizeof(ld7032_memory_setup));
|
||||
if (!qp_comms_bulk_command_sequence(device, ld7032_memory_setup, sizeof(ld7032_memory_setup))) {
|
||||
return false;
|
||||
}
|
||||
|
||||
uint8_t write_direction = 0;
|
||||
switch (rotation) {
|
||||
@@ -242,10 +252,12 @@ __attribute__((weak)) bool qp_ld7032_init(painter_device_t device, painter_rotat
|
||||
break;
|
||||
}
|
||||
|
||||
painter_driver_t * pdriver = (painter_driver_t *)device;
|
||||
painter_driver_t *pdriver = (painter_driver_t *)device;
|
||||
ld7032_comms_with_command_vtable_t *comms_vtable = (ld7032_comms_with_command_vtable_t *)pdriver->comms_vtable;
|
||||
|
||||
comms_vtable->send_command_data(device, LD7032_WRITE_DIRECTION, write_direction);
|
||||
if (!comms_vtable->send_command_data(device, LD7032_WRITE_DIRECTION, write_direction)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
qp_ld7032_power(device, true);
|
||||
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
|
||||
// Power control
|
||||
bool qp_oled_panel_power(painter_device_t device, bool power_on) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
oled_panel_painter_driver_vtable_t *vtable = (oled_panel_painter_driver_vtable_t *)driver->driver_vtable;
|
||||
qp_comms_command(device, power_on ? vtable->opcodes.display_on : vtable->opcodes.display_off);
|
||||
return true;
|
||||
@@ -59,7 +59,7 @@ bool qp_oled_panel_passthru_append_pixdata(painter_device_t device, uint8_t *tar
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
void qp_oled_panel_page_column_flush_rot0(painter_device_t device, surface_dirty_data_t *dirty, const uint8_t *framebuffer) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
oled_panel_painter_driver_vtable_t *vtable = (oled_panel_painter_driver_vtable_t *)driver->driver_vtable;
|
||||
|
||||
// TODO: account for offset_x/y in base driver
|
||||
@@ -92,7 +92,7 @@ void qp_oled_panel_page_column_flush_rot0(painter_device_t device, surface_dirty
|
||||
}
|
||||
|
||||
void qp_oled_panel_page_column_flush_rot90(painter_device_t device, surface_dirty_data_t *dirty, const uint8_t *framebuffer) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
oled_panel_painter_driver_vtable_t *vtable = (oled_panel_painter_driver_vtable_t *)driver->driver_vtable;
|
||||
|
||||
// TODO: account for offset_x/y in base driver
|
||||
@@ -126,7 +126,7 @@ void qp_oled_panel_page_column_flush_rot90(painter_device_t device, surface_dirt
|
||||
}
|
||||
|
||||
void qp_oled_panel_page_column_flush_rot180(painter_device_t device, surface_dirty_data_t *dirty, const uint8_t *framebuffer) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
oled_panel_painter_driver_vtable_t *vtable = (oled_panel_painter_driver_vtable_t *)driver->driver_vtable;
|
||||
|
||||
// TODO: account for offset_x/y in base driver
|
||||
@@ -161,7 +161,7 @@ void qp_oled_panel_page_column_flush_rot180(painter_device_t device, surface_dir
|
||||
}
|
||||
|
||||
void qp_oled_panel_page_column_flush_rot270(painter_device_t device, surface_dirty_data_t *dirty, const uint8_t *framebuffer) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
oled_panel_painter_driver_vtable_t *vtable = (oled_panel_painter_driver_vtable_t *)driver->driver_vtable;
|
||||
|
||||
// TODO: account for offset_x/y in base driver
|
||||
|
||||
@@ -71,8 +71,7 @@ __attribute__((weak)) bool qp_sh1106_init(painter_device_t device, painter_rotat
|
||||
sh1106_init_sequence[20] = 0x02;
|
||||
}
|
||||
|
||||
qp_comms_bulk_command_sequence(device, sh1106_init_sequence, sizeof(sh1106_init_sequence));
|
||||
return true;
|
||||
return qp_comms_bulk_command_sequence(device, sh1106_init_sequence, sizeof(sh1106_init_sequence));
|
||||
}
|
||||
|
||||
// Screen flush
|
||||
|
||||
@@ -73,8 +73,7 @@ __attribute__((weak)) bool qp_sh1107_init(painter_device_t device, painter_rotat
|
||||
sh1107_init_sequence[20] = 0x02;
|
||||
}
|
||||
|
||||
qp_comms_bulk_command_sequence(device, sh1107_init_sequence, sizeof(sh1107_init_sequence));
|
||||
return true;
|
||||
return qp_comms_bulk_command_sequence(device, sh1107_init_sequence, sizeof(sh1107_init_sequence));
|
||||
}
|
||||
|
||||
// Screen flush
|
||||
|
||||
@@ -44,7 +44,9 @@ __attribute__((weak)) bool qp_ssd1351_init(painter_device_t device, painter_rota
|
||||
SSD1351_DISPLAYON, 5, 0,
|
||||
};
|
||||
// clang-format on
|
||||
qp_comms_bulk_command_sequence(device, ssd1351_init_sequence, sizeof(ssd1351_init_sequence));
|
||||
if (!qp_comms_bulk_command_sequence(device, ssd1351_init_sequence, sizeof(ssd1351_init_sequence))) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Configure the rotation (i.e. the ordering and direction of memory writes in GRAM)
|
||||
const uint8_t madctl[] = {
|
||||
@@ -53,10 +55,10 @@ __attribute__((weak)) bool qp_ssd1351_init(painter_device_t device, painter_rota
|
||||
[QP_ROTATION_180] = SSD1351_MADCTL_BGR | SSD1351_MADCTL_MX,
|
||||
[QP_ROTATION_270] = SSD1351_MADCTL_BGR | SSD1351_MADCTL_MV,
|
||||
};
|
||||
qp_comms_command_databyte(device, SSD1351_SETREMAP, madctl[rotation]);
|
||||
qp_comms_command_databyte(device, SSD1351_STARTLINE, (rotation == QP_ROTATION_0 || rotation == QP_ROTATION_90) ? driver->base.panel_height : 0);
|
||||
|
||||
return true;
|
||||
if (!qp_comms_command_databyte(device, SSD1351_SETREMAP, madctl[rotation])) {
|
||||
return false;
|
||||
}
|
||||
return qp_comms_command_databyte(device, SSD1351_STARTLINE, (rotation == QP_ROTATION_0 || rotation == QP_ROTATION_90) ? driver->base.panel_height : 0);
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
@@ -63,7 +63,9 @@ __attribute__((weak)) bool qp_st7735_init(painter_device_t device, painter_rotat
|
||||
ST77XX_CMD_DISPLAY_ON, 20, 0
|
||||
};
|
||||
// clang-format on
|
||||
qp_comms_bulk_command_sequence(device, st7735_init_sequence, sizeof(st7735_init_sequence));
|
||||
if (!qp_comms_bulk_command_sequence(device, st7735_init_sequence, sizeof(st7735_init_sequence))) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Configure the rotation (i.e. the ordering and direction of memory writes in GRAM)
|
||||
const uint8_t madctl[] = {
|
||||
@@ -72,7 +74,9 @@ __attribute__((weak)) bool qp_st7735_init(painter_device_t device, painter_rotat
|
||||
[QP_ROTATION_180] = ST77XX_MADCTL_BGR | ST77XX_MADCTL_MX | ST77XX_MADCTL_MY,
|
||||
[QP_ROTATION_270] = ST77XX_MADCTL_BGR | ST77XX_MADCTL_MV | ST77XX_MADCTL_MY,
|
||||
};
|
||||
qp_comms_command_databyte(device, ST77XX_SET_MADCTL, madctl[rotation]);
|
||||
if (!qp_comms_command_databyte(device, ST77XX_SET_MADCTL, madctl[rotation])) {
|
||||
return false;
|
||||
}
|
||||
|
||||
#ifndef ST7735_NO_AUTOMATIC_VIEWPORT_OFFSETS
|
||||
st7735_automatic_viewport_offsets(device, rotation);
|
||||
|
||||
@@ -60,7 +60,9 @@ __attribute__((weak)) bool qp_st7789_init(painter_device_t device, painter_rotat
|
||||
ST77XX_CMD_DISPLAY_ON, 20, 0
|
||||
};
|
||||
// clang-format on
|
||||
qp_comms_bulk_command_sequence(device, st7789_init_sequence, sizeof(st7789_init_sequence));
|
||||
if (!qp_comms_bulk_command_sequence(device, st7789_init_sequence, sizeof(st7789_init_sequence))) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Configure the rotation (i.e. the ordering and direction of memory writes in GRAM)
|
||||
const uint8_t madctl[] = {
|
||||
@@ -69,7 +71,9 @@ __attribute__((weak)) bool qp_st7789_init(painter_device_t device, painter_rotat
|
||||
[QP_ROTATION_180] = ST77XX_MADCTL_RGB | ST77XX_MADCTL_MX | ST77XX_MADCTL_MY,
|
||||
[QP_ROTATION_270] = ST77XX_MADCTL_RGB | ST77XX_MADCTL_MV | ST77XX_MADCTL_MY,
|
||||
};
|
||||
qp_comms_command_databyte(device, ST77XX_SET_MADCTL, madctl[rotation]);
|
||||
if (!qp_comms_command_databyte(device, ST77XX_SET_MADCTL, madctl[rotation])) {
|
||||
return false;
|
||||
}
|
||||
|
||||
#ifndef ST7789_NO_AUTOMATIC_VIEWPORT_OFFSETS
|
||||
st7789_automatic_viewport_offsets(device, rotation);
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
|
||||
// Power control
|
||||
bool qp_tft_panel_power(painter_device_t device, bool power_on) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
tft_panel_dc_reset_painter_driver_vtable_t *vtable = (tft_panel_dc_reset_painter_driver_vtable_t *)driver->driver_vtable;
|
||||
qp_comms_command(device, power_on ? vtable->opcodes.display_on : vtable->opcodes.display_off);
|
||||
return true;
|
||||
@@ -33,7 +33,7 @@ bool qp_tft_panel_flush(painter_device_t device) {
|
||||
|
||||
// Viewport to draw to
|
||||
bool qp_tft_panel_viewport(painter_device_t device, uint16_t left, uint16_t top, uint16_t right, uint16_t bottom) {
|
||||
painter_driver_t * driver = (painter_driver_t *)device;
|
||||
painter_driver_t *driver = (painter_driver_t *)device;
|
||||
tft_panel_dc_reset_painter_driver_vtable_t *vtable = (tft_panel_dc_reset_painter_driver_vtable_t *)driver->driver_vtable;
|
||||
|
||||
// Fix up the drawing location if required
|
||||
@@ -90,7 +90,7 @@ bool qp_tft_panel_pixdata(painter_device_t device, const void *pixel_data, uint3
|
||||
|
||||
bool qp_tft_panel_palette_convert_rgb565_swapped(painter_device_t device, int16_t palette_size, qp_pixel_t *palette) {
|
||||
for (int16_t i = 0; i < palette_size; ++i) {
|
||||
rgb_t rgb = hsv_to_rgb_nocie((hsv_t){palette[i].hsv888.h, palette[i].hsv888.s, palette[i].hsv888.v});
|
||||
rgb_t rgb = hsv_to_rgb_nocie(palette[i].hsv888);
|
||||
uint16_t rgb565 = (((uint16_t)rgb.r) >> 3) << 11 | (((uint16_t)rgb.g) >> 2) << 5 | (((uint16_t)rgb.b) >> 3);
|
||||
palette[i].rgb565 = __builtin_bswap16(rgb565);
|
||||
}
|
||||
@@ -99,10 +99,7 @@ bool qp_tft_panel_palette_convert_rgb565_swapped(painter_device_t device, int16_
|
||||
|
||||
bool qp_tft_panel_palette_convert_rgb888(painter_device_t device, int16_t palette_size, qp_pixel_t *palette) {
|
||||
for (int16_t i = 0; i < palette_size; ++i) {
|
||||
rgb_t rgb = hsv_to_rgb_nocie((hsv_t){palette[i].hsv888.h, palette[i].hsv888.s, palette[i].hsv888.v});
|
||||
palette[i].rgb888.r = rgb.r;
|
||||
palette[i].rgb888.g = rgb.g;
|
||||
palette[i].rgb888.b = rgb.b;
|
||||
palette[i].rgb888 = hsv_to_rgb_nocie(palette[i].hsv888);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -97,7 +97,7 @@ void ps2_mouse_task(void) {
|
||||
mouse_report.x = ps2_host_recv_response();
|
||||
mouse_report.y = ps2_host_recv_response();
|
||||
# ifdef PS2_MOUSE_ENABLE_SCROLLING
|
||||
mouse_report.v = -(ps2_host_recv_response() & PS2_MOUSE_SCROLL_MASK);
|
||||
mouse_report.v = -(ps2_host_recv_response() & PS2_MOUSE_SCROLL_MASK);
|
||||
# endif
|
||||
} else {
|
||||
if (debug_mouse) print("ps2_mouse: fail to get mouse packet\n");
|
||||
|
||||
@@ -477,9 +477,9 @@ report_mouse_t cirque_pinnacle_get_report(report_mouse_t mouse_report) {
|
||||
|
||||
if (touchData.valid) {
|
||||
mouse_report.buttons = touchData.buttons;
|
||||
mouse_report.x = CONSTRAIN_HID_XY(touchData.xDelta);
|
||||
mouse_report.y = CONSTRAIN_HID_XY(touchData.yDelta);
|
||||
mouse_report.v = touchData.wheelCount;
|
||||
mouse_report.x = CONSTRAIN_HID_XY(touchData.xDelta);
|
||||
mouse_report.y = CONSTRAIN_HID_XY(touchData.yDelta);
|
||||
mouse_report.v = touchData.wheelCount;
|
||||
}
|
||||
return mouse_report;
|
||||
}
|
||||
|
||||
174
drivers/sensors/paw3222.c
Normal file
174
drivers/sensors/paw3222.c
Normal file
@@ -0,0 +1,174 @@
|
||||
/* Copyright 2024 Colin Lam (Ploopy Corporation)
|
||||
*
|
||||
* 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 2 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/>.
|
||||
*/
|
||||
|
||||
#include "paw3222.h"
|
||||
#include "wait.h"
|
||||
#include "gpio.h"
|
||||
#include "spi_master.h"
|
||||
#include "pointing_device_internal.h"
|
||||
|
||||
#define MSB1 0x80
|
||||
#define MSB0 0x7F
|
||||
|
||||
const pointing_device_driver_t paw3222_pointing_device_driver = {
|
||||
.init = paw3222_init,
|
||||
.get_report = paw3222_get_report,
|
||||
.set_cpi = paw3222_set_cpi,
|
||||
.get_cpi = paw3222_get_cpi,
|
||||
};
|
||||
|
||||
// Convert a 12-bit twos complement binary-represented number into a
|
||||
// signed 12-bit integer.
|
||||
static int16_t convert_twoscomp_12(uint16_t data) {
|
||||
if ((data & 0x800) == 0x800)
|
||||
return -2048 + (data & 0x7FF);
|
||||
else
|
||||
return data;
|
||||
}
|
||||
|
||||
void paw3222_write(uint8_t reg_addr, uint8_t data) {
|
||||
spi_start(PAW3222_CS_PIN, false, 3, PAW3222_SPI_DIVISOR);
|
||||
wait_us(1); // Tncs_lead
|
||||
spi_write(reg_addr | MSB1);
|
||||
spi_write(data);
|
||||
wait_us(1); // Tncs_lag
|
||||
spi_stop();
|
||||
}
|
||||
|
||||
uint8_t paw3222_read(uint8_t reg_addr) {
|
||||
spi_start(PAW3222_CS_PIN, false, 3, PAW3222_SPI_DIVISOR);
|
||||
wait_us(1); // Tncs_lead
|
||||
spi_write(reg_addr & MSB0);
|
||||
wait_us(10); // Tprep_rd
|
||||
uint8_t data = spi_read();
|
||||
wait_us(1); // Tncs_lag
|
||||
spi_stop();
|
||||
|
||||
return data;
|
||||
}
|
||||
|
||||
bool paw3222_init(void) {
|
||||
gpio_set_pin_output(PAW3222_CS_PIN);
|
||||
|
||||
// CS must be kept low at power-up stage for at least 1ms
|
||||
gpio_write_pin_low(PAW3222_CS_PIN);
|
||||
wait_ms(10);
|
||||
gpio_write_pin_high(PAW3222_CS_PIN);
|
||||
|
||||
spi_init();
|
||||
|
||||
// reboot
|
||||
paw3222_write(0x06, 0x80);
|
||||
wait_ms(50);
|
||||
|
||||
if (!paw3222_check_signature()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// initialize
|
||||
paw3222_write(0x09, 0x5A);
|
||||
paw3222_write(0x0D, 0x23);
|
||||
paw3222_write(0x0E, 0x24);
|
||||
paw3222_write(0x19, 0x1C);
|
||||
paw3222_write(0x05, 0xA1);
|
||||
paw3222_write(0x2B, 0x6D);
|
||||
paw3222_write(0x30, 0x2E);
|
||||
paw3222_write(0x5C, 0xDF);
|
||||
paw3222_write(0x7F, 0x01);
|
||||
paw3222_write(0x06, 0x14);
|
||||
paw3222_write(0x31, 0x25);
|
||||
paw3222_write(0x34, 0xC4);
|
||||
paw3222_write(0x36, 0xCC);
|
||||
paw3222_write(0x37, 0x42);
|
||||
paw3222_write(0x38, 0x01);
|
||||
paw3222_write(0x3A, 0x76);
|
||||
paw3222_write(0x3B, 0x34);
|
||||
paw3222_write(0x42, 0x39);
|
||||
paw3222_write(0x43, 0xF2);
|
||||
paw3222_write(0x44, 0x39);
|
||||
paw3222_write(0x45, 0xF0);
|
||||
paw3222_write(0x46, 0x12);
|
||||
paw3222_write(0x47, 0x39);
|
||||
paw3222_write(0x48, 0xE3);
|
||||
paw3222_write(0x49, 0x48);
|
||||
paw3222_write(0x4A, 0xD3);
|
||||
paw3222_write(0x4B, 0x98);
|
||||
paw3222_write(0x64, 0x46);
|
||||
paw3222_write(0x71, 0x28);
|
||||
paw3222_write(0x72, 0x28);
|
||||
paw3222_write(0x7F, 0x00);
|
||||
paw3222_write(0x09, 0x00);
|
||||
|
||||
// read a burst, then discard
|
||||
paw3222_read_burst();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
report_paw3222_t paw3222_read_burst(void) {
|
||||
report_paw3222_t report = {0};
|
||||
|
||||
uint8_t motion = paw3222_read(0x02);
|
||||
if ((motion & MSB1) == MSB1) {
|
||||
// Motion detected
|
||||
uint16_t dx = (uint16_t)paw3222_read(0x03);
|
||||
uint16_t dy = (uint16_t)paw3222_read(0x04);
|
||||
uint16_t dxy_hi = (uint16_t)paw3222_read(0x12);
|
||||
|
||||
dx = dx | ((dxy_hi & 0xF0) << 4);
|
||||
dy = dy | ((dxy_hi & 0x0F) << 8);
|
||||
|
||||
report.dx = convert_twoscomp_12(dx);
|
||||
report.dy = convert_twoscomp_12(dy);
|
||||
}
|
||||
|
||||
return report;
|
||||
}
|
||||
|
||||
void paw3222_set_cpi(uint16_t cpi) {
|
||||
uint16_t cpival = (cpi) < (480) ? (480) : ((cpi) > (4020) ? (4020) : (cpi));
|
||||
uint8_t cpival_x = (cpival + (30 / 2)) / 30;
|
||||
uint8_t cpival_y = (cpival + (29 / 2)) / 29;
|
||||
|
||||
paw3222_write(0x09, 0x5A);
|
||||
paw3222_write(0x0D, cpival_x);
|
||||
paw3222_write(0x0E, cpival_y);
|
||||
paw3222_write(0x09, 0x00);
|
||||
}
|
||||
|
||||
uint16_t paw3222_get_cpi(void) {
|
||||
uint8_t cpival = paw3222_read(0x0D);
|
||||
return (uint16_t)(cpival * 30);
|
||||
}
|
||||
|
||||
report_mouse_t paw3222_get_report(report_mouse_t mouse_report) {
|
||||
report_paw3222_t data = paw3222_read_burst();
|
||||
|
||||
if (data.dx != 0 || data.dy != 0) {
|
||||
pd_dprintf("Raw ] X: %d, Y: %d\n", data.dx, data.dy);
|
||||
mouse_report.x = CONSTRAIN_HID_XY(data.dx);
|
||||
mouse_report.y = CONSTRAIN_HID_XY(data.dy);
|
||||
}
|
||||
|
||||
return mouse_report;
|
||||
}
|
||||
|
||||
bool paw3222_check_signature(void) {
|
||||
uint8_t checkval_1 = paw3222_read(0x00);
|
||||
uint8_t checkval_2 = paw3222_read(0x01);
|
||||
|
||||
return (checkval_1 == 0x30 && checkval_2 == 0x02);
|
||||
}
|
||||
47
drivers/sensors/paw3222.h
Normal file
47
drivers/sensors/paw3222.h
Normal file
@@ -0,0 +1,47 @@
|
||||
/* Copyright 2024 Colin Lam (Ploopy Corporation)
|
||||
*
|
||||
* 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 2 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
|
||||
|
||||
#include <stdbool.h>
|
||||
#include <stdint.h>
|
||||
#include "pointing_device.h"
|
||||
|
||||
#ifndef PAW3222_CS_PIN
|
||||
# ifdef POINTING_DEVICE_CS_PIN
|
||||
# define PAW3222_CS_PIN POINTING_DEVICE_CS_PIN
|
||||
# else
|
||||
# error "No chip select pin defined -- missing POINTING_DEVICE_CS_PIN or PAW3222_CS_PIN define"
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#ifndef PAW3222_SPI_DIVISOR
|
||||
# error "No PAW3222 SPI divisor defined -- missing PAW3222_SPI_DIVISOR"
|
||||
#endif
|
||||
|
||||
typedef struct {
|
||||
int16_t dx;
|
||||
int16_t dy;
|
||||
} report_paw3222_t;
|
||||
|
||||
extern const pointing_device_driver_t paw3222_pointing_device_driver;
|
||||
|
||||
bool paw3222_init(void);
|
||||
report_paw3222_t paw3222_read_burst(void);
|
||||
void paw3222_set_cpi(uint16_t cpi);
|
||||
uint16_t paw3222_get_cpi(void);
|
||||
report_mouse_t paw3222_get_report(report_mouse_t mouse_report);
|
||||
bool paw3222_check_signature(void);
|
||||
@@ -72,14 +72,12 @@ STATIC_ASSERT(sizeof((pmw33xx_report_t){0}.motion) == 1, "pmw33xx_report_t.motio
|
||||
# ifndef PMW33XX_CS_PIN
|
||||
# ifdef POINTING_DEVICE_CS_PIN
|
||||
# define PMW33XX_CS_PIN POINTING_DEVICE_CS_PIN
|
||||
# define PMW33XX_CS_PINS \
|
||||
{ PMW33XX_CS_PIN }
|
||||
# define PMW33XX_CS_PINS {PMW33XX_CS_PIN}
|
||||
# else
|
||||
# error "No chip select pin defined -- missing PMW33XX_CS_PIN or PMW33XX_CS_PINS"
|
||||
# endif
|
||||
# else
|
||||
# define PMW33XX_CS_PINS \
|
||||
{ PMW33XX_CS_PIN }
|
||||
# define PMW33XX_CS_PINS {PMW33XX_CS_PIN}
|
||||
# endif
|
||||
#endif
|
||||
|
||||
@@ -88,8 +86,7 @@ STATIC_ASSERT(sizeof((pmw33xx_report_t){0}.motion) == 1, "pmw33xx_report_t.motio
|
||||
# if !defined(PMW33XX_CS_PIN_RIGHT)
|
||||
# define PMW33XX_CS_PIN_RIGHT PMW33XX_CS_PIN
|
||||
# endif
|
||||
# define PMW33XX_CS_PINS_RIGHT \
|
||||
{ PMW33XX_CS_PIN_RIGHT }
|
||||
# define PMW33XX_CS_PINS_RIGHT {PMW33XX_CS_PIN_RIGHT}
|
||||
#endif
|
||||
|
||||
// Defines so the old variable names are swapped by the appropiate value on each half
|
||||
|
||||
@@ -1,27 +0,0 @@
|
||||
{
|
||||
"development_board": "promicro",
|
||||
"bootloader": "qmk-dfu",
|
||||
"matrix_pins": {
|
||||
"cols": ["F5", "F6", "F7", "F4", "B3", "B1", "B2"],
|
||||
"rows": ["D3", "D2", "D1", "D4", "D7", "E6", "B4", "C6"]
|
||||
},
|
||||
"diode_direction": "COL2ROW",
|
||||
"rgb_matrix": {
|
||||
"animations": {
|
||||
"band_sat": true,
|
||||
"band_spiral_val": true,
|
||||
"breathing": true,
|
||||
"cycle_all": true,
|
||||
"cycle_left_right": true,
|
||||
"raindrops": true
|
||||
}
|
||||
},
|
||||
"encoder": {
|
||||
"rotary": [
|
||||
{"pin_a": "B5", "pin_b": "B6"}
|
||||
]
|
||||
},
|
||||
"ws2812": {
|
||||
"pin": "D0"
|
||||
}
|
||||
}
|
||||
@@ -2,28 +2,58 @@
|
||||
"manufacturer": "Freya",
|
||||
"keyboard_name": "splaytoraid",
|
||||
"maintainer": "freya-irl",
|
||||
"url": "https://github.com/freya-irl/splaytoraid40",
|
||||
"usb": {
|
||||
"device_version": "1.0.0",
|
||||
"pid": "0xCB00",
|
||||
"vid": "0x2004"
|
||||
},
|
||||
"features": {
|
||||
"extrakey": true,
|
||||
"rgb_matrix": true,
|
||||
"bootmagic": true,
|
||||
"console": true,
|
||||
"mousekey": true,
|
||||
"nkro": true,
|
||||
"encoder": true
|
||||
},
|
||||
"bootloader": "qmk-dfu",
|
||||
"bootmagic": {
|
||||
"matrix": [1, 0]
|
||||
},
|
||||
"build": {
|
||||
"lto": true
|
||||
},
|
||||
"development_board": "promicro",
|
||||
"diode_direction": "COL2ROW",
|
||||
"encoder": {
|
||||
"rotary": [
|
||||
{"pin_a": "B5", "pin_b": "B6"}
|
||||
]
|
||||
},
|
||||
"features": {
|
||||
"bootmagic": true,
|
||||
"encoder": true,
|
||||
"extrakey": true,
|
||||
"mousekey": true,
|
||||
"nkro": true,
|
||||
"rgb_matrix": true
|
||||
},
|
||||
"matrix_pins": {
|
||||
"cols": ["F5", "F6", "F7", "F4", "B3", "B1", "B2"],
|
||||
"rows": ["D3", "D2", "D1", "D4", "D7", "E6", "B4", "C6"]
|
||||
},
|
||||
"rgb_matrix": {
|
||||
"animations": {
|
||||
"band_sat": true,
|
||||
"band_spiral_val": true,
|
||||
"breathing": true,
|
||||
"cycle_all": true,
|
||||
"cycle_left_right": true,
|
||||
"cycle_out_in": true,
|
||||
"cycle_out_in_dual": true,
|
||||
"cycle_pinwheel": true,
|
||||
"cycle_up_down": true,
|
||||
"digital_rain": true,
|
||||
"dual_beacon": true,
|
||||
"hue_breathing": true,
|
||||
"jellybean_raindrops": true,
|
||||
"multisplash": true,
|
||||
"pixel_fractal": true,
|
||||
"pixel_rain": true,
|
||||
"rainbow_moving_chevron": true,
|
||||
"raindrops": true,
|
||||
"solid_reactive": true,
|
||||
"solid_reactive_simple": true,
|
||||
"solid_splash": true,
|
||||
"splash": true,
|
||||
"typing_heatmap": true
|
||||
},
|
||||
"default": {
|
||||
"animation": "breathing",
|
||||
"hue": 152,
|
||||
@@ -32,27 +62,36 @@
|
||||
},
|
||||
"driver": "ws2812",
|
||||
"layout": [
|
||||
{"flags": 4, "matrix": [0, 2], "x": 0, "y": 0},
|
||||
{"flags": 4, "matrix": [1, 0], "x": 20, "y": 0},
|
||||
{"flags": 4, "matrix": [7, 0], "x": 61, "y": 0},
|
||||
{"flags": 4, "matrix": [7, 1], "x": 163, "y": 0},
|
||||
{"flags": 4, "matrix": [5, 0], "x": 203, "y": 0},
|
||||
{"flags": 4, "matrix": [4, 2], "x": 224, "y": 0},
|
||||
{"flags": 4, "matrix": [6, 2], "x": 0, "y": 21},
|
||||
{"flags": 4, "matrix": [6, 1], "x": 224, "y": 21},
|
||||
{"flags": 4, "matrix": [3, 3], "x": 20, "y": 43},
|
||||
{"flags": 4, "matrix": [7, 3], "x": 61, "y": 43},
|
||||
{"flags": 4, "matrix": [6, 4], "x": 163, "y": 43},
|
||||
{"flags": 4, "matrix": [6, 3], "x": 203, "y": 43},
|
||||
{"flags": 4, "matrix": [4, 3], "x": 61, "y": 64},
|
||||
{"flags": 4, "matrix": [5, 5], "x": 81, "y": 64},
|
||||
{"flags": 4, "matrix": [7, 4], "x": 101, "y": 64},
|
||||
{"flags": 4, "matrix": [7, 5], "x": 122, "y": 64},
|
||||
{"flags": 4, "matrix": [1, 5], "x": 142, "y": 64},
|
||||
{"flags": 4, "matrix": [0, 3], "x": 163, "y": 64}
|
||||
{"matrix": [0, 2], "x": 0, "y": 0, "flags": 4},
|
||||
{"matrix": [1, 0], "x": 20, "y": 0, "flags": 4},
|
||||
{"matrix": [7, 0], "x": 61, "y": 0, "flags": 4},
|
||||
{"matrix": [7, 1], "x": 163, "y": 0, "flags": 4},
|
||||
{"matrix": [5, 0], "x": 203, "y": 0, "flags": 4},
|
||||
{"matrix": [4, 2], "x": 224, "y": 0, "flags": 4},
|
||||
{"matrix": [6, 2], "x": 0, "y": 21, "flags": 4},
|
||||
{"matrix": [6, 1], "x": 224, "y": 21, "flags": 4},
|
||||
{"matrix": [3, 3], "x": 20, "y": 43, "flags": 4},
|
||||
{"matrix": [7, 3], "x": 61, "y": 43, "flags": 4},
|
||||
{"matrix": [6, 4], "x": 163, "y": 43, "flags": 4},
|
||||
{"matrix": [6, 3], "x": 203, "y": 43, "flags": 4},
|
||||
{"matrix": [4, 3], "x": 61, "y": 64, "flags": 4},
|
||||
{"matrix": [5, 5], "x": 81, "y": 64, "flags": 4},
|
||||
{"matrix": [7, 4], "x": 101, "y": 64, "flags": 4},
|
||||
{"matrix": [7, 5], "x": 122, "y": 64, "flags": 4},
|
||||
{"matrix": [1, 5], "x": 142, "y": 64, "flags": 4},
|
||||
{"matrix": [0, 3], "x": 163, "y": 64, "flags": 4}
|
||||
],
|
||||
"max_brightness": 200
|
||||
},
|
||||
"url": "https://github.com/freya-irl/splaytoraid40",
|
||||
"usb": {
|
||||
"device_version": "1.0.0",
|
||||
"pid": "0xCB00",
|
||||
"vid": "0x2004"
|
||||
},
|
||||
"ws2812": {
|
||||
"pin": "D0"
|
||||
},
|
||||
"layouts": {
|
||||
"LAYOUT_36": {
|
||||
"layout": [
|
||||
@@ -1,49 +0,0 @@
|
||||
// Copyright 2023 Conor Burns (@Conor-Burns)
|
||||
/* SPDX-License-Identifier: GPL-2.0-or-later */
|
||||
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
enum layer_names {
|
||||
_BASE,
|
||||
_LOWER,
|
||||
_RAISE,
|
||||
_ADJUST
|
||||
};
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
[_BASE] = LAYOUT_40(
|
||||
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC,
|
||||
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_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH,
|
||||
KC_LSFT, KC_ESC, KC_ENT, KC_MPLY, KC_SPC, KC_DEL, KC_RSFT
|
||||
),
|
||||
|
||||
[_LOWER] = LAYOUT_40(
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______
|
||||
),
|
||||
|
||||
[_RAISE] = LAYOUT_40(
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______
|
||||
),
|
||||
|
||||
[_ADJUST] = LAYOUT_40(
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______
|
||||
)
|
||||
};
|
||||
|
||||
|
||||
const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][NUM_DIRECTIONS] = {
|
||||
[_BASE] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) },
|
||||
[_LOWER] = { ENCODER_CCW_CW(KC_MPRV, KC_MNXT) },
|
||||
[_RAISE] = { ENCODER_CCW_CW(UG_VALD, UG_VALU) },
|
||||
[_ADJUST] = { ENCODER_CCW_CW(KC_RGHT, KC_LEFT) }
|
||||
};
|
||||
21
keyboards/0xcb/splaytoraid/keymaps/default/keymap.json
Normal file
21
keyboards/0xcb/splaytoraid/keymaps/default/keymap.json
Normal file
@@ -0,0 +1,21 @@
|
||||
{
|
||||
"keyboard": "0xcb/splaytoraid",
|
||||
"keymap": "default",
|
||||
"config": {
|
||||
"features": {
|
||||
"encoder_map": true
|
||||
}
|
||||
},
|
||||
"layout": "LAYOUT_40",
|
||||
"layers": [
|
||||
[
|
||||
"KC_TAB", "KC_Q", "KC_W", "KC_E", "KC_R", "KC_T", "KC_Y", "KC_U", "KC_I", "KC_O", "KC_P", "KC_BSPC",
|
||||
"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_Z", "KC_X", "KC_C", "KC_V", "KC_B", "KC_N", "KC_M", "KC_COMM", "KC_DOT", "KC_SLSH",
|
||||
"KC_LSFT", "KC_ESC", "KC_ENT", "KC_MPLY", "KC_SPC", "KC_DEL", "KC_RSFT"
|
||||
]
|
||||
],
|
||||
"encoders": [
|
||||
[{"ccw": "KC_VOLD", "cw": "KC_VOLU"}]
|
||||
]
|
||||
}
|
||||
@@ -11,13 +11,10 @@ A 40% ergonomic keyboard with a stacked acrylic case and RGB underglow.
|
||||
Make example for this keyboard (after setting up your build environment):
|
||||
|
||||
make 0xcb/splaytoraid:default
|
||||
make 0xcb/splaytoraid/32u4:default
|
||||
|
||||
Flashing example for this keyboard:
|
||||
|
||||
make 0xcb/splaytoraid:default:flash
|
||||
make 0xcb/splaytoraid/32u4:default:flash
|
||||
|
||||
|
||||
See the [build environment setup](https://docs.qmk.fm/#/getting_started_build_tools) and the [make instructions](https://docs.qmk.fm/#/getting_started_make_guide) for more information. Brand new to QMK? Start with our [Complete Newbs Guide](https://docs.qmk.fm/#/newbs).
|
||||
|
||||
@@ -29,8 +26,4 @@ Enter the bootloader in 3 ways:
|
||||
* **Physical reset button**: Press the button on the controller (Helios) for more than 500ms or just press it (Pluto)
|
||||
* **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is available
|
||||
|
||||
Please note that the default bootloader for the `32u4` version is QMK DFU, for compatibility with [0xCB Pluto](https://github.com/0xCB-dev/0xCB-Pluto). Generic Pro Micros often use a different bootloader, such as `caterina`.
|
||||
|
||||
If the incorrect bootloader is specified, bootmagic reset and the `QK_BOOT` keycode will not work.
|
||||
|
||||
To avoid this problem, set the correct bootloader in your custom keymap's `rules.mk` file before compiling, or flash using an appropriate target (ex: `make 0xcb/splaytoraid/32u4:default:avrdude`). See [flashing instructions and bootloader information](https://docs.qmk.fm/#/flashing) for more details.
|
||||
When using an AVR microcontroller with this keyboard, the bootloader is configured to be QMK DFU for compatibility with [0xCB Pluto](https://github.com/0xCB-dev/0xCB-Pluto). If your microcontroller does not use this bootloader, ensure to set this parameter appropriately in your keymap's `rules.mk` file.
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user