Skip to content

Commit 573e9db

Browse files
authored
Merge pull request #14 from jfedor2/fix-800us-usb-frames
Fix for 0.8ms USB frames
2 parents 89c31c7 + 80d8bda commit 573e9db

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

drivers/STM32F7xx_HAL_Driver/Src/stm32f7xx_hal_hcd.c

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -532,8 +532,11 @@ void HAL_HCD_IRQHandler(HCD_HandleTypeDef *hhcd)
532532
(void)USB_FlushTxFifo(USBx, 0x10U);
533533
(void)USB_FlushRxFifo(USBx);
534534

535-
/* Restore FS Clock */
536-
(void)USB_InitFSLSPClkSel(hhcd->Instance, HCFG_48_MHZ);
535+
if (hhcd->Init.phy_itface == USB_OTG_EMBEDDED_PHY)
536+
{
537+
/* Restore FS Clock */
538+
(void)USB_InitFSLSPClkSel(hhcd->Instance, HCFG_48_MHZ);
539+
}
537540

538541
/* Handle Host Port Disconnect Interrupt */
539542
#if (USE_HAL_HCD_REGISTER_CALLBACKS == 1U)

0 commit comments

Comments
 (0)