2026-01-21 8:28 PM - last edited on 2026-01-28 5:47 AM by KDJEM.1
Hello ST Community Team,
We are currently working with the STM32N657X0H3Q1 device and using an external DRAM – S80KS5123GABHB020 (512 Mbit) connected via the XSPI interface.
We have successfully configured XSPI and external memory initialization (using CubeMX / HAL), and the external memory is intended to be used for TouchGFX frame buffers and application data.
However, we would like clarification on the following points:
What is the correct memory-mapped base address that should be used for the S80KS5123GABHB020 DSRAM on STM32N657X0H3Q1 ?
Is the memory accessed through the XSPI1 memory-mapped region, and what is the exact address range?
Are there any STM32N6-specific constraints or alignment requirements when using large external DSRAM (512 Mbit) for TouchGFX or heap allocation?
Is there any reference example or application note available for STM32N657 with external PSRAM configuration?
Currently, we are unsure at which address we should read/write the external DRAM, and accessing an incorrect address leads to HardFaults.
Any guidance or reference documentation would be very helpful.
Thank you for your support.
Best regards,
Marka.
2026-01-28 5:46 AM
Hello @siddum;
For addresses mapping, I recommend you to look at RM0486 Rev 3 Table 2. Memory map and peripheral register boundary addresses.
When configured in memory-mapped mode, the external SPI device is seen as an internal
memory. Note: No more than 256 Mbytes can be addressed even if the external device capacity is larger.
Also, I advise you to check 28.5 Address alignment and data number section in RM0486 Rev 3.
You can find in STM32CubeN6 firmware an XSPI_PSRAM_MemoryMapped example.
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.