Skip to main content
Associate III
August 13, 2024
Question

How do I boot from Flash in a Baremetal?

  • August 13, 2024
  • 1 reply
  • 1313 views

I am using the STM32MP131 in a baremetal environment. Since there is no internal flash, I am planning to use external flash and DDR.

I have confirmed that writing to and reading from the flash works, but I don't know how to start from FLASH instead of SYSRAM when powering on.

I saved the FW's bin data at address 0 of the Flash and tried changing the boot mode to QUADSPI Flash, but it did not work.

I think QUADSPI needs to be activated before reading and executing from Flash. Where should I activate this?

Do I also need to modify the linker script for the firmware that runs from Flash?

 

Please let me know if you have any solutions to this problem

Thank you very much in advance.

1 reply

Erwan SZYMANSKI
Technical Moderator
August 14, 2024
In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
StnoobsAuthor
Associate III
August 20, 2024

What does it mean that it does not support QSPI flash memory?

If so, what is the "Serial NOR Flash on QSPI" mentioned in the Boot Mode section of the STM32MP131 Datasheet?

 

Stnoobs_0-1724127096724.png

 

Erwan SZYMANSKI
Technical Moderator
August 20, 2024

Hello @Stnoobs ,
Yes the MP13, from an HW point of view can support it, and in SW this is the case on Linux side. But for MP13 Bare metal, drivers are not present. 

Kind regards,
Erwan.

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.