Add RGB underglow.
This commit is contained in:
parent
e96f256ab9
commit
1c5588d690
2 changed files with 46 additions and 0 deletions
|
@ -0,0 +1,34 @@
|
||||||
|
/*
|
||||||
|
* Copyright (c) 2022 The ZMK Contributors
|
||||||
|
*
|
||||||
|
* SPDX-License-Identifier: MIT
|
||||||
|
*/
|
||||||
|
|
||||||
|
&spi1 {
|
||||||
|
compatible = "nordic,nrf-spim";
|
||||||
|
status = "okay";
|
||||||
|
mosi-pin = <6>;
|
||||||
|
// Unused pins, needed for SPI definition, but not used by the ws2812 driver itself.
|
||||||
|
sck-pin = <5>;
|
||||||
|
miso-pin = <7>;
|
||||||
|
|
||||||
|
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 = <16>; /* number of LEDs */
|
||||||
|
spi-one-frame = <0x70>;
|
||||||
|
spi-zero-frame = <0x40>;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
/ {
|
||||||
|
chosen {
|
||||||
|
zmk,underglow = &led_strip;
|
||||||
|
};
|
||||||
|
};
|
12
app/boards/shields/sofle_rgb_keyhive/sofle_rgb_keyhive.conf
Normal file
12
app/boards/shields/sofle_rgb_keyhive/sofle_rgb_keyhive.conf
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
# Copyright (c) 2022, Josh Whitley
|
||||||
|
# SPDX-License-Identifier: MIT
|
||||||
|
|
||||||
|
# Uncomment the following line to enable the Sofle OLED Display
|
||||||
|
# CONFIG_ZMK_DISPLAY=y
|
||||||
|
|
||||||
|
# Uncomment the following two lines to enable the underglow LEDs
|
||||||
|
# CONFIG_ZMK_RGB_UNDERGLOW=y
|
||||||
|
# CONFIG_WS2812_STRIP=y
|
||||||
|
|
||||||
|
CONFIG_EC11=y
|
||||||
|
CONFIG_EC11_TRIGGER_GLOBAL_THREAD=y
|
Loading…
Add table
Reference in a new issue