2026-03-25 10:44 PM - last edited on 2026-03-27 6:00 AM by FBL
Hi,
I am using the STM32N6570-DK development kit and I want to flash my FSBL and Application firmware into external flash using USB.
Currently, I am able to flash the firmware using ST-LINK, but I want to perform flashing through USB as well.
I configured the boot pins as mentioned in the datasheet:
Any guidance or examples on how to enable external flash programming via USB would be very helpful.
Thank you.
2026-03-27 6:02 AM
Hi @Gowri_M
FSBL must be programmed first:
Check the following example firmware.
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.
2026-03-30 5:06 AM - edited 2026-03-30 5:08 AM
Hi @FBL
Thank you for the response.
I went through the example firmware you mentioned and tried to implement the same approach. I followed the example structure and updated the TSV file. I did not add any additional OpenBootloader implementation in my project, similar to the example. I only updated the TSV file for my application.
However, I am not sure if my approach is correct or aligned with the intended workflow in the example.
The files below were copied directly from the example and placed in my working directory:
Updated TSV file (FSBL + Application)
#Opt Id Name Type IP Offset Binary
P 0x1 fsbl-openbl Binary none 0x0 OpenBootloader_STM32N6570-DK-trusted.stm32
P 0x3 fsbl-extfl Binary none 0x0 MX66UW1G45G_STM32N6570-DK-OBL.bin
P 0x4 fsbl-extflash Binary nor0 0x0000000 my_app_FSBL.bin
P 0x4 fsbl-app Binary nor0 0x0100000 my_app_Appli.bin
In this case, I am not able to flash, and STM32CubeProgrammer shows an error:
Attempt 2: Flashing individually
I then tried flashing FSBL and Application separately by modifying the TSV file.
TSV for FSBL
#Opt Id Name Type IP Offset Binary
P 0x1 fsbl-openbl Binary none 0x0 OpenBootloader_STM32N6570-DK-trusted.stm32
P 0x3 fsbl-extfl Binary none 0x0 MX66UW1G45G_STM32N6570-DK-OBL.bin
P 0x4 fsbl-extflash Binary nor0 0x0000000 my_app_FSBL.binTSV for Application
#Opt Id Name Type IP Offset Binary
P 0x1 fsbl-openbl Binary none 0x0 OpenBootloader_STM32N6570-DK-trusted.stm32
P 0x3 fsbl-extfl Binary none 0x0 MX66UW1G45G_STM32N6570-DK-OBL.bin
P 0x4 fsbl-app Binary nor0 0x0100000 my_app_Appli.binIn this case:
I also tried flashing only FSBL, and it flashed successfully, but it still did not execute.
My Requirement
Previously, I was using STM32U5G7 in our project.
Now I am using STM32N6570-DK, and I want the same behavior:
Questions
Thanks!
2026-04-17 7:13 AM
Hello @Gowri_M
@Gowri_M wrote:Questions
- Is flashing external flash through USB supported on STM32N6570-DK?
- Do I need to configure any OTP boot source or BOOTROM settings to enable USB flashing?
Yes, the external flash programming over USB is supported by STM32CubeProgrammer. For the required configuration, please refer to the second method described in the article below:
How to connect the STM32N6 using STLINK and serial... - STMicroelectronics Community
2026-04-17 8:25 AM
Hi @Gowri_M
As explained in readme, the example shared uses BootROM, OpenBootloader and External Loader to program NOR flash.
For your final product, the FSBL must include the USB capability if you want field updates without ST-LINK.
The OpenBootloader itself does not need to be unchanged, but your FSBL must provide equivalent USB flashing support and external flash access.
After provisioning, the board must boot from external NOR mode for the FSBL/application to run.
Create a file called FlashLayout.tsv and write this content in it
#Opt Id Name Type IP Offset Binary
P 0x1 fsbl-openbl Binary none 0x0 OpenBootloader_STM32N6570-DK-trusted.stm32
When the External Loader is programmed in RAM by STM32CubeProgrammer through TSV file. You find it here.
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.