79414348

Date: 2025-02-05 10:06:08
Score: 0.5
Natty:
Report link

I saw that in the initialization code I got from STM32 was incorrcet. I just copied and pasted the code. Only change I did was the refresh rate, but I did not see that it's initializing BANK2. My SDRAM bank is 1, so I wrote:

    Command.CommandMode = FMC_SDRAM_CMD_CLK_ENABLE; /* Set MODE bits to "001" */
    Command.CommandTarget = FMC_SDRAM_CMD_TARGET_BANK1; /* configure the Target Bank bits */
    Command.AutoRefreshNumber = 1;
    Command.ModeRegisterDefinition = 0;
    HAL_SDRAM_SendCommand(&hsdram2, &Command, 0xfff);

and problem is solved.

Reasons:
  • Long answer (-0.5):
  • Has code block (-0.5):
  • Self-answer (0.5):
  • Low reputation (1):
Posted by: cserp