cancel
Showing results for 
Search instead for 
Did you mean: 

External flash loader for STM32H735AGIx using OCTOSPI1 on MX25LM51245g partly working

mathieu1
Associate II

Hello everyone,

I'm currently working on a custom board with an STM32H735AGI6, and I'm trying to create the external loader for the MX25LM51245g NOR flash on it. I use the OCTOSPI1 for the communication.

 I first created a basic project using STM32CubeIDE in version 1.18.1 to validate the OCTOSPI communication and hardware of my board. And I'm able read/write the register of the external flash, as well as erasing block or full chip, and writing data into it.

Then I tried to create the external loader fallowing this tutorial : https://controllerstech.com/w25q-flash-series-part-10-qspi-ext-loader-in-h750/ adapting it to my needs.

My problem is that when I test my external loader, through the STM32CubeIDE or the STM32CubeProgrammer, by erasing the first block and writing into it, the erase goes well, but I next get the error log 'failed to download sector[0].

I debug my external loader project directly from the RAM (0x24000004) address using STM32CubeIDE, and I'm able to erase and write as well.

I attached to this post the project I use to debug the OCTOSPI com and to create the external loader.

Thanks by advance for your help !

2 REPLIES 2
KDJEM.1
ST Employee

Hello @mathieu1;

 

Could you please check the memory parameters settings in Dev_Inf.c and precisely "Sector Size".

May MX25LM51245G_STM32H735G-DK project can help you to check your project.

Did you get the receive the same error mentioned in this FAQ Custom external loader "failed to download segment[0]" ?

 

Thank you.

Kaouthar

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.

Hello @KDJEM.1 ,

The memory paramters settings are good, given to the ones in the demo project and the datasheet of the MX25LM flash.

My error is :

Error: failed to download Sector[0]

Error: failed to download the File

 

I tried to add the functions of the FAQ you provided, but the error is still the same.

 

Thank you,

Mathieu