fix STM32L4 dwc2 Deactivate VBUS Sensing

This commit is contained in:
GrAgiu
2023-03-14 23:17:54 +08:00
committed by sakumisu
parent bb8cfe23de
commit 19d509052a

View File

@@ -553,7 +553,7 @@ int usb_dc_init(void)
USB_OTG_GLB->DIEPTXF[i] = 0U;
}
#if defined(STM32F7) || defined(STM32H7)
#if defined(STM32F7) || defined(STM32H7) ||defined(STM32L4)
#ifdef CONFIG_DWC2_VBUS_SENSING_ENABLE
/* Enable HW VBUS sensing */
USB_OTG_GLB->GCCFG |= USB_OTG_GCCFG_VBDEN;