2018-08-21 06:11 AM
Hi,
I'm trying to use the current CubeMX to generate USB CDC code for SMT32F303RE. The generated code doesn't connect to my Windows 10 machine. The device not even appear.
I did almost the same on STM32F411RE and STM32F407VG, both works perfectly.
Looking into the code I realized that the GPIO initialization code is not generated, I added it, but still no success.
I'm using the following components:
CubeMX v4.26.1
STM32F3 Series driver package v1.10.0
STM32F4 Serias driver package v1.21.0
Atollic TrueStudio v9.0.1
Thanks
Zoltan
2018-08-31 06:35 AM
Hello @ZGomo ,
Try to increase the heap and stack sizes.
Please, follow this FAQ "USB device not recognized", this may helps you:
https://st-microelectronics.jiveon.com/docs/DOC-1821-faq-usb-device-not-recognized
With Regards,
Imen
2018-08-31 06:59 AM
Hi,
i have the same problem and observed the same thing that the GPIOs are not initialized for the usb cdc. Tried the same and it doesnt work. Also tried increasing the heap size but for me it didn't change anything.
I hope we can resolve this!
Best regards
2018-09-02 11:14 AM
Hello @Imen DAHMEN ,
Unfortunately it doesn't help here.
The problem is not the "USB device not recognized", but the device doesn't show up. It is same like I didn't connect anything to my computer.
Actually I don't have enough time to dig deeper now as it started to work with F407VG, and I'm at early stage of the design, it has a few additional features what can be handy, so I simply switched to F407VG.
Maybe later I can work on a bit. This post mainly want to be a bug report, to enhance the code of the CubeMX, maybe someone can test it, and find out, if there is a problem or not.
Regards,
Zoltan
2018-09-02 11:46 AM
Try validating the hardware using the HAL examples.
Try also known working hardware like the F3-DISCO
2018-09-03 04:19 AM
Hi Clive,
I checked the hardware with the available HID example for the stm32f303ze board. This worked. So I don't think it is a hardware problem. I would guess that it is a software /configuration problem in cubeMX. Is that possible? I also think that the GPIO configuration is missing in the generated code.
thank you!