运行记录改变时,不进行上报,没10分钟或者APP读取时仍会上报

This commit is contained in:
2026-09-07 18:12:06 +08:00
parent 0de88083ba
commit f4b0b3213c
+3 -6
View File
@@ -647,6 +647,8 @@ static void jbUnpackDps(const uint8_t *bitmap, const uint8_t *values,
/* ════════════════════════════════════════════════════════════════
* jbBuildDiffMask — 比较上次与当前值,为变化的可上报 DP 置 mask 位
* 返回: 1 = 有 DP 发生变化, 0 = 全部未变化
* DP17 运行记录不参与差分:秒数常变,避免 2s 一包 124B;仍走读请求与定时全量
* ════════════════════════════════════════════════════════════════ */
static uint8_t jbBuildDiffMask(const jb_data_point_t *last,
const jb_data_point_t *cur,
@@ -752,12 +754,7 @@ static uint8_t jbBuildDiffMask(const jb_data_point_t *last,
mask[DP_ID_TIME_CONFIG7 / 8] |= (1 << (DP_ID_TIME_CONFIG7 % 8));
hasChange = 1;
}
/* DP17 运行记录 */
if (memcmp(last->run_record, cur->run_record, 124))
{
mask[DP_ID_RUN_RECORD / 8] |= (1 << (DP_ID_RUN_RECORD % 8));
hasChange = 1;
}
/* DP17 运行记录:不进差分(秒累加会刷 0x07);0x05 读 / 10min 全量仍带 */
/* DP19 设备故障使能 */
if (last->fault_en != cur->fault_en)
{