From c0d2dc7614b173e0ea4c78c6f899ab732542127a Mon Sep 17 00:00:00 2001
From: Junjie <fallin.jie@qq.com>
Date: 星期日, 13 七月 2025 19:54:28 +0800
Subject: [PATCH] #
---
src/main/java/com/zy/core/thread/impl/NyShuttleThread.java | 47 ++++++++++++++++++++++++++++-------------------
1 files changed, 28 insertions(+), 19 deletions(-)
diff --git a/src/main/java/com/zy/core/thread/impl/NyShuttleThread.java b/src/main/java/com/zy/core/thread/impl/NyShuttleThread.java
index 68771e5..e8a72d4 100644
--- a/src/main/java/com/zy/core/thread/impl/NyShuttleThread.java
+++ b/src/main/java/com/zy/core/thread/impl/NyShuttleThread.java
@@ -78,6 +78,22 @@
listenInit();//鐩戝惉鍒濆鍖栦簨浠�
readStatus();
Thread.sleep(100);
+
+ ShuttleAction shuttleAction = null;
+ try {
+ shuttleAction = SpringUtils.getBean(ShuttleAction.class);
+ }catch (Exception e){
+ continue;
+ }
+
+ if (shuttleAction == null) {
+ continue;
+ }
+ //婕旂ず妯″紡
+ shuttleAction.demo(deviceConfig.getDeviceNo());
+
+// //灏忚溅绌洪棽涓旀湁璺戝簱绋嬪簭
+// shuttleAction.moveLoc(deviceConfig.getDeviceNo());
} catch (Exception e) {
log.error("ShuttleThread Fail", e);
}
@@ -110,14 +126,7 @@
//瀛樺湪浠诲姟闇�瑕佹墽琛�
boolean result = shuttleAction.executeWork(deviceConfig.getDeviceNo(), taskNo);
}
-
-// //灏忚溅绌洪棽涓旀湁璺戝簱绋嬪簭
-// shuttleAction.moveLoc(deviceConfig.getDeviceNo());
-
- //婕旂ず妯″紡
- shuttleAction.demo(deviceConfig.getDeviceNo());
-
- Thread.sleep(200);
+ Thread.sleep(100);
} catch (Exception e) {
e.printStackTrace();
}
@@ -125,17 +134,17 @@
});
executeThread.start();
- //鍏朵粬浠诲姟
- Thread otherThread = new Thread(() -> {
- while (true) {
- try {
- saveLog();//淇濆瓨鏁版嵁
- } catch (Exception e) {
- e.printStackTrace();
- }
- }
- });
- otherThread.start();
+// //鍏朵粬浠诲姟
+// Thread otherThread = new Thread(() -> {
+// while (true) {
+// try {
+// saveLog();//淇濆瓨鏁版嵁
+// } catch (Exception e) {
+// e.printStackTrace();
+// }
+// }
+// });
+// otherThread.start();
}
private void saveLog() {
--
Gitblit v1.9.1