From b60ca6531a5f9361a82fae182883727e27081fe0 Mon Sep 17 00:00:00 2001
From: zjj <3272660260@qq.com>
Date: 星期一, 25 八月 2025 08:23:45 +0800
Subject: [PATCH] #

---
 src/main/java/com/zy/core/thread/SiemensCrnThread.java |    7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/src/main/java/com/zy/core/thread/SiemensCrnThread.java b/src/main/java/com/zy/core/thread/SiemensCrnThread.java
index adb5ad2..27394d2 100644
--- a/src/main/java/com/zy/core/thread/SiemensCrnThread.java
+++ b/src/main/java/com/zy/core/thread/SiemensCrnThread.java
@@ -157,8 +157,8 @@
             if (result.IsSuccess) {
                 if (null == crnProtocol) {
                     crnProtocol = new CrnProtocol();
-                    crnProtocol.setCrnNo(slave.getId());
                 }
+                crnProtocol.setCrnNo(slave.getId());
                 crnProtocol.setMode(siemensNet.getByteTransform().TransInt16(result.Content, 0));
                 crnProtocol.setTaskNo(siemensNet.getByteTransform().TransInt16(result.Content, 2));
                 crnProtocol.setStatus(siemensNet.getByteTransform().TransInt16(result.Content, 4));
@@ -185,8 +185,8 @@
 
                 // 澶嶄綅淇″彿
                 if (!Cools.isEmpty(crnProtocol.getStatusType()) && crnProtocol.getStatusType().equals(CrnStatusType.WAITING)) {
-//                    News.error("---绗竴姝ャ�乕鍫嗗灈鏈哄彿锛歿}, 宸ヤ綔鍙凤細{}, 杞借揣鍙颁俊鍙�:{}]==>> 鐘舵�佷负10锛岀瓑寰呯‘璁わ紒锛�",
-//                            slave.getId(),crnProtocol.getTaskNo(), crnProtocol.getLoaded()==1 ? "鏈夌墿" : "鏃犵墿");
+                    News.error("---绗竴姝ャ�乕鍫嗗灈鏈哄彿锛歿}, 宸ヤ綔鍙凤細{}, 杞借揣鍙颁俊鍙�:{},鐘舵��:{}]==>> 鐘舵�佷负10锛岀瓑寰呯‘璁わ紒锛�",
+                            slave.getId(),crnProtocol.getTaskNo(), crnProtocol.getLoaded()==1 ? "鏈夌墿" : "鏃犵墿",crnProtocol.getStatusType());
                     if (resetFlag) {
                         if(crnProtocol.getTaskNo()==9999){
                             backHpFlag = false;
@@ -354,6 +354,7 @@
                     if(result.IsSuccess){
                         //鍫嗗灈鏈轰换鍔″啓鍏ュ悗锛屽洖璇讳竴娆★紝鐪嬫槸鍚︽垚鍔�
                         Thread.sleep(200);
+                        log.info("鍫嗗灈鏈轰换鍔″畬鎴愬浣嶏紝姝ゆ椂鍫嗗灈鏈虹姸鎬�:"+crnProtocol.getStatusType()+",鍫嗗灈鏈篿d:"+crnProtocol.getCrnNo());
                         OperateResultExOne<byte[]> resultRead = siemensNet.Read("DB100.18", (short) 2);
                         if (resultRead.IsSuccess) {
                             commandFinish=siemensNet.getByteTransform().TransInt16(resultRead.Content, 0);

--
Gitblit v1.9.1