Mercurial > louis > kiibohd-controller
diff Output/pjrcUSB/arm/usb_mouse.c @ 439:68e19d7c953e
Adding proper remote wake-up support
- Maintains a sleep state variable (may be able to use as a signal in the future)
- On the first keypress, hold the RESUME signal for 10 ms (spec says between 1 and 15 ms)
- Removed some messages that were affecting sleep state
author | Jacob Alexander <haata@kiibohd.com> |
---|---|
date | Tue, 17 May 2016 01:18:14 -0700 |
parents | d3cef419c849 |
children | 45feb80a2ad1 |
line wrap: on
line diff
--- a/Output/pjrcUSB/arm/usb_mouse.c Mon May 16 23:25:08 2016 -0700 +++ b/Output/pjrcUSB/arm/usb_mouse.c Tue May 17 01:18:14 2016 -0700 @@ -163,6 +163,12 @@ { transmit_previous_timeout = 1; warn_print("USB Transmit Timeout..."); + + // Clear status and state + USBMouse_Buttons = 0; + USBMouse_Relative_x = 0; + USBMouse_Relative_y = 0; + USBMouse_Changed = 0; return; } yield();