Skip to content

Commit 3e89c0d

Browse files
feat: xiao dongle rgb, corne rgb fix: multiple xiao+promicro encoder def ref: CHANGELOG.txt for more...
1 parent 51779bb commit 3e89c0d

17 files changed

+238
-44
lines changed

CHANGELOG.txt

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,19 @@
11
Changelog file for Structures extra.
22
https://github.com/mctechnology17/zmk-config/blob/main/CHANGELOG.txt
33

4+
# FEATURES 0.0.2-beta4 (Feb 27, 2025)
5+
=======================================
6+
+ NEW FEATURES
7+
- [x] build.yaml updated
8+
- [x] Add build for rgb + oled display
9+
- [x] seeeduino_xiao_ble.overlay rgb added
10+
- [x] Add build for rgb + oled display + dongle
11+
- [x] corne.overlay rgb led definition, layer reserved added
12+
- [x] snippet: rgb-config common-config dongle-config for multiple settings
13+
- [x] Add right- left_encoder definition sofle_dongle_pro_micro.overlay sofle_dongle_xiao.overlay
14+
- [x] Add right- left_encoder definition splitkb_aurora_sofle_dongle_pro_micro.overlay splitkb_aurora_sofle_dongle_xiao.overlay
15+
- [x] Add left_encoder definition lily58_dongle_pro_micro.overlay lily58_dongle_xiao.overlay
16+
417
# FEATURES 0.0.2-beta3 (Jan 06, 2025)
518
=======================================
619
+ NEW FEATURES
@@ -52,6 +65,4 @@ https://github.com/mctechnology17/zmk-config/blob/main/CHANGELOG.txt
5265
- [ ] Add set up the workspace https://github.com/urob/zmk-config?tab=readme-ov-file#set-up-the-workspace
5366
- [ ] Add a wiki to the repository
5467
- [ ] Add a video tutorial to the repository
55-
- [ ] Add EXTRA_CONF_FILE for each device
56-
- [ ] Add build for rgb + oled display
57-
- [ ] Add build for rgb + oled display + dongle
68+
- [ ] README.md updated + fotos as reference

boards/seeeduino_xiao_ble.overlay

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
/*
2+
ref: For future reference, this pinout shows both pin numberings https://files.seeedstudio.com/wiki/XIAO-BLE/pinout2.png
3+
The &gpioX Y and NRF_PSEL(..., X, Y) uses the PX.Y notation (underlying nRF pin numbers), &xiao_d x uses the unified pinout Dx
4+
*/
5+
#include <dt-bindings/led/led.h>
6+
7+
&pinctrl {
8+
spi0_default: spi0_default {
9+
group1 {
10+
psels = <NRF_PSEL(SPIM_MOSI, 0, 29)>;
11+
};
12+
};
13+
14+
spi0_sleep: spi0_sleep {
15+
group1 {
16+
psels = <NRF_PSEL(SPIM_MOSI, 0, 29)>;
17+
low-power-enable;
18+
};
19+
};
20+
};
21+
22+
&spi3 {
23+
compatible = "nordic,nrf-spim";
24+
status = "okay";
25+
26+
pinctrl-0 = <&spi0_default>;
27+
pinctrl-1 = <&spi0_sleep>;
28+
pinctrl-names = "default", "sleep";
29+
30+
led_strip: ws2812@0 {
31+
compatible = "worldsemi,ws2812-spi";
32+
// label = "WS2812";
33+
34+
/* SPI */
35+
reg = <0>; /* ignored, but necessary for SPI bindings */
36+
spi-max-frequency = <4000000>;
37+
38+
/* WS2812 */
39+
chain-length = <27>; /* arbitrary; change at will */
40+
spi-one-frame = <0x70>;
41+
spi-zero-frame = <0x40>;
42+
43+
color-mapping = <LED_COLOR_ID_GREEN LED_COLOR_ID_RED LED_COLOR_ID_BLUE>;
44+
};
45+
};
46+
47+
/ {
48+
chosen {
49+
zmk,underglow = &led_strip;
50+
};
51+
};
52+
// vim: filetype=dts fdm=marker:

boards/shields/lily58/lily58_dongle_pro_micro.overlay

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,19 @@ RC(3,0) RC(3,1) RC(3,2) RC(3,3) RC(3,4) RC(3,5) RC(4,5) RC(4,6) RC(3,6) RC(3,7)
4040
rows = <0>;
4141
events = <0>;
4242
};
43-
// TODO: per-key RGB node(s)?
43+
44+
left_encoder: encoder_left {
45+
compatible = "alps,ec11";
46+
a-gpios = <&pro_micro 21 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
47+
b-gpios = <&pro_micro 20 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
48+
steps = <80>;
49+
};
50+
51+
sensors: sensors {
52+
compatible = "zmk,keymap-sensors";
53+
sensors = <&left_encoder>;
54+
triggers-per-rotation = <20>;
55+
};
4456
};
4557

