Question
STM32F103, HAL, USB CDC: hangup after reconnect
Posted on January 11, 2016 at 23:54
Hi.
I'm trying to make CDC console on STM32 device. But I've noticed some troubles: 1. When I re-connect USB cable to device, device just hangs. It seems like bug is in USB library - even blank project, that is generated by fresh CubeMX, hangs. This is most annoying trouble. 2. When I press reset, host PC (Linux) doesn't receive any re-initialization event, so connection becomes lost. Dev board have pull-up resistor directly to power line, so I can't emulate device reconnect. Can this be fixed in some way? 3. Startup (mostly - clocks initialization) takes enough long (~0.5-1 sec). For battery-backed device this isn't a trouble, but if I connect demo board directly to USB, it's often detected as unknown device. Can I do something with this? MCU - STM32F103C8T6 #usb #cdc #cdc #stm32cube #stm32f1