2016-03-26 08:57 AM
Hello,
I could use some help. I have to implement a USB Mass Storage device on a STM32L476. The final hardware is not ready jet, so I started by using a stm32476RG Nucleo board. I�ve started with the MSC_Standalone example, that is shipped with the STM32 Cube library version 1.4. I�ve replaced all storage callbacks with empty stubs (that currently just asserts(false)). The software builds fine under GCC and runs after initializing into the main loop without any faults or asserts. I wired an USB cable to the Nucleo (D+ to PA12, D- to PA11 and 5V to PA9; PA10, the configured ID Pin is open), no external pullup resistors are used.
The 8MHz from the stlink part of the board is connected to the HSI input (OSC_IN).
When I connect the USB cable to a PC, nothing happens. I can measure 5V at PA9, but on both D+ and D-, 0V and no signals. No I�ve checked the content of all OTG (device) registers, but found no obvious error.
Have you any suggestions for me, how to debug / trouble shoot this? Any tests that I can make to get more insight in my issue?
Thank you very much in advance and kind regards,
Torsten
#usb #msc #msc #usb #stm32l42016-06-23 07:51 AM
Ok, if the current 1.5.0 version doesn't have explicit support for the L486 then you'll have to review the materials for the L476 and make some determination about what the actual differences are, and how they impact your implementation, and then port the code.
2016-07-12 03:49 PM
Can you please share with me if you made the USB working? I've exactly the same problems like you have described. I'm using STM32L476 discovery board and also I've my own hardware, both with the same results. I don't have soldered there crystal to HSE, so I'm using 32kHz LSE with PLL. With BOOT pin shorted to GND the internal bootloader works, so no hardware problems, same like you have described. I've managed to get internal pull-up resistor working, when I've disabled in usbd_conf.c VBUS sensing. When it is disabled, then internal pull-up resistor works, but the computer does not recognize the device, it seems like no enumeration or anything else takes place. I also checked with debugger that IRQ for OTG is called, but I can move more forward. I'm looking also for MSC device, but no luck at all after already few days spent with this issue.