You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
380 B
26 lines
380 B
#ifndef __UTILS_H_____
|
|
#define __UTILS_H_____
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
#define CRC8_TABLE 1
|
|
|
|
/*
|
|
* jump to address `vect'.
|
|
* if success, don't return. failed, return -1.
|
|
*/
|
|
int go(unsigned long vect);
|
|
|
|
/* CRC-8 x8+x2+x+1 */
|
|
unsigned char crc8(const unsigned char *data, int len);
|
|
|
|
void delay_microseconds(unsigned int us);
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|