2024-06-10 10:20 PM
I am trying to make a USB HID self powered device with STM32G473 without VBUS. I understand that I will require VBUS sensing on reconnection but even when I have already connected the USB then power up my device I only get reset request from host after that it only raises the USB error interrupt. where could be the problem? Is VBUS sensing required in this case as well ?
This is my clock configuration:
2024-06-13 09:14 PM
I have generated the entire code with cube mx with HSE clock and PLL for USB. The direct code from cube mx is not working. is vbus sensing required even if USB port is connected to the pc even before my board is powered up? Does vbus serve any other purpose on the host side? Kindly help
2024-06-13 09:23 PM
also the usb port is not detected by cube programmer in DFU mode. but uart programming is working
2024-06-15 12:01 AM
on further observing I get resume, suspend and reset callback but instead of SOF callback I get only usb error callback
2024-07-13 10:48 AM
@gjaczet, did you ever figure out what was happening? I am encountering a similar issue, but when trying to create a VCP interface. I did see the errata entry that talked about the USB peripheral prematurely causing a suspend event. Possibly this is what you figured out was the problem? If so, perhaps you could share your workaround?
ST Support,
It appears that the current CubeMX USB stack does not handle masking the SUSP interrupt that was discussed in the errata? Please advise. Perhaps you could generate a stock CubeMX VCP or HID usb device project for the appropriate dev board and verify that it can enumerates correctly on a Windows 11 pc?
2024-07-13 01:18 PM
@gjaczet / ST Support:
Never mind, I had an issue where I accidentally kept interrupts disabled for longer than desired. Once this was corrected, USB VCP appears to be working fine.