cancel
Showing results for 
Search instead for 
Did you mean: 

Linker issues while compiling with IAR

NMath.0
Associate

We are using STM32F429I eval board and developing GUI based application using TouchGFX(Ver.4.9.3) and IAR(Ver.7.4).

We are facing linking error in IAR mentioned below,

Problem:  

Error[Lp011]: section placement failed 

unable to allocate space for sections/blocks with a total estimated minimum size of 0x2f6bfd bytes (max align 0x4) in <[0x08000000-0x081fffff]> (total uncommitted  

space 0x1ffe54). 

Error while running Linker 

4 REPLIES 4
Ozone
Lead II

Your code is too large for the selected device.

Either try to reduce the size with code optimization, or use a device with more flash memory.

Reducing the application size (removing debug code and/or not required functionality) is another option.

Hi @NMath.0​,

as @Ozone​ mentions, you have run out of internal flash on the device for the application.

I would suggest you move all image assets to the external flash on the Eval board.

Or at first, remove some of the large images in the application so it will fit in internal flash.

/Anders

@Anders Nedergaard PETERSEN How to move all image assets to external flash as TouchGFX automatically generates code ?

This is done using the linker script

All image assets generated by TouchGFX Designer has a section placement added to them, this is called ExtFlashSection.

In the linker script, define a region in the addressable external memory and place the ExtFlashSection in this region.

Here is an example:

definde symbol __region_external_start__ = 0x90000000
definde symbol __region_external_end__  = 0x9000FFFF
 
define region external_region   = mem:[from __region_external_start__ to __region_external_end__];
 
place in external_region { section ExtFlashSection };

/Anders