Do I need to modify the linker for simple SDRAM read/write operation?
Hi,
I am using the STM32F746G-Disco board with SW4STM32 IDE and I have the SDRAM working on it.
Now I am trying to port this project to the STM32CUBE IDE using the integrated STM32Cube.
However, when I try to read the SDRAM, I end up in the hard fault handler:
Hard fault: Bus, memory management or usage fault
Bus fault: Precise data access violation
Bus fault address: 0xc0000000
Writing to the same address doesn't trigger the hard fault.
uint32_t *pSdramAddress;
uint32_t u32;
pSdramAddress = (uint32_t*)0xC0000000;
*pSdramAddress = 12;
*pSdramAddress = 13;
u32 = 0;
u32 = *pSdramAddress;I first thought it would be a linker problem, but looking at the SW4STM32 IDE LinkerScript.ld, I don't see any mention of the SDRAM address or size.
Would the SDRAM address be declared somewhere else?
I did double check the FMC configuration, comparing it with the one on this page: https://community.st.com/s/article/FAQ-STM32F746G-Discovery-Create-a-basic-Graphical-Application-using-CubeMX
So I don't think the problem would be there.
Thanks for any help.
