Skip to main content
Associate
January 23, 2024
Solved

STM32F429I-DISC1 SDRAM Access

  • January 23, 2024
  • 3 replies
  • 1652 views

I created a new .ioc project with STM32CubeIDE 1.14.0.  I did the same with 1.12.0 with the same results.  When I build and debug the project and run to a breakpoint after all initialization is complete, when I examine memory at 0xd0000000 the frame returns all ??????????.  I made no changes except to change FreeRTOS to reentrant.  If I install code to write to 0xd0000000 and read it back I get a hard fault.

The hardware is good since if I do the same thing loading the LTDC_Paint example I see the frame buffer data at 0xd0000000.

Any ideas?

    This topic has been closed for replies.
    Best answer by Wayne2839

    I solved this by adding the BSP drivers to the project and calling BSP_LCD_Init() after all the MX initializations.

    I still don't understand why the SDRAM was inaccessible after the HAL_SDRAM_Init() in MX_FMC_Init().

     

    3 replies

    TDK
    January 23, 2024

    You can diff the two codebases to find the difference. WinMerge is one tool among many that can do this quickly.

    "If you feel a post has answered your question, please click ""Accept as Solution""."
    Wayne2839Author
    Associate
    January 23, 2024

    The codebases are very different.  Mine is a .ioc project using HAL_Init().  LCD_Paint uses MX_xxxx_Init().  Is HAL best avoided?

    Wayne2839AuthorBest answer
    Associate
    January 24, 2024

    I solved this by adding the BSP drivers to the project and calling BSP_LCD_Init() after all the MX initializations.

    I still don't understand why the SDRAM was inaccessible after the HAL_SDRAM_Init() in MX_FMC_Init().