diff --git a/acs/nladmin-system/src/main/java/org/nl/acs/device/wql/task_inst.xls b/acs/nladmin-system/src/main/java/org/nl/acs/device/wql/task_inst.xls index cca434e..46630da 100644 Binary files a/acs/nladmin-system/src/main/java/org/nl/acs/device/wql/task_inst.xls and b/acs/nladmin-system/src/main/java/org/nl/acs/device/wql/task_inst.xls differ diff --git a/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/basedriver/agv/ndcone/AgvNdcOneDeviceDriver.java b/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/basedriver/agv/ndcone/AgvNdcOneDeviceDriver.java index dae5f3d..3ff35c6 100644 --- a/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/basedriver/agv/ndcone/AgvNdcOneDeviceDriver.java +++ b/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/basedriver/agv/ndcone/AgvNdcOneDeviceDriver.java @@ -214,7 +214,7 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic //标准版-机械手对接位 if (device.getDeviceDriver() instanceof LnshPalletizingManipulatorSiteDeviceDriver) { lnshPalletizingManipulatorSiteDeviceDriver = (LnshPalletizingManipulatorSiteDeviceDriver) device.getDeviceDriver(); - lnshPalletizingManipulatorSiteDeviceDriver.writing(2); + lnshPalletizingManipulatorSiteDeviceDriver.writing(3); if (lnshPalletizingManipulatorSiteDeviceDriver.getMode() != 0 && lnshPalletizingManipulatorSiteDeviceDriver.getMove() != 0 && (lnshPalletizingManipulatorSiteDeviceDriver.getIo_action() == 3 || lnshPalletizingManipulatorSiteDeviceDriver.getIo_action() == 1) @@ -247,7 +247,7 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic //标准版-工位(交互模板) if(device.getDeviceDriver() instanceof LnshStationDeviceDriver){ lnshStationDeviceDriver=(LnshStationDeviceDriver) device.getDeviceDriver(); - lnshStationDeviceDriver.writing(2); + lnshStationDeviceDriver.writing(3); if(lnshStationDeviceDriver.getMode()!=0 &&lnshStationDeviceDriver.getMove() != 0 && (lnshStationDeviceDriver.getIo_action() == 3 || lnshStationDeviceDriver.getIo_action() == 1) @@ -329,7 +329,7 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic //标准版-下发条码输送线 if(device.getDeviceDriver() instanceof ConveyorBarcodeDeviceDriver){ conveyorBarcodeDeviceDriver = (ConveyorBarcodeDeviceDriver) device.getDeviceDriver(); - conveyorBarcodeDeviceDriver.writing(2); + conveyorBarcodeDeviceDriver.writing(3); if (conveyorBarcodeDeviceDriver.getMode() != 0 && conveyorBarcodeDeviceDriver.getMove() != 0 && (conveyorBarcodeDeviceDriver.getIo_action() == 3 || conveyorBarcodeDeviceDriver.getIo_action() == 1) @@ -362,7 +362,7 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic //标准版-叠盘机 LnshFoldDiscSiteDeviceDriverl if(device.getDeviceDriver() instanceof LnshFoldDiscSiteDeviceDriver){ lnshFoldDiscSiteDeviceDriver = (LnshFoldDiscSiteDeviceDriver) device.getDeviceDriver(); - lnshFoldDiscSiteDeviceDriver.writing(2); + lnshFoldDiscSiteDeviceDriver.writing(3); if (lnshFoldDiscSiteDeviceDriver.getMode() != 0 && lnshFoldDiscSiteDeviceDriver.getMove() != 0) { // && (lnshFoldDiscSiteDeviceDriver.getIo_action() == 3 || lnshFoldDiscSiteDeviceDriver.getIo_action() == 1) @@ -452,7 +452,7 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic //标准版-机械手对接位 if (device.getDeviceDriver() instanceof LnshPalletizingManipulatorSiteDeviceDriver) { lnshPalletizingManipulatorSiteDeviceDriver = (LnshPalletizingManipulatorSiteDeviceDriver) device.getDeviceDriver(); - lnshPalletizingManipulatorSiteDeviceDriver.writing(2); + lnshPalletizingManipulatorSiteDeviceDriver.writing(5); if (lnshPalletizingManipulatorSiteDeviceDriver.getMode() != 0 && lnshPalletizingManipulatorSiteDeviceDriver.getMove() == 0 && (lnshPalletizingManipulatorSiteDeviceDriver.getIo_action() == 3 || lnshPalletizingManipulatorSiteDeviceDriver.getIo_action() == 2) @@ -482,7 +482,7 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic //标准版-工位(交互模板) LnshStationDeviceDriver if(device.getDeviceDriver() instanceof LnshStationDeviceDriver){ lnshStationDeviceDriver = (LnshStationDeviceDriver) device.getDeviceDriver(); - lnshStationDeviceDriver.writing(2); + lnshStationDeviceDriver.writing(5); if (lnshStationDeviceDriver.getMode() != 0 && lnshStationDeviceDriver.getMove() == 0 && (lnshStationDeviceDriver.getIo_action() == 3 || lnshStationDeviceDriver.getIo_action() == 2) @@ -558,7 +558,7 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic //标准版-下发条码输送线 if(device.getDeviceDriver() instanceof ConveyorBarcodeDeviceDriver){ conveyorBarcodeDeviceDriver = (ConveyorBarcodeDeviceDriver) device.getDeviceDriver(); - conveyorBarcodeDeviceDriver.writing(2); + conveyorBarcodeDeviceDriver.writing(5); if (conveyorBarcodeDeviceDriver.getMode() != 0 && conveyorBarcodeDeviceDriver.getMove() != 0 && (conveyorBarcodeDeviceDriver.getIo_action() == 3 || conveyorBarcodeDeviceDriver.getIo_action() == 2) @@ -588,7 +588,7 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic //标准版-叠盘机 if(device.getDeviceDriver() instanceof LnshFoldDiscSiteDeviceDriver){ lnshFoldDiscSiteDeviceDriver = (LnshFoldDiscSiteDeviceDriver) device.getDeviceDriver(); - lnshFoldDiscSiteDeviceDriver.writing(2); + lnshFoldDiscSiteDeviceDriver.writing(5); if (lnshFoldDiscSiteDeviceDriver.getMode() != 0 && lnshFoldDiscSiteDeviceDriver.getMove() != 0 // && (lnshFoldDiscSiteDeviceDriver.getIo_action() == 3 || lnshFoldDiscSiteDeviceDriver.getIo_action() == 2) @@ -695,7 +695,7 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic //标准版-机械手对接位 if (device.getDeviceDriver() instanceof LnshPalletizingManipulatorSiteDeviceDriver) { lnshPalletizingManipulatorSiteDeviceDriver = (LnshPalletizingManipulatorSiteDeviceDriver) device.getDeviceDriver(); - lnshPalletizingManipulatorSiteDeviceDriver.writing(13); + lnshPalletizingManipulatorSiteDeviceDriver.writing(4); if (lnshPalletizingManipulatorSiteDeviceDriver.getMode() != 0 && lnshPalletizingManipulatorSiteDeviceDriver.getMove() == 0 && (lnshPalletizingManipulatorSiteDeviceDriver.getIo_action() == 1 || lnshPalletizingManipulatorSiteDeviceDriver.getIo_action() == 3) @@ -728,7 +728,7 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic //标准版-工位(交互模板) if(device.getDeviceDriver() instanceof LnshStationDeviceDriver){ lnshStationDeviceDriver = (LnshStationDeviceDriver) device.getDeviceDriver(); - lnshStationDeviceDriver.writing(13); + lnshStationDeviceDriver.writing(4); if (lnshStationDeviceDriver.getMode() != 0 && lnshStationDeviceDriver.getMove() == 0 && (lnshStationDeviceDriver.getIo_action() == 1 || lnshStationDeviceDriver.getIo_action() == 3) @@ -761,7 +761,7 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic //标准版-压制对接位 if(device.getDeviceDriver() instanceof ConveyorPressStationDeviceDriver){ conveyorPressStationDeviceDriver = (ConveyorPressStationDeviceDriver) device.getDeviceDriver(); - conveyorPressStationDeviceDriver.writing(13); + conveyorPressStationDeviceDriver.writing(4); if (conveyorPressStationDeviceDriver.getMode() != 0 && conveyorPressStationDeviceDriver.getMove() == 0 && (conveyorPressStationDeviceDriver.getIo_action() == 1 || conveyorPressStationDeviceDriver.getIo_action() == 3) @@ -810,7 +810,7 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic //标准版-下发条码输送线 if(device.getDeviceDriver() instanceof ConveyorBarcodeDeviceDriver){ conveyorBarcodeDeviceDriver = (ConveyorBarcodeDeviceDriver) device.getDeviceDriver(); - conveyorBarcodeDeviceDriver.writing(13); + conveyorBarcodeDeviceDriver.writing(4); if (conveyorBarcodeDeviceDriver.getMode() != 0 && conveyorBarcodeDeviceDriver.getMove() == 0 && (conveyorBarcodeDeviceDriver.getIo_action() == 1 || conveyorBarcodeDeviceDriver.getIo_action() == 3) @@ -843,7 +843,7 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic //标准版-叠盘机 if(device.getDeviceDriver() instanceof LnshFoldDiscSiteDeviceDriver){ lnshFoldDiscSiteDeviceDriver = (LnshFoldDiscSiteDeviceDriver) device.getDeviceDriver(); - lnshFoldDiscSiteDeviceDriver.writing(13); + lnshFoldDiscSiteDeviceDriver.writing(4); if (lnshFoldDiscSiteDeviceDriver.getMode() != 0 && lnshFoldDiscSiteDeviceDriver.getMove() == 0 // && (lnshFoldDiscSiteDeviceDriver.getIo_action() == 1 || lnshFoldDiscSiteDeviceDriver.getIo_action() == 3) @@ -940,7 +940,7 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic && (lnshPalletizingManipulatorSiteDeviceDriver.getIo_action() == 2 || lnshPalletizingManipulatorSiteDeviceDriver.getIo_action() == 3)) { inst.setExecute_status("6"); instructionService.update(inst); - lnshPalletizingManipulatorSiteDeviceDriver.writing(3); + lnshPalletizingManipulatorSiteDeviceDriver.writing(5); data = AgvService.sendAgvOneModeInst(phase, index, 0); lnshPalletizingManipulatorSiteDeviceDriver.setMessage(""); flag = true; @@ -969,7 +969,7 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic && (lnshStationDeviceDriver.getIo_action() == 2 || lnshStationDeviceDriver.getIo_action() == 3)) { inst.setExecute_status("6"); instructionService.update(inst); - lnshStationDeviceDriver.writing(3); + lnshStationDeviceDriver.writing(5); data = AgvService.sendAgvOneModeInst(phase, index, 0); lnshStationDeviceDriver.setMessage(""); flag = true; @@ -998,7 +998,7 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic && (conveyorPressStationDeviceDriver.getIo_action() == 2 || conveyorPressStationDeviceDriver.getIo_action() == 3)) { inst.setExecute_status("6"); instructionService.update(inst); - conveyorPressStationDeviceDriver.writing(3); + conveyorPressStationDeviceDriver.writing(5); TaskDto task=taskService.findByCode(inst.getTask_code()); if(ObjectUtil.isNotEmpty(task)){ String direction=task.getDirection(); @@ -1058,7 +1058,7 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic && (conveyorBarcodeDeviceDriver.getIo_action() == 2 || conveyorBarcodeDeviceDriver.getIo_action() == 3)) { inst.setExecute_status("6"); instructionService.update(inst); - conveyorBarcodeDeviceDriver.writing(3); + conveyorBarcodeDeviceDriver.writing(5); data = AgvService.sendAgvOneModeInst(phase, index, 0); conveyorBarcodeDeviceDriver.setMessage(""); flag = true; @@ -1088,7 +1088,7 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic ) { inst.setExecute_status("6"); instructionService.update(inst); - lnshFoldDiscSiteDeviceDriver.writing(3); + lnshFoldDiscSiteDeviceDriver.writing(5); data = AgvService.sendAgvOneModeInst(phase, index, 0); lnshFoldDiscSiteDeviceDriver.setMessage(""); flag = true; diff --git a/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/lnsh/conveyor_press_station/ConveyorPressStationDeviceDriver.java b/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/lnsh/conveyor_press_station/ConveyorPressStationDeviceDriver.java index e8bd4e5..9cb8c0e 100644 --- a/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/lnsh/conveyor_press_station/ConveyorPressStationDeviceDriver.java +++ b/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/lnsh/conveyor_press_station/ConveyorPressStationDeviceDriver.java @@ -708,10 +708,12 @@ public class ConveyorPressStationDeviceDriver extends AbstractOpcDeviceDriver im lucene.deviceExecuteLog(new LuceneLogDto(this.device_code, message + "参数:" + JSON.toJSONString(request))); if (resp.getCode() == 200) { - this.writing(200); - this.writing("to_command",resp.getIs_standing_finish()); - this.writing("to_mix_num",resp.getMix_num()); - this.setRequireSucess(true); + if(StrUtil.equals(resp.getIs_standing_finish(),"1")){ + this.writing(200); + this.setRequireSucess(true); + }else { + this.writing(400); + } } else { this.writing(400); message = RequestMethodEnum.getName("barcode_success_apply") + "barcode_success_apply 接口请求失败" + resp.getMessage();; diff --git a/acs/nladmin-system/src/main/java/org/nl/acs/ext/wms/service/impl/WmsToAcsServiceImpl.java b/acs/nladmin-system/src/main/java/org/nl/acs/ext/wms/service/impl/WmsToAcsServiceImpl.java index 4331c5e..4752190 100644 --- a/acs/nladmin-system/src/main/java/org/nl/acs/ext/wms/service/impl/WmsToAcsServiceImpl.java +++ b/acs/nladmin-system/src/main/java/org/nl/acs/ext/wms/service/impl/WmsToAcsServiceImpl.java @@ -225,6 +225,7 @@ public class WmsToAcsServiceImpl implements WmsToAcsService { jo.put("remark", remark); jo.put("params", params); jo.put("task_type", StrUtil.isEmpty(task_type) ? 1 : Integer.parseInt(task_type)); + jo.put("direction",direction); // 如果是无光电的设备 指令完成变更起点、终点状态 JSONObject startjo = new JSONObject(); startjo.put("device_code", start_device_code);