diff options
| author | HiFiPhile <[email protected]> | 2024-05-09 18:44:27 +0200 |
|---|---|---|
| committer | HiFiPhile <[email protected]> | 2024-05-09 18:44:27 +0200 |
| commit | ca479d6e4b8e034dda7026fa1f229d16001d61c2 (patch) | |
| tree | cf3ece4a6e7e781960f05c0c3abdae26856dd266 /src | |
| parent | 11b5b2af51df9602b29728caf2ceb47dca61d835 (diff) | |
Disable SOF on configuration change.
Diffstat (limited to 'src')
| -rw-r--r-- | src/device/usbd.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/device/usbd.c b/src/device/usbd.c index 047596924..e83553e0d 100644 --- a/src/device/usbd.c +++ b/src/device/usbd.c @@ -725,6 +725,9 @@ static bool process_control_request(uint8_t rhport, tusb_control_request_t const // already configured: need to clear all endpoints and driver first TU_LOG_USBD(" Clear current Configuration (%u) before switching\r\n", _usbd_dev.cfg_num); + // disable SOF + dcd_sof_enable(rhport, false); + // close all non-control endpoints, cancel all pending transfers if any dcd_edpt_close_all(rhport); |
