From 79210069562d58150fd2d04cf46429042b365199 Mon Sep 17 00:00:00 2001 From: Cem Aksoylar Date: Fri, 3 Jan 2025 21:40:05 -0800 Subject: [PATCH 1/4] feat(boards): Bring xiao_ble board to parity with seeeduino_xiao_ble --- app/boards/xiao_ble.conf | 15 ++++++++++++++ app/boards/xiao_ble.overlay | 39 +++++++++++++++++++++++++++++++++++++ 2 files changed, 54 insertions(+) create mode 100644 app/boards/xiao_ble.conf create mode 100644 app/boards/xiao_ble.overlay diff --git a/app/boards/xiao_ble.conf b/app/boards/xiao_ble.conf new file mode 100644 index 00000000000..5d6defebeee --- /dev/null +++ b/app/boards/xiao_ble.conf @@ -0,0 +1,15 @@ +CONFIG_CONSOLE=n +CONFIG_SERIAL=n +CONFIG_UART_CONSOLE=n +CONFIG_UART_INTERRUPT_DRIVEN=n +CONFIG_ZMK_USB=y +CONFIG_ZMK_BLE=y + +CONFIG_MPU_ALLOW_FLASH_WRITE=y +CONFIG_NVS=y +CONFIG_SETTINGS_NVS=y +CONFIG_FLASH=y +CONFIG_FLASH_PAGE_LAYOUT=y +CONFIG_FLASH_MAP=y + +CONFIG_HW_STACK_PROTECTION=n diff --git a/app/boards/xiao_ble.overlay b/app/boards/xiao_ble.overlay new file mode 100644 index 00000000000..da0c2f3622a --- /dev/null +++ b/app/boards/xiao_ble.overlay @@ -0,0 +1,39 @@ +/* + * Copyright (c) 2025 The ZMK Contributors + * + * SPDX-License-Identifier: MIT + */ + +/ { + chosen { + zephyr,console = &uart0; + zephyr,shell-uart = &uart0; + zephyr,uart-mcumgr = &uart0; + zephyr,bt-mon-uart = &uart0; + zephyr,bt-c2h-uart = &uart0; + + zmk,battery = &vbatt; + }; + + vbatt: vbatt { + compatible = "zmk,battery-voltage-divider"; + io-channels = <&adc 7>; + power-gpios = <&gpio0 14 (GPIO_OPEN_DRAIN | GPIO_ACTIVE_LOW)>; + output-ohms = <510000>; + full-ohms = <(1000000 + 510000)>; + }; +}; + +&xiao_serial { status = "disabled"; }; + +&xiao_i2c { status = "disabled"; }; + +&xiao_spi { status = "disabled"; }; + +&pwm0 { status = "disabled"; }; + +&{/pwmleds} { status = "disabled"; }; + +&ieee802154 { status = "disabled"; }; + +/delete-node/ &usb_cdc_acm_uart; From 13758ab9adf82aa01cc8030af95b7d37a9cf61e9 Mon Sep 17 00:00:00 2001 From: Cem Aksoylar Date: Fri, 3 Jan 2025 21:41:17 -0800 Subject: [PATCH 2/4] feat!(boards): Prefer xiao_ble over seeeduino_xiao_ble --- .../seeeduino_xiao_ble.zmk.yml => xiao_ble/xiao_ble.zmk.yml} | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) rename app/boards/arm/{seeeduino_xiao_ble/seeeduino_xiao_ble.zmk.yml => xiao_ble/xiao_ble.zmk.yml} (73%) diff --git a/app/boards/arm/seeeduino_xiao_ble/seeeduino_xiao_ble.zmk.yml b/app/boards/arm/xiao_ble/xiao_ble.zmk.yml similarity index 73% rename from app/boards/arm/seeeduino_xiao_ble/seeeduino_xiao_ble.zmk.yml rename to app/boards/arm/xiao_ble/xiao_ble.zmk.yml index 360bd04b314..7c960810ccc 100644 --- a/app/boards/arm/seeeduino_xiao_ble/seeeduino_xiao_ble.zmk.yml +++ b/app/boards/arm/xiao_ble/xiao_ble.zmk.yml @@ -1,6 +1,6 @@ file_format: "1" -id: seeeduino_xiao_ble -name: Seeeduino XIAO BLE +id: xiao_ble +name: Seeed XIAO BLE type: board arch: arm outputs: From 1745bc57215bea07e8d8858bbb383198da2b17fb Mon Sep 17 00:00:00 2001 From: Cem Aksoylar Date: Fri, 3 Jan 2025 22:22:26 -0800 Subject: [PATCH 3/4] ci: Switch to xiao_ble in core coverage --- app/core-coverage.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/core-coverage.yml b/app/core-coverage.yml index bc36495a758..6e8c1a3f61a 100644 --- a/app/core-coverage.yml +++ b/app/core-coverage.yml @@ -11,7 +11,7 @@ shield: include: - board: bdn9_rev2 - board: nice60 - - board: seeeduino_xiao_ble + - board: xiao_ble shield: hummingbird - board: nrf52840_m2 shield: m60 From d0b1a17d2db9911e39a7c6e5dee4a69a6ec257bf Mon Sep 17 00:00:00 2001 From: Cem Aksoylar Date: Fri, 3 Jan 2025 22:23:00 -0800 Subject: [PATCH 4/4] docs: Update docs examples for xiao_ble --- docs/docs/troubleshooting/hardware-issues.mdx | 6 +++--- docs/docs/user-setup.mdx | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/docs/troubleshooting/hardware-issues.mdx b/docs/docs/troubleshooting/hardware-issues.mdx index afb9fff1f80..4913be0aff5 100644 --- a/docs/docs/troubleshooting/hardware-issues.mdx +++ b/docs/docs/troubleshooting/hardware-issues.mdx @@ -87,15 +87,15 @@ include: # ------------------- # Your keyboards here # ------------------- - - board: seeeduino_xiao_ble # Replace with the Xiao-compatible board you're using + - board: xiao_ble # Replace with the Xiao-compatible board you're using shield: tester_xiao ``` Save the file, commit the changes and push them to GitHub. Download the new firmware zip file build by the latest GitHub Actions job. In it you will find an additional `tester_xiao` UF2 image file. Flash this file to your board. -The pinout of the seeeduino xiao interconnect is shown below: +The pinout of the Seeed Xiao interconnect is shown below: -![Seeeduino Xiao Interconnect pinout](../assets/interconnects/seeed_xiao/pinout.png) +![Seeed Xiao Interconnect pinout](../assets/interconnects/seeed_xiao/pinout.png) diff --git a/docs/docs/user-setup.mdx b/docs/docs/user-setup.mdx index 9f0dd1ce773..b6e1a8e0c65 100644 --- a/docs/docs/user-setup.mdx +++ b/docs/docs/user-setup.mdx @@ -124,7 +124,7 @@ When prompted, enter the number for the corresponding MCU board you would like t MCU Board Selection: 1) BlueMicro840 v1 5) nRF52840 M.2 Module 9) QMK Proton-C 2) Mikoto 5.20 6) nRFMicro 1.1 (flipped) 10) Seeeduino XIAO -3) nice!nano v1 7) nRFMicro 1.1/1.2 11) Seeeduino XIAO BLE +3) nice!nano v1 7) nRFMicro 1.1/1.2 11) Seeed XIAO BLE 4) nice!nano v2 8) nRFMicro 1.3/1.4 12) Quit Pick an MCU board: ```