cancel
Showing results for 
Search instead for 
Did you mean: 

Hard fault on Using FMC ram on stm32h753

sivaram
Associate III

I'm using a STM32H753 with external RAM. We were using it for LCD framebuffer. Now we are trying to migrate the stack and heap to the external RAM, when we run the code, getting hardfault on lines where std::array is declared. Any idea on how to debug further? 

 

11 REPLIES 11

Breakpoint set at __sbrk was not hit. 

Here is the disassembly screen shot, the hardfault occurs on execution of the highlighted instruction.

 

sivaram_0-1718950051643.png

The stack pointer was at 0xc052aaf0. 

pix1234
Associate

I'd suggest checking if the external RAM is properly initialized and if the memory regions are correctly configured in your linker script. Also, make sure the cache settings are appropriate for the external RAM. You might want to use the STM32's built-in debugging tools to step through and see where it fails.