BLE_DCF_TYQ_CH592F/BSP/inc/bsP_bt.h

22 lines
917 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.

struct __attribute__((packed)) valve_data
{
// uint8_t valve_id;
// uint8_t valve_mac[6];
uint8_t header;
uint8_t cmd;
uint8_t data_len;
uint8_t valve_type; // 阀门类型
uint8_t valve_bat; // 1B 电池电压 30=3V,18=1.8V
uint8_t valve_status; // 1B 阀门工作状态 超欠压、过流
uint8_t valve_connct_status; // 1B 阀门连接状态 电磁阀BLE控制盒 0=未连接 1=已连接
uint8_t valve_switch_status; // 1B 阀门开关状态 0=未知 1=关闭 2=关闭过,未按按键恢复 3=关闭过,按下了恢复键 4=打开
int8_t valve_temp; // 1B 阀门温度 有符号整数 25 ℃
uint8_t valve_humidity; // 1B 阀门湿度 0~100%;
uint32_t valve_in_pressure; // 4B 阀门入口压力 Pa
uint32_t valve_out_pressure; // 4B 阀门出口压力 Pa
uint32_t valve_atm_pressure; // 4B 阀门大气压力 Pa
uint8_t tail;
};