AnsweredAssumed Answered

How to compute for the same CRC32 that the ST-LINK utility tool is calculating?

Question asked by mret on Jan 19, 2017
Latest reply on Jan 23, 2017 by Imen D

Hi,

 

I'm developing a customized SPI Bootloader code. I plan to use CRC32 in verifying the programmed application code. I used this link as a reference for my CRC32 calculator C-code function in the Bootloader:

 

stm32-spi-bootloader/spi-bootloader.c at master · joeferner/stm32-spi-bootloader · GitHub 

http://www.ipgp.fr/~tuchais/earthworm/v6.3/src/data_sources/naqs2ew/crc32.c 

 

But, the values that I get when I use that function isn't the same to the ones I get when I load the hex or bin file to ST-Link. ST-Link is showing different CRC32 values.

 

On the other hand, when I use online tools such as:

 

http://www.fileformat.info/tool/hash.htm 

MD5 And CRC-32 Calculation Utilities For Windows (Similar To Unix "md5sum -b") 

 

I am getting the same CRC32 values with my C-code function.

 

Is ST-LINK using a different algorithm (but in the user manual, it says that it's using CRC32)?

 

Any insights is appreciated!

 

Thanks,

Outcomes