Class Xor8Checksum

Namespace
ProtoTest.Devices
Assembly
ProtoTest.Devices.dll

A one-byte XOR of every body byte.

public sealed class Xor8Checksum : IDeviceBinaryChecksum
Inheritance
Xor8Checksum
Implements
Inherited Members
Extension Methods

Properties

Size

Gets how many bytes the checksum takes.

public int Size { get; }

Property Value

int

Methods

Compute(ReadOnlySpan<byte>, Span<byte>)

Computes the checksum of body (every byte before it) into destination.

public void Compute(ReadOnlySpan<byte> body, Span<byte> destination)

Parameters

body ReadOnlySpan<byte>
destination Span<byte>