ARM Technical Support Knowledge Articles

MAKING HEX FILES FROM BINARY FILES

Applies to: General Topics

Answer

QUESTION

I need to create a HEX file from a BINARY file. Where can I find a utility that does that?

ANSWER

There is such a utility program available on the Keil web site called BIN2HEX.ZIP. This program converts BINARY files into Intel HEX, HEX-286, and HEX-386 files. Run this program from the DOS prompt to see the list of directives:

Syntax: BIN2HEX [/option] binfile [hexfile]

BINFILE   is the binary input file
HEXFILE   is the Intel HEX file to create

OPTION    may be any of the following

  /Ln     Bytes to read from binary file
  /In     Binary file starting offset
  /On     Output file address offset (where HEX data starts)
  /M      Merge data into existing HEX file
  /2      Generate HEX file using ext. segment address records (HEX86)
  /4      Generate HEX file using ext. linear address records (HEX386)
  /Q      Quiet mode (no statistics are displayed)
  /T      Exclude EOF record
  /A      Append to end of existing HEX file

  /?      This help text

Article last edited on: 2007-03-27 11:04:11

Rate this article

[Bad]
|
|
[Good]
Disagree? Move your mouse over the bar and click

Did you find this article helpful? Yes No

How can we improve this article?

Link to this article
Copyright © 2011 ARM Limited. All rights reserved. External (Open), Non-Confidential