This commit is contained in:
2026-02-24 09:58:06 +08:00
parent fb4e311fbe
commit 9d69b29eed
161 changed files with 20379 additions and 7340 deletions

View File

@@ -0,0 +1,43 @@
#ifndef _APP_COM_H_
#define _APP_COM_H_
#include "main.h"
#include "app_leakage.h"
#include "bsp_uart.h"
#define APP_COM_NUM (4)
#define APP_COM1 (0)
#define APP_COM2 (1)
#define APP_COM3 (2)
#define APP_COM4 (3)
typedef struct
{
u8 baudrate; /*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
}app_com_flash_data_t;
typedef struct app_com_class_t app_com_class_t;
struct app_com_class_t
{
app_com_flash_data_t flash_data; /*flash<73><68><EFBFBD><EFBFBD>*/
bsp_uart_t *com_uart; /*<2A>󶨵<EFBFBD>ʵ<EFBFBD><CAB5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
struct
{
void (*baud_rate)(app_com_class_t *,u16); /*<2A><><EFBFBD>ò<EFBFBD><C3B2><EFBFBD><EFBFBD><EFBFBD>*/
}set;
void (*init)(app_com_class_t *); /*<2A><>ʼ<EFBFBD><CABC>*/
};
typedef struct
{
app_com_class_t com[APP_COM_NUM];
void (*class_update)(void ); /*com<6F><6D><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
}app_com_t;
extern app_com_t app_com;
extern bsp_uart_t *com_to_uart[APP_COM_NUM];
#endif