Compare commits

...

No commits in common. "067f0029a66d62c448c1ef634999a9d25229dc32" and "287ef24fef40031b247590586ef6ea9bd891942a" have entirely different histories.

2 changed files with 0 additions and 6 deletions

View file

@ -339,14 +339,11 @@ After changing any IMU conversion, calibration, timing, or report packing:
5. Inject a known single-axis gyro rate and decode the packed quaternion. The corresponding component must change smoothly with the expected sign.
6. Perform the decisive end-to-end check: genuine Pro Controller → SDL3 bridge → UART → emulated Pico → Zelda. This path was confirmed correct after the mode-2 fix.
The quaternion implementation is adapted from HOJA's `NS-LIB-HID` and retains its CC BY-NC 4.0 attribution in `switch_pro_driver.cpp`.
## References
- GP2040-CE (controller firmware ecosystem): https://github.com/OpenStickCommunity/GP2040-CE
- nxbt (Switch controller research/tools): https://github.com/Brikwerk/nxbt
- Nintendo Switch Reverse Engineering notes: https://github.com/dekuNukem/Nintendo_Switch_Reverse_Engineering
- `hid-nintendo` driver reference: https://github.com/DanielOgorchock/linux/blob/ogorchock/drivers/hid/hid-nintendo.c
- HOJA `NS-LIB-HID` mode-2 reference: https://github.com/HandHeldLegend/NS-LIB-HID
## Troubleshooting
- **No input on Switch**: verify UART wiring (Pico GPIO4/5), baud matches both sides, Pico flashed with current firmware, and `Pro Controller Wired Communication` is enabled on the Switch.

View file

@ -197,9 +197,6 @@ static std::map<uint32_t, const uint8_t*> spi_flash_data = {
static inline uint16_t scale16To12(uint16_t pos) { return pos >> 4; }
// Quaternion IMU mode 2 is adapted from HandHeldLegend/NS-LIB-HID
// (ns_lib_motion.*, 2026, Mitchell Cairns / Hand Held Legend, LLC),
// licensed CC BY-NC 4.0: https://creativecommons.org/licenses/by-nc/4.0/
struct MotionQuaternion {
float x;
float y;