createCrc16(polynomial: number): (data: Uint8Array) => number
Creates a CRC16 function for the given polynomial.
Uses init=0xffff and xor=0xffff. With CRC16_CCITT_POLYNOMIAL this matches
CRC-16/X-25; other catalogue variants (CRC-16/ARC, CRC-16/MODBUS) use
different init/xor and need a custom implementation.
(data: Uint8Array) => number
A function that calculates CRC16 for given data