RTU/release/inc/cbb_compat.h

26 lines
599 B
C
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

/*
* cbb_compat.h — CBB 库兼容类型别名
*
* CBB 库lib60870使用了 u8/u16/u32/s16/s32/f32/BOOL/TRUE/FALSE
* 等自定义类型/宏,这些类型在原库中依赖 ostype.h 外部定义。
* 此处通过 gcc -include 注入,不修改 CBB 库任何源文件。
*/
#ifndef _CBB_COMPAT_H_
#define _CBB_COMPAT_H_
#include <stdint.h>
#include <stdbool.h>
typedef uint8_t u8;
typedef uint16_t u16;
typedef uint32_t u32;
typedef int16_t s16;
typedef int32_t s32;
typedef float f32;
typedef bool BOOL;
#define TRUE true
#define FALSE false
#endif /* _CBB_COMPAT_H_ */