studio support
This commit is contained in:
@@ -1,12 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2022 The ZMK Contributors
|
||||
# SPDX-License-Identifier: MIT
|
||||
#
|
||||
|
||||
config BOARD_SOFLE_LEFT
|
||||
bool
|
||||
|
||||
config BOARD_SOFLE_RIGHT
|
||||
bool
|
||||
|
||||
|
||||
@@ -1,17 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2022 Darryl deHaan
|
||||
# SPDX-License-Identifier: MIT
|
||||
#
|
||||
|
||||
config BOARD_SOFLE_LEFT
|
||||
bool "sofle left"
|
||||
depends on SOC_NRF52840_QIAA
|
||||
|
||||
|
||||
config BOARD_SOFLE_RIGHT
|
||||
bool "sofle right"
|
||||
depends on SOC_NRF52840_QIAA
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1,92 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2022 Darryl deHaan
|
||||
# SPDX-License-Identifier: MIT
|
||||
#
|
||||
|
||||
if BOARD_SOFLE_LEFT
|
||||
|
||||
config ZMK_KEYBOARD_NAME
|
||||
default "Sofle"
|
||||
|
||||
config ZMK_SPLIT_ROLE_CENTRAL
|
||||
default y
|
||||
|
||||
endif # BOARD_SOFLE_LEFT
|
||||
|
||||
|
||||
if BOARD_SOFLE_LEFT || BOARD_SOFLE_RIGHT
|
||||
|
||||
config BOARD
|
||||
default "sofle"
|
||||
|
||||
config ZMK_SPLIT
|
||||
default y
|
||||
|
||||
config BT_CTLR
|
||||
default BT
|
||||
|
||||
if USB
|
||||
|
||||
config USB_NRFX
|
||||
default y
|
||||
|
||||
config USB_DEVICE_STACK
|
||||
default y
|
||||
|
||||
endif # USB
|
||||
|
||||
if ZMK_DISPLAY
|
||||
|
||||
config I2C
|
||||
default y
|
||||
|
||||
config SSD1306
|
||||
default y
|
||||
|
||||
choice ZMK_DISPLAY_WORK_QUEUE
|
||||
default ZMK_DISPLAY_WORK_QUEUE_DEDICATED
|
||||
endchoice
|
||||
|
||||
endif
|
||||
|
||||
if SSD1306
|
||||
|
||||
config LV_Z_VDB_SIZE
|
||||
default 64
|
||||
|
||||
config LV_DPI_DEF
|
||||
default 148
|
||||
|
||||
config LV_Z_BITS_PER_PIXEL
|
||||
default 1
|
||||
|
||||
choice LV_COLOR_DEPTH
|
||||
default LV_COLOR_DEPTH_1
|
||||
endchoice
|
||||
|
||||
endif
|
||||
|
||||
endif # BOARD_SOFLE_LEFT || BOARD_SOFLE_RIGHT
|
||||
|
||||
if ZMK_BACKLIGHT
|
||||
|
||||
config PWM
|
||||
default y
|
||||
|
||||
config LED_PWM
|
||||
default y
|
||||
|
||||
endif # ZMK_BACKLIGHT
|
||||
|
||||
config BOARD_ENABLE_DCDC
|
||||
bool "Enable DCDC mode"
|
||||
select SOC_DCDC_NRF52X
|
||||
default y
|
||||
depends on (BOARD_SOFLE_LEFT || BOARD_SOFLE_RIGHT)
|
||||
|
||||
config BOARD_ENABLE_DCDC_HV
|
||||
bool "Enable High Voltage DCDC converter"
|
||||
default y
|
||||
select SOC_DCDC_NRF52X_HV
|
||||
depends on (BOARD_SOFLE_LEFT || BOARD_SOFLE_RIGHT)
|
||||
|
||||
@@ -1,6 +0,0 @@
|
||||
# Copyright (c) 2021 @MangoIV
|
||||
# SPDX-License-Identifier: MIT
|
||||
|
||||
board_runner_args(nrfjprog "--nrf-family=NRF52" "--softreset")
|
||||
include(${ZEPHYR_BASE}/boards/common/blackmagicprobe.board.cmake)
|
||||
include(${ZEPHYR_BASE}/boards/common/nrfjprog.board.cmake)
|
||||
@@ -1,29 +0,0 @@
|
||||
# go to sleep after one hour (1*60*60*1000ms)
|
||||
# CONFIG_ZMK_IDLE_SLEEP_TIMEOUT=3600000
|
||||
|
||||
# Turn on logging, and set ZMK logging to debug output
|
||||
# CONFIG_ZMK_USB_LOGGING=n
|
||||
#
|
||||
# Copyright (c) 2022 Darryl deHaan
|
||||
# SPDX-License-Identifier: MIT
|
||||
#
|
||||
|
||||
CONFIG_ZMK_SLEEP=y
|
||||
|
||||
|
||||
CONFIG_WS2812_STRIP=y
|
||||
CONFIG_ZMK_RGB_UNDERGLOW=y
|
||||
CONFIG_ZMK_RGB_UNDERGLOW_EXT_POWER=y
|
||||
CONFIG_ZMK_RGB_UNDERGLOW_ON_START=n
|
||||
CONFIG_ZMK_RGB_UNDERGLOW_BRT_MAX=90
|
||||
|
||||
CONFIG_ZMK_RGB_UNDERGLOW_AUTO_OFF_IDLE=y
|
||||
CONFIG_ZMK_RGB_UNDERGLOW_AUTO_OFF_USB=y
|
||||
CONFIG_ZMK_RGB_UNDERGLOW_HUE_START=160
|
||||
CONFIG_ZMK_RGB_UNDERGLOW_EFF_START=3
|
||||
|
||||
#CONFIG_ZMK_HID_CONSUMER_REPORT_USAGES_BASIC=y
|
||||
CONFIG_ZMK_MOUSE=y
|
||||
|
||||
CONFIG_BOARD_ENABLE_DCDC=y
|
||||
|
||||
@@ -1,197 +0,0 @@
|
||||
/*
|
||||
*
|
||||
* Copyright (c) 2021 Darryl deHaan
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
*/
|
||||
|
||||
/dts-v1/;
|
||||
#include <nordic/nrf52840_qiaa.dtsi>
|
||||
#include <dt-bindings/led/led.h>
|
||||
#include <dt-bindings/zmk/matrix_transform.h>
|
||||
|
||||
/ {
|
||||
model = "sofle";
|
||||
compatible = "sofle";
|
||||
|
||||
chosen {
|
||||
zephyr,code-partition = &code_partition;
|
||||
zephyr,sram = &sram0;
|
||||
zephyr,flash = &flash0;
|
||||
zmk,kscan = &kscan0;
|
||||
zephyr,display = &oled;
|
||||
zephyr,console = &cdc_acm_uart;
|
||||
zmk,underglow = &led_strip;
|
||||
zmk,matrix-transform = &default_transform;
|
||||
zmk,backlight = &backlight;
|
||||
};
|
||||
|
||||
left_encoder: encoder_left {
|
||||
compatible = "alps,ec11";
|
||||
label = "LEFT_ENCODER";
|
||||
resolution = <4>;
|
||||
steps = <40>;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
sensors {
|
||||
compatible = "zmk,keymap-sensors";
|
||||
sensors = <&left_encoder>;
|
||||
};
|
||||
|
||||
default_transform: keymap_transform_0 {
|
||||
compatible = "zmk,matrix-transform";
|
||||
columns = <14>;
|
||||
rows = <5>;
|
||||
map = <
|
||||
RC(0,0) RC(0,1) RC(0,2) RC(0,3) RC(0,4) RC(0,5) RC(0,7) RC(0,8) RC(0,9) RC(0,10) RC(0,11) RC(0,12) RC(0,13)
|
||||
RC(1,0) RC(1,1) RC(1,2) RC(1,3) RC(1,4) RC(1,5) RC(1,7) RC(1,8) RC(1,9) RC(1,10) RC(1,11) RC(1,12) RC(1,13)
|
||||
RC(2,0) RC(2,1) RC(2,2) RC(2,3) RC(2,4) RC(2,5) RC(2,7) RC(2,8) RC(2,9) RC(2,10) RC(2,11) RC(2,12) RC(2,13)
|
||||
RC(3,0) RC(3,1) RC(3,2) RC(3,3) RC(3,4) RC(3,5) RC(3,7) RC(3,8) RC(3,9) RC(3,10) RC(3,11) RC(3,12) RC(3,13)
|
||||
RC(4,0) RC(4,1) RC(4,2) RC(4,3) RC(4,4) RC(4,5) RC(4,7) RC(4,8) RC(4,9) RC(4,10) RC(4,11) RC(4,12)
|
||||
>;
|
||||
};
|
||||
};
|
||||
|
||||
&adc {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&gpiote {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&gpio0 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&gpio1 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usbd {
|
||||
status = "okay";
|
||||
cdc_acm_uart: cdc_acm_uart {
|
||||
compatible = "zephyr,cdc-acm-uart";
|
||||
};
|
||||
};
|
||||
|
||||
&flash0 {
|
||||
/*
|
||||
* For more information, see:
|
||||
* http://docs.zephyrproject.org/latest/devices/dts/flash_partitions.html
|
||||
*/
|
||||
partitions {
|
||||
compatible = "fixed-partitions";
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
|
||||
sd_partition: partition@0 {
|
||||
reg = <0x00000000 0x00026000>;
|
||||
};
|
||||
code_partition: partition@26000 {
|
||||
reg = <0x00026000 0x000c6000>;
|
||||
};
|
||||
|
||||
/*
|
||||
* The flash starting at 0x000ec000 and ending at
|
||||
* 0x000f3fff is reserved for use by the application.
|
||||
*/
|
||||
|
||||
/*
|
||||
* Storage partition will be used by FCB/LittleFS/NVS
|
||||
* if enabled.
|
||||
*/
|
||||
storage_partition: partition@ec000 {
|
||||
reg = <0x000ec000 0x00008000>;
|
||||
};
|
||||
|
||||
boot_partition: partition@f4000 {
|
||||
reg = <0x000f4000 0x0000c000>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&pinctrl {
|
||||
i2c0_default: i2c0_default {
|
||||
group1 {
|
||||
psels = <NRF_PSEL(TWIM_SDA, 0, 17)>,
|
||||
<NRF_PSEL(TWIM_SCL, 0, 20)>;
|
||||
};
|
||||
};
|
||||
|
||||
i2c0_sleep: i2c0_sleep {
|
||||
group1 {
|
||||
psels = <NRF_PSEL(TWIM_SDA, 0, 17)>,
|
||||
<NRF_PSEL(TWIM_SCL, 0, 20)>;
|
||||
low-power-enable;
|
||||
};
|
||||
};
|
||||
|
||||
spi3_default: spi3_default {
|
||||
group1 {
|
||||
psels = <NRF_PSEL(SPIM_MOSI, 1, 12)>; // WS2812_VEXT_DATA
|
||||
};
|
||||
};
|
||||
|
||||
spi3_sleep: spi3_sleep {
|
||||
group1 {
|
||||
psels = <NRF_PSEL(SPIM_MOSI, 1, 12)>;
|
||||
low-power-enable;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&i2c0 {
|
||||
status = "okay";
|
||||
|
||||
compatible = "nordic,nrf-twi";
|
||||
pinctrl-0 = <&i2c0_default>;
|
||||
pinctrl-1 = <&i2c0_sleep>;
|
||||
pinctrl-names = "default", "sleep";
|
||||
oled: ssd1306@3c {
|
||||
compatible = "solomon,ssd1306fb";
|
||||
reg = <0x3c>;
|
||||
label = "DISPLAY";
|
||||
width = <128>;
|
||||
height = <32>;
|
||||
segment-offset = <0>;
|
||||
page-offset = <0>;
|
||||
display-offset = <0>;
|
||||
multiplex-ratio = <31>;
|
||||
segment-remap;
|
||||
com-invdir;
|
||||
com-sequential;
|
||||
prechargep = <0x22>;
|
||||
};
|
||||
};
|
||||
|
||||
&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 = <7>; /* 6 keys have underglow at the moment */
|
||||
spi-one-frame = <0x70>;
|
||||
spi-zero-frame = <0x40>;
|
||||
|
||||
color-mapping = <LED_COLOR_ID_GREEN LED_COLOR_ID_RED LED_COLOR_ID_BLUE>;
|
||||
};
|
||||
};
|
||||
&pwm0 {
|
||||
status = "okay";
|
||||
pinctrl-0 = <&pwm0_default>;
|
||||
pinctrl-1 = <&pwm0_sleep>;
|
||||
pinctrl-names = "default", "sleep";
|
||||
};
|
||||
@@ -1,20 +0,0 @@
|
||||
identifier: sofle
|
||||
name: Solfe
|
||||
url: https://github.com/tokyo2006/zmk-config-sofle
|
||||
type: mcu
|
||||
arch: arm
|
||||
toolchain:
|
||||
- zephyr
|
||||
- gnuarmemb
|
||||
- xtools
|
||||
ram: 40
|
||||
supported:
|
||||
- adc
|
||||
- usb_device
|
||||
- ble
|
||||
- ieee802154
|
||||
- pwm
|
||||
- watchdog
|
||||
- gpio
|
||||
- i2c
|
||||
- spi
|
||||
@@ -1,15 +0,0 @@
|
||||
file_format: "1"
|
||||
id: sofle
|
||||
name: Sofle
|
||||
url: https://github.com/tokyo2006/zmk-config-sofle
|
||||
type: board
|
||||
arch: arm
|
||||
features:
|
||||
- keys
|
||||
- display
|
||||
outputs:
|
||||
- usb
|
||||
- ble
|
||||
siblings:
|
||||
- sofle_left
|
||||
- sofle_right
|
||||
@@ -1,85 +0,0 @@
|
||||
/*
|
||||
*
|
||||
* Copyright (c) 2021 Darryl deHaan
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
*/
|
||||
|
||||
#include "sofle.dtsi"
|
||||
#include <dt-bindings/led/led.h>
|
||||
|
||||
/{
|
||||
chosen {
|
||||
zmk,battery = &vbatt;
|
||||
zmk,backlight = &backlight;
|
||||
|
||||
};
|
||||
|
||||
kscan0: kscan {
|
||||
compatible = "zmk,kscan-gpio-matrix";
|
||||
wakeup-source;
|
||||
diode-direction = "col2row";
|
||||
row-gpios
|
||||
= <&gpio0 19 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
|
||||
, <&gpio0 8 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
|
||||
, <&gpio0 12 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
|
||||
, <&gpio0 11 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
|
||||
, <&gpio1 9 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
|
||||
;
|
||||
|
||||
col-gpios
|
||||
= <&gpio0 3 GPIO_ACTIVE_HIGH>
|
||||
, <&gpio0 28 GPIO_ACTIVE_HIGH>
|
||||
, <&gpio0 30 GPIO_ACTIVE_HIGH>
|
||||
, <&gpio0 21 GPIO_ACTIVE_HIGH>
|
||||
, <&gpio0 23 GPIO_ACTIVE_HIGH>
|
||||
, <&gpio0 22 GPIO_ACTIVE_HIGH>
|
||||
;
|
||||
};
|
||||
|
||||
ext-power {
|
||||
compatible = "zmk,ext-power-generic";
|
||||
label = "EXT_POWER";
|
||||
control-gpios = <&gpio0 13 GPIO_ACTIVE_HIGH>;
|
||||
init-delay-ms = <50>;
|
||||
};
|
||||
|
||||
vbatt: vbatt {
|
||||
compatible = "zmk,battery-nrf-vddh";
|
||||
};
|
||||
backlight: pwmleds {
|
||||
compatible = "pwm-leds";
|
||||
pwm_led_0 {
|
||||
pwms = <&pwm0 0 PWM_MSEC(1) PWM_POLARITY_NORMAL>;
|
||||
};
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
&left_encoder {
|
||||
a-gpios = <&gpio1 10 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
|
||||
b-gpios = <&gpio1 14 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
|
||||
status = "okay";
|
||||
};
|
||||
&pinctrl {
|
||||
// Other pinctrl definitions for other hardware
|
||||
pwm0_default: pwm0_default {
|
||||
group1 {
|
||||
psels = <NRF_PSEL(PWM_OUT0, 1, 13)>;
|
||||
};
|
||||
};
|
||||
pwm0_sleep: pwm0_sleep {
|
||||
group1 {
|
||||
psels = <NRF_PSEL(PWM_OUT0, 1, 13)>;
|
||||
low-power-enable;
|
||||
|
||||
};
|
||||
};
|
||||
};
|
||||
&pwm0 {
|
||||
status = "okay";
|
||||
pinctrl-0 = <&pwm0_default>;
|
||||
pinctrl-1 = <&pwm0_sleep>;
|
||||
pinctrl-names = "default", "sleep";
|
||||
};
|
||||
|
||||
@@ -1,80 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2022 Darryl deHaan
|
||||
# SPDX-License-Identifier: MIT
|
||||
#
|
||||
|
||||
CONFIG_SOC_SERIES_NRF52X=y
|
||||
CONFIG_SOC_NRF52840_QIAA=y
|
||||
CONFIG_BOARD_SOFLE_LEFT=y
|
||||
CONFIG_ZMK_SLEEP=y
|
||||
|
||||
|
||||
|
||||
|
||||
# Enable MPU
|
||||
CONFIG_ARM_MPU=y
|
||||
|
||||
# enable pinctrl
|
||||
CONFIG_PINCTRL=y
|
||||
|
||||
# enable GPIO
|
||||
CONFIG_GPIO=y
|
||||
|
||||
# Enable SPI
|
||||
CONFIG_SPI=y
|
||||
|
||||
# Enable writing to flash
|
||||
CONFIG_USE_DT_CODE_PARTITION=y
|
||||
CONFIG_BUILD_OUTPUT_UF2=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
|
||||
|
||||
# Enable 32kHz crystal
|
||||
CONFIG_CLOCK_CONTROL_NRF_K32SRC_XTAL=y
|
||||
CONFIG_CLOCK_CONTROL_NRF_K32SRC_30PPM=y
|
||||
|
||||
CONFIG_ZMK_USB=y
|
||||
CONFIG_ZMK_BLE=y
|
||||
|
||||
# enable display drivers
|
||||
CONFIG_ZMK_DISPLAY=y
|
||||
|
||||
|
||||
|
||||
#CONFIG_ZMK_DISPLAY_WORK_QUEUE_DEDICATED=y
|
||||
#CONFIG_ZMK_DISPLAY_DEDICATED_THREAD_STACK_SIZE=2048
|
||||
#CONFIG_LV_Z_BITS_PER_PIXEL=1
|
||||
#CONFIG_LV_COLOR_DEPTH_1=y
|
||||
#CONFIG_LV_DPI_DEF=145
|
||||
#CONFIG_LV_Z_VDB_SIZE=100
|
||||
#CONFIG_LV_USE_THEME_MONO=y
|
||||
#CONFIG_LV_COLOR_CHROMA_KEY_HEX=0x00FF00
|
||||
#CONFIG_ZMK_LV_FONT_DEFAULT_SMALL_MONTSERRAT_16=y
|
||||
#CONFIG_LV_FONT_MONTSERRAT_26=y
|
||||
#CONFIG_LV_FONT_DEFAULT_MONTSERRAT_26=y
|
||||
|
||||
|
||||
#EXT POWER
|
||||
CONFIG_ZMK_EXT_POWER=y
|
||||
|
||||
#BLE-passkey
|
||||
CONFIG_ZMK_BLE_PASSKEY_ENTRY=n
|
||||
|
||||
#BLE-clean
|
||||
CONFIG_ZMK_BLE_CLEAR_BONDS_ON_START=n
|
||||
|
||||
#usb-name
|
||||
CONFIG_USB_DEVICE_MANUFACTURER="sofle"
|
||||
|
||||
CONFIG_BT_CTLR_TX_PWR_PLUS_8=y
|
||||
CONFIG_ZMK_HID_REPORT_TYPE_NKRO=n
|
||||
#CONFIG_ZMK_HID_CONSUMER_REPORT_USAGES_BASIC=y
|
||||
|
||||
#EC11 enable
|
||||
CONFIG_EC11=y
|
||||
CONFIG_EC11_TRIGGER_GLOBAL_THREAD=y
|
||||
CONFIG_ZMK_MOUSE=y
|
||||
@@ -1,104 +0,0 @@
|
||||
/*
|
||||
*
|
||||
* Copyright (c) 2021 Darryl deHaan
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
*/
|
||||
#include "sofle.dtsi"
|
||||
#include <dt-bindings/led/led.h>
|
||||
|
||||
/{
|
||||
chosen {
|
||||
zmk,battery = &vbatt;
|
||||
zmk,backlight = &backlight;
|
||||
};
|
||||
|
||||
kscan0: kscan {
|
||||
compatible = "zmk,kscan-gpio-matrix";
|
||||
wakeup-source;
|
||||
diode-direction = "col2row";
|
||||
row-gpios
|
||||
= <&gpio0 19 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
|
||||
, <&gpio0 8 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
|
||||
, <&gpio0 12 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
|
||||
, <&gpio0 11 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
|
||||
, <&gpio1 9 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
|
||||
;
|
||||
|
||||
col-gpios
|
||||
= <&gpio0 22 GPIO_ACTIVE_HIGH>
|
||||
, <&gpio0 29 GPIO_ACTIVE_HIGH>
|
||||
, <&gpio0 3 GPIO_ACTIVE_HIGH>
|
||||
, <&gpio0 28 GPIO_ACTIVE_HIGH>
|
||||
, <&gpio0 30 GPIO_ACTIVE_HIGH>
|
||||
, <&gpio0 21 GPIO_ACTIVE_HIGH>
|
||||
, <&gpio0 23 GPIO_ACTIVE_HIGH>
|
||||
;
|
||||
};
|
||||
|
||||
ext-power {
|
||||
compatible = "zmk,ext-power-generic";
|
||||
label = "EXT_POWER";
|
||||
control-gpios = <&gpio0 13 GPIO_ACTIVE_HIGH>;
|
||||
init-delay-ms = <50>;
|
||||
};
|
||||
|
||||
vbatt: vbatt {
|
||||
compatible = "zmk,battery-nrf-vddh";
|
||||
init-delay-ms = <50>;
|
||||
};
|
||||
backlight: pwmleds {
|
||||
compatible = "pwm-leds";
|
||||
pwm_led_0 {
|
||||
pwms = <&pwm0 0 PWM_MSEC(1) PWM_POLARITY_NORMAL>;
|
||||
};
|
||||
};
|
||||
|
||||
};
|
||||
&default_transform {
|
||||
col-offset = <7>;
|
||||
};
|
||||
|
||||
&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 = <7>; /* 6 keys have underglow at the moment */
|
||||
spi-one-frame = <0x70>;
|
||||
spi-zero-frame = <0x40>;
|
||||
|
||||
color-mapping = <LED_COLOR_ID_GREEN LED_COLOR_ID_RED LED_COLOR_ID_BLUE>;
|
||||
};
|
||||
};
|
||||
&pinctrl {
|
||||
// Other pinctrl definitions for other hardware
|
||||
pwm0_default: pwm0_default {
|
||||
group1 {
|
||||
psels = <NRF_PSEL(PWM_OUT0, 1, 13)>;
|
||||
};
|
||||
};
|
||||
pwm0_sleep: pwm0_sleep {
|
||||
group1 {
|
||||
psels = <NRF_PSEL(PWM_OUT0, 1, 13)>;
|
||||
low-power-enable;
|
||||
};
|
||||
};
|
||||
};
|
||||
&pwm0 {
|
||||
status = "okay";
|
||||
pinctrl-0 = <&pwm0_default>;
|
||||
pinctrl-1 = <&pwm0_sleep>;
|
||||
pinctrl-names = "default", "sleep";
|
||||
};
|
||||
@@ -1,76 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 2022 Darryl deHaan
|
||||
# SPDX-License-Identifier: MIT
|
||||
#
|
||||
|
||||
CONFIG_SOC_SERIES_NRF52X=y
|
||||
CONFIG_SOC_NRF52840_QIAA=y
|
||||
CONFIG_BOARD_SOFLE_RIGHT=y
|
||||
CONFIG_ZMK_SLEEP=y
|
||||
|
||||
|
||||
|
||||
|
||||
# Enable MPU
|
||||
CONFIG_ARM_MPU=y
|
||||
|
||||
# enable pinctrl
|
||||
CONFIG_PINCTRL=y
|
||||
|
||||
# enable GPIO
|
||||
CONFIG_GPIO=y
|
||||
|
||||
# Enable SPI
|
||||
CONFIG_SPI=y
|
||||
|
||||
# Enable writing to flash
|
||||
CONFIG_USE_DT_CODE_PARTITION=y
|
||||
CONFIG_BUILD_OUTPUT_UF2=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
|
||||
|
||||
# Enable 32kHz crystal
|
||||
CONFIG_CLOCK_CONTROL_NRF_K32SRC_XTAL=y
|
||||
CONFIG_CLOCK_CONTROL_NRF_K32SRC_30PPM=y
|
||||
|
||||
CONFIG_ZMK_USB=n
|
||||
CONFIG_ZMK_BLE=y
|
||||
|
||||
# enable display drivers
|
||||
CONFIG_ZMK_DISPLAY=y
|
||||
|
||||
|
||||
|
||||
|
||||
#CONFIG_ZMK_DISPLAY_WORK_QUEUE_DEDICATED=y
|
||||
#CONFIG_ZMK_DISPLAY_DEDICATED_THREAD_STACK_SIZE=2048
|
||||
#CONFIG_LV_Z_BITS_PER_PIXEL=1
|
||||
#CONFIG_LV_COLOR_DEPTH_1=y
|
||||
#CONFIG_LV_DPI_DEF=145
|
||||
#CONFIG_LV_Z_VDB_SIZE=100
|
||||
#CONFIG_LV_USE_THEME_MONO=y
|
||||
#CONFIG_LV_COLOR_CHROMA_KEY_HEX=0x00FF00
|
||||
#CONFIG_ZMK_LV_FONT_DEFAULT_SMALL_MONTSERRAT_16=y
|
||||
#CONFIG_LV_FONT_MONTSERRAT_26=y
|
||||
#CONFIG_LV_FONT_DEFAULT_MONTSERRAT_26=y
|
||||
|
||||
#EXT POWER
|
||||
CONFIG_ZMK_EXT_POWER=y
|
||||
|
||||
#BLE-passkey
|
||||
CONFIG_ZMK_BLE_PASSKEY_ENTRY=n
|
||||
|
||||
#BLE-clean
|
||||
CONFIG_ZMK_BLE_CLEAR_BONDS_ON_START=n
|
||||
|
||||
#usb-name
|
||||
CONFIG_USB_DEVICE_MANUFACTURER="sofle"
|
||||
|
||||
CONFIG_BT_CTLR_TX_PWR_PLUS_8=y
|
||||
CONFIG_ZMK_HID_REPORT_TYPE_NKRO=n
|
||||
CONFIG_ZMK_MOUSE=y
|
||||
|
||||
@@ -1,2 +0,0 @@
|
||||
config SHIELD_NICE_VIEW_ADAPTER
|
||||
def_bool $(shields_list_contains,nice_view_adapter)
|
||||
@@ -1,29 +0,0 @@
|
||||
&pinctrl {
|
||||
spi0_default: spi0_default {
|
||||
group1 {
|
||||
psels = <NRF_PSEL(SPIM_SCK, 0, 20)>,
|
||||
<NRF_PSEL(SPIM_MOSI, 0, 17)>,
|
||||
<NRF_PSEL(SPIM_MISO, 0, 25)>;
|
||||
};
|
||||
};
|
||||
spi0_sleep: spi0_sleep {
|
||||
group1 {
|
||||
psels = <NRF_PSEL(SPIM_SCK, 0, 20)>,
|
||||
<NRF_PSEL(SPIM_MOSI, 0, 17)>,
|
||||
<NRF_PSEL(SPIM_MISO, 0, 25)>;
|
||||
low-power-enable;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
nice_view_spi: &spi0 {
|
||||
compatible = "nordic,nrf-spim";
|
||||
pinctrl-0 = <&spi0_default>;
|
||||
pinctrl-1 = <&spi0_sleep>;
|
||||
pinctrl-names = "default", "sleep";
|
||||
cs-gpios = <&gpio0 6 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
|
||||
&i2c0 {
|
||||
status = "disabled";
|
||||
};
|
||||
@@ -1,29 +0,0 @@
|
||||
&pinctrl {
|
||||
spi0_default: spi0_default {
|
||||
group1 {
|
||||
psels = <NRF_PSEL(SPIM_SCK, 0, 20)>,
|
||||
<NRF_PSEL(SPIM_MOSI, 0, 17)>,
|
||||
<NRF_PSEL(SPIM_MISO, 0, 25)>;
|
||||
};
|
||||
};
|
||||
spi0_sleep: spi0_sleep {
|
||||
group1 {
|
||||
psels = <NRF_PSEL(SPIM_SCK, 0, 20)>,
|
||||
<NRF_PSEL(SPIM_MOSI, 0, 17)>,
|
||||
<NRF_PSEL(SPIM_MISO, 0, 25)>;
|
||||
low-power-enable;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
nice_view_spi: &spi0 {
|
||||
compatible = "nordic,nrf-spim";
|
||||
pinctrl-0 = <&spi0_default>;
|
||||
pinctrl-1 = <&spi0_sleep>;
|
||||
pinctrl-names = "default", "sleep";
|
||||
cs-gpios = <&gpio0 6 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
|
||||
&i2c0 {
|
||||
status = "disabled";
|
||||
};
|
||||
@@ -1,2 +0,0 @@
|
||||
CONFIG_SSD1306=n
|
||||
CONFIG_ZMK_DISPLAY_STATUS_SCREEN_CUSTOM=y
|
||||
@@ -1,7 +0,0 @@
|
||||
file_format: "1"
|
||||
id: nice_view_adapter
|
||||
name: nice!view adapter
|
||||
type: shield
|
||||
url: https://nicekeyboards.com/nice-view
|
||||
requires: [i2c_oled]
|
||||
exposes: [nice_view_header]
|
||||
@@ -2,7 +2,7 @@
|
||||
CONFIG_ZMK_IDLE_SLEEP_TIMEOUT=3600000
|
||||
|
||||
# Turn on logging, and set ZMK logging to debug output
|
||||
# CONFIG_ZMK_USB_LOGGING=n
|
||||
CONFIG_ZMK_USB_LOGGING=n
|
||||
#
|
||||
# Copyright (c) 2022 Darryl deHaan
|
||||
# SPDX-License-Identifier: MIT
|
||||
@@ -42,7 +42,3 @@ CONFIG_ZMK_BACKLIGHT=y
|
||||
CONFIG_ZMK_BACKLIGHT_BRT_START=100
|
||||
CONFIG_ZMK_BACKLIGHT_ON_START=y
|
||||
CONFIG_ZMK_BACKLIGHT_AUTO_OFF_IDLE=n
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"id": "sofle",
|
||||
"name": "Sofle",
|
||||
"id": "eyelash_sofle",
|
||||
"name": "Eyelash Sofle",
|
||||
"layouts": {
|
||||
"default_layout": {
|
||||
"name": "default_layout",
|
||||
@@ -1,4 +1,3 @@
|
||||
#include <behaviors/mouse_keys.dtsi>
|
||||
#include <behaviors.dtsi>
|
||||
#include <dt-bindings/zmk/bt.h>
|
||||
#include <dt-bindings/zmk/keys.h>
|
||||
@@ -6,14 +5,23 @@
|
||||
#include <dt-bindings/zmk/outputs.h>
|
||||
#include <dt-bindings/zmk/rgb.h>
|
||||
|
||||
#include <input/processors.dtsi>
|
||||
|
||||
/*
|
||||
|
||||
&mmv_input_listener {
|
||||
input-processors = <&zip_xy_scaler 2 1>;
|
||||
};
|
||||
|
||||
&msc_input_listener {
|
||||
input-processors = <&zip_xy_scaler 2 1>;
|
||||
};
|
||||
|
||||
*/
|
||||
|
||||
#define ZMK_MOUSE_DEFAULT_MOVE_VAL 1200 // 600
|
||||
#define ZMK_MOUSE_DEFAULT_SCRL_VAL 20 // 10
|
||||
#define U_MS_U &mmv MOVE_UP
|
||||
#define U_MS_D &mmv MOVE_DOWN
|
||||
#define U_MS_L &mmv MOVE_LEFT
|
||||
#define U_MS_R &mmv MOVE_RIGHT
|
||||
#define ZMK_MOUSE_DEFAULT_MOVE_VAL 1200 // 600
|
||||
#define ZMK_MOUSE_DEFAULT_SCRL_VAL 20 // 10
|
||||
|
||||
|
||||
/ {
|
||||
behaviors {
|
||||
@@ -70,7 +78,7 @@
|
||||
layer_2 {
|
||||
bindings = <
|
||||
&kp TILDE &bt BT_SEL 0 &bt BT_SEL 1 &bt BT_SEL 2 &bt BT_SEL 3 &bt BT_SEL 4 &mmv MOVE_UP &kp F6 &kp F7 &kp F8 &kp F9 &kp F10 &trans
|
||||
&trans &bt BT_CLR &bt BT_CLR_ALL &trans &trans &trans &mmv MOVE_DOWN &trans &trans &kp F11 &kp F12 &kp UNDER &kp PLUS
|
||||
&studio_unlock &bt BT_CLR &bt BT_CLR_ALL &trans &trans &trans &mmv MOVE_DOWN &trans &trans &kp F11 &kp F12 &kp UNDER &kp PLUS
|
||||
&trans &out OUT_USB &out OUT_BLE &trans &trans &trans &mmv MOVE_LEFT &trans &trans &trans &trans &kp LBRC &kp RBRC
|
||||
&trans &sys_reset &trans &bootloader &trans &trans &mmv MOVE_RIGHT &trans &trans &sys_reset &soft_off &bootloader &trans
|
||||
&trans &trans &trans &trans &trans &trans &mkp LCLK &trans &trans &trans &trans &trans
|
||||
+15
-6
@@ -1,16 +1,25 @@
|
||||
manifest:
|
||||
remotes:
|
||||
- name: zmkfirmware
|
||||
url-base: https://github.com/petejohanson
|
||||
url-base: https://github.com/zmkfirmware
|
||||
# Additional modules containing boards/shields/custom code can be listed here as well.
|
||||
# See:
|
||||
# - https://zmk.dev/docs/features/modules
|
||||
# - https://docs.zephyrproject.org/3.5.0/develop/west/manifest.html#projects
|
||||
- name: gpeye
|
||||
url-base: https://github.com/GPeye
|
||||
- name: petejohanson
|
||||
url-base: https://github.com/petejohanson
|
||||
projects:
|
||||
- name: zmk
|
||||
remote: zmkfirmware
|
||||
revision: feat/pointers-move-scroll
|
||||
import: app/west.yml
|
||||
- name: urchin-peripheral-animation
|
||||
- name: eyelash_sofle
|
||||
url: https://github.com/a741725193/zmk-sofle
|
||||
revision: refactor
|
||||
- name: mario-peripheral-animation
|
||||
remote: gpeye
|
||||
revision: main
|
||||
- name: zmk
|
||||
remote: petejohanson
|
||||
revision: feat/pointers-with-input-processors
|
||||
import: app/west.yml
|
||||
self:
|
||||
path: config
|
||||
|
||||
Reference in New Issue
Block a user