mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-03-22 15:20:39 +01:00
[usb] Reset endpoints before setting them up.
This fixes an enumaration bug when plugging, un-plugging and re-plugging the calculator. Change-Id: Ifbb4386b46b7492ce2b833e9e4755fd3cfefc708
This commit is contained in:
@@ -214,6 +214,7 @@ void poll() {
|
||||
/* Handle USB RESET. */
|
||||
OTG.GINTSTS()->setENUMDNE(true); //Clear the ENUMDNE bit.
|
||||
usb_set_address(0);
|
||||
usb_endpoints_reset();
|
||||
usb_endpoint_setup();
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user