summaryrefslogtreecommitdiff
path: root/src/hid.c
diff options
context:
space:
mode:
authorPeter <peter@peterjohanson.com>2020-05-25 03:19:21 +0000
committerPeter <peter@peterjohanson.com>2020-05-25 03:19:21 +0000
commit96b87b2594d590b9eed009803218f773716fd2ac (patch)
tree6845d7cd69f18284ee47dc415930850ffffc6fd4 /src/hid.c
parented5532bf94e93d25e35498cfd7a9040b0c69597b (diff)
parent76a433fc392be31e56df256b630a21e61775d0af (diff)
Merge branch 'actions/mod-tap-initial-work' into 'master'
Actions: Mod-Tap initial work See merge request zmkproject/zmk!1
Diffstat (limited to 'src/hid.c')
-rw-r--r--src/hid.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/hid.c b/src/hid.c
index 51f92a7..5e87b59 100644
--- a/src/hid.c
+++ b/src/hid.c
@@ -21,6 +21,18 @@ int zmk_hid_unregister_mod(zmk_mod modifier)
_TOGGLE_MOD(modifier, false);
}
+int zmk_hid_register_mods(zmk_mod_flags modifiers)
+{
+ report.modifiers |= modifiers;
+ printk("After register mods %d have %d\n", modifiers, report.modifiers);
+}
+
+int zmk_hid_unregister_mods(zmk_mod_flags modifiers)
+{
+ report.modifiers &= ~modifiers;
+ printk("After unregister mods %d have %d\n", modifiers, report.modifiers);
+}
+
#define KEY_OFFSET 0x02
#define MAX_KEYS 6