Add streamcheap

This commit is contained in:
Luigi311 2022-02-03 14:08:23 -07:00
parent f946dc6893
commit 5d4d583f6e
5 changed files with 105 additions and 0 deletions

View file

@ -0,0 +1,7 @@
if SHIELD_STREAM_CHEAP
config ZMK_KEYBOARD_NAME
default "Stream Cheap"
endif

View file

@ -0,0 +1,5 @@
# Copyright (c) 2022 Luigi311
# SPDX-License-Identifier: MIT
config SHIELD_STREAM_CHEAP
def_bool $(shields_list_contains,stream_cheap)

View file

@ -0,0 +1,14 @@
# [Stream Cheap 2x4 Macropad](https://www.partsnotincluded.com/diy-stream-deck-mini-macro-keyboard/)
A small 8-key macropad as a cheap alternative to the stream deck.
## Features
- Direct GPIO wiring, no GPIO matrix at all.
- Simple PCB design for hotswap switches.
## Build
<https://www.thingiverse.com/thing:5231094>
west build -p -b nice_nano_v2 -- -DSHIELD=stream_cheap_2x4

View file

@ -0,0 +1,48 @@
/*
* Copyright (c) 2021 Luigi311
*
* SPDX-License-Identifier: MIT
*/
#include <behaviors.dtsi>
#include <dt-bindings/zmk/keys.h>
#include <dt-bindings/zmk/bt.h>
#define DEFAULT 0
#define LOWER 1
/ {
combos {
compatible = "zmk,combos";
combo_bootloader {
timeout-ms = <100>;
key-positions = <2 3 6 7>;
bindings = <&bootloader>;
};
combo_reboot {
timeout-ms = <100>;
key-positions = <0 1 4 5>;
bindings = <&reset>;
};
};
};
/ {
keymap0: keymap {
compatible = "zmk,keymap";
default_layer {
bindings = <
&kp F13 &kp F14 &kp F15 &kp F16
&kp F17 &kp F18 &kp F19 &mo LOWER
>;
};
lower_layer {
bindings = <
&kp F20 &kp F21 &kp F22 &kp F23
&bt BT_SEL 0 &bt BT_SEL 1 &bt BT_CLR &trans
>;
};
};
};

View file

@ -0,0 +1,31 @@
/*
* Copyright (c) 2021 Luigi311
*
* SPDX-License-Identifier: MIT
*/
/ {
chosen {
zmk,kscan = &kscan0;
};
kscan0: kscan_0 {
compatible = "zmk,kscan-gpio-direct";
label = "KSCAN";
input-gpios
= <&pro_micro 2 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>
, <&pro_micro 3 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>
, <&pro_micro 8 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>
, <&pro_micro 9 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>
, <&pro_micro 4 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>
, <&pro_micro 5 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>
, <&pro_micro 6 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>
, <&pro_micro 7 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>
;
};
};