X-Git-Url: https://git.zerfleddert.de/cgi-bin/gitweb.cgi/proxmark3-svn/blobdiff_plain/b8140ab10879ffe6fe8d7b7add1cb66f2610d2d1..00848e096b408a43786ea283d4e77d32189994b9:/common/crc.h?ds=sidebyside diff --git a/common/crc.h b/common/crc.h index 946be8a1..e2ccd34b 100644 --- a/common/crc.h +++ b/common/crc.h @@ -11,6 +11,7 @@ #include #include +#include typedef struct crc { uint32_t state; @@ -39,6 +40,10 @@ extern uint32_t crc_finish(crc_t *crc); // Calculate CRC-8/Maxim checksum uint32_t CRC8Maxim(uint8_t *buff, size_t size ); + +// Calculate CRC-8 Mifare MAD checksum +uint32_t CRC8Mad(uint8_t *buff, size_t size); + /* Static initialization of a crc structure */ #define CRC_INITIALIZER(_order, _polynom, _initial_value, _final_xor) { \ .state = ((_initial_value) & ((1L<<(_order))-1)), \