4658
&kata0510_lily58_layout {

boards/shields/lily58/lily58_dongle_xiao.overlay

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,19 @@ RC(3,0) RC(3,1) RC(3,2) RC(3,3) RC(3,4) RC(3,5) RC(4,5) RC(4,6) RC(3,6) RC(3,7)
4040
rows = <0>;
4141
events = <0>;
4242
};
43-
// TODO: per-key RGB node(s)?
43+
44+
left_encoder: encoder_left {
45+
compatible = "alps,ec11";
46+
a-gpios = <&xiao_d 5 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
47+
b-gpios = <&xiao_d 4 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
48+
steps = <80>;
49+
};
50+
51+
sensors {
52+
compatible = "zmk,keymap-sensors";
53+
sensors = <&left_encoder>;
54+
triggers-per-rotation = <20>;
55+
};
4456
};
4557

4658
&kata0510_lily58_layout {

boards/shields/sofle/sofle_dongle_pro_micro.overlay

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ RC(3,0) RC(3,1) RC(3,2) RC(3,3) RC(3,4) RC(3,5) RC(4,5) RC(4,6) RC(3,6) RC(3,7)
5050
, <&pro_micro 9 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
5151
;
5252
};
53+
*/
5354

5455
left_encoder: encoder_left {
5556
compatible = "alps,ec11";
@@ -72,7 +73,6 @@ RC(3,0) RC(3,1) RC(3,2) RC(3,3) RC(3,4) RC(3,5) RC(4,5) RC(4,6) RC(3,6) RC(3,7)
7273
sensors = <&left_encoder &right_encoder>;
7374
triggers-per-rotation = <20>;
7475
};
75-
*/
7676

7777
mock_kscan: kscan_0 {
7878
compatible = "zmk,kscan-mock";
@@ -81,7 +81,6 @@ RC(3,0) RC(3,1) RC(3,2) RC(3,3) RC(3,4) RC(3,5) RC(4,5) RC(4,6) RC(3,6) RC(3,7)
8181
rows = <0>;
8282
events = <0>;
8383
};
84-
// TODO: per-key RGB node(s)?
8584
};
8685

8786
&pro_micro_i2c {

boards/shields/sofle/sofle_dongle_xiao.overlay

Lines changed: 29 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -36,52 +36,46 @@ RC(3,0) RC(3,1) RC(3,2) RC(3,3) RC(3,4) RC(3,5) RC(4,5) RC(4,6) RC(3,6) RC(3,7)
3636
>;
3737
};
3838

39+
mock_kscan: kscan_0 {
40+
compatible = "zmk,kscan-mock";
41+
// wakeup-source;
42+
columns = <0>;
43+
rows = <0>;
44+
events = <0>;
45+
};
46+
3947
/*
40-
kscan0: kscan {
41-
compatible = "zmk,kscan-gpio-matrix";
42-
wakeup-source;
43-
44-
diode-direction = "col2row";
45-
row-gpios
46-
= <&pro_micro 5 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
47-
, <&pro_micro 6 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
48-
, <&pro_micro 7 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
49-
, <&pro_micro 8 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
50-
, <&pro_micro 9 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
51-
;
48+
row-gpios
49+
= <&xiao_d 0 GPIO_ACTIVE_HIGH>
50+
, <&xiao_d 1 GPIO_ACTIVE_HIGH>
51+
, <&xiao_d 2 GPIO_ACTIVE_HIGH>
52+
, <&xiao_d 3 GPIO_ACTIVE_HIGH>
53+
;
5254
};
55+
*/
5356

5457
left_encoder: encoder_left {
55-
compatible = "alps,ec11";
56-
a-gpios = <&pro_micro 21 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
57-
b-gpios = <&pro_micro 20 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
58-
steps = <80>;
59-
status = "disabled";
58+
compatible = "alps,ec11";
59+
a-gpios = <&xiao_d 5 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
60+
b-gpios = <&xiao_d 4 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
61+
steps = <80>;
62+
status = "disabled";
6063
};
6164

6265
right_encoder: encoder_right {
63-
compatible = "alps,ec11";
64-
a-gpios = <&pro_micro 20 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
65-
b-gpios = <&pro_micro 21 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
66-
steps = <80>;
67-
status = "disabled";
68-
};
66+
compatible = "alps,ec11";
67+
a-gpios = <&xiao_d 4 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
68+
b-gpios = <&xiao_d 5 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
69+
steps = <80>;
70+
status = "disabled";
6971

70-
sensors: sensors {
71-
compatible = "zmk,keymap-sensors";
72-
sensors = <&left_encoder &right_encoder>;
73-
triggers-per-rotation = <20>;
7472
};
75-
*/
7673

77-
mock_kscan: kscan_0 {
78-
compatible = "zmk,kscan-mock";
79-
// wakeup-source;
80-
columns = <0>;
81-
rows = <0>;
82-
events = <0>;
74+
sensors {
75+
compatible = "zmk,keymap-sensors";
76+
sensors = <&left_encoder &right_encoder>;
77+
triggers-per-rotation = <20>;
8378
};
84-
// TODO: per-key RGB node(s)?
8579
};
8680

