采用hexview的HEX文件合成

hexview下载路径:https://download.csdn.net/download/kxajd001/88261758

set year=%date:~0,4%
set month=%date:~5,2%
set day=%date:~8,2%
SET hour=%time:~0,2%
IF "%hour:~0,1%"==" " SET hour=0%HOUR:~1,1%
SET minute=%time:~3,2%
set path=.\..\..\01_SrcCode\app\project_20%date:~2,2%%month%%day%_%hour%%minute%

echo path =%path%

mkdir %path%
mkdir %path%\JFlash     
mkdir %path%\JFlash\ETC\JFlash
mkdir %path%\mcuboot
mkdir %path%\mcuApp

copy .\..\..\boot\Debug\Exe\boot.hex %path%\mcuboot\boot.hex  /v
copy .\..\..\01_SrcCode\app\Debug\Exe\app.hex %path%\mcuApp\app.hex  /v
copy .\..\..\01_SrcCode\app\tool %path%\JFlash\  /v
copy .\..\..\01_SrcCode\app\tool\ETC\JFlash %path%\JFlash\ETC\JFlash  /v

Rem Path to the executable exe of the Vector HexView tool on your PC
set "HexViewPath= .\..\..\tool\HexView\hexview.exe"
 
Rem Input_hex_File1 indicates one of the merged source files and its path
set "Input_hex_File1=%path%\mcuboot\boot.hex"
 
Rem Input_hex_File2 indicates one of the merged source files and its path
set "Input_hex_File2=%path%\mcuApp\app.hex"
 
Rem Output_hex_File indicates the output hex file, and its path, after the merge
set "Output_hex_File=%path%\JFlash\A%date:~2,2%%month%%day%.hex"

Rem Call the command line provided by the HexView tool and merge Input_hex_File1 and Input_hex_File2 to output a new Output_hex_File
%HexViewPath% /S /MT:%Input_hex_File1%+%Input_hex_File2% /XI:32 -o %Output_hex_File%

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值