merged.hex file built from the same code base is different.

Hello,

I noticed that if I rebuild the merged.hex file from exactly the same code base then all subsequent merged.hex files are different. This is causing us a problem at production.

I am guessing/suspecting this because the file signature/CRC has changed and the reason for its change is something like the timestamp.

Attached is a snapshot of the differences reported by 'Beyond Compare' utility. All the differences are at the end of the merged.hex file.

Q1/ Can you please explain why this is happening?

Q2/ Could you please point me to a document detailing the format of the merged.hex file.

Q3/ Is there a utility that checks only the code content of the merged.hex without including timestamp, CRC, Signature etc...?

Thank you.

Kind regards

Mohamed

Parents Reply
  • Hi Andreas,

    Thank you for all your efforts.

    Strip the signature and hash before comparing the firmware itself.

    Do you mean I manually strip the part of the output build files that show differences built from the same code base i.e merged.hex, app_update.bin and app_signed.hex?

    Use the imgtool verify command to check that the signature of both images can be verified with the same key.

    I am not familiar with imgtool, so I had a look at the case you shared with me where Benjamin V used the command line below,

    imgtool verify --key <key.pem> app_update.bin

    Where do I get the key.pem file from ?

    The Merged.hex is also a composition of different files and we recommend that you compare it to zephyr.hex to look closer into where the difference occurs

    I compared the files merged.hex and zypher.hex from the same build and I am no wiser.

    Thank you.

    Kind regards

    Mohamed

Children
Related