STM32F429ZI, CubeMX generated USB host project gets caught in the HOST ENUMERATION state.
- April 29, 2019
- 2 replies
- 977 views
I have linked the zipped test project that I used to verify the behavior that I will try to describe. I have a largely stripped down project with RTOS, USB Host Library with MSC, and a UART configured for printf() so I can utilize the USBLog debugging which has USBH_DEBUG_LEVEL at 3.
The test I was running is on a NUCLEO_F429ZI development board with a USB OTG cable as well as a UART connected for viewing the debug messages. I plug the USB drive in and the system enumerates the device. Typically, if I am being careful to be quick when disconnecting the USB drive, I can continuously disconnect and reconnect with successful enumeration each time.
If I am slow when disconnecting, the stack detects the disconnection, but then detects a faulty "USB Device Attached". At this point there is no drive installed. Any subsequent drive installations do not work. The MCU is still running, but it is stuck at the HOST_ENUMERATION state.
I found this in a different project an dug into the stack a fair bit, but thought that I should be able to get this going without any issues on a dev-kit with a largely CubeMX generated project. I saw the same issue in this project and would like to know if this is a known issue, or if there is a simple work around, or if I am overlooking something here.
Thanks for the help,
Eddie
