aboutsummaryrefslogtreecommitdiffstats
path: root/src/crc.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/crc.h')
-rw-r--r--src/crc.h29
1 files changed, 14 insertions, 15 deletions
diff --git a/src/crc.h b/src/crc.h
index 59a496a..0fde2d1 100644
--- a/src/crc.h
+++ b/src/crc.h
@@ -24,18 +24,17 @@
#include <stdint.h>
-
-// The init functions can be used to create a new table with a different polynome
-void init_crc8tab(uint8_t l_code, uint8_t l_init);
-extern uint8_t crc8tab[];
-
-uint8_t crc8(uint8_t l_crc, const void *lp_data, unsigned l_nb);
-
-void init_crc16tab(uint16_t l_code, uint16_t l_init);
-uint16_t crc16(uint16_t l_crc, const void *lp_data, unsigned l_nb);
-extern uint16_t crc16tab[];
-
-void init_crc32tab(uint32_t l_code, uint32_t l_init);
-uint32_t crc32(uint32_t l_crc, const void *lp_data, unsigned l_nb);
-extern uint32_t crc32tab[];
-
+namespace odr{
+
+ // The init functions can be used to create a new table with a different polynome
+ void init_crc8tab(uint8_t l_code, uint8_t l_init);
+
+ uint8_t crc8(uint8_t l_crc, const void *lp_data, unsigned l_nb);
+
+ void init_crc16tab(uint16_t l_code, uint16_t l_init);
+ uint16_t crc16(uint16_t l_crc, const void *lp_data, unsigned l_nb);
+
+ void init_crc32tab(uint32_t l_code, uint32_t l_init);
+ uint32_t crc32(uint32_t l_crc, const void *lp_data, unsigned l_nb);
+
+}