Keil中编译工程生成bin文件
在选项里输入以下指令即可在生成代码时生成bin文件程序:
fromelf.exe --bin -o "$L@L.bin" "#L"
说明
% File name with extension (PROJECT1.UVPROJ)
File name with extension and complete path specification (C:\MYPROJECT\PROJECT1.UVPROJ)
@ File name without extension or path specification (PROJECT1)
$ Path name of a file. Path names get extended with a backslash. For example, $P could generate C:\MYPROJECT.
L Linker output file. Typically the executable file used for debugging (PROJECT1).
据上: “$L@L.bin“ “#L中
$L:表示生成的链接文件的路径
@L: 表示生成的链接文件的文件名,但不包含扩展名
#L:表示生成的链接文件的完整路径名及文件名
完整的意思就是将生成的链接文件转化成bin文件,生成文件所在的的路径不变,名字不变,仅扩展名变为bin。