From b7951bdbb8925131cbc76be4902fcef0e88d0506 Mon Sep 17 00:00:00 2001 From: ytfl <ytfl@qq.com> Date: 星期二, 19 八月 2025 18:22:03 +0800 Subject: [PATCH] #自动获取电视机配置信息 --- src/main/java/com/zy/core/thread/SiemensCrnThread.java | 10 +++++++++- 1 files changed, 9 insertions(+), 1 deletions(-) diff --git a/src/main/java/com/zy/core/thread/SiemensCrnThread.java b/src/main/java/com/zy/core/thread/SiemensCrnThread.java index f9ecce5..27e31f3 100644 --- a/src/main/java/com/zy/core/thread/SiemensCrnThread.java +++ b/src/main/java/com/zy/core/thread/SiemensCrnThread.java @@ -208,7 +208,15 @@ } } - if (System.currentTimeMillis() - crnProtocol.getDeviceDataLog() > 1000 * 5) { + if (crnProtocol.getAlarm() > 0) { + crnProtocol.setLastCommandTime(-1L); + } + + if (crnProtocol.getAlarm() == 0 && crnProtocol.getLastCommandTime() == -1) { + crnProtocol.setLastCommandTime(System.currentTimeMillis()); + } + + if (System.currentTimeMillis() - crnProtocol.getDeviceDataLog() > 1000 * 1) { //閲囬泦鏃堕棿瓒呰繃5s锛屼繚瀛樹竴娆℃暟鎹褰� //淇濆瓨鏁版嵁璁板綍 DeviceDataLogService deviceDataLogService = SpringUtils.getBean(DeviceDataLogService.class); -- Gitblit v1.9.1