cancel
Showing results for 
Search instead for 
Did you mean: 

How to write initial loader to QSPI FLASH

STM32MP157DAB1, WINBOND QSPI memory attached to default pins.

How to program first stage bootloader trough DFU mode? Boot pins=000

STM32CuneProgrammer says:

15:11:45:986 : failed to read the requested memory content

15:11:46:788 : failed to read the requested memory content

15:11:47:790 : failed to read the requested memory content

and nothing able to download.

Memory work fine, If I use external SPI FLSH programmer - any diagnostics work well, JEDEC commands (Serial Flash Discoverable Parameters (SFDP), for Serial NOR Flash) to memory pass and get all properties.

MPU boot process from SPI memory well done (if boot pins = 001).

 Then I open my fsbl.stm32, message box about Partition ID appear at download phase, Where I should specify this ID?

3 REPLIES 3
PatrickF
ST Employee

Hello,

did uBoot 'see' your QSPI Flash ? All Flash programming with CubeProgrammer are done using uBoot.

Just keep the two first lines of your .tsv file (TF-A and uBoot), then, using the UART console, you have to press a key (at right time) to get uBoot prompt. Then you can try uBoot commands which can read/write the Flash.

Regards.

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.

How to load u-boot image in to QSPI? Can I done this trough CubeProgrammer?

flow with CubeProgrammer is the following (two first lines of the .tsv file):

  • TF-A is loaded in SYSRAM
  • uBoot is loaded in DDR

then, uBoot started and used to communicate with CubeProgrammer to program the Flash, usually you have the following lines in the .tsv

  • FSBL is flashed (usually TF-A, could be different than the TF-A used in two first lines). Eventually with some copy (depend on Flash)
  • SSBL is flashed (usually uBoot, could be different than the uBoot used in two first lines)
  • etc...

see https://wiki.st.com/stm32mpu/wiki/STM32CubeProgrammer_flashlayout#Typical_FlashLayout_file

Regards.

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.