Skip to content

Commit

Permalink
Add akohekohe shield
Browse files Browse the repository at this point in the history
  • Loading branch information
englmaxi committed Aug 18, 2024
1 parent 7e04495 commit bc4fe5d
Show file tree
Hide file tree
Showing 12 changed files with 398 additions and 72 deletions.
11 changes: 9 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,17 +1,24 @@
# zmk-config

<details>
<summary><a href="https://github.com/grassfedreeve/akohekohe">ʻākohekohe</a> (26 keys), <i><b>click here to see the keymap!</i></b></summary>
<img src="keymap-drawer/akohekohe.svg" >

_(keymap image generated with [caksoylar/keymap-drawer](https://github.com/caksoylar/keymap-drawer))_
</details>

<details>
<summary><a href="https://github.com/AlaaSaadAbdo/Rommana">Rommana</a> (30 keys), <i><b>click here to see the keymap!</i></b></summary>
<img src="keymap-drawer/rommana.svg" >

_(keymap image generated by [caksoylar/keymap-drawer](https://github.com/caksoylar/keymap-drawer))_
_(keymap image generated with [caksoylar/keymap-drawer](https://github.com/caksoylar/keymap-drawer))_
</details>

<details>
<summary><a href="https://github.com/davidphilipbarr/Sweep">Sweep</a> (34 keys), <i><b>click here to see the keymap!</i></b></summary>
<img src="keymap-drawer/sweep.svg" >

_(keymap image generated by [caksoylar/keymap-drawer](https://github.com/caksoylar/keymap-drawer))_
_(keymap image generated with [caksoylar/keymap-drawer](https://github.com/caksoylar/keymap-drawer))_
</details>

---
Expand Down
9 changes: 9 additions & 0 deletions boards/shields/akohekohe/Kconfig.defconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Copyright (c) 2022 The ZMK Contributors
# SPDX-License-Identifier: MIT

if SHIELD_AKOHEKOHE

config ZMK_KEYBOARD_NAME
default "akohekohe"

endif
5 changes: 5 additions & 0 deletions boards/shields/akohekohe/Kconfig.shield
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Copyright (c) 2022 The ZMK Contributors
# SPDX-License-Identifier: MIT

config SHIELD_AKOHEKOHE
def_bool $(shields_list_contains,akohekohe)
10 changes: 10 additions & 0 deletions boards/shields/akohekohe/akohekohe.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# 3 profiles
CONFIG_BT_MAX_CONN=3
CONFIG_BT_MAX_PAIRED=3

# combo config
CONFIG_ZMK_COMBO_MAX_COMBOS_PER_KEY=7

# battery reporting
CONFIG_ZMK_SPLIT_BLE_CENTRAL_BATTERY_LEVEL_FETCHING=y
CONFIG_ZMK_SPLIT_BLE_CENTRAL_BATTERY_LEVEL_PROXY=y
41 changes: 41 additions & 0 deletions boards/shields/akohekohe/akohekohe.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
{
"id": "akohekohe",
"name": "akohekohe",
"layouts": {
"default_layout": {
"name": "default_layout",
"layout": [
{ "row": 0, "col": 1, "x": 1.772, "y": 0.136, "r": 19, "rx": 2.272, "ry": 0.636 },
{ "row": 0, "col": 2, "x": 2.94, "y": 0.293, "r": 22, "rx": 3.44, "ry": 0.793 },
{ "row": 0, "col": 3, "x": 3.802, "y": 0.939, "r": 22, "rx": 4.302, "ry": 1.439 },
{ "row": 0, "col": 4, "x": 4.573, "y": 1.824, "r": 22, "rx": 5.073, "ry": 2.324 },
{ "row": 0, "col": 5, "x": 6.452, "y": 1.824, "r": -22, "rx": 6.952, "ry": 2.324 },
{ "row": 0, "col": 7, "x": 7.224, "y": 0.939, "r": -22, "rx": 7.724, "ry": 1.439 },
{ "row": 0, "col": 9, "x": 8.085, "y": 0.293, "r": -22, "rx": 8.585, "ry": 0.793 },
{ "row": 0, "col": 10, "x": 9.254, "y": 0.136, "r": -19, "rx": 9.754, "ry": 0.636 },

{ "row": 1, "col": 0, "x": 0.106, "y": 1.759, "r": 14, "rx": 0.606, "ry": 2.259 },
{ "row": 1, "col": 1, "x": 1.456, "y": 1.109, "r": 19, "rx": 1.956, "ry": 1.609 },
{ "row": 1, "col": 2, "x": 2.576, "y": 1.247, "r": 22, "rx": 3.076, "ry": 1.747 },
{ "row": 1, "col": 3, "x": 3.438, "y": 1.894, "r": 22, "rx": 3.938, "ry": 2.394 },
{ "row": 1, "col": 4, "x": 4.209, "y": 2.778, "r": 22, "rx": 4.709, "ry": 3.278 },
{ "row": 1, "col": 5, "x": 6.817, "y": 2.778, "r": -22, "rx": 7.317, "ry": 3.278 },
{ "row": 1, "col": 7, "x": 7.587, "y": 1.894, "r": -22, "rx": 8.087, "ry": 2.394 },
{ "row": 1, "col": 9, "x": 8.449, "y": 1.247, "r": -22, "rx": 8.949, "ry": 1.747 },
{ "row": 1, "col": 10, "x": 9.569, "y": 1.109, "r": -19, "rx": 10.069, "ry": 1.609 },
{ "row": 1, "col": 11, "x": 10.928, "y": 1.759, "r": -14, "rx": 11.428, "ry": 2.259 },

{ "row": 2, "col": 1, "x": 1.139, "y": 2.082, "r": 19, "rx": 1.639, "ry": 2.582 },
{ "row": 2, "col": 2, "x": 2.212, "y": 2.202, "r": 22, "rx": 2.712, "ry": 2.702 },
{ "row": 2, "col": 3, "x": 3.074, "y": 2.848, "r": 22, "rx": 3.574, "ry": 3.348 },
{ "row": 2, "col": 6, "x": 7.952, "y": 2.848, "r": -22, "rx": 8.452, "ry": 3.348 },
{ "row": 2, "col": 7, "x": 8.814, "y": 2.202, "r": -22, "rx": 9.314, "ry": 2.702 },
{ "row": 2, "col": 8, "x": 9.886, "y": 2.082, "r": -19, "rx": 10.386, "ry": 2.582 },

{ "row": 3, "col": 4, "x": 3.673, "y": 4.183, "r": 37, "rx": 4.173, "ry": 4.683, "w": 1.5 },
{ "row": 3, "col": 9, "x": 6.852, "y": 4.183, "r": -37, "rx": 7.852, "ry": 4.683, "w": 1.5 }
]
}
},
"sensors": []
}
97 changes: 97 additions & 0 deletions boards/shields/akohekohe/akohekohe.keymap
Original file line number Diff line number Diff line change
@@ -0,0 +1,97 @@
/*
* Copyright (c) 2022 The ZMK Contributors
*
* SPDX-License-Identifier: MIT
*/

#include <behaviors.dtsi>
#include <dt-bindings/zmk/keys.h>

#define DEF_L 0
#define NAV_L 1
#define NUM_L 2
#define SYM_L 3

// Using layer taps on thumbs, having quick tap as well helps w/ repeating space/backspace
&lt { quick-tap-ms = <200>; };

/ {
behaviors {
hm: homerow_mods {
compatible = "zmk,behavior-hold-tap";
#binding-cells = <2>;
tapping-term-ms = <225>;
flavor = "tap-preferred";
bindings = <&kp>, <&kp>;
};
};

combos {
compatible = "zmk,combos";
combo_z {
timeout-ms = <50>;
key-positions = <20 21>;
bindings = <&kp Z>;
};
combo_b {
timeout-ms = <50>;
key-positions = <21 22>;
bindings = <&kp B>;
};

combo_y {
timeout-ms = <50>;
key-positions = <23 24>;
bindings = <&kp Y>;
};

combo_slash {
timeout-ms = <50>;
key-positions = <24 25>;
bindings = <&kp SLASH>;
};
};

keymap {
compatible = "zmk,keymap";

default_layer {
bindings = <
&kp W &kp E &kp R &kp T &kp H &kp U &kp I &kp O
&hm LGUI A &hm LALT S &hm LCTRL D &hm LSHFT F &kp G &kp N &hm RSHFT J &hm RCTRL K &hm LALT L &hm RGUI QUOT
&kp X &kp C &kp V &kp M &kp COMMA &kp DOT
&kp RET &lt NUM_L SPACE
>;
};

nav_layer {
display-name = "Nav";
bindings = <
&trans &trans &trans &trans &trans &kp HOME &kp UARW &kp PG_UP
&trans &trans &trans &trans &trans &trans &kp LARW &kp DARW &kp RARW &trans
&trans &trans &trans &kp END &trans &kp PG_DN
&trans &kp ESC
>;
};

num_layer {
display-name = "Num";
bindings = <
&kp N7 &kp N8 &kp N9 &kp RBKT &trans &trans &trans &trans
&kp SEMI &kp N4 &kp N5 &kp N6 &kp EQUAL &trans &trans &trans &trans &trans
&kp N1 &kp N2 &kp N3 &trans &trans &trans
&kp MINUS &trans
>;
};

sym_layer {
display-name = "Sym";
bindings = <
&kp LS(N7) &kp LS(N8) &kp LS(N9) &kp RBRC &trans &trans &trans &trans
&kp COLON &kp LS(N4) &kp LS(N5) &kp LS(N6) &kp PLUS &trans &trans &trans &trans &trans
&kp LS(N1) &kp LS(N2) &kp LS(N3) &trans &trans &trans
&kp UNDER &trans
>;
};
};
};
56 changes: 56 additions & 0 deletions boards/shields/akohekohe/akohekohe.overlay
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
/*
* Copyright (c) 2022 The ZMK Contributors
*
* SPDX-License-Identifier: MIT
*/

#include <dt-bindings/zmk/matrix_transform.h>
#include <physical_layouts.dtsi>

/ {
chosen {
zmk,kscan = &kscan0;
zmk,matrix-transform = &default_transform;
/delete-property/ zephyr,console;
/delete-property/ zephyr,shell-uart;
};

default_transform: keymap_transform_0 {
compatible = "zmk,matrix-transform";
columns = <7>;
rows = <6>;
map = <
RC(1,0) RC(0,1) RC(1,1) RC(0,2) RC(1,2) RC(0,3) RC(1,3) RC(0,4)
RC(2,0) RC(3,0) RC(2,1) RC(3,1) RC(2,2) RC(3,2) RC(2,3) RC(3,3) RC(2,4) RC(3,4)
RC(4,0) RC(5,0) RC(4,1) RC(5,2) RC(4,3) RC(5,3)
RC(4,2) RC(5,4)
>;
};

kscan0: kscan_0 {
compatible = "zmk,kscan-gpio-matrix";
diode-direction = "row2col";
wakeup-source;

col-gpios
= <&xiao_d 6 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
, <&xiao_d 7 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
, <&xiao_d 8 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
, <&xiao_d 9 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
, <&xiao_d 10 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
;

row-gpios
= <&xiao_d 0 GPIO_ACTIVE_HIGH>
, <&xiao_d 1 GPIO_ACTIVE_HIGH>
, <&xiao_d 2 GPIO_ACTIVE_HIGH>
, <&xiao_d 3 GPIO_ACTIVE_HIGH>
, <&xiao_d 4 GPIO_ACTIVE_HIGH>
, <&xiao_d 5 GPIO_ACTIVE_HIGH>
;
};

};

&xiao_spi { status = "disabled"; };
&xiao_serial { status = "disabled"; };
8 changes: 8 additions & 0 deletions boards/shields/akohekohe/akohekohe.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
file_format: "1"
id: "akohekohe"
name: "akohekohe"
type: shield
url: https://github.com/grassfedreeve/akohekohe
requires: [seeed_xiao]
features:
- keys
10 changes: 10 additions & 0 deletions build.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,16 @@
# This file generates the GitHub Actions matrix
---
include:
# akohekohe
- board: seeeduino_xiao_ble
shield: akohekohe rgbled_adapter

- board: seeeduino_xiao_ble
shield: akohekohe rgbled_adapter
snippet: zmk-usb-logging
cmake-args: -DCONFIG_LOG_PROCESS_THREAD_STARTUP_DELAY_MS=8000
artifact-name: akohekohe_with_logging

# rommana
- board: seeeduino_xiao_ble
shield: rommana_dongle dongle_display
Expand Down
3 changes: 3 additions & 0 deletions config/akohekohe.keymap
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#define KEYS_26

#include "keymap/keymap.dtsi"
Loading

0 comments on commit bc4fe5d

Please sign in to comment.