Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
9 years, 10 months ago.
USB Device support for ST Nucleo - Free or PAID - for L152RE, F103RB, F302R8, F072RB
Hi, currently there seems to only be USB Device support for the STM32F4 chips. This chip has a USB OTG peripheral. The majority of other Nucleo boards seem to have FS USB (Full Speed), which has completely different registers. There have been numerous posts on this forum about people requesting USB support for devices with FS USB (Nucleo L152RE, F103RB, F302R8, F072RB..). I was wondering if anyone is possibly implementing this, or would be interest in doing it FOR A FEE?
We also have a new board with FS USB (NZ32-ST1L board http://forum.modtronix.com/index.php?topic=2197.0) that we need a driver for.
Seems like there are only 4 files that define the HAL for the current STM32F4 implementation. They are in the repository at https://github.com/mbedmicro/mbed/tree/master/libraries/USBDevice/USBDevice. Seems like it should not be too big job for someone who knows what to do.
Here is a list of some posts on this forum from other people who have also requested this functionality:
http://developer.mbed.org/questions/5707/If-I-need-the-implement-the-USB-function/
http://developer.mbed.org/questions/4225/How-to-make-the-USBDevice-lib-support-ST/
https://developer.mbed.org/questions/4207/Support-for-Nucleo-F302/
https://developer.mbed.org/questions/4969/STM32F072-USB-device/
1 Answer
7 years, 5 months ago.
The question is quite old, about more than 2 years agao. I have forwarded such questions to FAE of ARM mbed in a seminar. I got a suprising answer, he told me mbed did not consider USB as part of IoT, therefore mbed didn't put too much effort on that, aka. will no focus on USB in future as well.
Fortunately, a Japanese guy has merged PCD_HAL with existing F042/L152, and other people ported to F103. That approach proved ST's CubeMX generated HAL code can be merged with mbed platform.
Yes, we have to DIY.
BTW, I think exclusion USB out of IoT domain is a BIG MISTAKE. Since USB based modules can play very important roles in Gateway/Edge Nodes, with more features, including:
- Hot plug and play and Hot swap for connectivities, you can use any PC or Linux box with VHLL as Gateway.
- Hardware independent by USB bridge, you don't have to handle all the GPIO/ADC/PWM/I2C/SPI detal in Linux.
- Hot protocol swap, due to USB dongle changes, by using services in LInux
- Firmware DFU easily, no more extra serial I/O, by open source DFU tools.
- Standard Hardware/Firmware/Software development, for RAD.
- Serial compatible API, in case of CDC/ACM, PySerial/JavaCOM is easy for programming.
- Network compatible API, in case of CDC/NCM. socket programming is the nature of IoT.
Currently I am designing a general purpose gateway (LoRa/CAN/Sub-1GHz FSK/WiFi/BLE) with Python, most of the connectivities are connected via USB with STM32F042/F072/F103/F401.