hex.htm

来自「刚刚看到本站有Visual C++数字图象处理(人民邮电出版社)的电子书」· HTM 代码 · 共 350 行 · 第 1/2 页

HTM
350
字号
information within this record.</pre>

    <pre>load offset

this field contains 030303030h, the hexadecimal encoding of the

ascii characters '0000', since this field is not used for this

record.</pre>

    <pre>rectyp

this field contains 03032h, the hexadecimal encoding of the ascii

character '02', which specifies the record type to be an extended

segment address record.</pre>

    <pre>usba

this field contains four ascii hexadecimal digits that specify the

16-bit upper segment base address value.  the high-order byte is the

10th/1lth character pair of the record.  the low-order byte is the

12th/13th character pair of the record.</pre>

    <pre>chksum

this field contains the check sum on the reclen, load offset,

rectyp, and usba fields.</pre>

    <pre>5.    data record   (8-, 16-, or 32-bit formats)</pre>

    <pre>| record  |     load     |         |         |         |         |

|  mark   |    reclen    | offset  | rectyp  |  data   | chksum  |

|  ':'    |              |         |  '00'   |         |         |

  1-byte       1-byte      2-bytes   1-byte    n-bytes   1-byte

</pre>

    <pre>the data record provides a set of hexadecimal digits that represent

the ascii code for data bytes that make up a portion of a memory

image.  the method for calculating the absolute address (linear in

the 8-bit and 32-bit case and segmented in the 16-bit case) for each

byte of data is described in the discussions of the extended linear

address record and the extended segment address record.</pre>

    <pre>the contents of the individual fields within the record are:</pre>

    <pre>record mark

this field contains 03ah, the hexadecimal encoding of the ascii

colon (':') character.</pre>

    <pre>reclen

the field contains two ascii hexadecimal digits that specify the

number of data bytes in the record.  the maximum value is 'ff' or

04646h (255 decimal).</pre>

    <pre>load offset

this field contains four ascii hexadecimal digits representing the

offset from the lba (see extended linear address record) or sba (see

extended segment address record) defining the address which the

first byte of the data is to be placed.</pre>

    <pre>rectyp

this field contains 03030h, the hexadecimal encoding of the ascii

character '00', which specifies the record type to be a data record.</pre>

    <pre>data

this field contains pairs of ascii hexadecimal digits, one pair for

each data byte.</pre>

    <pre>chksum

this field contains the check sum on the reclen, load offset,

rectyp, and data fields.

</pre>

    <pre>6.    start linear address record  (32-bit format only)</pre>

    <pre>| record  |     load     |         |         |         |         |

|  mark   |    reclen    | offset  | rectyp  |  eip    | chksum  |

|  ':'    |    '04'      | '0000'  |  '05'   |         |         |

  1-byte       1-byte      2-bytes   1-byte    4-bytes   1-byte

</pre>

    <pre>the start linear address record is used to specify the execution

start address for the object file.  the value given is the 32-bit

linear address for the eip register.  note that this record only

specifies the code address within the 32-bit linear address space of

the 80386.  if the code is to start execution in the real mode of

the 80386, then the start segment address record should be used

instead, since that record specifies both the cs and ip register

contents necessary for real mode.</pre>

    <pre>the start linear address record can appear anywhere in a 32-bit

hexadecimal object file.  if such a record is not present in a

hexadecimal object file, a loader is free to assign a default start

address.</pre>

    <pre>the contents of the individual fields within the record are:</pre>

    <pre>record mark

this field contains 03ah, the hexadecimal encoding of the ascii

colon (':') character.</pre>

    <pre>reclen

the field contains 03034h, the hexadecimal encoding of the ascii

characters '04', which is the length, in bytes, of the eip register

content within this record.</pre>

    <pre>load offset

this field contains 030303030h, the hexadecimal encoding of the

ascii characters '0000', since this field is not used for this

