[LL][USB] Fix added to USB_ClearInterrupts(), should write 1 to clear the interrupt status bits of OTG_FS_GINTSTS register
diff --git a/Src/stm32f1xx_ll_usb.c b/Src/stm32f1xx_ll_usb.c index a99afeb..00522eb 100644 --- a/Src/stm32f1xx_ll_usb.c +++ b/Src/stm32f1xx_ll_usb.c
@@ -1176,7 +1176,7 @@ */ void USB_ClearInterrupts(USB_OTG_GlobalTypeDef *USBx, uint32_t interrupt) { - USBx->GINTSTS |= interrupt; + USBx->GINTSTS &= interrupt; } /** @@ -1738,6 +1738,10 @@ USBx_HC(hcnum)->HCCHAR |= USB_OTG_HCCHAR_CHENA; } } + else + { + USBx_HC(hcnum)->HCCHAR |= USB_OTG_HCCHAR_CHENA; + } } else {