habitat.utils.checksums: Various checksum calculation functions

Various checksum calculation utilities.

habitat.utils.checksums.crc16_ccitt(data)[source]

Calculate the CRC16 CCITT checksum of data.

(CRC16 CCITT: start 0xFFFF, poly 0x1021)

habitat.utils.checksums.xor(data)[source]

Calculate the XOR checksum of data.

habitat.utils.checksums.fletcher_16(data, modulus=255)[source]

Calculate the Fletcher-16 checksum of data, default modulus 255.

Previous topic

habitat.utils: various utilities

Next topic

habitat.utils.crashmat: Error handling and process termination

This Page