-

Changes

Jump to: navigation, search

Objtohex

2 bytes removed, 11:32, 31 July 2017
no edit summary
binary files, or object files as output. Any other format
required must be produced by running the utility program
OBJTOHEX. This allows conversion of object files as pro-duced produced by the linker into a variety of different formats,
including various hex formats. The program is invoked thus:
OBJTOHEX options inputfile outputfile
The options are:
;-B_�a_�d_�d_�rB<strong>addr</strong>:Produce a binary image output. This is similar to the-C option of the linker. If addr is supplied, thestart of the image file will be offset by addr. If addris omitted, the first byte in the file will be thelowest byte initialized. Addr may be given in decimal,octal or hexadecimal. The default radix is decimal, andsuffix letters of o or O indicate octal, and h or Hindicate hex. Thus -B100H will produce a file in .COMformat.
;-I :Include symbol records in the Intel format hex output.Each symbol record has a form similar to an objectrecord, but with a different record type. The databytes in the record are the symbol name, and theaddress is the value of the symbol. This is useful fordownloading to ROM debuggers.
;-C :Read a checksum specification from the standard input.The checksum specification is described below. Typi-cally Typically the specification will be in a file.
;-E_�s_�t_�a_�c_�kE<strong>stack</strong>:This option produces an MS-DOS .EXE format file. Theoptional stack argument will determine the maximumstack size the program will be allocated on execution.By default the program will be allocated the maximumstack available, up to the limit of 64K data. If astack argument is supplied, the stack size will notexceed the argument. This is useful to limit the amountof memory a program will use. The stack argument takesthe same form as the argument to -B above.
;-8_�s_�t_�a_�c_�k8<strong>stack</strong>:This option will produce a CP/M-86 .CMD file. The stackargument is the same as for the -E option.
;-A_�s_�t_�a_�c_�kA<strong>stack</strong>:This is used when producing a.out format files for unixsystems (specifically Venix-86). If the stack argumentis zero, the size of the data segment will be 64k, oth-erwise otherwise the stack will be placed below the data segment,and its size set to stack. This must be co-ordinatedwith appropriate arguments to the -p option of thelinker.
;-M :This flag will instruct objtohex to produce Motorola'S' format hex output.
;-L :This option is used when producing large model pro-gramsprograms; the linker will have been used with the -LMoption to retain segment relocation information in theobject file. Use of the -L option to objtohex willcause it to convert that segment relocation informationinto appropriate data in the executable file for usewhen the program is loaded. Either the operating systemor the run-time startup code will use the relocationdata to adjust segment references based on where inmemory the program is actually loaded. If the -Loption is followed by a symbol name, then the reloca-tion relocation information will be stored at the addressrepresented by that symbol in the output file, e.g.-L___�B_�b_�s_�s will cause it to be stored at the base of thebss psect (___�B_�b_�s_�s is defined by the linker to be theload address of the bss psect). If the special symbol_�D_�o_�s__�h_�d_�r is used then the relocation information will bestored in the .EXE file header. This is only valid inconjunction with the -E option.
;-L__<strong>Bbss</strong>:will cause it to be stored at the base of the bss psect (__<strong>Bbss</strong> is defined by the linker to be the load address of the bss psect). If the special symbol <strong>Dos_hdr</strong> is used then the relocation information will be stored in the .EXE file header. This is only valid in conjunction with the -E option. ;-S :The -S option instructs objtohex to write a symbolfile. The symbol file name is given after the -S, e.g.-S_�x_�xS<strong>xx._�s_�y_�msym.</strong>
Unless another format is specifically requested,
of a checksum line is:
addr1-addr2 where1-where2 +offset
initialized to zero. For example:
0005-1FFF 3-4 +1FFF

Navigation menu