各位大侠好!
最近我换了TI最新的CC2640R2F BLE开发包,从1.30版换到了1.50版。目前App运行没有发现问题,但在烧录时却遇到麻烦:使用SmartRF Flash Programmer 2 v1.7.5版,将App与Stack合二为一的Image文件烧入CC2640R2F时,出现如下错误:
1.如果选择编译出的.out文件烧入,报错为:
>Initiate access to target: XDS-00000230.
>Reading file: C:/ti/simplelink_cc2640r2_sdk_1_50_00_58/examples/rtos/CC2640R2_LAUNCHXL/blestack/simple_peripheral_healer/tirtos/iar/app/FlashROM_StackLibrary/Exe/ble_simple_peripheral_cc2640r2lp_app_FlashROM_StackLibrary.out.
>The elf file has an error in the alignment of a section.
2.如果选择编译出的.bin或.hex文件烧入,则报错为:
>Initiate access to target: XDS-00000230.
>Reading file: C:/ti/simplelink_cc2640r2_sdk_1_50_00_58/examples/rtos/CC2640R2_LAUNCHXL/blestack/simple_peripheral_healer/tirtos/iar/app/FlashROM_StackLibrary/Exe/ble_simple_peripheral_cc2640r2lp_app_FlashROM_StackLibrary.bin.
>Invalid address or size of file:
Address(0x0) + file size(263880) is higher than address of end flash area(0x1FFFF).
但是我在使用1.30版的开发包(Stack、App的Image尚未合二为一,需要分开烧录)却没有遇到这个问题。
编译后,bin文件大小我查看了,体积的确很大有258KB,hex文件则有725KB,但使用IAR平台直接往CC2640R2F片内以Debug方式烧入却不会失败,运行也正常,并且提示烧入的Image大小只有1K和94K左右,Log如下:
Mon Mar 19, 2018 09:44:58: IAR Embedded Workbench 8.11.2 (C:\Program Files (x86)\IAR Systems\Embedded Workbench 8.0\arm\bin\armproc.dll)Mon Mar 19, 2018 09:44:58: Loaded macro file: C:\Program Files (x86)\IAR Systems\Embedded Workbench 8.0\arm\config\debugger\TexasInstruments\CC26x0.dmacMon Mar 19, 2018 09:44:58: Loaded macro file: C:\Program Files (x86)\IAR Systems\Embedded Workbench 8.0\arm\config\flashloader\TexasInstruments\FlashCC26xx.macMon Mar 19, 2018 09:44:59: Connecting to TI XDS110 ( Probe no: 00000230 ) COM[5/4]Mon Mar 19, 2018 09:45:00: TI XDS ARM, device revision: 0x00000001, big endian: false, cache: false, board revision: 0x00000000,driver revision: 0x0B020200Mon Mar 19, 2018 09:45:00: Initial reset was performedMon Mar 19, 2018 09:45:01: 1056 bytes downloaded (8.25 Kbytes/sec)Mon Mar 19, 2018 09:45:01: Loaded debugee: C:\Program Files (x86)\IAR Systems\Embedded Workbench 8.0\arm\config\flashloader\TexasInstruments\FlashCC26x0RAM20.outMon Mar 19, 2018 09:45:01: Target resetMon Mar 19, 2018 09:45:13: Unloaded macro file: C:\Program Files (x86)\IAR Systems\Embedded Workbench 8.0\arm\config\flashloader\TexasInstruments\FlashCC26xx.macMon Mar 19, 2018 09:45:13: Downloaded C:\ti\simplelink_cc2640r2_sdk_1_50_00_58\examples\rtos\CC2640R2_LAUNCHXL\blestack\simple_peripheral_healer\tirtos\iar\app\FlashROM_StackLibrary\Exe\ble_simple_peripheral_cc2640r2lp_app_FlashROM_StackLibrary.outto flash memory.Mon Mar 19, 2018 09:45:16: 93792 bytes downloaded into FLASH (6.09 Kbytes/sec)Mon Mar 19, 2018 09:45:16: Loaded debugee: C:\ti\simplelink_cc2640r2_sdk_1_50_00_58\examples\rtos\CC2640R2_LAUNCHXL\blestack\simple_peripheral_healer\tirtos\iar\app\FlashROM_StackLibrary\Exe\ble_simple_peripheral_cc2640r2lp_app_FlashROM_StackLibrary.outMon Mar 19, 2018 09:45:16: Target resetMon Mar 19, 2018 09:46:45: Breakpoint hit: Code @ simple_peripheral.c:2011.3, type: default (auto)Mon Mar 19, 2018 09:47:03: IAR Embedded Workbench 8.11.2 (C:\Program Files (x86)\IAR Systems\Embedded Workbench 8.0\arm\bin\armproc.dll)
注:使用的编程平台为IAR 8.11.2,导出exe文件设定格式如下:
不知道是哪里设定不对?
谢谢
user5329684:
这个问题解决了吗?
我也发现使用IAR download可以烧进去,但使用flash programmer烧不进去,提示Invalid address:0x20000。
YiKai Chen:
回复 user5329684:
flash programmer 2 address 要改成0x00000
user5329684:
回复 YiKai Chen:
没有看到修改address的地方?
而且,查看bin文件有129K,另外个可烧写类似项目的bin只有127kB。