Connecting USB to Cortex-M4 on STM32mp157 possible?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2020-03-06 12:38 AM
I'd like to connect one USB port to the RTOS, running on the Cortex-M4. According CubeMX this is not possible (no square availble to tick). Is this really not possible?
According the datasheet (DS12505 Rev3, page 19, 'Block Diagram'):
- USBH is connected to AXIM bus, but the corresponding arrow is blue (= AHB ).
- The USB OTG I can not find there.
According same datasheet (page 36, 'Bus Matirx'):
- USBH is connected to AXIM
- USBO is connected to MLAHB
This is not clear to me.
Denise
Solved! Go to Solution.
- Labels:
-
STM32MP15 Lines
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2020-03-06 2:37 AM
Altough using OTG from Cortex-M4 is somewhat possible from pure HW point of view, the SW does not allow this use case due to the fact that USBPHY and all clocks are handled by Linux (including the PLL USB used by both USBH and OTG).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2020-03-06 2:37 AM
Altough using OTG from Cortex-M4 is somewhat possible from pure HW point of view, the SW does not allow this use case due to the fact that USBPHY and all clocks are handled by Linux (including the PLL USB used by both USBH and OTG).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2020-03-06 2:41 AM
Thanks for this clarification. That's a pitty to me, but ok.
Denise
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2020-03-06 4:47 AM
You may have to rethink your use case, by e.g. 'subcontracting' the USB data transfer to Linux (e.g. using rpmsg/OpenAMP). For sure system latency and power will not be equivalent than a direct management for M4 (the SRAM size not used by the USB stack could be used to buffer more data locally before requesting Linux<->USB wake up)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2020-03-06 7:16 AM
As 'real-time conditions' are the reason why I want to connect USB to the M4, subcontracting does not really bring a benefit, I think. In my case I assume that using the A7 directly is much simpler. Other solution would be to replace USB by UART to be able to execute everything on the M4.
But thanks for the hint. I will surely investigate to check the rpmsg/OpenAMP feature (it's new to me..)
