是的,消息1中的理解是正确的,但是在路上有很多细节,这个过程可能略有不同,这取决于编译器和链接器的使用,使用什么编程工具链,以及目标机器是什么。R是最典型的,如果安装了XC8编译器,在/DOCS目录中与编译器安装并行,则有XC8C编译器用户指南,它描述了如何对具有高级整体程序优化的编译器进行操作。它存储在类似于:C//程序文件(x)的地方。86)/Microchip /XC8/V1.42/DOCS/MPLABAXXC8YCCOMPILRIOR USER指南。PDFL是困难的:如果编译和链接用于调试,“.HEX”文件并不是没有产生或使用的。“ELF”文件,实际上是由链接器产生的,都需要为MicroCONT编程所需的所有信息。Road,并且在调试过程中还需要调试符号信息,因此,如果程序由调试器执行,则可能不需要'.HEX '文件。否则,“.HEX”文件将由一个从“.ELF”文件中提取信息的程序在单独的步骤中创建,并写入I。NTO十六进制文本,在一个文件中,你可以在文本编辑器中打开并查看它。它被许多在生产编程中使用的闪存编程工具所使用,并且由可以输入序列号的实用程序使用,并且对于每一个生成和编程的程序都是不同的。在PIC设备中,有一个单独的文档:Flash编程规范,你可以找到它,并从每个PIC设备的产品网页下载它。在途中有几个中间文件。可以在IDE中设置复选框,或者给命令行添加一个。为了保持这些,其中一些可能是有用的,如果追逐一个困难的bug,但可能有很多东西,很难知道在哪里搜索。
以上来自于百度翻译
以下为原文
Yes,
the understanding in message #1 is correct as an overwiev.
There is however a lot of details along the way,
and the process may be slightly different, depending upon what compiler and linker is used,
what programming toolchain is used, and what target machine is intended.
While not the simplest, nor the most typical,
if you have XC8 compiler installed, in /docs directory in parallel with the compiler installation,
there is XC8 C Compiler user's guide, with descriptions of how it is done for a compiler that have advanced whole program optimization.
It is stored somewhere like:
C:/Program Files (x86)/Microchip/xc8/v1.42/docs/MPLAB_XC8_C_Compiler_User_Guide.pdf
Just to be difficult:
If compiling and linking for debugging, a '.hex' file is not nessesarily produced nor used.
The '.elf' file, which is what may actually be produced by the linker, have all information needed to program the microcontroller, and also have debugging symbol information that will be needed during debugging anyway,
so if programming is performed by the debugger, a '.hex' file may not be needed.
Otherwise, the '.hex' file is created in a separate step by a program that extract information from '.elf' file, and write into hexadecimal text, in a file that you may open and look at in a text editor.
It is used by many flash programming tools used in production programming, and by utility programs that may put in serial numbers and such that shall be different for each item produced and programmed.
Then for every family of PIC devices, there is a separate document: Flash Programming Specification,
you can find it and download it from the product webpage for each PIC device.
There are several intermediate files produced along the way.
It is possible to set a checkbox in the IDE, or give an addition to command line, to keep these.
Some of these may be useful if chasing a difficult bug, but there may be a lot of stuff, and be difficult to know where to search.
Regards,
Mysil
是的,消息1中的理解是正确的,但是在路上有很多细节,这个过程可能略有不同,这取决于编译器和链接器的使用,使用什么编程工具链,以及目标机器是什么。R是最典型的,如果安装了XC8编译器,在/DOCS目录中与编译器安装并行,则有XC8C编译器用户指南,它描述了如何对具有高级整体程序优化的编译器进行操作。它存储在类似于:C//程序文件(x)的地方。86)/Microchip /XC8/V1.42/DOCS/MPLABAXXC8YCCOMPILRIOR USER指南。PDFL是困难的:如果编译和链接用于调试,“.HEX”文件并不是没有产生或使用的。“ELF”文件,实际上是由链接器产生的,都需要为MicroCONT编程所需的所有信息。Road,并且在调试过程中还需要调试符号信息,因此,如果程序由调试器执行,则可能不需要'.HEX '文件。否则,“.HEX”文件将由一个从“.ELF”文件中提取信息的程序在单独的步骤中创建,并写入I。NTO十六进制文本,在一个文件中,你可以在文本编辑器中打开并查看它。它被许多在生产编程中使用的闪存编程工具所使用,并且由可以输入序列号的实用程序使用,并且对于每一个生成和编程的程序都是不同的。在PIC设备中,有一个单独的文档:Flash编程规范,你可以找到它,并从每个PIC设备的产品网页下载它。在途中有几个中间文件。可以在IDE中设置复选框,或者给命令行添加一个。为了保持这些,其中一些可能是有用的,如果追逐一个困难的bug,但可能有很多东西,很难知道在哪里搜索。
以上来自于百度翻译
以下为原文
Yes,
the understanding in message #1 is correct as an overwiev.
There is however a lot of details along the way,
and the process may be slightly different, depending upon what compiler and linker is used,
what programming toolchain is used, and what target machine is intended.
While not the simplest, nor the most typical,
if you have XC8 compiler installed, in /docs directory in parallel with the compiler installation,
there is XC8 C Compiler user's guide, with descriptions of how it is done for a compiler that have advanced whole program optimization.
It is stored somewhere like:
C:/Program Files (x86)/Microchip/xc8/v1.42/docs/MPLAB_XC8_C_Compiler_User_Guide.pdf
Just to be difficult:
If compiling and linking for debugging, a '.hex' file is not nessesarily produced nor used.
The '.elf' file, which is what may actually be produced by the linker, have all information needed to program the microcontroller, and also have debugging symbol information that will be needed during debugging anyway,
so if programming is performed by the debugger, a '.hex' file may not be needed.
Otherwise, the '.hex' file is created in a separate step by a program that extract information from '.elf' file, and write into hexadecimal text, in a file that you may open and look at in a text editor.
It is used by many flash programming tools used in production programming, and by utility programs that may put in serial numbers and such that shall be different for each item produced and programmed.
Then for every family of PIC devices, there is a separate document: Flash Programming Specification,
you can find it and download it from the product webpage for each PIC device.
There are several intermediate files produced along the way.
It is possible to set a checkbox in the IDE, or give an addition to command line, to keep these.
Some of these may be useful if chasing a difficult bug, but there may be a lot of stuff, and be difficult to know where to search.
Regards,
Mysil
举报