cancel
Showing results for 
Search instead for 
Did you mean: 

linker error after upgrading to touchGFX 4.21.4

CDavi.3
Associate II

I have a full working project targeted to touchGFX 4.20 (compile and run fine). I've tried to upgrade to 4.21.4 but I have the following linker error:

"Error: L6216E: Cannot use base/limit symbols for non-contiguous section .ARM.exidx"

The migrating procedure is the following:

open the .ioc file of the project and migrate touchGFX to 4.21.4 - generate project files

open the project with touchGFX designer and save

open in MDK and compile ==> I see the linker error (If I recompile the project before the migration, it just run fine)

Some project info:

microcontroller: STM32F750N8H6

IDE: keil mdk 5.37

ARM compiler: 6.18

cube mx: 6.8.1

Scatter file:

; *************************************************************
 
; *** Scatter-Loading Description File generated by uVision ***
 
; *************************************************************
 
 
 
LR_ROM1 0x90000000 0x01000000 {  ; load region size_region
 
 ER_ROM1 0x90000000 0x01000000 { ; load address = execution address
 
  *.o (RESET, +First)
 
  *(InRoot$$Sections)
 
  .ANY (+RO)
 
  .ANY (+XO)
 
 }
 
 ; Execute main in the RAM_ITCM (16k)
 
 ;  NOTE: if Keil finds that the load region (LR_***) value settled by the user is different from 
 
 ; execute region (ER_YYY) value it generates a little routine that copy the code from load region 
 
 ; to Execute region and then allows the CPU to jump to the new region to execute the code (it jumps to 
 
 ; execute region address). Here the load region is 0x90000000 (internal flash throgh TCM ) and the 
 
 ; execute region is 0x00000000 (internal RAM: RAM-ITCM).
 
 ER_RAMITCM 0x00000000 0x4000 {
 
	main.o
 
	stm32f7xx_it.o
 
	stm32f7xx_hal.o
 
	stm32f7xx_hal_ltdc.o
 
	stm32f7xx_hal_dma2d.o
 
	STM32DMA.o
 
	TouchGFXGeneratedHAL.o
 
	TouchGFXHAL.o
 
	app_touchgfx.o
 
	OSWrappers.o
 
	stm32f7xx_hal_hcd.o
 
	usbh_core.o
 
	usb_host.o
 
 }
 
 ;RW_IRAM1 0x20000000 0x00050000 { ; RW data
 
 ; .ANY (+RW +ZI)
 
 ;}
 
 ; Added new region
 
 DMA_BUFFER 0x20000000 0x0400 {	;	1024byte - DTCM ram parte 1 - non cachable - usato per buffer dma
 
 *(.dma_buffer)
 
 }
 
 RW_IRAM1 0x20000400 0x0000FC00 { ; RW data - DTCM ram parte 2 - non cachable
 
  .ANY (+RW +ZI)
 
 }
 
 ; Added new region
 
 TouchGFX_Framebuffer 0x20010000 0x0003FC20 {	;	3FC20 - non viene abilitata la cache qui - framebuffer
 
 *(TouchGFX_Framebuffer)
 
 }
 
  
 
 ; Added new region
 
 RW_IRAM2 0x2004FC20 0x03E0 {	;	992byte - non viene abilitata la cache qui
 
  .ANY (+RW +ZI)
 
 }
 
}
 

The problem is due to the region that resides in the ITCM-RAM (ER_RAMITCM - for speed up the execution of some code). If I remove it , the project compile fine (obviously without using ITCM ram).

What is quite strange is that, the same project , with the same scatter file, it just run fine with the previous touchGFX (4.20)

6 REPLIES 6
CDavi.3
Associate II

just a quick update. If I compile the project with compiler V5.06 (so using Middlewares\ST\touchgfx\lib\core\cortex_m7\Keil\touchgfx_core.lib) it seem to compile fine. It doesn't seems to compile (linker error L6216E) when using compiler V6.18, i.e. using this library: Middlewares\ST\touchgfx\lib\core\cortex_m7\Keil6.x\touchgfx_core_wchar16.lib

Sarra.S
ST Employee

STM32G750N8 ??

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

I'm sorry: STM32F750N8H6

Jnevi.1
Senior

i now face the same problem. Is there any solution available?

are you using the same version of compiler and touchGFX?

CDavi.3
Associate II

I can confirm that the problem persist even with:

  • touchGFX 4.23
  • ARM compiler 6.18

But it wasn't present with touchGFX 4.20.

My guess is something has changed in the compiler flags of the touchgfx library (.lib) itself.

It might be possible to have the library (touchgfx\lib\core\cortex_m7\Keil6.x\touchgfx_core_wchar16.lib) compiled with these compilation flags? "-fno-exceptions -fno-unwind-tables"