|
|
@ -16,11 +16,8 @@ import org.nl.acs.device_driver.FeedLmsRealFailed; |
|
|
|
import org.nl.acs.device_driver.agv.utils.TwoAgvPhase; |
|
|
|
import org.nl.acs.device_driver.conveyor.standard_inspect_site.StandardInspectSiteDeviceDriver; |
|
|
|
import org.nl.acs.device_driver.conveyor.standard_ordinary_site.StandardOrdinarySiteDeviceDriver; |
|
|
|
import org.nl.acs.device_driver.paper_tube_pick_site.PaperTubePickSiteDeviceDriver; |
|
|
|
import org.nl.acs.device_driver.storage.standard_storage.StandardStorageDeviceDriver; |
|
|
|
import org.nl.acs.device_driver.driver.AbstractDeviceDriver; |
|
|
|
import org.nl.acs.device_driver.two_conveyor.hongxiang_conveyor.HongXiangStationDeviceDriver; |
|
|
|
import org.nl.acs.device_driver.two_conveyor.manipulator_agv_station.ManipulatorAgvStationDeviceDriver; |
|
|
|
import org.nl.acs.ext.wms.service.AcsToWmsService; |
|
|
|
import org.nl.acs.ext.wms.service.impl.AcsToWmsServiceImpl; |
|
|
|
import org.nl.acs.history.ErrorUtil; |
|
|
@ -150,13 +147,10 @@ public class AgvNdcTwoDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
//货架
|
|
|
|
StandardStorageDeviceDriver standardStorageDeviceDriver; |
|
|
|
//纸管抓取位
|
|
|
|
PaperTubePickSiteDeviceDriver paperTubePickSiteDeviceDriver; |
|
|
|
//标准-光电检测
|
|
|
|
StandardInspectSiteDeviceDriver standardInspectSiteDeviceDriver; |
|
|
|
//烘箱对接位
|
|
|
|
HongXiangStationDeviceDriver hongXiangStationDeviceDriver; |
|
|
|
//行架-agv对接位
|
|
|
|
ManipulatorAgvStationDeviceDriver manipulatorAgvStationDeviceDriver; |
|
|
|
|
|
|
|
if (phase == 0x02) { |
|
|
|
if (ObjectUtil.isEmpty(inst)) { |
|
|
@ -237,48 +231,6 @@ public class AgvNdcTwoDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, standardInspectSiteDeviceDriver.getMove(), standardInspectSiteDeviceDriver.getAction() |
|
|
|
, standardInspectSiteDeviceDriver.getError(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof ManipulatorAgvStationDeviceDriver) { |
|
|
|
manipulatorAgvStationDeviceDriver = (ManipulatorAgvStationDeviceDriver) device.getDeviceDriver(); |
|
|
|
|
|
|
|
try { |
|
|
|
manipulatorAgvStationDeviceDriver.writing(2); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if ((manipulatorAgvStationDeviceDriver.getAction() == 1)) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + ",动作信号:" + manipulatorAgvStationDeviceDriver.getAction() + "报警信号:" + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{},动作信号{} ,不满足取货条件,指令号{}", device_code, manipulatorAgvStationDeviceDriver.getAction(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof HongXiangStationDeviceDriver) { |
|
|
|
hongXiangStationDeviceDriver = (HongXiangStationDeviceDriver) device.getDeviceDriver(); |
|
|
|
try { |
|
|
|
hongXiangStationDeviceDriver.writing(1); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if (hongXiangStationDeviceDriver.getMove() > 0) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + "光电信号:" + hongXiangStationDeviceDriver.getMove() + ",动作信号:" + hongXiangStationDeviceDriver.getAction() + "报警信号:" + hongXiangStationDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, hongXiangStationDeviceDriver.getMove(), hongXiangStationDeviceDriver.getAction() |
|
|
|
, hongXiangStationDeviceDriver.getError(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof PaperTubePickSiteDeviceDriver) { |
|
|
|
paperTubePickSiteDeviceDriver = (PaperTubePickSiteDeviceDriver) device.getDeviceDriver(); |
|
|
|
try { |
|
|
|
paperTubePickSiteDeviceDriver.writing(2); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if (paperTubePickSiteDeviceDriver.getMove() > 0) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + "光电信号:" + paperTubePickSiteDeviceDriver.getMove() + ",动作信号:" + paperTubePickSiteDeviceDriver.getAction() + "报警信号:" + paperTubePickSiteDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, paperTubePickSiteDeviceDriver.getMove(), paperTubePickSiteDeviceDriver.getAction() |
|
|
|
, paperTubePickSiteDeviceDriver.getError(), ikey); |
|
|
|
} |
|
|
|
} else { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
LuceneLogDto logDto = LuceneLogDto.builder() |
|
|
@ -343,48 +295,6 @@ public class AgvNdcTwoDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
standardOrdinarySiteDeviceDriver.setAgvphase(phase); |
|
|
|
standardOrdinarySiteDeviceDriver.setIndex(index); |
|
|
|
standardOrdinarySiteDeviceDriver.setInst(inst); |
|
|
|
} else if (device.getDeviceDriver() instanceof ManipulatorAgvStationDeviceDriver) { |
|
|
|
manipulatorAgvStationDeviceDriver = (ManipulatorAgvStationDeviceDriver) device.getDeviceDriver(); |
|
|
|
|
|
|
|
try { |
|
|
|
manipulatorAgvStationDeviceDriver.writing(3); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if ((manipulatorAgvStationDeviceDriver.getAction() == 1)) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + ",动作信号:" + manipulatorAgvStationDeviceDriver.getAction() + "报警信号:" + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{},动作信号{} ,不满足取货条件,指令号{}", device_code, manipulatorAgvStationDeviceDriver.getAction(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof HongXiangStationDeviceDriver) { |
|
|
|
hongXiangStationDeviceDriver = (HongXiangStationDeviceDriver) device.getDeviceDriver(); |
|
|
|
try { |
|
|
|
hongXiangStationDeviceDriver.writing(0); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if (hongXiangStationDeviceDriver.getMove() > 0) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + "光电信号:" + hongXiangStationDeviceDriver.getMove() + ",动作信号:" + hongXiangStationDeviceDriver.getAction() + "报警信号:" + hongXiangStationDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, hongXiangStationDeviceDriver.getMove(), hongXiangStationDeviceDriver.getAction() |
|
|
|
, hongXiangStationDeviceDriver.getError(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof PaperTubePickSiteDeviceDriver) { |
|
|
|
paperTubePickSiteDeviceDriver = (PaperTubePickSiteDeviceDriver) device.getDeviceDriver(); |
|
|
|
try { |
|
|
|
paperTubePickSiteDeviceDriver.writing(3); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if (paperTubePickSiteDeviceDriver.getMove() == 0) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + "光电信号:" + paperTubePickSiteDeviceDriver.getMove() + ",动作信号:" + paperTubePickSiteDeviceDriver.getAction() + "报警信号:" + paperTubePickSiteDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, paperTubePickSiteDeviceDriver.getMove(), paperTubePickSiteDeviceDriver.getAction() |
|
|
|
, paperTubePickSiteDeviceDriver.getError(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof StandardInspectSiteDeviceDriver) { |
|
|
|
standardInspectSiteDeviceDriver = (StandardInspectSiteDeviceDriver) device.getDeviceDriver(); |
|
|
|
|
|
|
@ -458,48 +368,6 @@ public class AgvNdcTwoDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
standardOrdinarySiteDeviceDriver.setAgvphase(phase); |
|
|
|
standardOrdinarySiteDeviceDriver.setIndex(index); |
|
|
|
standardOrdinarySiteDeviceDriver.setInst(inst); |
|
|
|
} else if (device.getDeviceDriver() instanceof ManipulatorAgvStationDeviceDriver) { |
|
|
|
manipulatorAgvStationDeviceDriver = (ManipulatorAgvStationDeviceDriver) device.getDeviceDriver(); |
|
|
|
|
|
|
|
try { |
|
|
|
manipulatorAgvStationDeviceDriver.writing(2); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if ((manipulatorAgvStationDeviceDriver.getAction() == 1)) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + ",动作信号:" + manipulatorAgvStationDeviceDriver.getAction() + "报警信号:" + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{},动作信号{} ,不满足取货条件,指令号{}", device_code, manipulatorAgvStationDeviceDriver.getAction(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof PaperTubePickSiteDeviceDriver) { |
|
|
|
paperTubePickSiteDeviceDriver = (PaperTubePickSiteDeviceDriver) device.getDeviceDriver(); |
|
|
|
try { |
|
|
|
paperTubePickSiteDeviceDriver.writing(2); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if (paperTubePickSiteDeviceDriver.getMove() == 1) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + "光电信号:" + paperTubePickSiteDeviceDriver.getMove() + ",动作信号:" + paperTubePickSiteDeviceDriver.getAction() + "报警信号:" + paperTubePickSiteDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, paperTubePickSiteDeviceDriver.getMove(), paperTubePickSiteDeviceDriver.getAction() |
|
|
|
, paperTubePickSiteDeviceDriver.getError(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof HongXiangStationDeviceDriver) { |
|
|
|
hongXiangStationDeviceDriver = (HongXiangStationDeviceDriver) device.getDeviceDriver(); |
|
|
|
try { |
|
|
|
hongXiangStationDeviceDriver.writing(1); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if (hongXiangStationDeviceDriver.getMove() > 0) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + "光电信号:" + hongXiangStationDeviceDriver.getMove() + ",动作信号:" + hongXiangStationDeviceDriver.getAction() + "报警信号:" + hongXiangStationDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, hongXiangStationDeviceDriver.getMove(), hongXiangStationDeviceDriver.getAction() |
|
|
|
, hongXiangStationDeviceDriver.getError(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof StandardInspectSiteDeviceDriver) { |
|
|
|
standardInspectSiteDeviceDriver = (StandardInspectSiteDeviceDriver) device.getDeviceDriver(); |
|
|
|
|
|
|
@ -571,48 +439,6 @@ public class AgvNdcTwoDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
standardOrdinarySiteDeviceDriver.setAgvphase(phase); |
|
|
|
standardOrdinarySiteDeviceDriver.setIndex(index); |
|
|
|
standardOrdinarySiteDeviceDriver.setInst(inst); |
|
|
|
} else if (device.getDeviceDriver() instanceof HongXiangStationDeviceDriver) { |
|
|
|
hongXiangStationDeviceDriver = (HongXiangStationDeviceDriver) device.getDeviceDriver(); |
|
|
|
try { |
|
|
|
hongXiangStationDeviceDriver.writing(0); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if (hongXiangStationDeviceDriver.getMove() == 0) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + "光电信号:" + hongXiangStationDeviceDriver.getMove() + ",动作信号:" + hongXiangStationDeviceDriver.getAction() + "报警信号:" + hongXiangStationDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, hongXiangStationDeviceDriver.getMove(), hongXiangStationDeviceDriver.getAction() |
|
|
|
, hongXiangStationDeviceDriver.getError(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof ManipulatorAgvStationDeviceDriver) { |
|
|
|
manipulatorAgvStationDeviceDriver = (ManipulatorAgvStationDeviceDriver) device.getDeviceDriver(); |
|
|
|
|
|
|
|
try { |
|
|
|
manipulatorAgvStationDeviceDriver.writing(3); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if ((manipulatorAgvStationDeviceDriver.getAction() == 1)) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + ",动作信号:" + manipulatorAgvStationDeviceDriver.getAction() + "报警信号:" + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{},动作信号{} ,不满足取货条件,指令号{}", device_code, manipulatorAgvStationDeviceDriver.getAction(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof PaperTubePickSiteDeviceDriver) { |
|
|
|
paperTubePickSiteDeviceDriver = (PaperTubePickSiteDeviceDriver) device.getDeviceDriver(); |
|
|
|
try { |
|
|
|
paperTubePickSiteDeviceDriver.writing(3); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if (paperTubePickSiteDeviceDriver.getMove() == 0) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + "光电信号:" + paperTubePickSiteDeviceDriver.getMove() + ",动作信号:" + paperTubePickSiteDeviceDriver.getAction() + "报警信号:" + paperTubePickSiteDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, paperTubePickSiteDeviceDriver.getMove(), paperTubePickSiteDeviceDriver.getAction() |
|
|
|
, paperTubePickSiteDeviceDriver.getError(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof StandardInspectSiteDeviceDriver) { |
|
|
|
standardInspectSiteDeviceDriver = (StandardInspectSiteDeviceDriver) device.getDeviceDriver(); |
|
|
|
|
|
|
@ -705,48 +531,6 @@ public class AgvNdcTwoDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
standardOrdinarySiteDeviceDriver.setIndex(index); |
|
|
|
standardOrdinarySiteDeviceDriver.setInst(inst); |
|
|
|
|
|
|
|
} else if (device.getDeviceDriver() instanceof PaperTubePickSiteDeviceDriver) { |
|
|
|
paperTubePickSiteDeviceDriver = (PaperTubePickSiteDeviceDriver) device.getDeviceDriver(); |
|
|
|
try { |
|
|
|
paperTubePickSiteDeviceDriver.writing(4); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if (paperTubePickSiteDeviceDriver.getMove() == 0) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + "光电信号:" + paperTubePickSiteDeviceDriver.getMove() + ",动作信号:" + paperTubePickSiteDeviceDriver.getAction() + "报警信号:" + paperTubePickSiteDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, paperTubePickSiteDeviceDriver.getMove(), paperTubePickSiteDeviceDriver.getAction() |
|
|
|
, paperTubePickSiteDeviceDriver.getError(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof ManipulatorAgvStationDeviceDriver) { |
|
|
|
manipulatorAgvStationDeviceDriver = (ManipulatorAgvStationDeviceDriver) device.getDeviceDriver(); |
|
|
|
|
|
|
|
try { |
|
|
|
manipulatorAgvStationDeviceDriver.writing(4); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if ((manipulatorAgvStationDeviceDriver.getAction() == 1)) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + ",动作信号:" + manipulatorAgvStationDeviceDriver.getAction() + "报警信号:" + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{},动作信号{} ,不满足取货条件,指令号{}", device_code, manipulatorAgvStationDeviceDriver.getAction(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof HongXiangStationDeviceDriver) { |
|
|
|
hongXiangStationDeviceDriver = (HongXiangStationDeviceDriver) device.getDeviceDriver(); |
|
|
|
try { |
|
|
|
hongXiangStationDeviceDriver.writing(1); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if (hongXiangStationDeviceDriver.getMove() == 0) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + "光电信号:" + hongXiangStationDeviceDriver.getMove() + ",动作信号:" + hongXiangStationDeviceDriver.getAction() + "报警信号:" + hongXiangStationDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, hongXiangStationDeviceDriver.getMove(), hongXiangStationDeviceDriver.getAction() |
|
|
|
, hongXiangStationDeviceDriver.getError(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof StandardInspectSiteDeviceDriver) { |
|
|
|
standardInspectSiteDeviceDriver = (StandardInspectSiteDeviceDriver) device.getDeviceDriver(); |
|
|
|
standardInspectSiteDeviceDriver.writing(1); |
|
|
@ -819,48 +603,6 @@ public class AgvNdcTwoDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
standardOrdinarySiteDeviceDriver.setAgvphase(phase); |
|
|
|
standardOrdinarySiteDeviceDriver.setIndex(index); |
|
|
|
standardOrdinarySiteDeviceDriver.setInst(inst); |
|
|
|
} else if (device.getDeviceDriver() instanceof ManipulatorAgvStationDeviceDriver) { |
|
|
|
manipulatorAgvStationDeviceDriver = (ManipulatorAgvStationDeviceDriver) device.getDeviceDriver(); |
|
|
|
|
|
|
|
try { |
|
|
|
manipulatorAgvStationDeviceDriver.writing(5); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if ((manipulatorAgvStationDeviceDriver.getAction() == 1)) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + ",动作信号:" + manipulatorAgvStationDeviceDriver.getAction() + "报警信号:" + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{},动作信号{} ,不满足取货条件,指令号{}", device_code, manipulatorAgvStationDeviceDriver.getAction(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof HongXiangStationDeviceDriver) { |
|
|
|
hongXiangStationDeviceDriver = (HongXiangStationDeviceDriver) device.getDeviceDriver(); |
|
|
|
try { |
|
|
|
hongXiangStationDeviceDriver.writing(0); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if (hongXiangStationDeviceDriver.getMove() > 0) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + "光电信号:" + hongXiangStationDeviceDriver.getMove() + ",动作信号:" + hongXiangStationDeviceDriver.getAction() + "报警信号:" + hongXiangStationDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, hongXiangStationDeviceDriver.getMove(), hongXiangStationDeviceDriver.getAction() |
|
|
|
, hongXiangStationDeviceDriver.getError(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof PaperTubePickSiteDeviceDriver) { |
|
|
|
paperTubePickSiteDeviceDriver = (PaperTubePickSiteDeviceDriver) device.getDeviceDriver(); |
|
|
|
try { |
|
|
|
paperTubePickSiteDeviceDriver.writing(5); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if (paperTubePickSiteDeviceDriver.getMove() > 0) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + "光电信号:" + paperTubePickSiteDeviceDriver.getMove() + ",动作信号:" + paperTubePickSiteDeviceDriver.getAction() + "报警信号:" + paperTubePickSiteDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, paperTubePickSiteDeviceDriver.getMove(), paperTubePickSiteDeviceDriver.getAction() |
|
|
|
, paperTubePickSiteDeviceDriver.getError(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof StandardInspectSiteDeviceDriver) { |
|
|
|
standardInspectSiteDeviceDriver = (StandardInspectSiteDeviceDriver) device.getDeviceDriver(); |
|
|
|
standardInspectSiteDeviceDriver.writing(0); |
|
|
@ -932,48 +674,6 @@ public class AgvNdcTwoDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
standardOrdinarySiteDeviceDriver.setIndex(index); |
|
|
|
standardOrdinarySiteDeviceDriver.setInst(inst); |
|
|
|
|
|
|
|
} else if (device.getDeviceDriver() instanceof ManipulatorAgvStationDeviceDriver) { |
|
|
|
manipulatorAgvStationDeviceDriver = (ManipulatorAgvStationDeviceDriver) device.getDeviceDriver(); |
|
|
|
|
|
|
|
try { |
|
|
|
manipulatorAgvStationDeviceDriver.writing(4); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if ((manipulatorAgvStationDeviceDriver.getAction() == 1)) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + ",动作信号:" + manipulatorAgvStationDeviceDriver.getAction() + "报警信号:" + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{},动作信号{} ,不满足取货条件,指令号{}", device_code, manipulatorAgvStationDeviceDriver.getAction(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof HongXiangStationDeviceDriver) { |
|
|
|
hongXiangStationDeviceDriver = (HongXiangStationDeviceDriver) device.getDeviceDriver(); |
|
|
|
try { |
|
|
|
hongXiangStationDeviceDriver.writing(1); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if (hongXiangStationDeviceDriver.getMove() == 0) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + "光电信号:" + hongXiangStationDeviceDriver.getMove() + ",动作信号:" + hongXiangStationDeviceDriver.getAction() + "报警信号:" + hongXiangStationDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, hongXiangStationDeviceDriver.getMove(), hongXiangStationDeviceDriver.getAction() |
|
|
|
, hongXiangStationDeviceDriver.getError(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof PaperTubePickSiteDeviceDriver) { |
|
|
|
paperTubePickSiteDeviceDriver = (PaperTubePickSiteDeviceDriver) device.getDeviceDriver(); |
|
|
|
try { |
|
|
|
paperTubePickSiteDeviceDriver.writing(4); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if (paperTubePickSiteDeviceDriver.getMove() == 0) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + "光电信号:" + paperTubePickSiteDeviceDriver.getMove() + ",动作信号:" + paperTubePickSiteDeviceDriver.getAction() + "报警信号:" + paperTubePickSiteDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, paperTubePickSiteDeviceDriver.getMove(), paperTubePickSiteDeviceDriver.getAction() |
|
|
|
, paperTubePickSiteDeviceDriver.getError(), ikey); |
|
|
|
} |
|
|
|
} else { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} |
|
|
@ -1040,48 +740,6 @@ public class AgvNdcTwoDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
standardOrdinarySiteDeviceDriver.setIndex(index); |
|
|
|
standardOrdinarySiteDeviceDriver.setInst(inst); |
|
|
|
|
|
|
|
} else if (device.getDeviceDriver() instanceof ManipulatorAgvStationDeviceDriver) { |
|
|
|
manipulatorAgvStationDeviceDriver = (ManipulatorAgvStationDeviceDriver) device.getDeviceDriver(); |
|
|
|
|
|
|
|
try { |
|
|
|
manipulatorAgvStationDeviceDriver.writing(5); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if ((manipulatorAgvStationDeviceDriver.getAction() == 1)) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + ",动作信号:" + manipulatorAgvStationDeviceDriver.getAction() + "报警信号:" + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{},动作信号{} ,不满足取货条件,指令号{}", device_code, manipulatorAgvStationDeviceDriver.getAction(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof PaperTubePickSiteDeviceDriver) { |
|
|
|
paperTubePickSiteDeviceDriver = (PaperTubePickSiteDeviceDriver) device.getDeviceDriver(); |
|
|
|
try { |
|
|
|
paperTubePickSiteDeviceDriver.writing(5); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if (paperTubePickSiteDeviceDriver.getMove() > 0) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + "光电信号:" + paperTubePickSiteDeviceDriver.getMove() + ",动作信号:" + paperTubePickSiteDeviceDriver.getAction() + "报警信号:" + paperTubePickSiteDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, paperTubePickSiteDeviceDriver.getMove(), paperTubePickSiteDeviceDriver.getAction() |
|
|
|
, paperTubePickSiteDeviceDriver.getError(), ikey); |
|
|
|
} |
|
|
|
} else if (device.getDeviceDriver() instanceof HongXiangStationDeviceDriver) { |
|
|
|
hongXiangStationDeviceDriver = (HongXiangStationDeviceDriver) device.getDeviceDriver(); |
|
|
|
try { |
|
|
|
hongXiangStationDeviceDriver.writing(0); |
|
|
|
} catch (Exception e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if (hongXiangStationDeviceDriver.getMove() > 0) { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} else { |
|
|
|
message = "设备号:" + device_code + "光电信号:" + hongXiangStationDeviceDriver.getMove() + ",动作信号:" + hongXiangStationDeviceDriver.getAction() + "报警信号:" + hongXiangStationDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件"; |
|
|
|
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, hongXiangStationDeviceDriver.getMove(), hongXiangStationDeviceDriver.getAction() |
|
|
|
, hongXiangStationDeviceDriver.getError(), ikey); |
|
|
|
} |
|
|
|
} else { |
|
|
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); |
|
|
|
} |
|
|
|