Skip to content

Commit

Permalink
another encoder attempt
Browse files Browse the repository at this point in the history
  • Loading branch information
charludo committed Oct 15, 2023
1 parent bed52fe commit 0d0fb42
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 7 deletions.
13 changes: 13 additions & 0 deletions config/arkenswoop.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
CONFIG_EC11=y
CONFIG_EC11_TRIGGER_GLOBAL_THREAD=y

CONFIG_ZMK_MOUSE=y
CONFIG_ZMK_MOUSE_TICK_DURATION=8
CONFIG_ZMK_MOUSE_WORK_QUEUE_DEDICATED=y

CONFIG_ZMK_SLEEP=y
CONFIG_ZMK_IDLE_SLEEP_TIMEOUT=1800000

CONFIG_BT_CTLR_TX_PWR_PLUS_8=y

CONFIG_ZMK_KEYBOARD_NAME="Arkenswoop"
13 changes: 7 additions & 6 deletions config/boards/shields/arkenswoop/arkenswoop.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -41,24 +41,25 @@ RC(2,0) RC(2,1) RC(2,2) RC(2,3) RC(2,4) RC(2,5) RC(2,6) RC(2,7) RC(2,8) RC(2,9)
left_encoder: encoder_left {
compatible = "alps,ec11";
label = "LEFT_ENCODER";
a-gpios = <&pro_micro 16 GPIO_PULL_UP>;
b-gpios = <&pro_micro 10 GPIO_PULL_UP>;
resolution = <4>;
a-gpios = <&pro_micro 16 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
b-gpios = <&pro_micro 10 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
steps = <16>;
status = "okay";
};

right_encoder: encoder_right {
compatible = "alps,ec11";
label = "RIGHT_ENCODER";
a-gpios = <&pro_micro 10 GPIO_PULL_UP>;
b-gpios = <&pro_micro 16 GPIO_PULL_UP>;
resolution = <4>;
a-gpios = <&pro_micro 10 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
b-gpios = <&pro_micro 16 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
steps = <16>;
status = "okay";
};

sensors {
compatible = "zmk,keymap-sensors";
sensors = <&left_encoder &right_encoder>;
triggers-per-rotation = <16>;
};
};

Expand Down
1 change: 0 additions & 1 deletion config/boards/shields/arkenswoop/arkenswoop.zmk.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ name: arkenswoop/Sweep
type: shield
url: https://github.com/davidphilipbarr/Sweep
requires: [pro_micro]
exposes: [i2c_oled]
features:
- keys
- encoder
Expand Down

0 comments on commit 0d0fb42

Please sign in to comment.