Convert hex to bin file with correct address offset

1.4k views Asked by At

I want to convert a hex file into a bin file. I know that this question is already asked several times but my problem is, that no tool can give me the absolute starting address of the hex file.

For example, if I use the "hex2bin"-Tool (http://hex2bin.sourceforge.net/) to convert a .hex in .bin, the tool does not return the absolute "start address"/"offset address" of the hex file and at the end I can't find a given absolute address in the .bin file.

I hope someone can suggest me a solution to solve this problem.

1

There are 1 answers

0
user1519979 On

enter image description hereRead out the 3rd and 4th byte off you hex file. It should specify teh offset of your data bytes.

http://www.piclist.com/techref/fileext/hex/intel.htm

Each record has a LOAD OFFSET field which specifies the 16- bit starting load offset of the data bytes, therefore this field is only used for Data Records. In other records where this field is not used, it should be coded as four ASCII zero characters ('0000' or 030303030H).