cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F412G-DISCO `FramebufferSection' will not fit in region `RAMFB'

HAnh
Associate III

Hi Everyone.

I use STM32F412G-DISCO to custom TFT 320x240 and set up the touchGFX the same.

HAnh_0-1734365665216.png

But when I generate the code it shows me the error "STM32F412G-DISCO.elf section `FramebufferSection' will not fit in region `RAMFB'

HAnh_1-1734365769742.png

HAnh_2-1734365893189.png

I checked in the flash file. the RAMFB is configurated 128K

I don't know how to fix this. Can anyone help me advice in this case?

2 REPLIES 2
MM..1
Chief III

Simply 320x240x2 = 150k  then cant fit into 128k

GaetanGodart
ST Employee

Hello @HAnh ,

 

As MM said, your framebuffer is too big for the size of your RAMFB.
The color depth of your pixels is RGB565 so 5+6+5 = 16 bits which is 2 bytes.
So you will need 240 * 320 * 2bytes = 153600 bytes.

You need to either :

  • reduce your color depth (not the best)
  • reduce your display size (probably not your goal)
  • increase your memory, maybe with an external memory

 

Regards,

Gaetan Godart
Software engineer at ST (TouchGFX)