Skip to main content
Visitor II
August 22, 2024
Question

USB Device hangs on high data rate in STM32H750VB

  • August 22, 2024
  • 1 reply
  • 701 views

I am reaching out to request your assistance with an issue we are encountering on the STM32H750VB microcontroller related to USB data transmission. The problem arises when operating at high data rates, specifically with external USB synchronization and high BPM settings (e.g., 999 BPM) with a 1/32T scale. In this scenario, the USB device stops sending data altogether, with no messages being transmitted.

Upon debugging, we found that the condition if ((epint & USB_OTG_DIEPINT_TXFE) == USB_OTG_DIEPINT_TXFE) in the USB interrupt handling code is not being satisfied after the USB stops transmitting. This suggests that the USB buffer may not be empty, leading us to believe there could be a buffer-related issue.

To address this, we increased the buffer size using the following configuration: HAL_PCDEx_SetRxFiFo(&hpcd_USB_OTG_FS, 0x200); HAL_PCDEx_SetTxFiFo(&hpcd_USB_OTG_FS, 0, 0x200); HAL_PCDEx_SetTxFiFo(&hpcd_USB_OTG_FS, 1, 0x200);

However, even after adjusting the buffer size, the issue persists, and the USB device continues to hang under the same conditions.

We kindly request your support in diagnosing and resolving this issue as it is critical to our project. Any guidance or suggestions you can provide would be greatly appreciated.

    This topic has been closed for replies.

    1 reply

    Technical Moderator
    August 26, 2024

    Hi @Saagar 

    Which USB class being used? Could you share your USB full initialization?