8781
&xiao_i2c {

boards/shields/splitkb_aurora_sofle/splitkb_aurora_sofle_dongle_pro_micro.overlay

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,30 @@ RC(3,0) RC(3,1) RC(3,2) RC(3,3) RC(3,4) RC(3,5) RC(4,5) RC(4,6) RC(3,6) RC(3,7)
4343
rows = <0>;
4444
events = <0>;
4545
};
46-
// TODO: per-key RGB node(s)?
46+
47+
left_encoder: left_encoder {
48+
compatible = "alps,ec11";
49+
steps = <144>;
50+
status = "disabled";
51+
52+
a-gpios = <&pro_micro 16 GPIO_PULL_UP>;
53+
b-gpios = <&pro_micro 10 GPIO_PULL_UP>;
54+
};
55+
56+
right_encoder: right_encoder {
57+
compatible = "alps,ec11";
58+
steps = <144>;
59+
status = "disabled";
60+
61+
a-gpios = <&pro_micro 16 GPIO_PULL_UP>;
62+
b-gpios = <&pro_micro 10 GPIO_PULL_UP>;
63+
};
64+
65+
sensors: sensors {
66+
compatible = "zmk,keymap-sensors";
67+
sensors = <&left_encoder &right_encoder>;
68+
triggers-per-rotation = <36>;
69+
};
4770
};
4871

4972
&pro_micro_i2c {

boards/shields/splitkb_aurora_sofle/splitkb_aurora_sofle_dongle_xiao.overlay

Lines changed: 33 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,39 @@ RC(3,0) RC(3,1) RC(3,2) RC(3,3) RC(3,4) RC(3,5) RC(4,5) RC(4,6) RC(3,6) RC(3,7)
4343
rows = <0>;
4444
events = <0>;
4545
};
46-
// TODO: per-key RGB node(s)?
46+
47+
/*
48+
row-gpios
49+
= <&xiao_d 0 GPIO_ACTIVE_HIGH>
50+
, <&xiao_d 1 GPIO_ACTIVE_HIGH>
51+
, <&xiao_d 2 GPIO_ACTIVE_HIGH>
52+
, <&xiao_d 3 GPIO_ACTIVE_HIGH>
53+
;
54+
};
55+
*/
56+
57+
left_encoder: encoder_left {
58+
compatible = "alps,ec11";
59+
a-gpios = <&xiao_d 5 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
60+
b-gpios = <&xiao_d 4 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
61+
steps = <80>;
62+
status = "disabled";
63+
};
64+
65+
right_encoder: encoder_right {
66+
compatible = "alps,ec11";
67+
a-gpios = <&xiao_d 4 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
68+
b-gpios = <&xiao_d 5 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
69+
steps = <80>;
70+
status = "disabled";
71+
72+
};
73+
74+
sensors {
75+
compatible = "zmk,keymap-sensors";
76+
sensors = <&left_encoder &right_encoder>;
77+
triggers-per-rotation = <20>;
78+
};
4779
};
4880

4981
&xiao_i2c {

build.yaml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,19 @@ include:
165165
artifact-name: puchi_corne_dongle_view
166166
# snippet: zmk-usb-logging
167167
### Pro Micro END ###
168+
169+
### ProMicro_Dongle START ###
170+
# NICE x PUCHI and nice_oled + rgb
171+
- board: nice_nano_v2
172+
shield: corne_left nice_oled
173+
cmake-args: -DCONFIG_ZMK_KEYBOARD_NAME=\"Corne_Oled_RGB\"
174+
artifact-name: nice_corne_left_oled_rgb
175+
snippet: rgb-config studio-rpc-usb-uart
176+
- board: puchi_ble_v1
177+
shield: corne_right nice_oled
178+
snippet: rgb-config
179+
artifact-name: puchi_corne_right_oled_rgb
180+
### Pro Micro END ###
168181
### CORNE END ###
169182

170183
### SOFLEV2 SOFLEV1 SOFLEPLUS START ###

config/corne.keymap

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@
99
#include <dt-bindings/zmk/keys.h>
1010
#include <dt-bindings/zmk/mouse.h>
1111

12+
&led_strip {
13+
chain-length = <27>;
14+
};
15+
1216
/ {
1317
keymap {
1418
compatible = "zmk,keymap";
@@ -60,5 +64,17 @@
6064
&kp LGUI &studio_unlock &kp SPACE &kp RET &studio_unlock &kp RALT
6165
>;
6266
};
67+
extra_1 {
68+
status = "reserved";
69+
};
70+
71+
extra_2 {
72+
status = "reserved";
73+
};
74+
75+
extra_3 {
76+
status = "reserved";
77+
};
78+
};
6379
};
6480
};

0 commit comments

Comments
 (0)