fix: 出库任务状态优化,修改分切双工位行架放空满逻辑

This commit is contained in:
yanps
2025-02-22 13:49:43 +08:00
parent 4f71e50af7
commit 069c5fc63b
3 changed files with 29 additions and 10 deletions

View File

@@ -551,12 +551,12 @@ public class SiemensConveyorCkkDeviceDriver extends AbstractOpcDeviceDriver impl
instructionService.update(inst);
logServer.deviceExecuteLog(device_code, "", "", "入库输送线任务开始反馈执行中状态,反馈成功,指令号:" + task);
}
if (StrUtil.equals(inst.getInstruction_status(), "1")) {
/*if (StrUtil.equals(inst.getInstruction_status(), "1")) {
if (!StrUtil.equals(inst.getExecute_code(), this.device_code)) {
inst.setExecute_device_code(this.device_code);
instructionService.update(inst);
}
}
}*/
} else {
inst_message = null;
}

View File

@@ -18,6 +18,7 @@ import org.nl.acs.device_driver.DeviceDriver;
import org.nl.acs.device_driver.FeedLmsRealFailed;
import org.nl.acs.device_driver.RouteableDeviceDriver;
import org.nl.acs.device_driver.basedriver.siemens_conveyor.SiemensConveyorDeviceDriver;
import org.nl.acs.device_driver.basedriver.standard_ordinary_site.StandardOrdinarySiteDeviceDriver;
import org.nl.acs.device_driver.driver.AbstractOpcDeviceDriver;
import org.nl.acs.device_driver.driver.ExecutableDeviceDriver;
import org.nl.acs.ext.wms.service.AcsToWmsService;
@@ -1409,6 +1410,15 @@ public class SlitTwoManipulatorDeviceDriver extends AbstractOpcDeviceDriver impl
}
}
}
}else if(startDevice.getDeviceDriver() instanceof StandardOrdinarySiteDeviceDriver){
if (to_command2 != 2) {
this.writing("to_command2", "2");
}
if (type == 2) {
this.setNow_steps_type2(3);
} else if (type == 3) {
this.setNow_steps_type3(3);
}
}
} else {
if (this.getNow_steps_type2() == 2 || this.getNow_steps_type3() == 2) {
@@ -1579,9 +1589,9 @@ public class SlitTwoManipulatorDeviceDriver extends AbstractOpcDeviceDriver impl
}
//双任务 后工位反馈任务完成 并反馈
if (mode == 3 && action2 == 4 && move2 == 0 && task1 > 0 && task2 > 0 && type == 3) {
if (to_command2 != 5) {
this.writing("to_command2", "5");
if (mode == 3 && action1 == 4 && move2 == 0 && task1 > 0 && task2 > 0 && type == 3) {
if (to_command1 != 5) {
this.writing("to_command1", "5");
}
this.setNow_steps_type3(8);
} else {
@@ -1648,6 +1658,15 @@ public class SlitTwoManipulatorDeviceDriver extends AbstractOpcDeviceDriver impl
}
}
}
}else if (nextDevice.getDeviceDriver() instanceof StandardOrdinarySiteDeviceDriver){
if (to_command1 != 4) {
this.writing("to_command1", "4");
}
if (type == 1) {
this.setNow_steps_type1(5);
} else if (type == 3) {
this.setNow_steps_type3(9);
}
}
} else {
if (this.getNow_steps_type1() == 4 || this.getNow_steps_type3() == 8) {
@@ -1705,13 +1724,13 @@ public class SlitTwoManipulatorDeviceDriver extends AbstractOpcDeviceDriver impl
//双工位 任务完成 前工位反馈4
if (mode == 3 && action1 == 4 && move1 == 0 && task1 > 0 && task2 > 0 && type == 3) {
if (mode == 3 && action2 == 4 && move1 == 0 && task1 > 0 && task2 > 0 && type == 3) {
//inst_message
Instruction inst1 = instructionService.findByCodeFromCache(String.valueOf(task1));
if (inst1 != null) {
if (StrUtil.equals(inst1.getInstruction_status(), "1")) {
if (to_command1 != 5) {
this.writing("to_command1", "5");
if (to_command2 != 5) {
this.writing("to_command2", "5");
}
this.setNow_steps_type3(10);
this.setNow_steps_type3(0);

View File

@@ -216,10 +216,10 @@ public class LiKuToAcsServiceImpl implements LiKuToAcsService {
inst.setInstruction_status("2");
instructionService.finish(inst.getInstruction_id());
}
if (!"2".equals(inst.getInstruction_status())) {
/*if (!"2".equals(inst.getInstruction_status())) {
inst.setRemark("立库已反馈完成,待输送上报任务号");
instructionService.update(inst);
}
}*/
}
} else if(StrUtil.equals(status,"4")){