-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 21cf4e5
Showing
25 changed files
with
1,243 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
on: [push, pull_request, workflow_dispatch] | ||
|
||
jobs: | ||
build: | ||
uses: zmkfirmware/zmk/.github/workflows/build-user-config.yml@main |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
if SHIELD_CHARYBDIS_DONGLE | ||
|
||
config ZMK_KEYBOARD_NAME | ||
default "Charybdis" | ||
|
||
config ZMK_SPLIT_ROLE_CENTRAL | ||
default y | ||
|
||
endif | ||
|
||
if SHIELD_CHARYBDIS_DONGLE || SHIELD_CHARYBDIS_LEFT || SHIELD_CHARYBDIS_RIGHT | ||
|
||
config ZMK_SPLIT | ||
default y | ||
|
||
endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
config SHIELD_CHARYBDIS_DONGLE | ||
def_bool $(shields_list_contains,charybdis_dongle) | ||
|
||
config SHIELD_CHARYBDIS_LEFT | ||
def_bool $(shields_list_contains,charybdis_left) | ||
|
||
config SHIELD_CHARYBDIS_RIGHT | ||
def_bool $(shields_list_contains,charybdis_right) |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,161 @@ | ||
#include <dt-bindings/zmk/matrix_transform.h> | ||
#include <physical_layouts.dtsi> | ||
|
||
/ { | ||
chosen { | ||
zmk,kscan = &kscan0; | ||
zmk,physical-layout = &charybdis_6col_layout; | ||
}; | ||
|
||
default_transform: keymap_transform_0 { | ||
compatible = "zmk,matrix-transform"; | ||
columns = <12>; | ||
rows = <4>; | ||
|
||
map = < | ||
RC(0,0) RC(0,1) RC(0,2) RC(0,3) RC(0,4) RC(0,5) RC(0,11) RC(0,10) RC(0,9) RC(0,8) RC(0,7) RC(0,6) | ||
RC(1,0) RC(1,1) RC(1,2) RC(1,3) RC(1,4) RC(1,5) RC(1,11) RC(1,10) RC(1,9) RC(1,8) RC(1,7) RC(1,6) | ||
RC(2,0) RC(2,1) RC(2,2) RC(2,3) RC(2,4) RC(2,5) RC(2,11) RC(2,10) RC(2,9) RC(2,8) RC(2,7) RC(2,6) | ||
RC(3,3) RC(3,4) RC(3,1) RC(3,7) RC(3,9) | ||
>; | ||
}; | ||
|
||
five_column_transform: keymap_transform_1 { | ||
compatible = "zmk,matrix-transform"; | ||
columns = <10>; | ||
rows = <4>; | ||
|
||
map = < | ||
RC(0,1) RC(0,2) RC(0,3) RC(0,4) RC(0,5) RC(0,10) RC(0,9) RC(0,8) RC(0,7) RC(0,6) | ||
RC(1,1) RC(1,2) RC(1,3) RC(1,4) RC(1,5) RC(1,10) RC(1,9) RC(1,8) RC(1,7) RC(1,6) | ||
RC(2,1) RC(2,2) RC(2,3) RC(2,4) RC(2,5) RC(2,10) RC(2,9) RC(2,8) RC(2,7) RC(2,6) | ||
RC(3,3) RC(3,4) RC(3,1) RC(3,6) RC(3,8) | ||
>; | ||
}; | ||
|
||
kscan0: kscan { | ||
diode-direction = "row2col"; | ||
}; | ||
|
||
charybdis_6col_layout: charybdis_6col_layout { | ||
compatible = "zmk,physical-layout"; | ||
display-name = "6-column"; | ||
|
||
transform = <&default_transform>; | ||
|
||
keys // w h x y rot rx ry | ||
= <&key_physical_attrs 100 100 0 57 0 0 0> | ||
, <&key_physical_attrs 100 100 100 57 0 0 0> | ||
, <&key_physical_attrs 100 100 200 12 0 0 0> | ||
, <&key_physical_attrs 100 100 300 0 0 0 0> | ||
, <&key_physical_attrs 100 100 400 12 0 0 0> | ||
, <&key_physical_attrs 100 100 500 12 0 0 0> | ||
, <&key_physical_attrs 100 100 900 12 0 0 0> | ||
, <&key_physical_attrs 100 100 1000 12 0 0 0> | ||
, <&key_physical_attrs 100 100 1100 0 0 0 0> | ||
, <&key_physical_attrs 100 100 1200 12 0 0 0> | ||
, <&key_physical_attrs 100 100 1300 57 0 0 0> | ||
, <&key_physical_attrs 100 100 1400 57 0 0 0> | ||
, <&key_physical_attrs 100 100 0 157 0 0 0> | ||
, <&key_physical_attrs 100 100 100 157 0 0 0> | ||
, <&key_physical_attrs 100 100 200 112 0 0 0> | ||
, <&key_physical_attrs 100 100 300 100 0 0 0> | ||
, <&key_physical_attrs 100 100 400 112 0 0 0> | ||
, <&key_physical_attrs 100 100 500 112 0 0 0> | ||
, <&key_physical_attrs 100 100 900 112 0 0 0> | ||
, <&key_physical_attrs 100 100 1000 112 0 0 0> | ||
, <&key_physical_attrs 100 100 1100 100 0 0 0> | ||
, <&key_physical_attrs 100 100 1200 112 0 0 0> | ||
, <&key_physical_attrs 100 100 1300 157 0 0 0> | ||
, <&key_physical_attrs 100 100 1400 157 0 0 0> | ||
, <&key_physical_attrs 100 100 0 257 0 0 0> | ||
, <&key_physical_attrs 100 100 100 257 0 0 0> | ||
, <&key_physical_attrs 100 100 200 212 0 0 0> | ||
, <&key_physical_attrs 100 100 300 200 0 0 0> | ||
, <&key_physical_attrs 100 100 400 212 0 0 0> | ||
, <&key_physical_attrs 100 100 500 212 0 0 0> | ||
, <&key_physical_attrs 100 100 900 212 0 0 0> | ||
, <&key_physical_attrs 100 100 1000 212 0 0 0> | ||
, <&key_physical_attrs 100 100 1100 200 0 0 0> | ||
, <&key_physical_attrs 100 100 1200 212 0 0 0> | ||
, <&key_physical_attrs 100 100 1300 257 0 0 0> | ||
, <&key_physical_attrs 100 100 1400 257 0 0 0> | ||
, <&key_physical_attrs 100 100 348 312 0 0 0> | ||
, <&key_physical_attrs 100 100 348 312 1500 398 789> | ||
, <&key_physical_attrs 100 100 348 312 3000 398 789> | ||
, <&key_physical_attrs 100 100 1052 312 (-3000) 1102 789> | ||
, <&key_physical_attrs 100 100 1052 312 (-1500) 1102 789> | ||
; | ||
}; | ||
|
||
charybdis_5col_layout: charybdis_5col_layout{ | ||
compatible = "zmk,physical-layout"; | ||
display-name = "5-column"; | ||
|
||
transform = <&five_column_transform>; | ||
|
||
keys // w h x y rot rx ry | ||
= <&key_physical_attrs 100 100 0 57 0 0 0> | ||
, <&key_physical_attrs 100 100 100 12 0 0 0> | ||
, <&key_physical_attrs 100 100 200 0 0 0 0> | ||
, <&key_physical_attrs 100 100 300 12 0 0 0> | ||
, <&key_physical_attrs 100 100 400 12 0 0 0> | ||
, <&key_physical_attrs 100 100 800 12 0 0 0> | ||
, <&key_physical_attrs 100 100 900 12 0 0 0> | ||
, <&key_physical_attrs 100 100 1000 0 0 0 0> | ||
, <&key_physical_attrs 100 100 1100 12 0 0 0> | ||
, <&key_physical_attrs 100 100 1200 57 0 0 0> | ||
, <&key_physical_attrs 100 100 0 157 0 0 0> | ||
, <&key_physical_attrs 100 100 100 112 0 0 0> | ||
, <&key_physical_attrs 100 100 200 100 0 0 0> | ||
, <&key_physical_attrs 100 100 300 112 0 0 0> | ||
, <&key_physical_attrs 100 100 400 112 0 0 0> | ||
, <&key_physical_attrs 100 100 800 112 0 0 0> | ||
, <&key_physical_attrs 100 100 900 112 0 0 0> | ||
, <&key_physical_attrs 100 100 1000 100 0 0 0> | ||
, <&key_physical_attrs 100 100 1100 112 0 0 0> | ||
, <&key_physical_attrs 100 100 1200 157 0 0 0> | ||
, <&key_physical_attrs 100 100 0 257 0 0 0> | ||
, <&key_physical_attrs 100 100 100 212 0 0 0> | ||
, <&key_physical_attrs 100 100 200 200 0 0 0> | ||
, <&key_physical_attrs 100 100 300 212 0 0 0> | ||
, <&key_physical_attrs 100 100 400 212 0 0 0> | ||
, <&key_physical_attrs 100 100 800 212 0 0 0> | ||
, <&key_physical_attrs 100 100 900 212 0 0 0> | ||
, <&key_physical_attrs 100 100 1000 200 0 0 0> | ||
, <&key_physical_attrs 100 100 1100 212 0 0 0> | ||
, <&key_physical_attrs 100 100 1200 257 0 0 0> | ||
, <&key_physical_attrs 100 100 248 312 0 0 0> | ||
, <&key_physical_attrs 100 100 248 312 1500 298 789> | ||
, <&key_physical_attrs 100 100 248 312 3000 298 789> | ||
, <&key_physical_attrs 100 100 952 312 (-3000) 1002 789> | ||
, <&key_physical_attrs 100 100 952 312 (-1500) 1002 789> | ||
; | ||
}; | ||
|
||
charybdis_position_map { | ||
compatible = "zmk,physical-layout-position-map"; | ||
|
||
complete; | ||
|
||
twelve { | ||
physical-layout = <&charybdis_6col_layout>; | ||
positions | ||
= < 0 1 2 3 4 5 6 7 8 9 10 11 > | ||
, <12 13 14 15 16 17 18 19 20 21 22 23 > | ||
, <24 25 26 27 28 29 30 31 32 33 34 35 > | ||
, < 36 37 38 39 40 > | ||
; | ||
}; | ||
|
||
ten { | ||
physical-layout = <&charybdis_5col_layout>; | ||
positions | ||
= <35 0 1 2 3 4 5 6 7 8 9 36> | ||
, <37 10 11 12 13 14 15 16 17 18 19 38> | ||
, <39 20 21 22 23 24 25 26 27 28 29 40> | ||
, < 30 31 32 33 34 > | ||
; | ||
}; | ||
}; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
#include <behaviors.dtsi> | ||
#include <dt-bindings/zmk/keys.h> | ||
#include <dt-bindings/zmk/bt.h> | ||
#include <dt-bindings/zmk/pointing.h> | ||
|
||
/ { | ||
trackball_listener { | ||
compatible = "zmk,input-listener"; | ||
device = <&vtrackball>; | ||
}; | ||
|
||
keymap { | ||
compatible = "zmk,keymap"; | ||
|
||
Base { | ||
bindings = < | ||
&kp LGUI &kp Q &kp W &kp E &kp R &kp T &kp Y &kp U &kp I &kp O &kp P &kp RGUI | ||
&kp RCTRL &kp A &kp S &kp D &kp F &kp G &kp H &kp J &kp K &kp L &kp SEMI &kp RCTRL | ||
&kp LSHIFT &kp Z &kp X &kp C &kp V &kp B &kp N &kp M &kp COMMA &kp DOT < 7 SLASH &kp RSHIFT | ||
&kp BSPC &kp SPACE &mo 1 &mo 2 &kp RET | ||
>; | ||
}; | ||
|
||
Lower { | ||
bindings = < | ||
&none &none &kp C_NEXT &kp C_PP &kp C_PREV &none &kp LBKT &kp N7 &kp N8 &kp N9 &kp RBKT &none | ||
&none &kp LGUI &kp LALT &kp LCTRL &kp LSHIFT &none &kp KP_PLUS &kp N4 &kp N5 &kp N6 &kp KP_MINUS &none | ||
&none &none &none &none &none &bootloader &kp KP_MULTIPLY &kp N1 &kp N2 &kp N3 &kp KP_SLASH &none | ||
&none &none &trans &none &trans | ||
>; | ||
}; | ||
|
||
Raise { | ||
bindings = < | ||
&none &none &none &none &none &none &none &kp C_VOL_UP &kp C_MUTE &kp C_VOL_DN &none &none | ||
&none &kp LEFT &kp UP &kp DOWN &kp RIGHT &none &none &kp RSHIFT &kp RCTRL &kp RALT &kp RGUI &none | ||
&none &kp HOME &kp PG_UP &kp PG_DN &kp END &none &none &none &none &none &none &none | ||
&trans &trans &none &trans &none | ||
>; | ||
}; | ||
|
||
Pointer { | ||
bindings = < | ||
&bootloader &none &none &none &none &none &none &none &none &none &none &bootloader | ||
&none &kp LGUI &kp LALT &kp LCTRL &kp LSHIFT &none &none &kp RSHIFT &kp RCTRL &kp RALT &kp RGUI &none | ||
&none &none &none &none &none &none &none &none &none &none &none &none | ||
&mkp MB2 &mkp MB1 &mkp MB3 &mkp MB3 &mkp MB1 | ||
>; | ||
}; | ||
}; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
file_format: "1" | ||
id: charybdis | ||
name: Charybdis | ||
type: shield | ||
url: https://github.com/bastardkb/charybdis/ | ||
requires: [pro_micro] | ||
features: | ||
- keys | ||
- pointer | ||
siblings: | ||
- charybdis_dongle | ||
- charybdis_left | ||
- charybdis_right |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
#define INPUT_EV_KEY 0x01 /**< Key event */ | ||
#define INPUT_EV_REL 0x02 /**< Relative coordinate event */ | ||
#define INPUT_EV_ABS 0x03 /**< Absolute coordinate event */ | ||
#define INPUT_EV_MSC 0x04 /**< Miscellaneous event */ | ||
#define INPUT_EV_VENDOR_START 0xf0 /**< Vendor specific event start */ | ||
#define INPUT_EV_VENDOR_STOP 0xff /**< Vendor specific event stop */ | ||
|
||
#define INPUT_REL_X 0x00 /**< Relative X coordinate */ | ||
#define INPUT_REL_Y 0x01 /**< Relative Y coordinate */ | ||
#define INPUT_REL_WHEEL 0x08 /**< Relative wheel coordinate */ | ||
#define INPUT_REL_HWHEEL 0x06 /**< Relative horizontal wheel coordinate */ | ||
#define INPUT_REL_MISC 0x09 /**< Relative misc coordinate */ | ||
|
||
&pinctrl { | ||
spi0_default: spi0_default { | ||
group1 { | ||
psels = <NRF_PSEL(SPIM_SCK, 0, 8)>, | ||
<NRF_PSEL(SPIM_MOSI, 0, 17)>, | ||
<NRF_PSEL(SPIM_MISO, 0, 17)>; | ||
}; | ||
}; | ||
|
||
spi0_sleep: spi0_sleep { | ||
group1 { | ||
psels = <NRF_PSEL(SPIM_SCK, 0, 8)>, | ||
<NRF_PSEL(SPIM_MOSI, 0, 17)>, | ||
<NRF_PSEL(SPIM_MISO, 0, 17)>; | ||
low-power-enable; | ||
}; | ||
}; | ||
}; | ||
|
||
&spi0 { | ||
status = "okay"; | ||
compatible = "nordic,nrf-spim"; | ||
pinctrl-0 = <&spi0_default>; | ||
pinctrl-1 = <&spi0_sleep>; | ||
pinctrl-names = "default", "sleep"; | ||
cs-gpios = <&gpio0 20 GPIO_ACTIVE_LOW>; | ||
|
||
trackball: trackball@0 { | ||
status = "okay"; | ||
compatible = "pixart,pmw3610"; | ||
reg = <0>; | ||
spi-max-frequency = <2000000>; | ||
irq-gpios = <&gpio0 6 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; | ||
cpi = <800>; | ||
evt-type = <INPUT_EV_REL>; | ||
x-input-code = <INPUT_REL_X>; | ||
y-input-code = <INPUT_REL_Y>; | ||
}; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
CONFIG_ZMK_SPLIT_BLE_CENTRAL_PERIPHERALS=2 | ||
CONFIG_BT_CTLR_TX_PWR_PLUS_8=y | ||
|
||
CONFIG_INPUT=y | ||
CONFIG_ZMK_POINTING=y | ||
CONFIG_ZMK_POINTING_SMOOTH_SCROLLING=y | ||
|
||
CONFIG_ZMK_SLEEP=n |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
#include "charybdis.dtsi" | ||
#include "split_input_common.dtsi" | ||
/ { | ||
chosen { | ||
zmk,kscan = &mock_kscan; | ||
}; | ||
|
||
mock_kscan: kscan_1 { | ||
compatible = "zmk,kscan-mock"; | ||
columns = <0>; | ||
rows = <0>; | ||
events = <0>; | ||
}; | ||
}; | ||
|
||
&trackball_listener { | ||
status = "okay"; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
CONFIG_INPUT=y |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
#include "charybdis.dtsi" | ||
|
||
&kscan0 { | ||
compatible = "zmk,kscan-gpio-matrix"; | ||
|
||
col-gpios | ||
= <&pro_micro 19 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)> | ||
, <&pro_micro 20 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)> | ||
, <&pro_micro 10 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)> | ||
, <&pro_micro 6 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)> | ||
, <&pro_micro 7 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)> | ||
, <&pro_micro 8 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)> | ||
; | ||
|
||
row-gpios | ||
= <&pro_micro 18 GPIO_ACTIVE_HIGH> | ||
, <&pro_micro 5 GPIO_ACTIVE_HIGH> | ||
, <&pro_micro 4 GPIO_ACTIVE_HIGH> | ||
, <&pro_micro 9 GPIO_ACTIVE_HIGH> | ||
; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
CONFIG_SPI=y | ||
CONFIG_INPUT=y | ||
CONFIG_PMW3610=y | ||
CONFIG_ZMK_POINTING=y | ||
CONFIG_ZMK_EXT_POWER=y | ||
|
||
CONFIG_PMW3610_SWAP_XY=y | ||
CONFIG_PMW3610_INVERT_X=y | ||
CONFIG_PMW3610_INVERT_Y=y | ||
|
||
CONFIG_PMW3610_REST1_SAMPLE_TIME_MS=20 | ||
CONFIG_PMW3610_REST2_SAMPLE_TIME_MS=200 | ||
CONFIG_PMW3610_REST3_SAMPLE_TIME_MS=300 | ||
CONFIG_PMW3610_RUN_DOWNSHIFT_TIME_MS=500 | ||
CONFIG_PMW3610_REST1_DOWNSHIFT_TIME_MS=3000 | ||
CONFIG_PMW3610_REST2_DOWNSHIFT_TIME_MS=30000 | ||
|
||
CONFIG_PMW3610_SMART_ALGORITHM=y |
Oops, something went wrong.