SumProject/board/ports/led_matrix/drv_matrix_led.h

30 lines
858 B
C

#ifndef _LED_MATRIX
#define _LED_MATRIX
#include <rtthread.h>
typedef struct RGBColor_TypeDef
{
uint8_t G;
uint8_t R;
uint8_t B;
} RGBColor_TypeDef; // 颜色结构体
// //灯处于特定颜色还是闪烁状态
// extern uint8_t LED_Blink_Staue[LED_NUM]={0};
// // 灯闪烁颜色缓存
// extern RGBColor_TypeDef LED_Blink_Color[LED_NUM] = {0};
extern const RGBColor_TypeDef LED_DARK;
extern const RGBColor_TypeDef LED_GREEN;
extern const RGBColor_TypeDef LED_RED;
extern const RGBColor_TypeDef LED_BLUE;
extern const RGBColor_TypeDef LED_WHITE;
extern void Set_LEDColor(uint16_t LedId, RGBColor_TypeDef Color);
extern void LED_Set(uint16_t LedId, RGBColor_TypeDef Color);
extern void LED_Blink(uint16_t LedId, RGBColor_TypeDef Color);
extern void RGB_Reflash(void);
extern void LED_LITTLE_TEST(void);
extern void led_matrix_rst();
#endif