want to get 2 or 4 byte Firmware Checksum

For questions and comments on programming in general. And for any items that don't fit into the forums below.

Moderators: Benj, Mods

Post Reply
Inqore-Systems
Posts: 3
Joined: Thu Feb 16, 2017 1:54 pm
Contact:

want to get 2 or 4 byte Firmware Checksum

Post by Inqore-Systems »

Hi,
I am a new User of Flowcode 7. In order to maintain the Firmware version, i want to view the Checksum produced by the Hex or bin file, so how that can be done in FlowCode 7?

User avatar
Benj
Matrix Staff
Posts: 15312
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 4803 times
Been thanked: 4314 times
Contact:

Re: want to get 2 or 4 byte Firmware Checksum

Post by Benj »

Hello,

Have you seen the Auto Version Identifier component available from the tools menu. This will provide you with an auto incrementing ID value every time you compile the project and can be easily accessed from inside the firmware. You also get the build time and date if this is useful.

If you just want a checksum of say the .hex firmware file then you can use something like this.
http://onlinemd5.com/

Inqore-Systems
Posts: 3
Joined: Thu Feb 16, 2017 1:54 pm
Contact:

Re: want to get 2 or 4 byte Firmware Checksum

Post by Inqore-Systems »

Benj wrote:Hello,

Have you seen the Auto Version Identifier component available from the tools menu. This will provide you with an auto incrementing ID value every time you compile the project and can be easily accessed from inside the firmware. You also get the build time and date if this is useful.

If you just want a checksum of say the .hex firmware file then you can use something like this.
http://onlinemd5.com/
Thank you very much for reply Benj,partially your suggestion works, however if the checksum of the hex file would have been integrated in the generated hex file that would have been easier to maintain the version.

Can this request can be taken in the Flowcode, can i expect in the next release?

User avatar
Benj
Matrix Staff
Posts: 15312
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 4803 times
Been thanked: 4314 times
Contact:

Re: want to get 2 or 4 byte Firmware Checksum

Post by Benj »

Hello,
if the checksum of the hex file would have been integrated in the generated hex file that would have been easier to maintain the version.
I'll have to think about this one, is the auto version ID component not doing it for you?

We would basically have to compile the hex file, collect the checksum and then edit the hex file to add the calculated check sum which would essentially then break the checksum. I'm not sure how to do this in any other way then how the auto version ID is currently doing other than maybe having a routine to scan through all the flash memory and perform the check sum calculations on the micro. This would be possible on a fixed device but that is not the Flowcode philosophy and so would be complex if not impossible to do for all devices.

Post Reply