cancel
Showing results for 
Search instead for 
Did you mean: 

STM32N6570-DK: Cannot erase external Flash

EKirs.1
Associate II

Hello,

I have received the new STM32N6570-DK board a week ago. It successfully runs the "out-of-box" demo FW programmed into the external Flash and I am also able to load and run some simpler examples from SRAM through the integrated ST-Link debugger. However, when I try going further and would like to run more advanced examples requiring external Flash, I am having issues programming and erasing the external flash in the STM32CubeProgrammer. I do follow the steps in the manual (selecting the proper "external loader" MX66UW1G45G_STM32N6570-DK), however I receive the error "Error: Sector erase operation has failed at least for one of the existing specified sectors.Please verify flash memory protection." when trying to erase first 8 sectors or program another binary into the external Flash. 

Is the external flash locked by some option bytes or OTP? Is there anything that needs to be done to unlock it?

I am using STM32Programmer v2.18.0.

Attached is the screenshot of the error when it happens.

 

Thank you.

1 ACCEPTED SOLUTION

Accepted Solutions
EKirs.1
Associate II

Thank you for your response, Maryem.

Indeed, I had two external loaders selected (STM32N6570-DK and the one related to the OTP fuses). After leaving only STM32N6570-DK selected, the Flash can be erased and programmed with success.

Best regards,

Evgeny 

View solution in original post

2 REPLIES 2
Maryem
ST Employee

Hello @EKirs.1 ,

 

Could you please provide the OTP dump ? Additionally, I noticed from the attached screenshot that there are two external loaders selected. Could you specify which other external loader you are selecting ?

 

Maryem.


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.
EKirs.1
Associate II

Thank you for your response, Maryem.

Indeed, I had two external loaders selected (STM32N6570-DK and the one related to the OTP fuses). After leaving only STM32N6570-DK selected, the Flash can be erased and programmed with success.

Best regards,

Evgeny