File tree Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -229,6 +229,14 @@ void USBPhyHw::init(USBPhyEvents *events)
229
229
hpcd.Init .use_external_vbus = DISABLE;
230
230
231
231
__HAL_RCC_USB_OTG_HS_CLK_ENABLE ();
232
+
233
+ #ifdef __HAL_RCC_USB1_OTG_FS_ULPI_CLK_SLEEP_DISABLE
234
+ __HAL_RCC_USB1_OTG_FS_ULPI_CLK_SLEEP_DISABLE ();
235
+ #endif
236
+ #ifdef __HAL_RCC_USB2_OTG_FS_ULPI_CLK_SLEEP_DISABLE
237
+ __HAL_RCC_USB2_OTG_FS_ULPI_CLK_SLEEP_DISABLE ();
238
+ #endif
239
+
232
240
map = PinMap_USB_HS;
233
241
234
242
#elif (MBED_CONF_TARGET_USB_SPEED == USE_USB_OTG_FS)
@@ -238,6 +246,14 @@ void USBPhyHw::init(USBPhyEvents *events)
238
246
hpcd.Init .speed = PCD_SPEED_FULL;
239
247
240
248
__HAL_RCC_USB_OTG_FS_CLK_ENABLE ();
249
+
250
+ #ifdef __HAL_RCC_USB1_OTG_FS_ULPI_CLK_SLEEP_DISABLE
251
+ __HAL_RCC_USB1_OTG_FS_ULPI_CLK_SLEEP_DISABLE ();
252
+ #endif
253
+ #ifdef __HAL_RCC_USB2_OTG_FS_ULPI_CLK_SLEEP_DISABLE
254
+ __HAL_RCC_USB2_OTG_FS_ULPI_CLK_SLEEP_DISABLE ();
255
+ #endif
256
+
241
257
map = PinMap_USB_FS;
242
258
243
259
#elif (MBED_CONF_TARGET_USB_SPEED == USE_USB_NO_OTG)
You can’t perform that action at this time.
0 commit comments