summaryrefslogtreecommitdiff
path: root/app/src/kscan.c
diff options
context:
space:
mode:
authorPete Johanson <peter@peterjohanson.com>2020-06-19 15:32:33 -0400
committerPete Johanson <peter@peterjohanson.com>2020-06-19 15:32:33 -0400
commitc23d752917774bc740c791e2f7eeef6f8f9e1033 (patch)
tree54da84e2a8c4a3bf68c0f28b29cc096605c3db94 /app/src/kscan.c
parent865f41a46d4d4a6d35515d1192232efdd7d67942 (diff)
Some initial work on behavior bindings for keymaps
Diffstat (limited to 'app/src/kscan.c')
-rw-r--r--app/src/kscan.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/app/src/kscan.c b/app/src/kscan.c
index 1f54a14..d1ed621 100644
--- a/app/src/kscan.c
+++ b/app/src/kscan.c
@@ -49,11 +49,12 @@ void zmk_kscan_process_msgq(struct k_work *item)
while (k_msgq_get(&zmk_kscan_msgq, &ev, K_NO_WAIT) == 0)
{
bool pressed = (ev.state == ZMK_KSCAN_EVENT_STATE_PRESSED);
- zmk_key key = zmk_keymap_keycode_from_position(ev.row, ev.column);
- struct zmk_key_event kev = (struct zmk_key_event){.row = ev.row, .column = ev.column, .key = key, .pressed = pressed};
+ zmk_keymap_position_state_changed(ev.row, ev.column, pressed);
+ // zmk_key key = zmk_keymap_keycode_from_position(ev.row, ev.column);
+ // struct zmk_key_event kev = (struct zmk_key_event){.row = ev.row, .column = ev.column, .key = key, .pressed = pressed};
- LOG_DBG("Row: %d, col: %d, key: %d, pressed: %s\n", ev.row, ev.column, key, (pressed ? "true" : "false"));
- zmk_handle_key(kev);
+ // LOG_DBG("Row: %d, col: %d, key: %d, pressed: %s\n", ev.row, ev.column, key, (pressed ? "true" : "false"));
+ // zmk_handle_key(kev);
}
}