cancel
Showing results for 
Search instead for 
Did you mean: 

How to modify STM32 external loader (.stldr) for custom QSPI pinout (CS2 instead of CS1) on STM32H747?

Shiv09
Associate III

Hello,

I am working on a custom board based on the STM32H747 to develop a Touchgfx application as User Interface, where I am using the same QSPI Flash device as the STM32H747I-EVAL kit (MT25TL01G 1Gbit), but with a different chip-select pin wiring.

On the STM32H747I-EVAL board, the external loader (MT25TL01G_STM32H747I-EVAL.stldr) is configured to use:

  • QSPI_BK1_NCS (PG6) as the common chip-select for both banks.

On my custom board, the MT25TL01G device is wired as:

  • QSPI_BK2_NCS (PC11) as the common chip-select for both banks.

I updated my firmware, CubeMX configuration, pin assignments, and the QSPI initialization, and QSPI is now working correctly inside my application firmware.

However, STM32CubeProgrammer cannot flash the external QSPI because the supplied stldr file still expects the original chip-select pin (PG6).
The external loader obviously needs to be rebuilt with the new QSPI pin mapping.

My questions are:

  1. Is it possible to modify or rebuild the .stldr external loader for the STM32H747?
  2. Where can I find the source code project for the MT25TL01G external loader used by the STM32H747I-EVAL board?
    • I only see the compiled .stldr file, not the C source files.
  3. What is the recommended procedure to edit the GPIO configuration (specifically NCS pin PC11 instead of PG6) and rebuild the loader?
  4. If the loader sources are not provided, does ST offer a way to generate a custom external loader for QSPI using CubeMX or another tool?

I simply need a way to rebuild the external loader with the following modification:

Chip Select pin: PC11 (QSPI_BK2_NCS)
Dual-Flash: Enabled
Flash Size: 1Gbit MT25TL01G

Any guidance or documentation on how to correctly regenerate a custom QSPI external loader for STM32CubeProgrammer would be greatly appreciated.

Thank you.

1 REPLY 1
MOBEJ
ST Employee

Hello @Shiv09,

Regarding your second question, you can find the MT25TL01G external loader driver at the following GitHub repository:
GitHub - STMicroelectronics/stm32-mt25tl01g

This component is utilized in the BSP example included in the latest STM32CubeH7 package. You can download the most recent STM32CubeH7 package from ST.com. Within this package, you will find a BSP example under STM32H747I_Disco examples  that contains a sub-demo named QSPI_demo, which demonstrates the usage of this driver.

Br

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.