Expand description
Utility for cyclic redundancy check (CRC) calculate.
§Examples
use easy_modbus::util::crc::{check, compute};
let data = vec![0x0B, 0x01, 0x00, 0x1D, 0x00, 0x1F];
let crc = compute(&data);
assert_eq!(crc, 0xED6E);
let b = check(&data, 0xED6E);
assert_eq!(b, true);