From fbfe9076eaa13dfbfc34e604fb3f7d26820b4137 Mon Sep 17 00:00:00 2001
From: yxFwq <1>
Date: 星期五, 30 五月 2025 08:15:57 +0800
Subject: [PATCH] #

---
 src/main/java/com/zy/core/thread/JarThread.java |   51 ++++++----
 src/main/webapp/views/crn.html                  |    7 +
 src/main/webapp/static/js/console.map23.js      |   26 ++--
 src/main/webapp/views/index.html                |    4 
 src/main/webapp/views/ste.html                  |   11 +-
 src/main/webapp/static/js/console.map21.js      |  142 +++++++++++++++++++++++++++
 src/main/webapp/static/js/console.map.js        |   58 +++++++++++
 7 files changed, 253 insertions(+), 46 deletions(-)

diff --git a/src/main/java/com/zy/core/thread/JarThread.java b/src/main/java/com/zy/core/thread/JarThread.java
index fd92bdd..3f3fdc2 100644
--- a/src/main/java/com/zy/core/thread/JarThread.java
+++ b/src/main/java/com/zy/core/thread/JarThread.java
@@ -121,7 +121,7 @@
                     }
                 }
             } catch (Exception e) {
-                log.error("rgv杩炴帴澶辫触锛侊紒锛� ===>> [id:{}] [ip:{}] [port:{}]", slave.getId(), slave.getIp(), slave.getPort());
+                log.error("jar杩炴帴澶辫触锛侊紒锛� ===>> [id:{}] [ip:{}] [port:{}]", slave.getId(), slave.getIp(), slave.getPort());
                 initSte();
 //                e.printStackTrace();
             }
