cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F2/F4 problems with various ULPI USB PHYs

ian2399
Associate II
Posted on August 09, 2012 at 12:43

Hi

I have a problem with STM32F207/407 (not) working with a ULPI PHY, in this caseSMSC USB3340. The system (which is device-only) will work at USB full-speed but not high-speed. Itseems that others have similar problems - some ULPI-compliant PHYs seem to work,others not.

Logic analysis of the ULPI bus and USB line states show that during the USB_RESET period, the STM sets the PHY's Function Control register to generate the ChirpK indicating that the device can work at high-speed.  However, the ChirpK is never generated, so enumeration falls back to full-speed. Instead of sending the ChirpK, DP goes to 1.6V and DM to 0V.

It is possible that the problem arises because the USB Core sets theLPM bit (bit7) in the PHY's Function Control register. It looks at first sight as if PHYs which do notsupport LPM (and so ignore the bit) work correctly, and vice-versa.  For example on this forum we see a USB3343 not working and a USB3320 (similar but with no LPM support) working.

Does anyone at ST know if there is there a way to cause the STM32F deviceNOT to set the LPM bit in the ULPI PHY Function Control register? It would seem likely, but no such control is documented.

Does anyone have any further experience of which PHYs do and don't work in this regard?

Thanks

Ian

#usb-ulpi-phy-usb3340
30 REPLIES 30
Martin Devera
Associate III

Hi, I added in in my usb init routine as I don't use HAL/Middleware. I use in-house simple USB framework.

However probably you can modify the register DCFG directly after calling HAL's USB init function.

M.