#ifndef MAD_CORE_COMMON_H #define MAD_CORE_COMMON_H #include "common/math.h" #include "common/types.h" #include "common/watchdog.h" #include #include #define UNUSED(s) (void)(s) #define BIT(n) (0x1U << (n)) #define MAX(a, b) ((a) > (b) ? (a) : (b)) #define MIN(a, b) ((a) < (b) ? (a) : (b)) #define CLAMP(n, hi, lo) (MIN((hi), MAX((n), (lo)))) void Info(const char *fmt, ...); void Error(const char *fmt, ...); #include #define Sleep(ms) _delay_ms(ms) #endif // MAD_CORE_COMMON_H