summaryrefslogtreecommitdiff
path: root/app/boards/shields
diff options
context:
space:
mode:
authorPete Johanson <peter@peterjohanson.com>2020-08-19 16:05:51 -0400
committerGitHub <noreply@github.com>2020-08-19 16:05:51 -0400
commit2a0e35c11f02257e7292ea5766b952fa8b364bbf (patch)
tree94e9907805e98800909f482470e8e694324d05be /app/boards/shields
parentebd6fbb2254cfcdd8af6309dd9a5c3251ac19935 (diff)
parent93b1e0ac442234c4ce60caf6937fa764df8d9913 (diff)
Merge pull request #101 from okke-formsma/nrfmicro
nrfmicro support
Diffstat (limited to 'app/boards/shields')
-rw-r--r--app/boards/shields/kyria/boards/nrfmicro_11.overlay29
-rw-r--r--app/boards/shields/kyria/boards/nrfmicro_11_flipped.overlay28
-rw-r--r--app/boards/shields/kyria/boards/nrfmicro_13.overlay28
3 files changed, 85 insertions, 0 deletions
diff --git a/app/boards/shields/kyria/boards/nrfmicro_11.overlay b/app/boards/shields/kyria/boards/nrfmicro_11.overlay
new file mode 100644
index 0000000..d7f724f
--- /dev/null
+++ b/app/boards/shields/kyria/boards/nrfmicro_11.overlay
@@ -0,0 +1,29 @@
+&spi1 {
+ compatible = "nordic,nrf-spi";
+ status = "okay";
+ mosi-pin = <6>;
+ // Unused pins, needed for SPI definition, but not used by the ws2812 driver itself.
+ sck-pin = <12>; // 0.12 is not broken out on the nRFMicro
+ miso-pin = <22>; // 0.22 is not broken out on the nRFMicro
+
+ led_strip: ws2812@0 {
+ compatible = "worldsemi,ws2812-spi";
+ label = "WS2812";
+
+ /* 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>;
+ };
+};
+
+/ {
+ chosen {
+ zmk,underglow = &led_strip;
+ };
+};
+
diff --git a/app/boards/shields/kyria/boards/nrfmicro_11_flipped.overlay b/app/boards/shields/kyria/boards/nrfmicro_11_flipped.overlay
new file mode 100644
index 0000000..c5f2a94
--- /dev/null
+++ b/app/boards/shields/kyria/boards/nrfmicro_11_flipped.overlay
@@ -0,0 +1,28 @@
+&spi1 {
+ compatible = "nordic,nrf-spi";
+ status = "okay";
+ mosi-pin = <6>;
+ // Unused pins, needed for SPI definition, but not used by the ws2812 driver itself.
+ sck-pin = <12>; // 0.12 is not broken out on the nRFMicro
+ miso-pin = <22>; // 0.22 is not broken out on the nRFMicro
+
+ led_strip: ws2812@0 {
+ compatible = "worldsemi,ws2812-spi";
+ label = "WS2812";
+
+ /* 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>;
+ };
+};
+
+/ {
+ chosen {
+ zmk,underglow = &led_strip;
+ };
+};
diff --git a/app/boards/shields/kyria/boards/nrfmicro_13.overlay b/app/boards/shields/kyria/boards/nrfmicro_13.overlay
new file mode 100644
index 0000000..c5f2a94
--- /dev/null
+++ b/app/boards/shields/kyria/boards/nrfmicro_13.overlay
@@ -0,0 +1,28 @@
+&spi1 {
+ compatible = "nordic,nrf-spi";
+ status = "okay";
+ mosi-pin = <6>;
+ // Unused pins, needed for SPI definition, but not used by the ws2812 driver itself.
+ sck-pin = <12>; // 0.12 is not broken out on the nRFMicro
+ miso-pin = <22>; // 0.22 is not broken out on the nRFMicro
+
+ led_strip: ws2812@0 {
+ compatible = "worldsemi,ws2812-spi";
+ label = "WS2812";
+
+ /* 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>;
+ };
+};
+
+/ {
+ chosen {
+ zmk,underglow = &led_strip;
+ };
+};