Skip to main content
JacquesV
Associate
March 27, 2020
Question

Linux and custom code on dual core MCU

  • March 27, 2020
  • 5 replies
  • 1902 views

Hi Everyone

I'm wanting to have an STM32H747 run custom code on the M4 and Linux on the M7 with some basic interaction/messaging between the two.

I've never attempted anything like this before and will be very grateful for any advice offered by the community to achieve this.

Specifically, how to get Linux on the M7 and getting the two cores communicating.

References to app notes, your own experience and or general related advice welcome, if, of course, you will indulge me.

Thanks

Jacques

This topic has been closed for replies.

5 replies

TDK
March 27, 2020

The M7 core isn't a normal target for Linux. It's not that powerful to support all the overhead required of a full fledged OS. I would not recommend it.

"If you feel a post has answered your question, please click ""Accept as Solution""."
JacquesV
JacquesVAuthor
Associate
March 27, 2020

What about STLINUX?

Danish1
Lead III
March 27, 2020

Sorry to put a dampener on things, but are you sure that the M7 can run Linux?

I know ST say their stm32MP1 MPUs can run Linux. But they are much more powerful.

When I looked into things, I understood that Linux needs a memory-management unit. There was an almost-linux called uClinux aimed at microcontrollers.

As to getting the cores communicating, I think there is shared access to SRAM4. You could have two circular buffers - one for messages in each direction. The writing processor would update its "write" index when it has added something to the buffer and the reading processor would update its "read" index when it has read the message. This is fine where the messages are simple byte streams.

Hope this helps,

Danish

JacquesV
JacquesVAuthor
Associate
March 27, 2020

I am considering STLINUX and eLinux as starting points... Thanks for the info on SRAM4

TDK
March 27, 2020

> The STLinux distribution and development environment provides everything required to build Linux based systems for  STMicroelectronics  products which are based around the ARM Cortex A9, ST40 or ST200 CPUs.

Note that the M7 is not a target.

"If you feel a post has answered your question, please click ""Accept as Solution""."