summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
m---------laks0
-rw-r--r--main.cpp26
2 files changed, 25 insertions, 1 deletions
diff --git a/laks b/laks
-Subproject 043e8eb4929ca2078bba9aab3ca763beb429f23
+Subproject 29d8f1b4e89f31e2f3b448c4d40c6c251862968
diff --git a/main.cpp b/main.cpp
index 2e05399..680d71b 100644
--- a/main.cpp
+++ b/main.cpp
@@ -16,8 +16,31 @@ void reset_bootloader() {
SCB.AIRCR = (0x5fa << 16) | (1 << 2); // SYSRESETREQ
}
-auto report_desc = gamepad(
+auto report_desc = keyboard(
// Inputs.
+ usage_page(UsagePage::Keyboard),
+ usage('z' - 'a' + 4),
+ usage('s' - 'a' + 4),
+ usage('x' - 'a' + 4),
+ usage('d' - 'a' + 4),
+ usage('c' - 'a' + 4),
+ usage('f' - 'a' + 4),
+ usage('v' - 'a' + 4),
+ usage('g' - 'a' + 4),
+ usage('b' - 'a' + 4),
+ usage(0x28),
+ usage(0x2a),
+ usage(0xe0),
+ usage(0xe1),
+ logical_minimum(0),
+ logical_maximum(1),
+ report_count(13),
+ report_size(1),
+ input(0x02),
+
+ padding_in(3 + 8 + 8),
+
+ /*
buttons(15),
padding_in(1),
@@ -36,6 +59,7 @@ auto report_desc = gamepad(
report_count(1),
report_size(8),
input(0x02),
+ */
// Outputs.
usage_page(UsagePage::Ordinal),