record.</pre>

    <pre>rectyp

this field contains 03035h, the hexadecimal encoding of the ascii

character '05', which specifies the record type to be a start linear

address record.</pre>

    <pre>eip

this field contains eight ascii hexadecimal digits that specify the

32-bit eip register contents.  the high-order byte is the 10th/1lth

character pair.</pre>

    <pre>chksum

this field contains the check sum on the reclen, load offset,

rectyp, and eip fields.

</pre>

    <pre>7.    start segment address record (16- or 32-bit formats)</pre>

    <pre>| record  |     load     |         |         |         |         |

|  mark   |    reclen    | offset  | rectyp  |  cs/ip  | chksum  |

|  ':'    |    '04'      | '0000'  |  '03'   |         |         |

  1-byte       1-byte      2-bytes   1-byte    4-bytes   1-byte

</pre>

    <pre>the start segment address record is used to specify the execution

start address for the object file.  the value given is the 20-bit

segment address for the cs and ip registers.  note that this record

only specifies the code address within the 20-bit segmented address

space of the 8086/80186.</pre>

    <pre>the start segment address record can appear anywhere in a 16-bit

hexadecimal object file.   if such a record is not present in a

hexadecimal object file, a loader is free to assign a default start

address.</pre>

    <pre>the contents of the individual fields within the record are:</pre>

    <pre>record mark

this field contains 03ah, the hexadecimal encoding of the ascii

colon (':') character.</pre>

    <pre>reclen

the field contains 03034h, the hexadecimal encoding of the ascii

characters '04', which is the length, in bytes, of the cs/ip

register contents within this record.</pre>

    <pre>load offset

this field contains 030303030h, the hexadecimal encoding of the

ascii characters '0000', since this field is not used for this

record.</pre>

    <pre>rectyp

this field contains 03033h, the hexadecimal encoding of the ascii

character '03', which specifies the record type to be a start

segment address record.</pre>

    <pre>cs/ip

this field contains eight ascii hexadecimal digits that specify the

16-bit cs register and 16-bit ip register contents.  the high-order

byte of the cs register content is the 10th/llth character pair, the

low-order byte is the 12th/13th character pair of the record.  the

high-order byte of the ip register content is the 14th/15th

character pair, the low-order byte is the 16th/17th character pair

of the record.</pre>

    <pre>chksum

this field contains the check sum on the reclen, load offset,

rectyp, and cs/ip fields.



</pre>

    <pre>8.   end of file record  (8-, 16-, or 32-bit formats)</pre>

    <pre>| record  |     load     |         |         |         |

|  mark   |    reclen    | offset  | rectyp  | chksum  |

|  ':'    |    '00'      | '0000'  |  '01'   |         |

  1-byte       1-byte      2-bytes   1-byte    1-byte</pre>

    <pre>the end of file record specifies the end of the hexadecimal object

file.</pre>

    <pre>the contents of the individual fields within the record are:</pre>

    <pre>record  mark

this field contains 03ah, the hexadecimal encoding of the ascii

colon (':') character.</pre>

    <pre>reclen

the field contains 03030h, the hexadecimal encoding of the ascii

characters '00'.  since this record does not contain any info/data

bytes, the length is zero.</pre>

    <pre>load  offset

this field contains 030303030h, the hexadecimal encoding of the

ascii characters '0000', since this field is not used for this

record.</pre>

    <pre>rectyp

this field contains 03031h, the hexadecimal encoding of the ascii

character '01', which specifies the record type to be an end of file

record.</pre>

    <pre>chksum

this field contains the check sum an the reclen, load offset, and

rectyp fields.  since all the fields are static, the check sum can

also be calculated statically, and the value is 04646h, the

hexadecimal encoding of the ascii characters 'ff'.d</pre>

    </td>

  </tr>

</table>

</center></div>



<p align="center"><a href="../index.htm">返回</a></p>

</body>

</html>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?