case CHK16 calculated incorrectly from HxD
Intel Hex or Motorola Hex file converter
Brought to you by:
jpelletier
Hello,
While CRC32 and Checksum 8 is correctly calculated i can't say the same for checksum16.
Aren't we missing the carries?
This implementation seems different
http://www.netfor2.com/tcpsum.htm
HxD is reporting a correct value but hex2bin is not
I tried the string "123456789" with HxD: it gives 1DD which is the sum of 31 to 39 in hex.
Hex2bin does the checksum16 calculation on word values: 3132+3334+3536+3738+39FF (B Endian) or 3231+3433+3635+3837+FF39 (L Endian). FF is a pad byte.
I will add a checksum16 calculation on byte values in the next release.
Thanks for your report!
Implemented as -k 5 checksum method