From 328ec5ebbccf444b03e1290d4fd5bf1fdf518410 Mon Sep 17 00:00:00 2001 From: Darren Victoriano Date: Mon, 3 Feb 2025 22:54:37 -0800 Subject: [PATCH] testing --- boards/nice_nano.overlay | 46 --------- boards/nice_nano_v2.overlay | 46 --------- boards/shields/corne/Kconfig.defconfig | 2 +- boards/shields/corne/Kconfig.shield | 2 - boards/shields/corne/corne.conf | 6 -- boards/shields/corne/corne.dtsi | 94 ------------------- boards/shields/corne/corne.keymap | 42 --------- boards/shields/corne/corne.zmk.yml | 16 ---- boards/shields/corne/corne_dongle.overlay | 22 +++++ boards/shields/corne/corne_left.conf | 3 - boards/shields/corne/corne_left.overlay | 18 ---- .../shields/corne/corne_peripheral_left.conf | 26 ----- .../corne/corne_peripheral_left.overlay | 18 ---- boards/shields/corne/corne_right.overlay | 26 ----- build.yaml | 17 ++-- 15 files changed, 33 insertions(+), 351 deletions(-) delete mode 100644 boards/nice_nano.overlay delete mode 100644 boards/nice_nano_v2.overlay delete mode 100644 boards/shields/corne/corne.conf delete mode 100644 boards/shields/corne/corne.dtsi delete mode 100644 boards/shields/corne/corne.keymap delete mode 100644 boards/shields/corne/corne.zmk.yml delete mode 100644 boards/shields/corne/corne_left.overlay delete mode 100644 boards/shields/corne/corne_peripheral_left.conf delete mode 100644 boards/shields/corne/corne_peripheral_left.overlay delete mode 100644 boards/shields/corne/corne_right.overlay diff --git a/boards/nice_nano.overlay b/boards/nice_nano.overlay deleted file mode 100644 index 424a617..0000000 --- a/boards/nice_nano.overlay +++ /dev/null @@ -1,46 +0,0 @@ -#include - -&pinctrl { - spi3_default: spi3_default { - group1 { - psels = ; - }; - }; - - spi3_sleep: spi3_sleep { - group1 { - psels = ; - low-power-enable; - }; - }; -}; - -&spi3 { - compatible = "nordic,nrf-spim"; - status = "okay"; - - pinctrl-0 = <&spi3_default>; - pinctrl-1 = <&spi3_sleep>; - pinctrl-names = "default", "sleep"; - - led_strip: ws2812@0 { - compatible = "worldsemi,ws2812-spi"; - - /* SPI */ - reg = <0>; /* ignored, but necessary for SPI bindings */ - spi-max-frequency = <4000000>; - - /* WS2812 */ - chain-length = <10>; /* arbitrary; change at will */ - spi-one-frame = <0x70>; - spi-zero-frame = <0x40>; - - color-mapping = ; - }; -}; - -/ { - chosen { - zmk,underglow = &led_strip; - }; -}; diff --git a/boards/nice_nano_v2.overlay b/boards/nice_nano_v2.overlay deleted file mode 100644 index 424a617..0000000 --- a/boards/nice_nano_v2.overlay +++ /dev/null @@ -1,46 +0,0 @@ -#include - -&pinctrl { - spi3_default: spi3_default { - group1 { - psels = ; - }; - }; - - spi3_sleep: spi3_sleep { - group1 { - psels = ; - low-power-enable; - }; - }; -}; - -&spi3 { - compatible = "nordic,nrf-spim"; - status = "okay"; - - pinctrl-0 = <&spi3_default>; - pinctrl-1 = <&spi3_sleep>; - pinctrl-names = "default", "sleep"; - - led_strip: ws2812@0 { - compatible = "worldsemi,ws2812-spi"; - - /* SPI */ - reg = <0>; /* ignored, but necessary for SPI bindings */ - spi-max-frequency = <4000000>; - - /* WS2812 */ - chain-length = <10>; /* arbitrary; change at will */ - spi-one-frame = <0x70>; - spi-zero-frame = <0x40>; - - color-mapping = ; - }; -}; - -/ { - chosen { - zmk,underglow = &led_strip; - }; -}; diff --git a/boards/shields/corne/Kconfig.defconfig b/boards/shields/corne/Kconfig.defconfig index dc69844..4eb1fc8 100644 --- a/boards/shields/corne/Kconfig.defconfig +++ b/boards/shields/corne/Kconfig.defconfig @@ -22,7 +22,7 @@ config BT_MAX_PAIRED endif -if SHIELD_CORNE_LEFT || SHIELD_CORNE_RIGHT || SHIELD_CORNE_DONGLE || SHIELD_CORNE_PERIPHERAL_LEFT +if SHIELD_CORNE_LEFT || SHIELD_CORNE_RIGHT || SHIELD_CORNE_DONGLE config ZMK_SPLIT default y diff --git a/boards/shields/corne/Kconfig.shield b/boards/shields/corne/Kconfig.shield index dbcb528..e3a38ce 100644 --- a/boards/shields/corne/Kconfig.shield +++ b/boards/shields/corne/Kconfig.shield @@ -10,5 +10,3 @@ config SHIELD_CORNE_RIGHT config SHIELD_CORNE_DONGLE def_bool $(shields_list_contains,corne_dongle) -config SHIELD_CORNE_PERIPHERAL_LEFT - def_bool $(shields_list_contains,corne_peripheral_left) diff --git a/boards/shields/corne/corne.conf b/boards/shields/corne/corne.conf deleted file mode 100644 index 974243c..0000000 --- a/boards/shields/corne/corne.conf +++ /dev/null @@ -1,6 +0,0 @@ -# Uncomment the following lines to enable the Corne RGB Underglow -# CONFIG_ZMK_RGB_UNDERGLOW=y -# CONFIG_WS2812_STRIP=y - -# Uncomment the following line to enable the Corne OLED Display -# CONFIG_ZMK_DISPLAY=y diff --git a/boards/shields/corne/corne.dtsi b/boards/shields/corne/corne.dtsi deleted file mode 100644 index e1dcc05..0000000 --- a/boards/shields/corne/corne.dtsi +++ /dev/null @@ -1,94 +0,0 @@ -/* - * Copyright (c) 2020 Pete Johanson - * - * SPDX-License-Identifier: MIT - */ - -#include - -#include -#include - -&foostan_corne_6col_layout { - transform = <&default_transform>; -}; - -&foostan_corne_5col_layout { - transform = <&five_column_transform>; -}; - -/ { - chosen { - zephyr,display = &oled; - zmk,kscan = &kscan0; - zmk,physical-layout = &foostan_corne_6col_layout; - }; - - default_transform: keymap_transform_0 { - compatible = "zmk,matrix-transform"; - columns = <12>; - rows = <4>; -// | SW1 | SW2 | SW3 | SW4 | SW5 | SW6 | | SW6 | SW5 | SW4 | SW3 | SW2 | SW1 | -// | SW7 | SW8 | SW9 | SW10 | SW11 | SW12 | | SW12 | SW11 | SW10 | SW9 | SW8 | SW7 | -// | SW13 | SW14 | SW15 | SW16 | SW17 | SW18 | | SW18 | SW17 | SW16 | SW15 | SW14 | SW13 | -// | SW19 | SW20 | SW21 | | SW21 | SW20 | SW19 | - map = < -RC(0,0) RC(0,1) RC(0,2) RC(0,3) RC(0,4) RC(0,5) RC(0,6) RC(0,7) RC(0,8) RC(0,9) RC(0,10) RC(0,11) -RC(1,0) RC(1,1) RC(1,2) RC(1,3) RC(1,4) RC(1,5) RC(1,6) RC(1,7) RC(1,8) RC(1,9) RC(1,10) RC(1,11) -RC(2,0) RC(2,1) RC(2,2) RC(2,3) RC(2,4) RC(2,5) RC(2,6) RC(2,7) RC(2,8) RC(2,9) RC(2,10) RC(2,11) - RC(3,3) RC(3,4) RC(3,5) RC(3,6) RC(3,7) RC(3,8) - >; - }; - - five_column_transform: keymap_transform_1 { - compatible = "zmk,matrix-transform"; - columns = <10>; - rows = <4>; -// | SW2 | SW3 | SW4 | SW5 | SW6 | | SW6 | SW5 | SW4 | SW3 | SW2 | -// | SW8 | SW9 | SW10 | SW11 | SW12 | | SW12 | SW11 | SW10 | SW9 | SW8 | -// | SW14 | SW15 | SW16 | SW17 | SW18 | | SW18 | SW17 | SW16 | SW15 | SW14 | -// | SW19 | SW20 | SW21 | | SW21 | SW20 | SW19 | - map = < -RC(0,1) RC(0,2) RC(0,3) RC(0,4) RC(0,5) RC(0,6) RC(0,7) RC(0,8) RC(0,9) RC(0,10) -RC(1,1) RC(1,2) RC(1,3) RC(1,4) RC(1,5) RC(1,6) RC(1,7) RC(1,8) RC(1,9) RC(1,10) -RC(2,1) RC(2,2) RC(2,3) RC(2,4) RC(2,5) RC(2,6) RC(2,7) RC(2,8) RC(2,9) RC(2,10) - RC(3,3) RC(3,4) RC(3,5) RC(3,6) RC(3,7) RC(3,8) - >; - }; - - kscan0: kscan { - compatible = "zmk,kscan-gpio-matrix"; - wakeup-source; - - diode-direction = "col2row"; - row-gpios - = <&pro_micro 4 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)> - , <&pro_micro 5 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)> - , <&pro_micro 6 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)> - , <&pro_micro 7 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)> - ; - - }; - - // TODO: per-key RGB node(s)? -}; - -&pro_micro_i2c { - status = "okay"; - - oled: ssd1306@3c { - compatible = "solomon,ssd1306fb"; - reg = <0x3c>; - width = <128>; - height = <32>; - segment-offset = <0>; - page-offset = <0>; - display-offset = <0>; - multiplex-ratio = <31>; - segment-remap; - com-invdir; - com-sequential; - inversion-on; - prechargep = <0x22>; - }; -}; diff --git a/boards/shields/corne/corne.keymap b/boards/shields/corne/corne.keymap deleted file mode 100644 index 1bc054b..0000000 --- a/boards/shields/corne/corne.keymap +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Copyright (c) 2020 The ZMK Contributors - * - * SPDX-License-Identifier: MIT - */ - -#include -#include -#include - -/ { - keymap { - compatible = "zmk,keymap"; - - default_layer { - bindings = < -&kp TAB &kp Q &kp W &kp E &kp R &kp T &kp Y &kp U &kp I &kp O &kp P &kp BSPC -&kp LCTRL &kp A &kp S &kp D &kp F &kp G &kp H &kp J &kp K &kp L &kp SEMI &kp ENTER -&kp LSHFT &kp Z &kp X &kp C &kp V &kp B &kp N &kp M &kp COMMA &kp DOT &kp FSLH &kp ESC - &kp LGUI &mo 1 &kp SPACE &kp SPACE &mo 2 &kp RALT - >; - }; - - lower_layer { - bindings = < -&kp LS(TAB) &kp N1 &kp N2 &kp N3 &kp N4 &kp N5 &kp N6 &kp N7 &kp N8 &kp N9 &kp N0 &kp BSPC -&kp LCTRL &none &none &none &none &none &kp LEFT_ARROW &kp DOWN_ARROW &kp UP_ARROW &kp RIGHT_ARROW &none &kp ENTER -&kp LSHFT &bt BT_SEL 0 &bt BT_SEL 1 &bt BT_SEL 2 &bt BT_SEL 3 &bt BT_SEL 4 &bt BT_CLR &none &none &none &none &kp ESC - &kp LGUI &mo 1 &kp SPACE &kp SPACE &mo 2 &kp RALT - >; - }; - - raise_layer { - bindings = < -&kp LC(TAB) &kp EXCL &kp AT &kp POUND &kp DOLLAR &kp PERCENT &kp CARET &kp AMPERSAND &kp STAR &kp PLUS &kp EQUAL &kp BSPC -&kp LCTRL &kp GRAVE &kp TILDE &kp LEFT_BRACE &kp LEFT_BRACKET &kp LEFT_PARENTHESIS &kp RIGHT_PARENTHESIS &kp RIGHT_BRACKET &kp RIGHT_BRACE &kp BACKSLASH &kp PIPE &kp ENTER -&kp LSHFT &none &none &none &kp SQT &kp MINUS &kp UNDER &kp DOUBLE_QUOTES &none &none &none &kp RIGHT_SHIFT - &kp LGUI &mo 1 &kp SPACE &kp SPACE &mo 2 &kp RALT - >; - }; - }; -}; diff --git a/boards/shields/corne/corne.zmk.yml b/boards/shields/corne/corne.zmk.yml deleted file mode 100644 index 5e78dbc..0000000 --- a/boards/shields/corne/corne.zmk.yml +++ /dev/null @@ -1,16 +0,0 @@ -file_format: "1" -id: corne -name: Corne -type: shield -url: https://github.com/foostan/crkbd/ -requires: [pro_micro] -exposes: [i2c_oled] -features: - - keys - - display - - underglow -siblings: - - corne_left - - corne_right - - corne_dongle - - corne_peripheral_left diff --git a/boards/shields/corne/corne_dongle.overlay b/boards/shields/corne/corne_dongle.overlay index 10bc4dd..5d68c0c 100644 --- a/boards/shields/corne/corne_dongle.overlay +++ b/boards/shields/corne/corne_dongle.overlay @@ -5,12 +5,17 @@ */ #include +#include #include &foostan_corne_6col_layout { transform = <&default_transform>; }; +&foostan_corne_5col_layout { + transform = <&five_column_transform>; +}; + / { chosen { zmk,kscan = &mock_kscan; @@ -40,4 +45,21 @@ RC(2,0) RC(2,1) RC(2,2) RC(2,3) RC(2,4) RC(2,5) RC(2,6) RC(2,7) RC(2,8) RC(2,9) RC(3,3) RC(3,4) RC(3,5) RC(3,6) RC(3,7) RC(3,8) >; }; + + five_column_transform: keymap_transform_1 { + compatible = "zmk,matrix-transform"; + columns = <10>; + rows = <4>; +// | SW2 | SW3 | SW4 | SW5 | SW6 | | SW6 | SW5 | SW4 | SW3 | SW2 | +// | SW8 | SW9 | SW10 | SW11 | SW12 | | SW12 | SW11 | SW10 | SW9 | SW8 | +// | SW14 | SW15 | SW16 | SW17 | SW18 | | SW18 | SW17 | SW16 | SW15 | SW14 | +// | SW19 | SW20 | SW21 | | SW21 | SW20 | SW19 | + map = < +RC(0,1) RC(0,2) RC(0,3) RC(0,4) RC(0,5) RC(0,6) RC(0,7) RC(0,8) RC(0,9) RC(0,10) +RC(1,1) RC(1,2) RC(1,3) RC(1,4) RC(1,5) RC(1,6) RC(1,7) RC(1,8) RC(1,9) RC(1,10) +RC(2,1) RC(2,2) RC(2,3) RC(2,4) RC(2,5) RC(2,6) RC(2,7) RC(2,8) RC(2,9) RC(2,10) + RC(3,3) RC(3,4) RC(3,5) RC(3,6) RC(3,7) RC(3,8) + >; + }; + }; diff --git a/boards/shields/corne/corne_left.conf b/boards/shields/corne/corne_left.conf index 5f46928..fc91a52 100644 --- a/boards/shields/corne/corne_left.conf +++ b/boards/shields/corne/corne_left.conf @@ -1,6 +1,3 @@ -# Board Name -CONFIG_ZMK_KEYBOARD_NAME="Corne-Bop" - # Enable and adjust nice!view CONFIG_ZMK_DISPLAY=y CONFIG_ZMK_WIDGET_BATTERY_STATUS_SHOW_PERCENTAGE=y diff --git a/boards/shields/corne/corne_left.overlay b/boards/shields/corne/corne_left.overlay deleted file mode 100644 index 117cb19..0000000 --- a/boards/shields/corne/corne_left.overlay +++ /dev/null @@ -1,18 +0,0 @@ -/* - * Copyright (c) 2020 Pete Johanson - * - * SPDX-License-Identifier: MIT - */ - -#include "corne.dtsi" - -&kscan0 { - col-gpios - = <&pro_micro 21 GPIO_ACTIVE_HIGH> - , <&pro_micro 20 GPIO_ACTIVE_HIGH> - , <&pro_micro 19 GPIO_ACTIVE_HIGH> - , <&pro_micro 18 GPIO_ACTIVE_HIGH> - , <&pro_micro 15 GPIO_ACTIVE_HIGH> - , <&pro_micro 14 GPIO_ACTIVE_HIGH> - ; -}; diff --git a/boards/shields/corne/corne_peripheral_left.conf b/boards/shields/corne/corne_peripheral_left.conf deleted file mode 100644 index fc91a52..0000000 --- a/boards/shields/corne/corne_peripheral_left.conf +++ /dev/null @@ -1,26 +0,0 @@ -# Enable and adjust nice!view -CONFIG_ZMK_DISPLAY=y -CONFIG_ZMK_WIDGET_BATTERY_STATUS_SHOW_PERCENTAGE=y -CONFIG_ZMK_WIDGET_WPM_STATUS=n - -# Disable in-built nice!view widget -CONFIG_ZMK_DISPLAY_STATUS_SCREEN_BUILT_IN=y -CONFIG_ZMK_LV_FONT_DEFAULT_SMALL_MONTSERRAT_26=y -CONFIG_LV_FONT_DEFAULT_MONTSERRAT_26=y - -# Increase the bluetooth transmission power -CONFIG_BT_CTLR_TX_PWR_PLUS_8=y -CONFIG_ZMK_BLE_EXPERIMENTAL_FEATURES=y - -# Set sleep timeout to 30 minutes -CONFIG_ZMK_SLEEP=y -CONFIG_ZMK_IDLE_SLEEP_TIMEOUT=1800000 - -# Enable eager debouncing -CONFIG_ZMK_KSCAN_DEBOUNCE_PRESS_MS=1 -CONFIG_ZMK_KSCAN_DEBOUNCE_RELEASE_MS=10 - -# Enable ZMK Studio for Realtime Keymap Updates -# CONFIG_ZMK_STUDIO=y -# CONFIG_ZMK_STUDIO_LOCKING=n - diff --git a/boards/shields/corne/corne_peripheral_left.overlay b/boards/shields/corne/corne_peripheral_left.overlay deleted file mode 100644 index 117cb19..0000000 --- a/boards/shields/corne/corne_peripheral_left.overlay +++ /dev/null @@ -1,18 +0,0 @@ -/* - * Copyright (c) 2020 Pete Johanson - * - * SPDX-License-Identifier: MIT - */ - -#include "corne.dtsi" - -&kscan0 { - col-gpios - = <&pro_micro 21 GPIO_ACTIVE_HIGH> - , <&pro_micro 20 GPIO_ACTIVE_HIGH> - , <&pro_micro 19 GPIO_ACTIVE_HIGH> - , <&pro_micro 18 GPIO_ACTIVE_HIGH> - , <&pro_micro 15 GPIO_ACTIVE_HIGH> - , <&pro_micro 14 GPIO_ACTIVE_HIGH> - ; -}; diff --git a/boards/shields/corne/corne_right.overlay b/boards/shields/corne/corne_right.overlay deleted file mode 100644 index a8a0cfe..0000000 --- a/boards/shields/corne/corne_right.overlay +++ /dev/null @@ -1,26 +0,0 @@ -/* - * Copyright (c) 2020 Pete Johanson - * - * SPDX-License-Identifier: MIT - */ - -#include "corne.dtsi" - -&default_transform { - col-offset = <6>; -}; - -&five_column_transform { - col-offset = <6>; -}; - -&kscan0 { - col-gpios - = <&pro_micro 14 GPIO_ACTIVE_HIGH> - , <&pro_micro 15 GPIO_ACTIVE_HIGH> - , <&pro_micro 18 GPIO_ACTIVE_HIGH> - , <&pro_micro 19 GPIO_ACTIVE_HIGH> - , <&pro_micro 20 GPIO_ACTIVE_HIGH> - , <&pro_micro 21 GPIO_ACTIVE_HIGH> - ; -}; diff --git a/build.yaml b/build.yaml index 637e086..18ab2af 100644 --- a/build.yaml +++ b/build.yaml @@ -22,22 +22,25 @@ include: # Add custom dongle and a peripheral left corne - board: seeeduino_xiao_ble shield: corne_dongle + snippet: studio-rpc-usb-uart + cmake-args: -DCONFIG_ZMK_SPLIT_ROLE_CENTRAL=y -DCONFIG_ZMK_STUDIO=y -DCONFIG_ZMK_STUDIO_LOCKING=n artifact-name: xiao_dongle - - board: nice_nano_v2 - shield: corne_peripheral_left nice_view_adapter nice_view - artifact-name: corne_left_slave - # - board: nice_nano_v2 - # shield: corne_left nice_view_adapter nice_view - # artifact-name: corne_left_master + - board: nice_nano_v2 + shield: corne_left nice_view_adapter nice_view + cmake-args: -DCONFIG_ZMK_SPLIT_ROLE_CENTRAL=n + artifact-name: nano_corne_left + - board: nice_nano_v2 shield: corne_right nice_view_adapter nice_view - artifact-name: corne_right_slave + cmake-args: -DCONFIG_ZMK_SPLIT_ROLE_CENTRAL=n + artifact-name: nano_corne_right # reset_settings - board: nice_nano_v2 shield: settings_reset artifact-name: nano_reset_settings + - board: seeeduino_xiao_ble shield: settings_reset artifact-name: xiao_reset_settings