This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TMS320F28069: hex2000是否可以自动把单独生成的page1文件和page0的hex文件合并?

Part Number: TMS320F28069

目前我的固件用到了CLA, CLA1mathTables和.const_cla两个段放到了Page1,结果就是编译完成的时候输出了两个hex文件,

1).hex结尾的hex文件,包括了Page0所有代码

2).i10结尾的hex文件,包括Page1的数据

编译器给出了一个警告,warning: Data is being written to auto-generated file XXXX.i10

如果没有这个警告,100%的用户hex文件会因为缺少.i10文件内容无法运行,即使有这个警告,也会有很多用户忽视警告造成hex文件不完整。这种方式的好处暂时没发现,坏处很明显:给用户挖坑。

我目前是每次手动合并两个hex文件,非常麻烦。是否可以给hex2000.exe工具加一个选项,比如--merge,自动合并两个生成的hex文件?两个文件内容地址并不冲突,手工合并可以做到,hex2000.exe自动合并自然也不是问题。

搜了一些解决方案,有提到改cmd将所有的Page1改为Page0,比如:

https://e2e.ti.com/support/tools/code-composer-studio-group/ccs/f/code-composer-studio-forum/550845/why-lost-data-in-flash-during-converter-out-to-hex-use-lab5b/2014744#2014744

这样来做,即使能够实现,也很不优雅,改变了cmd文件的语义,得不偿失。最优雅的方法是给hex2000.exe工具增加一个合并输出hex文件的选项。