NYE update
This commit is contained in:
parent
9e611e184b
commit
93b6c889d7
13 changed files with 306 additions and 0 deletions
65
app/boards/shields/duckboard/CMakeCache.txt
Normal file
65
app/boards/shields/duckboard/CMakeCache.txt
Normal file
|
@ -0,0 +1,65 @@
|
||||||
|
# This is the CMakeCache file.
|
||||||
|
# For build in directory: /home/jackhartstein/zmk/app/boards/shields/duck
|
||||||
|
# It was generated by CMake: /usr/local/bin/cmake
|
||||||
|
# You can edit this file to change values found and used by cmake.
|
||||||
|
# If you do not want to change any of the values, simply exit the editor.
|
||||||
|
# If you do want to change a value, simply edit, save, and exit the editor.
|
||||||
|
# The syntax for the file is as follows:
|
||||||
|
# KEY:TYPE=VALUE
|
||||||
|
# KEY is the name of a variable in the cache.
|
||||||
|
# TYPE is a hint to GUIs for the type of VALUE, DO NOT EDIT TYPE!.
|
||||||
|
# VALUE is the current value for the KEY.
|
||||||
|
|
||||||
|
########################
|
||||||
|
# EXTERNAL cache entries
|
||||||
|
########################
|
||||||
|
|
||||||
|
//No help, variable specified on the command line.
|
||||||
|
BOARD:UNINITIALIZED=nice_nano
|
||||||
|
|
||||||
|
//Path to a file.
|
||||||
|
BOARD_DIR:PATH=/home/jackhartstein/zmk/app/boards/arm/nice_nano
|
||||||
|
|
||||||
|
//Selected user ZMK config
|
||||||
|
CACHED_ZMK_CONFIG:STRING=
|
||||||
|
|
||||||
|
//No help, variable specified on the command line.
|
||||||
|
WEST_PYTHON:UNINITIALIZED=/usr/bin/python3
|
||||||
|
|
||||||
|
|
||||||
|
########################
|
||||||
|
# INTERNAL cache entries
|
||||||
|
########################
|
||||||
|
|
||||||
|
//This is the directory where this CMakeCache.txt was created
|
||||||
|
CMAKE_CACHEFILE_DIR:INTERNAL=/home/jackhartstein/zmk/app/boards/shields/duck
|
||||||
|
//Major version of cmake used to create the current loaded cache
|
||||||
|
CMAKE_CACHE_MAJOR_VERSION:INTERNAL=3
|
||||||
|
//Minor version of cmake used to create the current loaded cache
|
||||||
|
CMAKE_CACHE_MINOR_VERSION:INTERNAL=19
|
||||||
|
//Patch version of cmake used to create the current loaded cache
|
||||||
|
CMAKE_CACHE_PATCH_VERSION:INTERNAL=2
|
||||||
|
//Path to CMake executable.
|
||||||
|
CMAKE_COMMAND:INTERNAL=/usr/local/bin/cmake
|
||||||
|
//Path to cpack program executable.
|
||||||
|
CMAKE_CPACK_COMMAND:INTERNAL=/usr/local/bin/cpack
|
||||||
|
//Path to ctest program executable.
|
||||||
|
CMAKE_CTEST_COMMAND:INTERNAL=/usr/local/bin/ctest
|
||||||
|
//Name of external makefile project generator.
|
||||||
|
CMAKE_EXTRA_GENERATOR:INTERNAL=
|
||||||
|
//Name of generator.
|
||||||
|
CMAKE_GENERATOR:INTERNAL=Ninja
|
||||||
|
//Generator instance identifier.
|
||||||
|
CMAKE_GENERATOR_INSTANCE:INTERNAL=
|
||||||
|
//Name of generator platform.
|
||||||
|
CMAKE_GENERATOR_PLATFORM:INTERNAL=
|
||||||
|
//Name of generator toolset.
|
||||||
|
CMAKE_GENERATOR_TOOLSET:INTERNAL=
|
||||||
|
//Source directory with the top level CMakeLists.txt file for this
|
||||||
|
// project
|
||||||
|
CMAKE_HOME_DIRECTORY:INTERNAL=/home/jackhartstein/zmk/app
|
||||||
|
//number of local generators
|
||||||
|
CMAKE_NUMBER_OF_MAKEFILES:INTERNAL=1
|
||||||
|
//Path to CMake installation.
|
||||||
|
CMAKE_ROOT:INTERNAL=/usr/local/share/cmake-3.19
|
||||||
|
|
|
@ -0,0 +1 @@
|
||||||
|
# This file is generated by cmake for dependency checking of the CMakeCache.txt file
|
17
app/boards/shields/duckboard/Kconfig.defconfig
Normal file
17
app/boards/shields/duckboard/Kconfig.defconfig
Normal file
|
@ -0,0 +1,17 @@
|
||||||
|
# Copyright (c) 2020 The ZMK Contributors
|
||||||
|
# SPDX-License-Identifier: MIT
|
||||||
|
#
|
||||||
|
# Author: Jack Hartstein
|
||||||
|
|
||||||
|
if SHIELD_DUCKBOARD
|
||||||
|
|
||||||
|
config ZMK_KEYBOARD_NAME
|
||||||
|
default "duckboard"
|
||||||
|
|
||||||
|
config ZMK_USB
|
||||||
|
default y
|
||||||
|
|
||||||
|
config ZMK_BLE
|
||||||
|
default y
|
||||||
|
|
||||||
|
endif
|
7
app/boards/shields/duckboard/Kconfig.shield
Normal file
7
app/boards/shields/duckboard/Kconfig.shield
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
# Copyright (c) 2020 The ZMK Contributors
|
||||||
|
# SPDX-License-Identifier: MIT
|
||||||
|
#
|
||||||
|
# Author: Jack Hartstein
|
||||||
|
|
||||||
|
config SHIELD_DUCKBOARD
|
||||||
|
def_bool $(shields_list_contains,duckboard)
|
27
app/boards/shields/duckboard/README.md
Normal file
27
app/boards/shields/duckboard/README.md
Normal file
|
@ -0,0 +1,27 @@
|
||||||
|
## ZMK Firmware adapted for duckboard/nice!nano combo
|
||||||
|
|
||||||
|
Last Updated: 31 Dec 2020
|
||||||
|
|
||||||
|
**_warning:_** this is beta firmware that is in its very early stages, many functions still need to be tested
|
||||||
|
|
||||||
|
Please message me on [discord](https://discord.gg/K3SJrtN5PJ) if you find any bugs
|
||||||
|
|
||||||
|
Credit for the ZMK Firmware to [The ZMK Contributors](https://zmkfirmware.dev/)
|
||||||
|
Hardware credit for the duckboard to [doodboard](https://doodboard.xyz/)
|
||||||
|
Hardware credit for the nice!nano to Nicell of [nice keyboards](https://nicekeyboards.com/)
|
||||||
|
|
||||||
|
Join the [ZMK Discord Server](https://zmkfirmware.dev/community/discord/invite) and the [doodboard Discord Server](https://discord.gg/UCEnxWk)
|
||||||
|
|
||||||
|
Flashing Instructions:
|
||||||
|
*download the duck.uf2 file
|
||||||
|
*plug in the nice!nano to your computer and put it in bootloader (short gnd+rst twice)
|
||||||
|
*the nano should appear as a storage device on your computer once in bootloader mode
|
||||||
|
*drag the duck.uf2 file into the nano storage and it should flash automatically
|
||||||
|
|
||||||
|
further flashing instructions in the [nice!nano docs](https://docs.nicekeyboards.com/#/nice!nano/getting_started?id=flashing-firmware-and-bootloaders)
|
||||||
|
|
||||||
|
*Default Layout:*
|
||||||
|
|
||||||
|
| Layer 0 (Default) | Layer 1 (Function) | Layer 2 (RGB and BT) |
|
||||||
|
------ | ------ | ------
|
||||||
|
 |  | 
|
35
app/boards/shields/duckboard/boards/nice_nano.overlay
Normal file
35
app/boards/shields/duckboard/boards/nice_nano.overlay
Normal file
|
@ -0,0 +1,35 @@
|
||||||
|
/* Copyright (c) 2020 The ZMK Contributors
|
||||||
|
* SPDX-License-Identifier: MIT
|
||||||
|
*
|
||||||
|
* Author: Jack Hartstein
|
||||||
|
* Last Edited: Dec 20 2020
|
||||||
|
*/
|
||||||
|
|
||||||
|
&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 = <8>; /* arbitrary; change at will */
|
||||||
|
spi-one-frame = <0x70>;
|
||||||
|
spi-zero-frame = <0x40>;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
/ {
|
||||||
|
chosen {
|
||||||
|
zmk,underglow = &led_strip;
|
||||||
|
};
|
||||||
|
};
|
38
app/boards/shields/duckboard/duckboard.conf
Normal file
38
app/boards/shields/duckboard/duckboard.conf
Normal file
|
@ -0,0 +1,38 @@
|
||||||
|
# Copyright (c) 2020 The ZMK Contributors
|
||||||
|
# SPDX-License-Identifier: MIT
|
||||||
|
#
|
||||||
|
# Author: Jack Hartstein
|
||||||
|
|
||||||
|
# Enable Encoders
|
||||||
|
CONFIG_EC11=y
|
||||||
|
CONFIG_EC11_TRIGGER_GLOBAL_THREAD=y
|
||||||
|
|
||||||
|
# Enable underglow
|
||||||
|
CONFIG_ZMK_RGB_UNDERGLOW=y
|
||||||
|
# Use the STRIP config specific to the LEDs you're using
|
||||||
|
CONFIG_WS2812_STRIP=y
|
||||||
|
|
||||||
|
# USB debugging settings
|
||||||
|
|
||||||
|
# Turn on logging, and set ZMK logging to debug output
|
||||||
|
CONFIG_LOG=y
|
||||||
|
CONFIG_ZMK_LOG_LEVEL_DBG=y
|
||||||
|
|
||||||
|
# Turn on USB CDC ACM device
|
||||||
|
CONFIG_USB=y
|
||||||
|
CONFIG_USB_DEVICE_STACK=y
|
||||||
|
CONFIG_USB_CDC_ACM=y
|
||||||
|
CONFIG_USB_CDC_ACM_RINGBUF_SIZE=1024
|
||||||
|
CONFIG_USB_CDC_ACM_DEVICE_NAME="CDC_ACM"
|
||||||
|
CONFIG_USB_CDC_ACM_DEVICE_COUNT=1
|
||||||
|
|
||||||
|
# Enable serial console
|
||||||
|
CONFIG_SERIAL=y
|
||||||
|
CONFIG_CONSOLE=y
|
||||||
|
CONFIG_UART_INTERRUPT_DRIVEN=y
|
||||||
|
CONFIG_UART_LINE_CTRL=y
|
||||||
|
|
||||||
|
# Enable USB UART, and set the console device
|
||||||
|
CONFIG_UART_CONSOLE=y
|
||||||
|
CONFIG_USB_UART_CONSOLE=y
|
||||||
|
CONFIG_UART_CONSOLE_ON_DEV_NAME="CDC_ACM_0"
|
19
app/boards/shields/duckboard/duckboard.dtsi
Normal file
19
app/boards/shields/duckboard/duckboard.dtsi
Normal file
|
@ -0,0 +1,19 @@
|
||||||
|
/* Copyright (c) 2020 The ZMK Contributors
|
||||||
|
* SPDX-License-Identitfier: MIT
|
||||||
|
*
|
||||||
|
* Author: Jack Hartstein
|
||||||
|
*/
|
||||||
|
/ {
|
||||||
|
left_encoder: encoder_left {
|
||||||
|
compatible = "alps,ec11";
|
||||||
|
label = "LEFT_ENCODER";
|
||||||
|
a-gpios = <&pro_micro_a 1 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
|
||||||
|
b-gpios = <&pro_micro_a 2 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
|
||||||
|
resolution = <2>;
|
||||||
|
};
|
||||||
|
|
||||||
|
sensors {
|
||||||
|
compatible = "zmk,keymap-sensors";
|
||||||
|
sensors = <&left_encoder>;
|
||||||
|
};
|
||||||
|
};
|
56
app/boards/shields/duckboard/duckboard.keymap
Normal file
56
app/boards/shields/duckboard/duckboard.keymap
Normal file
|
@ -0,0 +1,56 @@
|
||||||
|
/* Copyright (c) 2020 The ZMK Contributors
|
||||||
|
* SPDX-License-Identifier: MIT
|
||||||
|
*
|
||||||
|
* Author: Jack Hartstein
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include <behaviors.dtsi>
|
||||||
|
#include <dt-bindings/zmk/keys.h>
|
||||||
|
#include <dt-bindings/zmk/rgb.h>
|
||||||
|
#include <dt-bindings/zmk/bt.h>
|
||||||
|
#include <dt-bindings/zmk/ext_power.h>
|
||||||
|
|
||||||
|
#define DEFAULT 0
|
||||||
|
#define FUNC 1
|
||||||
|
#define RGB_BT 2
|
||||||
|
|
||||||
|
/ {
|
||||||
|
keymap {
|
||||||
|
compatible = "zmk,keymap";
|
||||||
|
|
||||||
|
default_layer {
|
||||||
|
bindings = <
|
||||||
|
&tog FUNC &kp KP_SLASH &kp KP_ASTERISK &kp KP_MINUS
|
||||||
|
&kp KP_NUMBER_7 &kp KP_NUMBER_8 &kp KP_NUMBER_9
|
||||||
|
&kp KP_NUMBER_4 &kp KP_NUMBER_5 &kp KP_NUMBER_6 &kp KP_PLUS
|
||||||
|
&kp K_MUTE &kp KP_NUMBER_1 &kp KP_NUMBER_2 &kp KP_NUMBER_3
|
||||||
|
&kp BACKSPACE &none &kp KP_NUMBER_0 &kp KP_DOT &kp KP_ENTER
|
||||||
|
>;
|
||||||
|
|
||||||
|
sensor-bindings = <&inc_dec_kp C_VOL_UP C_VOL_DN>;
|
||||||
|
};
|
||||||
|
|
||||||
|
func_layer {
|
||||||
|
bindings = <
|
||||||
|
&tog RGB_BT &trans &trans &trans
|
||||||
|
&kp HOME &kp UP &kp PG_UP
|
||||||
|
&kp LEFT &none &kp RIGHT &trans
|
||||||
|
&ext_power EP_TOG &kp END &kp DOWN &kp PG_DN
|
||||||
|
&none &none &kp INS &kp DEL &trans
|
||||||
|
>;
|
||||||
|
|
||||||
|
sensor-bindings = <&inc_dec_kp C_VOL_UP C_VOL_DN>;
|
||||||
|
};
|
||||||
|
|
||||||
|
rgb_bt_layer {
|
||||||
|
bindings = <
|
||||||
|
&tog DEFAULT &rgb_ug RGB_TOG &rgb_ug RGB_EFF &none
|
||||||
|
&rgb_ug RGB_HUI &rgb_ug RGB_SAI &rgb_ug RGB_BRI
|
||||||
|
&rgb_ug RGB_HUD &rgb_ug RGB_SAD &rgb_ug RGB_BRD &none
|
||||||
|
&bootloader &none &bt BT_CLR &bt BT_NXT
|
||||||
|
&none &none &none &bt BT_PRV &none
|
||||||
|
>;
|
||||||
|
sensor-bindings = <&inc_dec_kp C_VOL_UP C_VOL_DN>;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
41
app/boards/shields/duckboard/duckboard.overlay
Normal file
41
app/boards/shields/duckboard/duckboard.overlay
Normal file
|
@ -0,0 +1,41 @@
|
||||||
|
/*
|
||||||
|
* Copyright (c) 2020 The ZMK Contributors
|
||||||
|
* SPDX-License-Identifier: MIT
|
||||||
|
*
|
||||||
|
* Author: Jack Hartstein
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include "duckboard.dtsi"
|
||||||
|
|
||||||
|
/ {
|
||||||
|
|
||||||
|
chosen {
|
||||||
|
zmk,kscan = &kscan0;
|
||||||
|
};
|
||||||
|
|
||||||
|
kscan0: kscan_0 {
|
||||||
|
compatible = "zmk,kscan-gpio-matrix";
|
||||||
|
label = "KSCAN";
|
||||||
|
diode-direction = "col2row";
|
||||||
|
|
||||||
|
row-gpios
|
||||||
|
= <&pro_micro_d 5 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
|
||||||
|
, <&pro_micro_d 6 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
|
||||||
|
, <&pro_micro_d 7 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
|
||||||
|
, <&pro_micro_d 8 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
|
||||||
|
, <&pro_micro_d 9 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
|
||||||
|
;
|
||||||
|
|
||||||
|
col-gpios
|
||||||
|
= <&pro_micro_a 0 GPIO_ACTIVE_HIGH>
|
||||||
|
, <&pro_micro_d 15 GPIO_ACTIVE_HIGH>
|
||||||
|
, <&pro_micro_d 14 GPIO_ACTIVE_HIGH>
|
||||||
|
, <&pro_micro_d 16 GPIO_ACTIVE_HIGH>
|
||||||
|
, <&pro_micro_d 10 GPIO_ACTIVE_HIGH>
|
||||||
|
;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
&left_encoder {
|
||||||
|
status = "okay";
|
||||||
|
};
|
BIN
app/boards/shields/duckboard/img/layer0.JPG
Normal file
BIN
app/boards/shields/duckboard/img/layer0.JPG
Normal file
Binary file not shown.
After Width: | Height: | Size: 35 KiB |
BIN
app/boards/shields/duckboard/img/layer1.JPG
Normal file
BIN
app/boards/shields/duckboard/img/layer1.JPG
Normal file
Binary file not shown.
After Width: | Height: | Size: 36 KiB |
BIN
app/boards/shields/duckboard/img/layer2.JPG
Normal file
BIN
app/boards/shields/duckboard/img/layer2.JPG
Normal file
Binary file not shown.
After Width: | Height: | Size: 41 KiB |
Loading…
Add table
Reference in a new issue