@@ -137,7 +137,7 @@
                 readStatus();
 
             } catch (Exception e) {
-                log.error("RGV鏁版嵁璇诲彇绾跨▼寮傚父锛侊紒锛� ===>> [id:{}] [ip:{}] [port:{}]", slave.getId(), slave.getIp(), slave.getPort());
+                log.error("JAR鏁版嵁璇诲彇绾跨▼寮傚父锛侊紒锛� ===>> [id:{}] [ip:{}] [port:{}]", slave.getId(), slave.getIp(), slave.getPort());
 
                 initSte();
 //                e.printStackTrace();
@@ -151,34 +151,43 @@
      * 鍒濆鍖栧爢鍨涙満鐘舵��
      */
     private void initSte() {
-        if (null == jarProtocol) {
-            jarProtocol = new JarProtocol();
+        try{
+            if (null == jarProtocol) {
+                jarProtocol = new JarProtocol();
+            }
+            jarProtocol.setJarNo(slave.getId());
+            jarProtocol.setMode( 0);
+            jarProtocol.setStatus(JarStatusType.OFF_LINE);
+            jarProtocol.setJarErr(0);
+        } catch (Exception e){
+            log.error("JAR鍒濆鍖栧紓甯革紒锛侊紒 ===>> [id:{}] [ip:{}] [port:{}]", slave.getId(), slave.getIp(), slave.getPort());
         }
-        jarProtocol.setJarNo(slave.getId());
-        jarProtocol.setMode( 0);
-        jarProtocol.setStatus(JarStatusType.OFF_LINE);
-        jarProtocol.setJarErr(0);
     }
 
     @Override
     public boolean connect() {
         boolean result = false;
-        // 涓嶈兘鏈� 妲藉彿 鍜� 鏈烘灦鍙�
-        siemensS7Net = new SiemensS7Net(SiemensPLCS.S200Smart, slave.getIp());
+
+        try{
+            // 涓嶈兘鏈� 妲藉彿 鍜� 鏈烘灦鍙�
+            siemensS7Net = new SiemensS7Net(SiemensPLCS.S200Smart, slave.getIp());
 //        siemensS7Net.setRack(slave.getRack().byteValue());
 //        siemensS7Net.setSlot(slave.getSlot().byteValue());
-        OperateResult connect = siemensS7Net.ConnectServer();
-        if(connect.IsSuccess){
-            result = true;
-            OutputQueue.STE.offer(MessageFormat.format( "銆恵0}銆戠~鍖栫綈plc杩炴帴鎴愬姛 ===>> [id:{1}] [ip:{2}] [port:{3}]", DateUtils.convert(new Date()), slave.getId(), slave.getIp(), slave.getPort()));
-            News.info("纭寲缃恜lc杩炴帴鎴愬姛 ===>> [id:{}] [ip:{}] [port:{}]", slave.getId(), slave.getIp(), slave.getPort());
-        } else {
-            OutputQueue.STE.offer(MessageFormat.format("銆恵0}銆戠~鍖栫綈plc杩炴帴澶辫触锛侊紒锛� ===>> [id:{1}] [ip:{2}] [port:{3}] ", DateUtils.convert(new Date()), slave.getId(), slave.getIp(), slave.getPort()));
-            News.error("纭寲缃恜lc杩炴帴澶辫触锛侊紒锛� ===>> [id:{}] [ip:{}] [port:{}]", slave.getId(), slave.getIp(), slave.getPort());
-            initSte();
+            OperateResult connect = siemensS7Net.ConnectServer();
+            if(connect.IsSuccess){
+                result = true;
+                OutputQueue.STE.offer(MessageFormat.format( "銆恵0}銆戠~鍖栫綈plc杩炴帴鎴愬姛 ===>> [id:{1}] [ip:{2}] [port:{3}]", DateUtils.convert(new Date()), slave.getId(), slave.getIp(), slave.getPort()));
+                News.info("纭寲缃恜lc杩炴帴鎴愬姛 ===>> [id:{}] [ip:{}] [port:{}]", slave.getId(), slave.getIp(), slave.getPort());
+            } else {
+                OutputQueue.STE.offer(MessageFormat.format("銆恵0}銆戠~鍖栫綈plc杩炴帴澶辫触锛侊紒锛� ===>> [id:{1}] [ip:{2}] [port:{3}] ", DateUtils.convert(new Date()), slave.getId(), slave.getIp(), slave.getPort()));
+                News.error("纭寲缃恜lc杩炴帴澶辫触锛侊紒锛� ===>> [id:{}] [ip:{}] [port:{}]", slave.getId(), slave.getIp(), slave.getPort());
+                initSte();
+            }
+        } catch (Exception e){
+            log.error("纭寲缃恜lc杩炴帴澶辫触锛侊紒锛� ===>> [id:{}] [ip:{}] [port:{}]", slave.getId(), slave.getIp(), slave.getPort());
         }
-//        melsecMcNet.ConnectClose();
         return result;
+//        melsecMcNet.ConnectClose();
     }
 
     /**
@@ -329,7 +338,7 @@
             }
         } catch (Exception e) {
 //            e.printStackTrace();
-            log.error(e.getMessage());
+            log.error("纭寲缃恜lc鐘舵�佷俊鎭け璐�"+e.getMessage());
             OutputQueue.STE.offer(MessageFormat.format("銆恵0}銆戣鍙栫~鍖栫綈plc鐘舵�佷俊鎭け璐� ===>> [id:{1}] [ip:{2}] [port:{3}]", DateUtils.convert(new Date()), slave.getId(), slave.getIp(), slave.getPort()));
 //            News.error("璇诲彇绌挎杞lc鐘舵�佷俊鎭け璐� ===>> [id:{}] [ip:{}] [port:{}]", slave.getId(), slave.getIp(), slave.getPort());
             initSte();
diff --git a/src/main/webapp/static/js/console.map.js b/src/main/webapp/static/js/console.map.js
index b779058..b082245 100644
--- a/src/main/webapp/static/js/console.map.js
+++ b/src/main/webapp/static/js/console.map.js
@@ -80,11 +80,67 @@
         "height": 23
     }, {
         "type": "rackDescs",
+        "id": "lb_desc22",
+        "text": "#22",
+        "top": 278,
+        "left": 1640,
+        "width": 30,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc23",
+        "text": "#23",
+        "top": 333,
+        "left": 1640,
+        "width": 30,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc24",
+        "text": "#24",
+        "top": 355,
+        "left": 1640,
+        "width": 30,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc25",
+        "text": "#25",
+        "top": 406,
+        "left": 1640,
+        "width": 30,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc26",
+        "text": "#26",
+        "top": 462,
+        "left": 1640,
+        "width": 30,
+        "height": 23
+    }, {
+        "type": "rackDescs",
         "id": "lb_desc27",
         "text": "#27",
         "top": 484,
         "left": 1640,
-        "width": 41,
+        "width": 30,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc6H",
+        "text": "#6鍙峰爢鍨涙満",
+        "top": 307,
+        "left": 1700,
+        "width": 100,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc7H",
+        "text": "#7鍙峰爢鍨涙満",
+        "top": 435,
+        "left": 1700,
+        "width": 100,
         "height": 23
     }],
     "crns": [{
diff --git a/src/main/webapp/static/js/console.map21.js b/src/main/webapp/static/js/console.map21.js
index 65f7b79..7fdf736 100644
--- a/src/main/webapp/static/js/console.map21.js
+++ b/src/main/webapp/static/js/console.map21.js
@@ -136,20 +136,156 @@
     }],
     "rackDescs": [{
         "type": "rackDescs",
-        "id": "lb_desc16",
+        "id": "lb_desc1",
         "text": "#1",
         "top": 661,
         "left": 470,
-        "width": 30,
+        "width": 41,
         "height": 23
     }, {
         "type": "rackDescs",
-        "id": "lb_desc1",
+        "id": "lb_desc2",
+        "text": "#2",
+        "top": 639,
+        "left": 470,
+        "width": 41,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc3",
+        "text": "#3",
+        "top": 591,
+        "left": 470,
+        "width": 41,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc4",
         "text": "#4",
         "top": 569,
         "left": 470,
         "width": 41,
         "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc5",
+        "text": "#5",
+        "top": 547,
+        "left": 470,
+        "width": 41,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc6",
+        "text": "#6",
+        "top": 525,
+        "left": 470,
+        "width": 41,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc7",
+        "text": "#7",
+        "top": 477,
+        "left": 470,
+        "width": 41,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc8",
+        "text": "#8",
+        "top": 455,
+        "left": 470,
+        "width": 41,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc9",
+        "text": "#9",
+        "top": 432,
+        "left": 300,
+        "width": 41,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc10",
+        "text": "#10",
+        "top": 384,
+        "left": 300,
+        "width": 41,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc11",
+        "text": "#11",
+        "top": 362,
+        "left": 300,
+        "width": 41,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc12",
+        "text": "#12",
+        "top": 314,
+        "left": 300,
+        "width": 41,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc13",
+        "text": "#13",
+        "top": 292,
+        "left": 300,
+        "width": 41,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc14",
+        "text": "#14",
+        "top": 244,
+        "left": 300,
+        "width": 41,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc1H",
+        "text": "#1鍙峰爢鍨涙満",
+        "top": 615,
+        "left": 350,
+        "width": 100,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc2H",
+        "text": "#2鍙峰爢鍨涙満",
+        "top": 501,
+        "left": 350,
+        "width": 100,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc3H",
+        "text": "#3鍙峰爢鍨涙満",
+        "top": 408,
+        "left": 350,
+        "width": 100,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc4H",
+        "text": "#4鍙峰爢鍨涙満",
+        "top": 338,
+        "left": 350,
+        "width": 100,
+        "height": 23
+    }, {
+        "type": "rackDescs",
+        "id": "lb_desc5H",
+        "text": "#5鍙峰爢鍨涙満",
+        "top": 268,
+        "left": 350,
+        "width": 100,
+        "height": 23
     }],
     "crns": [{
         "type": "crane",
diff --git a/src/main/webapp/static/js/console.map23.js b/src/main/webapp/static/js/console.map23.js
index 44414de..5682d8c 100644
--- a/src/main/webapp/static/js/console.map23.js
+++ b/src/main/webapp/static/js/console.map23.js
@@ -87,31 +87,31 @@
                 "text": "636",
                 "top": 650,
                 "left": 480,
-                "width": 79,
+                "width": 69,
                 "height": 59
             }, {
                 "type": "stn",
                 "id": "site-635",
                 "text": "635",
                 "top": 650,
-                "left": 560,
-                "width": 79,
+                "left": 550,
+                "width": 69,
                 "height": 59
             }, {
                 "type": "stn",
                 "id": "site-634",
                 "text": "634",
                 "top": 650,
-                "left": 640,
-                "width": 79,
+                "left": 620,
+                "width": 59,
                 "height": 59
             }, {
                 "type": "stn",
                 "id": "site-633",
                 "text": "633",
                 "top": 650,
-                "left": 720,
-                "width": 69,
+                "left": 680,
+                "width": 59,
                 "height": 59
             }, {
                 "type": "stn",
@@ -366,7 +366,7 @@
                 "id": "site-627",
                 "text": "627",
                 "top": 590,
-                "left": 730,
+                "left": 680,
                 "width": 49,
                 "height": 59
             }, {
@@ -374,7 +374,7 @@
                 "id": "site-628",
                 "text": "628",
                 "top": 590,
-                "left": 980,
+                "left": 930,
                 "width": 49,
                 "height": 59
             }, {
@@ -382,7 +382,7 @@
                 "id": "site-632",
                 "text": "632",
                 "top": 650,
-                "left": 790,
+                "left": 740,
                 "width": 59,
                 "height": 59
             }, {
@@ -390,7 +390,7 @@
                 "id": "site-631",
                 "text": "631",
                 "top": 650,
-                "left": 850,
+                "left": 800,
                 "width": 59,
                 "height": 59
             }, {
@@ -398,7 +398,7 @@
                 "id": "site-630",
                 "text": "630",
                 "top": 650,
-                "left": 910,
+                "left": 860,
                 "width": 59,
                 "height": 59
             }, {
@@ -406,7 +406,7 @@
                 "id": "site-629",
                 "text": "629",
                 "top": 650,
-                "left": 970,
+                "left": 920,
                 "width": 59,
                 "height": 59
             }]
diff --git a/src/main/webapp/views/crn.html b/src/main/webapp/views/crn.html
index e9c53c9..5595d96 100644
--- a/src/main/webapp/views/crn.html
+++ b/src/main/webapp/views/crn.html
@@ -89,6 +89,12 @@
                     <!--            <span>&nbsp;</span>-->
                     <input id="crn6" disabled="disabled">
                 </div>
+                <div class="crn-command-item">
+                    <label>7#</label>
+                    <button id="demoBtn-7" class="demoBtn" onclick="demoSwitch(this.id)"> - </button>
+                    <!--            <span>&nbsp;</span>-->
+                    <input id="crn7" disabled="disabled">
+                </div>
             </div>
             <!-- 鍫嗗灈鏈虹姸鎬佷綅淇℃伅 -->
             <div class="crn-state">
@@ -160,6 +166,7 @@
                         <label><input type="radio" name="crnSelect" value="4">&nbsp;4鍙峰爢鍨涙満</label>
                         <label><input type="radio" name="crnSelect" value="5">&nbsp;5鍙峰爢鍨涙満</label>
                         <label><input type="radio" name="crnSelect" value="6">&nbsp;6鍙峰爢鍨涙満</label>
+                        <label><input type="radio" name="crnSelect" value="7">&nbsp;7鍙峰爢鍨涙満</label>
                     </div>
                 </div>
                 <!-- 婧愮珯/婧愬簱浣� 閫夋嫨 -->
diff --git a/src/main/webapp/views/index.html b/src/main/webapp/views/index.html
index 29445b6..7b11270 100644
--- a/src/main/webapp/views/index.html
+++ b/src/main/webapp/views/index.html
@@ -21,8 +21,8 @@
             <li><a id="console23" onclick="nav(this.id)" class="nav-select" href="#">浜屾ゼ涓夊尯</a></li>
             <li><a id="pipeline" onclick="nav(this.id)" class="nav-unselect" href="#">杈撻�佽澶�</a></li>
             <li><a id="crn" onclick="nav(this.id)" class="nav-unselect" href="#">鍫嗗灈鏈�</a></li>
-            <li><a id="rgv" onclick="nav(this.id)" class="nav-unselect" href="#">RGV</a></li>
-            <li><a id="ste" onclick="nav(this.id)" class="nav-unselect" href="#">绌挎杞�</a></li>
+            <li><a id="rgv" onclick="nav(this.id)" class="nav-unselect" href="#">纭寲RGV</a></li>
+            <li><a id="ste" onclick="nav(this.id)" class="nav-unselect" href="#">纭寲绌挎杞�</a></li>
         </ul>
     </div>
 </div>
diff --git a/src/main/webapp/views/ste.html b/src/main/webapp/views/ste.html
index 72eb83f..107d609 100644
--- a/src/main/webapp/views/ste.html
+++ b/src/main/webapp/views/ste.html
@@ -31,11 +31,11 @@
                     <button class="demoBtn pos-btn">鏁版嵁缁存姢</button>
                     <!--                        <button id="mode-2" class="demoBtn mode-btn" > - </button>-->
                 </div>
-                <div data-steNo="3" class="ste-command-item" style="margin-top: 30px">
-                    <label>3#</label>
-                    <button class="demoBtn pos-btn">鏁版嵁缁存姢</button>
-                    <!--                        <button id="mode-3" class="demoBtn mode-btn" > - </button>-->
-                </div>
+<!--                <div data-steNo="3" class="ste-command-item" style="margin-top: 30px">-->
+<!--                    <label>3#</label>-->
+<!--                    <button class="demoBtn pos-btn">鏁版嵁缁存姢</button>-->
+<!--                    &lt;!&ndash;                        <button id="mode-3" class="demoBtn mode-btn" > - </button>&ndash;&gt;-->
+<!--                </div>-->
             </div>
             <!-- 鍫嗗灈鏈虹姸鎬佷綅淇℃伅 -->
             <div class="ste-state">
@@ -100,7 +100,6 @@
                     <div class="select-container">
                         <label><input type="radio" name="steSelect" value="1" checked>&nbsp;1鍙风┛姊溅</label>
                         <label><input type="radio" name="steSelect" value="2">&nbsp;2鍙风┛姊溅</label>
-                        <label><input type="radio" name="steSelect" value="3">&nbsp;3鍙风┛姊溅</label>
                     </div>
                 </div>
             </div>

--
Gitblit v1.9.1