-
Notifications
You must be signed in to change notification settings - Fork 17.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
AP_Math: rename crc_sum8 to crc_sum8_with_carry
the name "sum8" is usually used for "sum all bytes into a uint8_t discarding carry"
- Loading branch information
1 parent
7da434d
commit 34ecdec
Showing
2 changed files
with
5 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -35,8 +35,10 @@ uint32_t crc32_small(uint32_t crc, const uint8_t *buf, uint32_t size); | |
uint32_t crc_crc24(const uint8_t *bytes, uint16_t len); | ||
uint16_t crc_crc16_ibm(uint16_t crc_accum, uint8_t *data_blk_ptr, uint16_t data_blk_size); | ||
|
||
// checksum used by SPORT/FPort | ||
uint8_t crc_sum8(const uint8_t *p, uint8_t len); | ||
// checksum used by SPORT/FPort. For each byte, adds it to a 16-bit | ||
// sum, then adds those two bytes together. Returns the complement of | ||
// the final sum. | ||
uint8_t crc_sum8_with_carry(const uint8_t *p, uint8_t len); | ||
|
||
// Copyright (C) 2010 Swift Navigation Inc. | ||
// Contact: Fergus Noble <[email protected]> | ||
|