cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F4 USB CDC broken after upgrading Standard Periph Library

gw
Associate II
Posted on July 01, 2014 at 18:22

Hi,

I recently updated the standard peripheral library for the F407Discovery from v1.0.0 to v1.3.0, because I intended to try and compile my code for the newer F401 and F429 discovery chips.

However after doing this, the USB library v2.1.0 (which appears to be the latest outside of STM32Cube) that I was using for USB CDC stopped working. It didn't work on the F407, F401 or the F429 boards.

I now get the following report when I plug the device in:

[32163.760027] usb 3-2: new full-speed USB device number 89 using uhci_hcd

[32163.880023] usb 3-2: device descriptor read/64, error -71

[32164.104028] usb 3-2: device descriptor read/64, error -71

[32164.320022] usb 3-2: new full-speed USB device number 90 using uhci_hcd

[32164.440025] usb 3-2: device descriptor read/64, error -71

[32164.664027] usb 3-2: device descriptor read/64, error -71

[32164.880029] usb 3-2: new full-speed USB device number 91 using uhci_hcd

[32165.288018] usb 3-2: device not accepting address 91, error -71

[32165.400035] usb 3-2: new full-speed USB device number 92 using uhci_hcd

[32165.808021] usb 3-2: device not accepting address 92, error -71

[32165.808043] hub 3-0:1.0: unable to enumerate USB device on port 2

Previously it worked fine...

Does anyone have any ideas? The new peripheral library just went in without any problems at all, so I'm not sure what could have caused the problems...

thanks!

#stm32-usb-vcp
4 REPLIES 4
gw
Associate II
Posted on July 07, 2014 at 09:50

Anyone?

Is there a USB CDC example for the F401C discovery board that I could work off to ensure that the versions of the relevant libraries are in sync?
Amel NASRI
ST Employee
Posted on July 08, 2014 at 10:59

Hi Williams,

Using the new standard library version shouldn't have any impact on the USB library (STM32_USB-Host-Device_Lib_V2.1.0). In fact, this later contains its own drivers.

-Mayla-

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

gw
Associate II
Posted on July 08, 2014 at 16:20

So STM32_USB-Host-Device_Lib_V2.1.0 is the correct/current one to use that will work on F401 chips? Or is the STM32 cube stuff recommended for everything now?

I wonder whether I was using the old peripheral library in an odd way, because it only worked with the F407 - I was using 'FS' not 'HS', and I'm not sure if that makes a difference.
gw
Associate II
Posted on July 30, 2014 at 18:12

I've just found the issue here, if anyone else is bothered...

The new library assumes that all of the chips are connected to 25Mhz crystals - when every single discovery board I've seen has 8Mhz crystals on it. Once that's done everything works.