2023-03-03 05:33 AM - last edited on 2024-11-26 02:03 AM by Andrew Neil
Hi,
is it generally possible to program/read/erase an external connected Flash-Memory (e.g. Quad-SPI-Flash) with STM32CubeProgrammer via USART bootloader?
With upper configuration MCU-Flash program/read/erase is possible, but no access to Quad-SPI-Flash (address = 0x90000000), see picture.
With selected ST-LINK probe access to Quad-SPI-Flash is possible.
Thanks in advance,
Karsten
Solved! Go to Solution.
2023-03-03 09:50 AM
Currently, CubeProgrammer does not support programming via external loaders when connected via Bootloaders (eg. UART or USB-DFU). The External Loaders are only supported by CubeProgrammer when connected via ST-Link. This functionality is being considered, but at this time, it isn't certain.
Outside of using the CubeProgrammer, this is definitely possible. Actually, a solution for programming external flash memory via UART bootloader (X-CUBE-EXTBOOT) already exists and is described in AN4852 - "Programming an external Flash memory using the UART bootloader built-in STM32 microcontrollers", but it uses the STM32 Flash loader demonstrator which is no longer maintained.
Nevertheless, this package and application note should provide enough resources for you to be able to develop custom solution if needed.
2023-03-03 09:50 AM
Currently, CubeProgrammer does not support programming via external loaders when connected via Bootloaders (eg. UART or USB-DFU). The External Loaders are only supported by CubeProgrammer when connected via ST-Link. This functionality is being considered, but at this time, it isn't certain.
Outside of using the CubeProgrammer, this is definitely possible. Actually, a solution for programming external flash memory via UART bootloader (X-CUBE-EXTBOOT) already exists and is described in AN4852 - "Programming an external Flash memory using the UART bootloader built-in STM32 microcontrollers", but it uses the STM32 Flash loader demonstrator which is no longer maintained.
Nevertheless, this package and application note should provide enough resources for you to be able to develop custom solution if needed.
2023-03-07 01:50 AM
Thank you for your quick support.
Regards,
Karsten
2023-03-07 06:40 AM
If you code your own mini loader you could certainly write external memories using X-MODEM from a suitable Terminal application.
The STM32 System Loader could likely facilitate a staged-loader, where you push a more complex and board specific loader into RAM, and transfer control to that
2024-11-26 01:37 AM
Hi Karsten,
did you accomplish a working solution to this issue?
I just ran into the same use case that I need to use some kind of external Loader via the UART-Bootloader and still looking for the best way to tackle this issue.
Thanks and best regards
Alex