AnsweredAssumed Answered

CRC32 Calculation in MPC5777C

Question asked by Prathap V C on Jul 29, 2019
Latest reply on Jul 29, 2019 by Lukas Zadrapa

const uint8_t TextString1[] = "0123456789"; 

 

CRC.CNTX[0].CRC_CFG.R = 0x00000005;        /* CRC-32 polynomial, Inversion selection enabled */
CRC.CNTX[0].CRC_CSTAT.R = 0xFFFFFFFF;   /* Seed value 0xFFFFFFFF */

 

 

for(i=0; i<sizeof(TextString1)-1; i++)                     /* size of TextString1 is decreased by 1 due to null character of string */
*(uint8_t*)&CRC.CNTX[0].CRC_INP.R = TextString1[i];

crc_outpt = CRC.CNTX[0].CRC_OUTP.R;

 

 

Output:

crc_outpt = 0x63e32165

 

 

But when i enter the same string on CRC32 Online calculator in following link

https://crc32.online/

the result is a684c7c6

 

 

Why is this difference in output of CRC32?  Can you suggest any settings to be modified

 

Outcomes