具体情况为:
1、我的ICF文件如下:
define symbol __ICFEDIT_intvec_start__ = 0x08000000;
define symbol __ICFEDIT_region_ROM_start__ = 0x08000000 ;
define symbol __ICFEDIT_region_ROM_end__ = 0x0807FFFF;
define symbol __ICFEDIT_region_RAM_start__ = 0x20000000;
define symbol __ICFEDIT_region_RAM_end__ = 0x20002800;
define symbol __ICFEDIT_size_cstack__ = 0x800;
define symbol __ICFEDIT_size_heap__ = 0x100;
define memory mem with size = 4G;
define region ROM_region = mem:[from __ICFEDIT_region_ROM_start__ to __ICFEDIT_region_ROM_end__];
define region RAM_region = mem:[from __ICFEDIT_region_RAM_start__ to __ICFEDIT_region_RAM_end__];
define block CSTACK with alignment = 8, size = __ICFEDIT_size_cstack__ { };
define block HEAP with alignment = 8, size = __ICFEDIT_size_heap__ { };
initialize by copy { readwrite };
do not initialize { section .noinit };
place at address mem:__ICFEDIT_intvec_start__ { readonly section .intvec };
place in ROM_region { readonly };
place in RAM_region { readwrite,
block CSTACK, block HEAP };
似乎不应该有地址错误。
2、使用JLINK进行仿真时,经常进入HardFault_Handler,debug窗口出现core is locked-up,然后,只有重新下载,才可以继续仿真。
3、但是,发现汇编栏的汇编代码全部变成0xFFFFFFFF。
4、使用JLINK-RAM查看8000000地址的数据,发现从8001400到8001800,全部是0XFF。也就是说,这部分代码损坏了?
换了JLINK的驱动,不灵。编译器是IAR 5.4 |