|
|
@ -236,10 +236,8 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
&& (lnshPalletizingManipulatorSiteDeviceDriver.getAction() == 3 || lnshPalletizingManipulatorSiteDeviceDriver.getAction() == 1)) { |
|
|
|
inst.setExecute_status("1"); |
|
|
|
instructionService.update(inst); |
|
|
|
lnshPalletizingManipulatorSiteDeviceDriver.writing(2); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
Map<String, Object> map = new LinkedHashMap<>(); |
|
|
|
map.put("to_command",2); |
|
|
|
lnshPalletizingManipulatorSiteDeviceDriver.writing(map); |
|
|
|
lnshPalletizingManipulatorSiteDeviceDriver.setMessage(""); |
|
|
|
flag = true; |
|
|
|
} else { |
|
|
@ -274,10 +272,8 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
&& (lnshStationDeviceDriver.getAction() == 3 || lnshStationDeviceDriver.getAction() == 1)){ |
|
|
|
inst.setExecute_status("1"); |
|
|
|
instructionService.update(inst); |
|
|
|
lnshStationDeviceDriver.writing(2); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
Map<String, Object> map = new LinkedHashMap<>(); |
|
|
|
map.put("to_command",2); |
|
|
|
lnshStationDeviceDriver.writing(map); |
|
|
|
lnshStationDeviceDriver.setMessage(""); |
|
|
|
flag=true; |
|
|
|
}else{ |
|
|
@ -311,10 +307,10 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
&& conveyorPressStationDeviceDriver.getMove() != 0 |
|
|
|
&& (conveyorPressStationDeviceDriver.getIo_action() == 3 || conveyorPressStationDeviceDriver.getIo_action() == 1) |
|
|
|
&& (conveyorPressStationDeviceDriver.getAction() == 3 || conveyorPressStationDeviceDriver.getAction() == 1)) { |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
Map<String, Object> map = new LinkedHashMap<>(); |
|
|
|
map.put("to_command",2); |
|
|
|
conveyorPressStationDeviceDriver.writing(map); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
conveyorPressStationDeviceDriver.setMessage(""); |
|
|
|
flag = true; |
|
|
|
} else { |
|
|
@ -369,11 +365,9 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
) { |
|
|
|
inst.setExecute_status("1"); |
|
|
|
instructionService.update(inst); |
|
|
|
conveyorBarcodeDeviceDriver.writing(2); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
conveyorBarcodeDeviceDriver.setMessage(""); |
|
|
|
Map<String, Object> map = new LinkedHashMap<>(); |
|
|
|
map.put("to_command",2); |
|
|
|
conveyorBarcodeDeviceDriver.writing(map); |
|
|
|
flag = true; |
|
|
|
} else { |
|
|
|
String message = ""; |
|
|
@ -401,10 +395,8 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
// && (lnshFoldDiscSiteDeviceDriver.getAction() == 3 || lnshFoldDiscSiteDeviceDriver.getAction() == 1)
|
|
|
|
inst.setExecute_status("1"); |
|
|
|
instructionService.update(inst); |
|
|
|
lnshFoldDiscSiteDeviceDriver.writing(2); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
Map<String, Object> map = new LinkedHashMap<>(); |
|
|
|
map.put("to_command",2); |
|
|
|
lnshFoldDiscSiteDeviceDriver.writing(map); |
|
|
|
lnshFoldDiscSiteDeviceDriver.setMessage(""); |
|
|
|
flag = true; |
|
|
|
} else { |
|
|
@ -506,11 +498,9 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
&& (lnshPalletizingManipulatorSiteDeviceDriver.getIo_action() == 3 || lnshPalletizingManipulatorSiteDeviceDriver.getIo_action() == 2) |
|
|
|
) { |
|
|
|
inst.setExecute_status("5"); |
|
|
|
lnshPalletizingManipulatorSiteDeviceDriver.writing(3); |
|
|
|
instructionService.update(inst); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
Map<String, Object> map = new LinkedHashMap<>(); |
|
|
|
map.put("to_command",3); |
|
|
|
lnshPalletizingManipulatorSiteDeviceDriver.writing(map); |
|
|
|
lnshPalletizingManipulatorSiteDeviceDriver.setMessage(""); |
|
|
|
flag = true; |
|
|
|
} else { |
|
|
@ -542,10 +532,8 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
) { |
|
|
|
inst.setExecute_status("5"); |
|
|
|
instructionService.update(inst); |
|
|
|
lnshStationDeviceDriver.writing(3); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
Map<String, Object> map = new LinkedHashMap<>(); |
|
|
|
map.put("to_command",3); |
|
|
|
lnshStationDeviceDriver.writing(map); |
|
|
|
lnshStationDeviceDriver.setMessage(""); |
|
|
|
flag = true; |
|
|
|
} else { |
|
|
@ -577,10 +565,10 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
) { |
|
|
|
inst.setExecute_status("5"); |
|
|
|
instructionService.update(inst); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
Map<String, Object> map = new LinkedHashMap<>(); |
|
|
|
map.put("to_command",3); |
|
|
|
conveyorPressStationDeviceDriver.writing(map); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
conveyorPressStationDeviceDriver.setMessage(""); |
|
|
|
flag = true; |
|
|
|
} else { |
|
|
@ -625,11 +613,9 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
conveyorBarcodeDeviceDriver = (ConveyorBarcodeDeviceDriver) device.getDeviceDriver(); |
|
|
|
if (conveyorBarcodeDeviceDriver.getMode() != 0) { |
|
|
|
inst.setExecute_status("5"); |
|
|
|
conveyorBarcodeDeviceDriver.writing(3); |
|
|
|
instructionService.update(inst); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
Map<String, Object> map = new LinkedHashMap<>(); |
|
|
|
map.put("to_command",3); |
|
|
|
conveyorBarcodeDeviceDriver.writing(map); |
|
|
|
conveyorBarcodeDeviceDriver.setMessage(""); |
|
|
|
flag = true; |
|
|
|
} else { |
|
|
@ -657,11 +643,9 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
// && (lnshFoldDiscSiteDeviceDriver.getIo_action() == 3 || lnshFoldDiscSiteDeviceDriver.getIo_action() == 2)
|
|
|
|
) { |
|
|
|
inst.setExecute_status("5"); |
|
|
|
lnshFoldDiscSiteDeviceDriver.writing(3); |
|
|
|
instructionService.update(inst); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
Map<String, Object> map = new LinkedHashMap<>(); |
|
|
|
map.put("to_command",3); |
|
|
|
lnshFoldDiscSiteDeviceDriver.writing(map); |
|
|
|
lnshFoldDiscSiteDeviceDriver.setMessage(""); |
|
|
|
flag = true; |
|
|
|
} else { |
|
|
@ -778,10 +762,8 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
&& (lnshPalletizingManipulatorSiteDeviceDriver.getAction() == 2 || lnshPalletizingManipulatorSiteDeviceDriver.getAction() == 3)) { |
|
|
|
inst.setExecute_status("3"); |
|
|
|
instructionService.update(inst); |
|
|
|
lnshPalletizingManipulatorSiteDeviceDriver.writing(4); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
Map<String, Object> map = new LinkedHashMap<>(); |
|
|
|
map.put("to_command",4); |
|
|
|
lnshPalletizingManipulatorSiteDeviceDriver.writing(map); |
|
|
|
lnshPalletizingManipulatorSiteDeviceDriver.setMessage(""); |
|
|
|
flag = true; |
|
|
|
} else { |
|
|
@ -816,10 +798,8 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
&& (lnshStationDeviceDriver.getAction() == 2 || lnshStationDeviceDriver.getAction() == 3)) { |
|
|
|
inst.setExecute_status("3"); |
|
|
|
instructionService.update(inst); |
|
|
|
lnshStationDeviceDriver.writing(4); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
Map<String, Object> map = new LinkedHashMap<>(); |
|
|
|
map.put("to_command",4); |
|
|
|
lnshStationDeviceDriver.writing(map); |
|
|
|
lnshStationDeviceDriver.setMessage(""); |
|
|
|
flag = true; |
|
|
|
} else { |
|
|
@ -854,10 +834,10 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
&& (conveyorPressStationDeviceDriver.getAction() == 2 || conveyorPressStationDeviceDriver.getAction() == 3)) { |
|
|
|
inst.setExecute_status("3"); |
|
|
|
instructionService.update(inst); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
Map<String, Object> map = new LinkedHashMap<>(); |
|
|
|
map.put("to_command",4); |
|
|
|
conveyorPressStationDeviceDriver.writing(map); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
conveyorPressStationDeviceDriver.setMessage(""); |
|
|
|
flag = true; |
|
|
|
} else { |
|
|
@ -906,10 +886,8 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
if (conveyorBarcodeDeviceDriver.getMode() == 2&& conveyorBarcodeDeviceDriver.getMove()==0){ |
|
|
|
inst.setExecute_status("3"); |
|
|
|
instructionService.update(inst); |
|
|
|
conveyorBarcodeDeviceDriver.writing(4); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
Map<String, Object> map = new LinkedHashMap<>(); |
|
|
|
map.put("to_command",4); |
|
|
|
conveyorBarcodeDeviceDriver.writing(map); |
|
|
|
conveyorBarcodeDeviceDriver.setMessage(""); |
|
|
|
flag = true; |
|
|
|
} else { |
|
|
@ -939,10 +917,8 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
) { |
|
|
|
inst.setExecute_status("3"); |
|
|
|
instructionService.update(inst); |
|
|
|
lnshFoldDiscSiteDeviceDriver.writing(4); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
Map<String, Object> map = new LinkedHashMap<>(); |
|
|
|
map.put("to_command",4); |
|
|
|
lnshFoldDiscSiteDeviceDriver.writing(map); |
|
|
|
lnshFoldDiscSiteDeviceDriver.setMessage(""); |
|
|
|
flag = true; |
|
|
|
} else { |
|
|
@ -1040,10 +1016,8 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
&& (lnshPalletizingManipulatorSiteDeviceDriver.getIo_action() == 2 || lnshPalletizingManipulatorSiteDeviceDriver.getIo_action() == 3)) { |
|
|
|
inst.setExecute_status("6"); |
|
|
|
instructionService.update(inst); |
|
|
|
lnshPalletizingManipulatorSiteDeviceDriver.writing(5); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
Map<String, Object> map = new LinkedHashMap<>(); |
|
|
|
map.put("to_command",5); |
|
|
|
lnshPalletizingManipulatorSiteDeviceDriver.writing(map); |
|
|
|
lnshPalletizingManipulatorSiteDeviceDriver.setMessage(""); |
|
|
|
flag = true; |
|
|
|
} else { |
|
|
@ -1074,10 +1048,8 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
&& (lnshStationDeviceDriver.getIo_action() == 2 || lnshStationDeviceDriver.getIo_action() == 3)) { |
|
|
|
inst.setExecute_status("6"); |
|
|
|
instructionService.update(inst); |
|
|
|
lnshStationDeviceDriver.writing(5); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
Map<String, Object> map = new LinkedHashMap<>(); |
|
|
|
map.put("to_command",5); |
|
|
|
lnshStationDeviceDriver.writing(map); |
|
|
|
lnshStationDeviceDriver.setMessage(""); |
|
|
|
flag = true; |
|
|
|
} else { |
|
|
@ -1122,11 +1094,10 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
}else{ |
|
|
|
log.info("任务号为空"); |
|
|
|
} |
|
|
|
|
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
Map<String, Object> map = new LinkedHashMap<>(); |
|
|
|
map.put("to_command",5); |
|
|
|
conveyorPressStationDeviceDriver.writing(map); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
conveyorPressStationDeviceDriver.setMessage(""); |
|
|
|
flag = true; |
|
|
|
} else { |
|
|
@ -1175,10 +1146,8 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
if(ObjectUtil.isNotEmpty(inst.getVehicle_code())){ |
|
|
|
conveyorBarcodeDeviceDriver.writing("to_barcode",inst.getVehicle_code()); |
|
|
|
} |
|
|
|
conveyorBarcodeDeviceDriver.writing(5); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
Map<String, Object> map = new LinkedHashMap<>(); |
|
|
|
map.put("to_command",5); |
|
|
|
conveyorBarcodeDeviceDriver.writing(map); |
|
|
|
TaskDto task=taskService.findByCode(inst.getTask_code()); |
|
|
|
String material=task.getDirection(); |
|
|
|
conveyorBarcodeDeviceDriver.setMessage(""); |
|
|
@ -1210,10 +1179,8 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic |
|
|
|
) { |
|
|
|
inst.setExecute_status("6"); |
|
|
|
instructionService.update(inst); |
|
|
|
lnshFoldDiscSiteDeviceDriver.writing(5); |
|
|
|
data = AgvService.sendAgvOneModeInst(phase, index, 0); |
|
|
|
Map<String, Object> map = new LinkedHashMap<>(); |
|
|
|
map.put("to_command",5); |
|
|
|
lnshFoldDiscSiteDeviceDriver.writing(map); |
|
|
|
lnshFoldDiscSiteDeviceDriver.setMessage(""); |
|
|
|
flag = true; |
|
|
|
} else { |
|
|
|