feat(keymap): extract pure HID decode into host-testable crate
The Key type, US-QWERTY translate, and the edge-detecting boot-report parser lived in usb_kbd.rs, unreachable by cargo test (the firmware crate is pinned to the xtensa target). Move them to a dependency-free #![no_std] + #![forbid(unsafe_code)] crate so the one path that parses untrusted device bytes can be exercised on the host. 14 tests, including an ASCII-invariant sweep over all 256 usage IDs (pins the guarantee the editor's byte==char indexing relies on) and a never-panics fuzz over arbitrary-length/content reports.
This commit is contained in:
2
keymap/.gitignore
vendored
Normal file
2
keymap/.gitignore
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
/target
|
||||
/Cargo.lock
|
||||
Reference in New Issue
Block a user