Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/flipperdevices/libusb_stm32.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDmitry Filimonchuk <dmitrystu@gmail.com>2022-01-03 15:39:25 +0300
committerGitHub <noreply@github.com>2022-01-03 15:39:25 +0300
commit9f437aebe01418525663d76b74d62fbe2510d4fa (patch)
tree1637edb19dee3f5bfc3d56a871a7774a86cc2941
parentda829b9f6d68329d0ac3078d7e67d4cf450811c5 (diff)
parent8a7846d0213c51aa4167e7fbe3118e33848e79b7 (diff)
Merge pull request #106 from flipperdevices/master
STM32WB55: fix suspend event bug
-rw-r--r--src/usbd_stm32wb55_devfs.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/usbd_stm32wb55_devfs.c b/src/usbd_stm32wb55_devfs.c
index 884343c..d06425c 100644
--- a/src/usbd_stm32wb55_devfs.c
+++ b/src/usbd_stm32wb55_devfs.c
@@ -417,8 +417,8 @@ static void evt_poll(usbd_device *dev, usbd_evt_callback callback) {
USB->ISTR &= ~USB_ISTR_WKUP;
} else if (_istr & USB_ISTR_SUSP) {
_ev = usbd_evt_susp;
- USB->CNTR |= USB_CNTR_FSUSP;
USB->ISTR &= ~USB_ISTR_SUSP;
+ USB->CNTR |= USB_CNTR_FSUSP;
} else if (_istr & USB_ISTR_ERR) {
USB->ISTR &= ~USB_ISTR_ERR;
_ev = usbd_evt_error;