dRonin  adbada4
dRonin firmware
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
pios_crc.h
Go to the documentation of this file.
1 
14 /*
15  * This program is free software; you can redistribute it and/or modify
16  * it under the terms of the GNU General Public License as published by
17  * the Free Software Foundation; either version 3 of the License, or
18  * (at your option) any later version.
19  *
20  * This program is distributed in the hope that it will be useful, but
21  * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
22  * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
23  * for more details.
24  *
25  * You should have received a copy of the GNU General Public License along
26  * with this program; if not, see <http://www.gnu.org/licenses/>
27  */
28 
29 #include <stdint.h>
30 
31 uint8_t PIOS_CRC_updateByte(uint8_t crc, const uint8_t data);
32 uint8_t PIOS_CRC_updateCRC(uint8_t crc, const uint8_t* data, int32_t length);
33 uint8_t PIOS_CRC_updateCRC_TBS(uint8_t crc, const uint8_t *data, int32_t length);
34 
35 uint16_t PIOS_CRC16_updateByte(uint16_t crc, const uint8_t data);
36 uint16_t PIOS_CRC16_updateCRC(uint16_t crc, const uint8_t* data, int32_t length);
37 uint16_t PIOS_CRC16_CCITT_updateCRC(uint16_t crc, const uint8_t *data, uint32_t data_len);
38 
39 uint32_t PIOS_CRC32_updateByte(uint32_t crc, const uint8_t data);
40 uint32_t PIOS_CRC32_updateCRC(uint32_t crc, const uint8_t* data, int32_t length);
union @12 crc
uint16_t PIOS_CRC16_CCITT_updateCRC(uint16_t crc, const uint8_t *data, uint32_t data_len)
Definition: pios_crc.c:235
uint8_t data[XFER_BYTES_PER_PACKET]
Definition: bl_messages.h:129
uint8_t length
uint8_t PIOS_CRC_updateByte(uint8_t crc, const uint8_t data)
Definition: pios_crc.c:141
uint16_t PIOS_CRC16_updateByte(uint16_t crc, const uint8_t data)
Definition: pios_crc.c:198
uint32_t PIOS_CRC32_updateByte(uint32_t crc, const uint8_t data)
Definition: pios_crc.c:265
uint16_t PIOS_CRC16_updateCRC(uint16_t crc, const uint8_t *data, int32_t length)
Update a CRC with a data buffer.
Definition: pios_crc.c:210
uint8_t PIOS_CRC_updateCRC_TBS(uint8_t crc, const uint8_t *data, int32_t length)
Definition: pios_crc.c:185
uint32_t PIOS_CRC32_updateCRC(uint32_t crc, const uint8_t *data, int32_t length)
Update a CRC with a data buffer.
Definition: pios_crc.c:277
uint8_t PIOS_CRC_updateCRC(uint8_t crc, const uint8_t *data, int32_t length)
Update a CRC with a data buffer.
Definition: pios_crc.c:153