AnsweredAssumed Answered

crc8 Calculation for MAD2 sector AN10787

Question asked by Charles Missud on Apr 8, 2019
Latest reply on May 6, 2019 by Jonathan Iglesias

Hi,

 

We are using Mifare Plus card. We want to implement MIFARE Application Diractory (MAD2) sector as per AN10787 of NXP. It's just that I do not have the same result for the CRC8 calculation as per the table 11 of the application note.

My result is 0xA2 while the example says it should be 0x89.

Notice that I've used the function from NXP library:

      phStatus_t phTools_CalculateCrc8(uint8_t bOption,uint8_t bPreset,uint8_t bPolynom,uint8_t * pData,
                                 uint16_t wDataLength,uint8_t * pCrc)

Notice also that the Polynom definition is provided by NXP (''PH_TOOLS_CRC8_POLY_EPCUID   0x1DU ") but not the preset value mentionned into the application note which I pass directly as 0xE3.

 

Also, using an online Web CRC8 calculator I've found that my result is compliant with CRC-8/I-CODE (using 0xFD* as the preset value).

* : Note that 0xFD is the preset value of NXP Mifare PH_TOOLS_CRC8_PRESET_UID... !!!???

 

Anyone aware of the issue ?

Does anyone have another example of the expected result for MAD2 CRC8 calculation ?

 

Thanks, regards,

Outcomes