设备屏蔽功能
适配新版界面
This commit is contained in:
2026-03-06 13:48:42 +08:00
parent 090eb335a8
commit 7373c0ad95
14 changed files with 854 additions and 337 deletions
+6 -1
View File
@@ -6,6 +6,9 @@
#define ENABLE (1)
#define DISABLE (0)
#define BLOCKED (1) /*屏蔽*/
#define UNBLOCKED (0)
#define APP_LEAKAGE_SUB_DEVICE_STATE_LEAKAGE (0x0001) /*漏液状态*/
#define APP_LEAKAGE_SUB_DEVICE_STATE_OPEN (0x0002) /*断带状态*/
#define APP_LEAKAGE_SUB_DEVICE_STATE_TIME_OUT (0x8000) /*通讯超时*/
@@ -24,6 +27,8 @@ typedef struct
{
u8 state; /*状态 使能 非使能*/
u8 com; /*端口*/
u8 baudrate; /*波特率*/
u8 shield; /*设备屏蔽状态*/
u8 modbus_id; /*modbus id*/
u8 device_name[APP_LEAKAGE_STRING_NANE_LEN]; /*设备名*/
u8 region_name[APP_LEAKAGE_STRING_NANE_LEN]; /*区域名*/
@@ -61,7 +66,7 @@ typedef struct
u8 device_id; /* 设备ID */
u8 device_name[APP_LEAKAGE_STRING_NANE_LEN]; /* 设备名称 */
u16 alarm_type; /* 报警类型 */
u8 start_time[6]; /* 开始时间: 年(2字节)月日时分 */
u8 start_time[7]; /* 开始时间: 年(2字节)月日时分 */
u16 leak_distance; /* 漏液距离 (0表示非漏液报警) */
u8 channel; /* 通道号 (0-3) */
} app_leakage_history_alarm_t;