No initialize flash array

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

No initialize flash array

1,685 次查看
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by blasiis on Mon Jun 13 05:42:14 MST 2016
Dear all, i have LPC1758 abd a structure fixed in rom like this:


__attribute__ ((section(".myText"))) const uint8_t arText[200];


Tastiera_Lcd_Debug_memory.ld:
..........
  MyText   (rx) : ORIGIN = 0x00068000, LENGTH = 0x8000 /* 32K */

Tastiera_Lcd_Debug.ld:
..........
.myText : ALIGN(4)
{ *(.myText)
} > MyText


When I program the flash entering in debug, the text array is initializated to 0x00, how can I not initialize the rom array ?


Thanks
标记 (2)
0 项奖励
回复
3 回复数

1,612 次查看
lpcware
NXP Employee
NXP Employee
bump
0 项奖励
回复

1,612 次查看
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by blasiis on Mon Jun 13 07:02:41 MST 2016
OK Thanks Solved the problem with:

.myText (NOLOAD) : ALIGN(4)
{ *(.myText)
} > MyText

0 项奖励
回复

1,612 次查看
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by vtw.433e on Mon Jun 13 06:42:03 MST 2016
Assuming that you want to leave whatever values are already stored at that location, you should give the section the NOLOAD attribute in the linker script.
0 项奖励
回复