This indeed fixes the values read back:
80000000ff No buttons, no movement
80010000ff Left button
80050000ff Left+right buttons
80070000ff All buttons
800012fdff Force applied
80000fffff force applied
Adds support for:
- CLEAR/SET FEATURE (ignored)
- GET_CONFIGURATION (always returns 1 since there is only a single config)
- GET_INTERFACE (always returns 0 since there are not altsettings)
Matrix is getting scanned and converted into boot-style HID interface.
Most keys are basically working.
However the enabled debug UART prevents use of the following keys:
DELETE PRINTSCREEN INSERT PAGEUP PAGEDOWN
as S15 is in fixed output mode and thus can't be sensed right now.
Tested:
- UART debug output works at 115200 baud (pad S15)
- Jumps to bootloader on watchdog timeout
- Jumps to bootloader when Return is held while plugging in USB
- Jumps to bootloader when UTX/URX lines are shorted
- Measured max GPIO toggling speed is 3MHz