diff --git a/app.db b/app.db index caca704..e727053 100644 Binary files a/app.db and b/app.db differ diff --git a/src/main/java/com/iflytop/digester/DigestionTaskThread.java b/src/main/java/com/iflytop/digester/DigestionTaskThread.java index 3af7bfc..0085b12 100644 --- a/src/main/java/com/iflytop/digester/DigestionTaskThread.java +++ b/src/main/java/com/iflytop/digester/DigestionTaskThread.java @@ -267,7 +267,7 @@ public class DigestionTaskThread extends Thread { // 正常消解结束; this.updateTaskStatus("LastRound", "取出试管架"); device.door.open(); // 打开门 - this.waitForTubeRackTakeOut(); // 等待取出 + this.waitForTubeRackTakeOut(this.heatingSlot.tubes); // 等待取出 device.door.close(); // 关闭门 this.heatingSlot.setTubeRackNo(null); // 释放加热位 this.updateTaskStatus("LastRound", "执行最后一轮配置结束"); @@ -395,14 +395,15 @@ public class DigestionTaskThread extends Thread { // 取出剩余异常试管 device.transferArm.takeOutTubesFromErrorSlot(this.errorTubeIndexes); + + // 等待取出试管架 + device.door.open(); var errorSlot = device.heatingTurntable.getErrorSlot(); + this.waitForTubeRackTakeOut(errorSlot.tubes); for ( var index : this.errorTubeIndexes ) { errorSlot.tubes.set(index, null); } - // 等待取出试管架 - device.door.open(); - this.waitForTubeRackTakeOut(); device.door.close(); this.unlockLiquidPlate("异常处理:剩余试管已取出"); } catch (InterruptedException e) { @@ -477,7 +478,11 @@ public class DigestionTaskThread extends Thread { // 等待取出试管架 device.door.open(); - this.waitForTubeRackTakeOut(); + List tubes = new ArrayList<>(); + for ( var index : this.finishedErrorTubeIndexes ) { + tubes.add(errorSlot.tubes.get(index)); + } + this.waitForTubeRackTakeOut(tubes); device.door.close(); this.unlockLiquidPlate("异常处理:消解完成的试管已取出"); @@ -553,13 +558,13 @@ public class DigestionTaskThread extends Thread { } // 等待取出试管架 - private void waitForTubeRackTakeOut() { + private void waitForTubeRackTakeOut( List tubes ) { this.updateTaskStatus("TubeRackTakeOutWait", "等待取出试管架"); Map message = new HashMap<>(); message.put("taskId", this.taskModel.outTaskId); message.put("batchNo", this.taskModel.batchNo); - message.put("tubes", this.heatingSlot.tubes); + message.put("tubes", tubes); if ( "auto".equals(this.taskModel.mode) ) { this.manager.sendMessageToTransBot("TubeRackTakeOut", message); } else {