From 28d780e477647d8741d5c9d5927ed66078775801 Mon Sep 17 00:00:00 2001
From: tqs <56479841@qq.com>
Date: 星期三, 01 二月 2023 13:00:09 +0800
Subject: [PATCH] #
---
src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java | 31 +++++++++++++++++++++++--------
1 files changed, 23 insertions(+), 8 deletions(-)
diff --git a/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java b/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java
index 2f671c0..155519e 100644
--- a/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java
+++ b/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java
@@ -121,6 +121,7 @@
staProtocol.setStaNo((short)100);
devpThread.setPakMk(staProtocol.getSiteId(), false);
boolean result = MessageQueue.offer(SlaveType.Devp, devp.getId(), new Task(2, staProtocol));
+ News.error("MainServiceImpl generateStoreWrkFile"+"103涓哄嚭搴撴ā寮忥紝绂佹鍏ュ簱锛岄��鍥炲叆搴撳彛銆傦紒锛侊紒");
continue;
}
if ( inSta.getStaNo()==203 && devpThread.ioModeOf2F == IoModeType.PAKOUT_MODE) {
@@ -129,6 +130,7 @@
staProtocol.setStaNo((short)200);
devpThread.setPakMk(staProtocol.getSiteId(), false);
boolean result = MessageQueue.offer(SlaveType.Devp, devp.getId(), new Task(2, staProtocol));
+ News.error("MainServiceImpl generateStoreWrkFile"+"203涓哄嚭搴撴ā寮忥紝绂佹鍏ュ簱锛岄��鍥炲叆搴撳彛銆傦紒锛侊紒");
continue;
}
@@ -1045,7 +1047,25 @@
continue;
}
+ // 鑾峰彇鍫嗗灈鏈哄嚭搴撶珯淇℃伅
+ SiemensDevpThread devpThread = (SiemensDevpThread) SlaveConnection.get(SlaveType.Devp, crnStn.getDevpPlcId());
+ StaProtocol staProtocol = devpThread.getStation().get(crnStn.getStaNo());
+ if (staProtocol == null) {
+ continue;
+ } else {
+ staProtocol = staProtocol.clone();
+ }
+
if (wrkMast.getCrnNo().equals(2)){
+ if (wrkMast.getStaNo() == 103 && devpThread.ioModeOf1F != IoModeType.PAKOUT_MODE) {
+ News.error("MainServiceImpl locToCrnStn"+"103闈炲嚭搴撴ā寮忥紝绂佹鍑哄簱銆備换鍔″彿:{}锛侊紒锛�",wrkMast.getWrkNo());
+ continue;
+ }
+ if (wrkMast.getStaNo() == 203 && devpThread.ioModeOf2F != IoModeType.PAKOUT_MODE) {
+ News.error("MainServiceImpl locToCrnStn"+"203闈炲嚭搴撴ā寮忥紝绂佹鍑哄簱銆備换鍔″彿:{}锛侊紒锛�",wrkMast.getWrkNo());
+ continue;
+ }
+
if (wrkMast.getWrkSts() == 11 && (wrkMast.getIoType() == 103 || wrkMast.getIoType() == 107)){
Integer sour = wrkMast.getSourceStaNo();
List<WrkMast> wrkMasts = wrkMastMapper.selectWrkStsAndIoType0(sour);
@@ -1156,14 +1176,7 @@
News.error("鍑哄簱鎿嶄綔搴撲綅鐘舵�佷笉绗﹀悎--鐘舵��, 搴撲綅鍙�={}锛屽簱浣嶇姸鎬�={}", wrkMast.getLocNo(), sourceSta.getLocSts());
continue;
}
- // 鑾峰彇鍫嗗灈鏈哄嚭搴撶珯淇℃伅
- DevpThread devpThread = (DevpThread) SlaveConnection.get(SlaveType.Devp, crnStn.getDevpPlcId());
- StaProtocol staProtocol = devpThread.getStation().get(crnStn.getStaNo());
- if (staProtocol == null) {
- continue;
- } else {
- staProtocol = staProtocol.clone();
- }
+
// 鏌ヨ绔欑偣璇︾粏淇℃伅
BasDevp staDetl = basDevpService.selectById(crnStn.getStaNo());
if (staDetl == null) {
@@ -3237,6 +3250,7 @@
staProtocol.setStaNo((short)100);
devpThread.setPakMk(staProtocol.getSiteId(), false);
boolean result = MessageQueue.offer(SlaveType.Devp, devp.getId(), new Task(2, staProtocol));
+ News.error("MainServiceImpl storeEmptyPlt"+"103涓哄嚭搴撴ā寮忥紝绂佹鍏ュ簱锛岄��鍥炲叆搴撳彛銆傦紒锛侊紒");
continue;
}
if ( emptyInSta.getStaNo()==203 && devpThread.ioModeOf2F == IoModeType.PAKOUT_MODE) {
@@ -3245,6 +3259,7 @@
staProtocol.setStaNo((short)200);
devpThread.setPakMk(staProtocol.getSiteId(), false);
boolean result = MessageQueue.offer(SlaveType.Devp, devp.getId(), new Task(2, staProtocol));
+ News.error("MainServiceImpl storeEmptyPlt"+"203涓哄嚭搴撴ā寮忥紝绂佹鍏ュ簱锛岄��鍥炲叆搴撳彛銆傦紒锛侊紒");
continue;
}
--
Gitblit v1.9.1