Method: OpenC3::Crc64#initialize

Defined in:
lib/openc3/utilities/crc.rb

#initialize(poly = DEFAULT_POLY, seed = DEFAULT_SEED, xor = true, reflect = true) ⇒ Crc64

Creates a 64 bit CRC algorithm instance. By default it is initialzed to use the algorithm.

Parameters:

  • poly (Integer) (defaults to: DEFAULT_POLY)

    Polynomial to use when calculating the CRC

  • seed (Integer) (defaults to: DEFAULT_SEED)

    Seed value to start the calculation

  • xor (Boolean) (defaults to: true)

    Whether to XOR the CRC result with 0xFFFF

  • reflect (Boolean) (defaults to: true)

    Whether to bit reverse each byte of data before calculating the CRC



307
308
309
310
311
312
# File 'lib/openc3/utilities/crc.rb', line 307

def initialize(poly = DEFAULT_POLY,
               seed = DEFAULT_SEED,
               xor = true,
               reflect = true)
  super(poly, seed, xor, reflect)
end