Skip to main content
RZasa.1
Associate II
October 29, 2023
Solved

TouchGFX example question

Hello,

Could somebody explain what is the purpose of this second line of code below taken from main.c in TouchGFX example for STM32HB3I-DK?:

SDRAM_Initialization_Sequence(&hsdram1, &command);

*(__IO uint32_t*)(0xD0000000) = 0x11111122;

It works fine with provided example but my program (set up from scratch in CubeMX) is going to mem fault on this line. When I comment this line out my program works fine. D0000000 is start of address of external SDRAM. Is it something to do with testing speculative memory access? I know nothing about it.

 

This topic has been closed for replies.
ST Employee
October 30, 2023

Hello @RZasa.1 ,

Sorry for the inconvenience. Yes, the second line which is a write operation was meant for testing and should have been removed. So, you can easily ignore it.  

Thank you for the notice

Mohammad MORADIST Software Developer | TouchGFX

2 replies

ST Employee
October 30, 2023

Hello @RZasa.1 ,

Sorry for the inconvenience. Yes, the second line which is a write operation was meant for testing and should have been removed. So, you can easily ignore it.  

Thank you for the notice

Mohammad MORADIST Software Developer | TouchGFX
RZasa.1
RZasa.1Author
Associate II
October 30, 2023

Thank you.