JaiaBot  1.20.1
JaiaBot micro-AUV software
fletcher16.h File Reference
#include <stdint.h>
#include <stdlib.h>
Include dependency graph for fletcher16.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

uint16_t fletcher16 (const void *input_str, size_t num_bytes)
 Calculate the Fletcher-16 checksum of a block of data. More...
 

Function Documentation

◆ fletcher16()

uint16_t fletcher16 ( const void *  input_str,
size_t  num_bytes 
)

Calculate the Fletcher-16 checksum of a block of data.

Parameters
input_strPointer to the start of the data block.
num_bytesLength of the data block, in bytes.
Returns
Note
The Fletcher checksum is an algorithm for computing a position-dependent checksum devised by John G. Fletcher (1934–2012) at Lawrence Livermore Labs in the late 1970s.[1] The objective of the Fletcher checksum was to provide error-detection properties approaching those of a cyclic redundancy check but with the lower computational effort associated with summation techniques.

Definition at line 9 of file fletcher16.h.