AnsweredAssumed Answered

SDRAM initialisation with CubeMX

Question asked by Dominik Dráb on Feb 26, 2018

Hi, I was trying to get SDRAM working on custom board with STM32F746. After I calculated timing parameters and generated code with CubeMX i tried to write and read some data form SDRAM, but it always ended in hard fault.

I expected memory initialisation to be OK, because according to UM1905 (HAL user manual), I should be able to write/read after calling HAL_SDRAM_Init().

STM32F HAL UM

As you can see, from the text it seems that SDRAM initialisation sequence (3d) IS part of  HAL_SDRAM_Init(), but in fact it is not. After I added BSP_SDRAM_Initialization_Sequence() from discovery board example to my code, read/write is working.

So if I understand correctly, step 3d should be instead separate step and it means that the user is supposed to implement his own initialisation sequence. 

Outcomes