How to create HEX files ?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

How to create HEX files ?

4,926 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Nodame on Thu Feb 11 18:04:08 MST 2010
Would someone please let me know how to create HEX files ?
Is there any option in the project settings tab fot it ?
Sory, I cound not find it.
0 Kudos
Reply
3 Replies

2,780 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Nodame on Thu Feb 11 18:38:46 MST 2010
Sorry, I got it.
Default setting is usualy defined with '#' for existing project examples.
HEX will be created if '#' is deleted from project settings description.

Thank you for your helpful suggestion.
0 Kudos
Reply

2,780 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Nodame on Thu Feb 11 18:33:33 MST 2010
Dear sir,
I found that command description in the project settings as you said.
But in fact, I don't know where HEX file was create.
There is no HEX file in the workspace - even in Debug folder also,
Would you please let me know where ?
0 Kudos
Reply

2,780 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by NXP_USA on Thu Feb 11 18:16:05 MST 2010

Quote: Nodame
Would someone please let me know how to create HEX files ?
Is there any option in the project settings tab fot it ?
Sory, I cound not find it.



LPCXpresso creates .axf files by default, but it includes a program called arm-none-eabi-objcopy which can generate a .hex file.

From the command line:
CD to the LPCXpresso directory- usually C:\NXP\LPCXpresso3.2
Now run objcopy by typing:
Tools\bin\arm-none-eabi-objcopy -O Format input-file output-file

Format is one of binary, srec, ihex, tekhex, symbolsrec. ihex generates an Intel hex format.

input-file is the .axf file and output-file is the name of the output file

A call to objcopy can be added as a post-build step to auto-generate the hex file.

arm-none-eabi-objcopy –O ihex ${BuildArtifactFileName} ${BuildArtifactFileBaseName}.hex
0 Kudos
Reply