|
|
@ -69,11 +69,11 @@ public class CraftsStepService { |
|
|
|
} |
|
|
|
return switch (method) { |
|
|
|
case "preHeat" -> preHeat(heatModuleCode, params, craftMonitor); |
|
|
|
case "addLiquid" -> addLiquid(heatModuleCode, params, craftMonitor); |
|
|
|
//case "addLiquid" -> addLiquid(heatModuleCode, params, craftMonitor); |
|
|
|
case "addThin" -> addThin(heatModuleCode, params, craftMonitor); |
|
|
|
case "addThick" -> addThick(heatModuleCode, params, craftMonitor); |
|
|
|
case "heat" -> heat(heatModuleCode, params, craftMonitor); |
|
|
|
case "reduceLiquid" -> reduceLiquid(heatModuleCode, params, craftMonitor); |
|
|
|
//case "reduceLiquid" -> reduceLiquid(heatModuleCode, params, craftMonitor); |
|
|
|
case "clean" -> clean(heatModuleCode, params, craftMonitor); |
|
|
|
case "dry" -> dry(heatModuleCode, params, craftMonitor); |
|
|
|
case "anneal" -> anneal(heatModuleCode, params, craftMonitor); |
|
|
@ -281,9 +281,8 @@ public class CraftsStepService { |
|
|
|
Point3D heatModuleTrayClawPoint3D = heatModuleService.getHeatModuleTrayClawPoint3D(heatModuleCode);//获取目标加热模块托盘夹取点 |
|
|
|
Double drainDistance = systemConfigService.getSystemConfigDoubleByCode(SystemConfigCode.drain_distance);//排空距离 |
|
|
|
Double preFillDistance = systemConfigService.getSystemConfigDoubleByCode(SystemConfigCode.pre_fill_distance);//预充距离 |
|
|
|
Double preFillPosition = devicePositionService.getPosition(DevicePositionCode.solutionModuleMotorDownPreFillPositon).getPositon(); |
|
|
|
Solutions solutions=solutionsService.getByCode(SolutionCode.thin.name());//获取溶液 |
|
|
|
Container container=containerService.getBySolutionsId(solutions.getId());//获取容器 |
|
|
|
Solutions solutions = solutionsService.getByCode(SolutionCode.thin.name());//获取溶液 |
|
|
|
Container container = containerService.getBySolutionsId(solutions.getId());//获取容器 |
|
|
|
Double volume = params.getDouble("volume");//量 |
|
|
|
JSONArray jsonArray = params.getJSONArray("columns");//列数 |
|
|
|
Integer channel = container.getChannel();//获取阀门通道 |
|
|
@ -299,31 +298,12 @@ public class CraftsStepService { |
|
|
|
log.info("工艺{},申请转运模组并等待", heatModuleCode); |
|
|
|
transferModuleService.requestTransferModule(CraftsTransferTypeCode.move_liquid);//申请转运模组并等待 |
|
|
|
|
|
|
|
/*预充开始*/ |
|
|
|
log.info("工艺{},预充开始", heatModuleCode); |
|
|
|
solutionModuleService.solutionMotorMoveZero();//加液机械臂上升 |
|
|
|
transferModuleService.transferXMove(heatArea1TrayClawPoint.getX());//转运模块移动至加热位1 |
|
|
|
solutionModuleService.solutionMotorMove(liquidAreaPreFillPoint);//加液机械臂下降至至预充点位 |
|
|
|
log.info("工艺{},加液机械臂上升", heatModuleCode); |
|
|
|
solutionModuleService.solutionMotorMoveZero();//加液机械臂上升 |
|
|
|
log.info("工艺{},电磁阀对应通道打开", heatModuleCode); |
|
|
|
solutionModuleService.liquidValveSwitch(SolutionCode.waste);//电磁阀对应通道打开 |
|
|
|
log.info("工艺{},加液机械臂下降至预充位置", heatModuleCode); |
|
|
|
solutionModuleService.solutionMotorMove(preFillPosition);//加液机械臂下降至预充位置 |
|
|
|
log.info("工艺{},排空", heatModuleCode); |
|
|
|
solutionModuleService.liquidPumpMove(-drainDistance);//排空 |
|
|
|
log.info("工艺{},电磁阀对应通道打开", heatModuleCode); |
|
|
|
solutionModuleService.liquidValveSwitchByChannel(channel);//电磁阀对应通道打开 |
|
|
|
log.info("工艺{},预充", heatModuleCode); |
|
|
|
solutionModuleService.liquidPumpMove(preFillDistance);//预充 |
|
|
|
log.info("工艺{},加液机械臂上升", heatModuleCode); |
|
|
|
solutionModuleService.solutionMotorMoveZero();//加液机械臂上升 |
|
|
|
/*预充结束*/ |
|
|
|
|
|
|
|
/*移动至加液区开始*/ |
|
|
|
boolean feedTrayExist = deviceSensorService.getSensorStatus(DeviceSensorCode.LIQUID_TRAY_EXIST);//获取上料区传感器状态 |
|
|
|
//Assert.isTrue(feedTrayExist, () -> new AppException(ResultCode.FEED_AREA_NO_TRAY)); |
|
|
|
log.info("工艺{},上料区存在托盘", heatModuleCode); |
|
|
|
Assert.isTrue(feedTrayExist, () -> new AppException(ResultCode.FEED_AREA_NO_TRAY)); |
|
|
|
log.info("工艺{},加液机械臂上升", heatModuleCode); |
|
|
|
solutionModuleService.solutionMotorMoveZero();//加液机械臂上升 |
|
|
|
log.info("工艺{},机械臂移动至上料区", heatModuleCode); |
|
|
|
webSocketService.pushCraftsDebug(CraftsDebugGenerator.generateJson(heatModuleCode.toString(), "机械臂移动至上料区", feedAreaTrayPoint3D)); |
|
|
|
log.info("工艺{},将X轴移动至上料区托盘夹取点 + 进出卡槽移动距离", heatModuleCode); |
|
|
@ -342,10 +322,29 @@ public class CraftsStepService { |
|
|
|
deviceStateService.getDeviceState().getSolutionModule().setPumping(true);//正在加液 |
|
|
|
deviceStateService.getDeviceState().getTrayByHeatModuleCode(heatModuleCode).setInSolutionPositon(true);//托盘状态 |
|
|
|
boolean clawTrayExist = deviceSensorService.getSensorStatus(DeviceSensorCode.CLAW_TRAY_EXIST);//获取传感器状态 |
|
|
|
//Assert.isTrue(clawTrayExist, () -> new AppException(ResultCode.TARGET_HEAT_MODULE_NO_TRAY));//加液区无托盘 |
|
|
|
Assert.isTrue(clawTrayExist, () -> new AppException(ResultCode.TARGET_HEAT_MODULE_NO_TRAY));//加液区无托盘 |
|
|
|
/*移动至加液区结束*/ |
|
|
|
|
|
|
|
|
|
|
|
/*预充开始*/ |
|
|
|
feedTrayExist = deviceSensorService.getSensorStatus(DeviceSensorCode.LIQUID_TRAY_EXIST);//获取传感器状态 |
|
|
|
Assert.isTrue(!feedTrayExist, () -> new AppException(ResultCode.FEED_AREA_EXIST_TRAY));//上料区有托盘 |
|
|
|
log.info("工艺{},预充开始", heatModuleCode); |
|
|
|
transferModuleService.transferXMove(heatArea1TrayClawPoint.getX());//转运模块移动至加热位1 |
|
|
|
log.info("工艺{},加液机械臂下降至预充位置", heatModuleCode); |
|
|
|
solutionModuleService.solutionMotorMove(liquidAreaPreFillPoint);//加液机械臂下降至至预充点位 |
|
|
|
log.info("工艺{},电磁阀对应通道打开", heatModuleCode); |
|
|
|
solutionModuleService.liquidValveSwitch(SolutionCode.waste);//电磁阀对应通道打开 |
|
|
|
log.info("工艺{},排空", heatModuleCode); |
|
|
|
solutionModuleService.liquidPumpMove(-drainDistance);//排空 |
|
|
|
log.info("工艺{},电磁阀对应通道打开", heatModuleCode); |
|
|
|
solutionModuleService.liquidValveSwitchByChannel(channel);//电磁阀对应通道打开 |
|
|
|
log.info("工艺{},预充", heatModuleCode); |
|
|
|
solutionModuleService.liquidPumpMove(preFillDistance);//预充 |
|
|
|
log.info("工艺{},加液机械臂上升", heatModuleCode); |
|
|
|
solutionModuleService.solutionMotorMoveZero();//加液机械臂上升 |
|
|
|
/*预充结束*/ |
|
|
|
|
|
|
|
/*开始加液*/ |
|
|
|
List<Integer> columns = new ArrayList<>(); |
|
|
|
if (jsonArray != null) { |
|
|
@ -432,15 +431,15 @@ public class CraftsStepService { |
|
|
|
Point3D heatModuleTrayClawPoint3D = heatModuleService.getHeatModuleTrayClawPoint3D(heatModuleCode);//获取目标加热模块托盘夹取点 |
|
|
|
Double drainDistance = systemConfigService.getSystemConfigDoubleByCode(SystemConfigCode.drain_distance);//排空距离 |
|
|
|
Double preFillDistance = systemConfigService.getSystemConfigDoubleByCode(SystemConfigCode.pre_fill_distance);//预充距离 |
|
|
|
Double preFillPosition = devicePositionService.getPosition(DevicePositionCode.solutionModuleMotorDownPreFillPositon).getPositon(); |
|
|
|
Solutions solutions=solutionsService.getByCode(SolutionCode.thick.name());//获取溶液 |
|
|
|
Container container=containerService.getBySolutionsId(solutions.getId());//获取容器 |
|
|
|
Solutions solutions = solutionsService.getByCode(SolutionCode.thick.name());//获取溶液 |
|
|
|
Container container = containerService.getBySolutionsId(solutions.getId());//获取容器 |
|
|
|
Double volume = params.getDouble("volume");//量 |
|
|
|
JSONArray jsonArray = params.getJSONArray("columns");//列数 |
|
|
|
Integer channel = container.getChannel();//获取阀门通道 |
|
|
|
Double trayTubeHorizontalSpacingDistance = devicePositionService.getPosition(DevicePositionCode.trayTubeHorizontalSpacingDistance).getDistance(); //托盘试管水平间距 |
|
|
|
double scale = systemConfigService.getSystemConfigDoubleByCode(SystemConfigCode.valueOf(solutions.getCode()));//获取转换比 |
|
|
|
Double solutionModuleMotorDownInTubeAddPositon = devicePositionService.getPosition(DevicePositionCode.solutionModuleMotorDownInTubeAddPositon).getPositon(); //加液模块电机下降进入试管加液位置 |
|
|
|
Double solutionModuleMotorDownInTubeExtPositon = devicePositionService.getPosition(DevicePositionCode.solutionModuleMotorDownInTubeExtPositon).getPositon(); //加液模块电机下降进入试管加液位置 |
|
|
|
double addLiquidDistance = volume * scale; |
|
|
|
Double reduceDistance = systemConfigService.getSystemConfigDoubleByCode(SystemConfigCode.reduce_distance);//抽液距离 |
|
|
|
Point3D heatArea1TrayClawPoint = devicePositionService.getPosition(DevicePositionCode.heatArea1TrayClawPoint).getPoint3D(); |
|
|
@ -450,30 +449,10 @@ public class CraftsStepService { |
|
|
|
log.info("工艺{},申请转运模组并等待", heatModuleCode); |
|
|
|
transferModuleService.requestTransferModule(CraftsTransferTypeCode.move_liquid);//申请转运模组并等待 |
|
|
|
|
|
|
|
/*预充开始*/ |
|
|
|
log.info("工艺{},预充开始", heatModuleCode); |
|
|
|
solutionModuleService.solutionMotorMoveZero();//加液机械臂上升 |
|
|
|
transferModuleService.transferXMove(heatArea1TrayClawPoint.getX());//转运模块移动至加热位1 |
|
|
|
solutionModuleService.solutionMotorMove(liquidAreaPreFillPoint);//加液机械臂下降至至预充点位 |
|
|
|
log.info("工艺{},加液机械臂上升", heatModuleCode); |
|
|
|
solutionModuleService.solutionMotorMoveZero();//加液机械臂上升 |
|
|
|
log.info("工艺{},电磁阀对应通道打开", heatModuleCode); |
|
|
|
solutionModuleService.liquidValveSwitch(SolutionCode.waste);//电磁阀对应通道打开 |
|
|
|
log.info("工艺{},加液机械臂下降至预充位置", heatModuleCode); |
|
|
|
solutionModuleService.solutionMotorMove(preFillPosition);//加液机械臂下降至预充位置 |
|
|
|
log.info("工艺{},排空", heatModuleCode); |
|
|
|
solutionModuleService.liquidPumpMove(-drainDistance);//排空 |
|
|
|
log.info("工艺{},电磁阀对应通道打开", heatModuleCode); |
|
|
|
solutionModuleService.liquidValveSwitchByChannel(channel);//电磁阀对应通道打开 |
|
|
|
log.info("工艺{},预充", heatModuleCode); |
|
|
|
solutionModuleService.liquidPumpMove(preFillDistance);//预充 |
|
|
|
log.info("工艺{},加液机械臂上升", heatModuleCode); |
|
|
|
solutionModuleService.solutionMotorMoveZero();//加液机械臂上升 |
|
|
|
/*预充结束*/ |
|
|
|
|
|
|
|
/*移动至加液区*/ |
|
|
|
boolean heatTrayExist = deviceSensorService.getTrayStateByHeatModuleCode(heatModuleCode);//获取加热区试管架 |
|
|
|
//Assert.isTrue(heatTrayExist, () -> new AppException(ResultCode.TARGET_HEAT_MODULE_NO_TRAY));//目标加热区无托盘 |
|
|
|
Assert.isTrue(heatTrayExist, () -> new AppException(ResultCode.TARGET_HEAT_MODULE_NO_TRAY));//目标加热区无托盘 |
|
|
|
log.info("工艺{},加热区存在托盘", heatModuleCode); |
|
|
|
log.info("工艺{},机械臂移动至加热区", heatModuleCode); |
|
|
|
webSocketService.pushCraftsDebug(CraftsDebugGenerator.generateJson(heatModuleCode.toString(), "机械臂移动至加热区", heatModuleCode.name())); |
|
|
@ -492,12 +471,13 @@ public class CraftsStepService { |
|
|
|
transferModuleService.transferMove(liquidAreaTrayPoint3D);//移动至加液时托盘位置点 |
|
|
|
deviceStateService.getDeviceState().getTrayByHeatModuleCode(heatModuleCode).setInSolutionPositon(true);//托盘状态 |
|
|
|
boolean clawTrayExist = deviceSensorService.getSensorStatus(DeviceSensorCode.CLAW_TRAY_EXIST);//获取传感器状态 |
|
|
|
//Assert.isTrue(clawTrayExist, () -> new AppException(ResultCode.TARGET_HEAT_MODULE_NO_TRAY));//加液区无托盘 |
|
|
|
Assert.isTrue(clawTrayExist, () -> new AppException(ResultCode.TARGET_HEAT_MODULE_NO_TRAY));//加液区无托盘 |
|
|
|
/*移动至加液区结束*/ |
|
|
|
|
|
|
|
|
|
|
|
/*开始抽液*/ |
|
|
|
log.info("工艺{},开始抽液", heatModuleCode); |
|
|
|
solutionModuleService.liquidValveSwitch(SolutionCode.waste);//电磁阀转换到废液 |
|
|
|
List<Integer> reduceColumns = new ArrayList<>(); |
|
|
|
TubeState[] tubes = deviceStateService.getDeviceState().getTrayByHeatModuleCode(heatModuleCode).getTubes(); |
|
|
|
for (TubeState tube : tubes) { |
|
|
@ -512,7 +492,7 @@ public class CraftsStepService { |
|
|
|
log.info("工艺{},机械臂移动到试管位置{}", heatModuleCode, i); |
|
|
|
transferModuleService.transferXMove(liquidAreaTrayPoint3D.getX() + distance);//机械臂移动到试管位置 |
|
|
|
log.info("工艺{},加液机械臂下降", heatModuleCode); |
|
|
|
solutionModuleService.solutionMotorMove(solutionModuleMotorDownInTubeAddPositon);//加液机械臂下降 |
|
|
|
solutionModuleService.solutionMotorMove(solutionModuleMotorDownInTubeExtPositon);//加液机械臂下降 |
|
|
|
webSocketService.pushCraftsDebug(CraftsDebugGenerator.generateJson(heatModuleCode.toString(), "抽取溶液", addLiquidDistance)); |
|
|
|
log.info("工艺{},加液", heatModuleCode); |
|
|
|
solutionModuleService.liquidPumpMove(-reduceDistance);//加液 position |
|
|
@ -523,9 +503,30 @@ public class CraftsStepService { |
|
|
|
|
|
|
|
/*抽液结束*/ |
|
|
|
|
|
|
|
|
|
|
|
/*预充开始*/ |
|
|
|
boolean feedTrayExist = deviceSensorService.getSensorStatus(DeviceSensorCode.LIQUID_TRAY_EXIST);//获取传感器状态 |
|
|
|
Assert.isTrue(!feedTrayExist, () -> new AppException(ResultCode.FEED_AREA_EXIST_TRAY));//上料区有托盘 |
|
|
|
log.info("工艺{},预充开始", heatModuleCode); |
|
|
|
log.info("工艺{},加液机械臂上升", heatModuleCode); |
|
|
|
solutionModuleService.solutionMotorMoveZero();//加液机械臂上升 |
|
|
|
transferModuleService.transferXMove(heatArea1TrayClawPoint.getX());//转运模块移动至加热位1 |
|
|
|
solutionModuleService.solutionMotorMove(liquidAreaPreFillPoint);//加液机械臂下降至至预充点位 |
|
|
|
log.info("工艺{},电磁阀对应通道打开", heatModuleCode); |
|
|
|
solutionModuleService.liquidValveSwitch(SolutionCode.waste);//电磁阀对应通道打开 |
|
|
|
log.info("工艺{},排空", heatModuleCode); |
|
|
|
solutionModuleService.liquidPumpMove(-drainDistance);//排空 |
|
|
|
log.info("工艺{},电磁阀对应通道打开", heatModuleCode); |
|
|
|
solutionModuleService.liquidValveSwitchByChannel(channel);//电磁阀对应通道打开 |
|
|
|
log.info("工艺{},预充", heatModuleCode); |
|
|
|
solutionModuleService.liquidPumpMove(preFillDistance);//预充 |
|
|
|
log.info("工艺{},加液机械臂上升", heatModuleCode); |
|
|
|
solutionModuleService.solutionMotorMoveZero();//加液机械臂上升 |
|
|
|
/*预充结束*/ |
|
|
|
|
|
|
|
/*移动至加液区*/ |
|
|
|
log.info("工艺{},移动至加液区", heatModuleCode); |
|
|
|
transferModuleService.transferMove(liquidAreaTrayPoint3D);//移动至加液时托盘位置点 |
|
|
|
transferModuleService.transferMove(liquidAreaTrayPoint3D);//移动至加液至托盘位置点 |
|
|
|
/*移动至加液区*/ |
|
|
|
|
|
|
|
/*开始加液*/ |
|
|
@ -566,7 +567,7 @@ public class CraftsStepService { |
|
|
|
/*移动至加热区*/ |
|
|
|
log.info("工艺{},移动至加热区", heatModuleCode); |
|
|
|
boolean heatModuleTrayExist = deviceSensorService.getTrayStateByHeatModuleCode(heatModuleCode);//目标加热模块有无托盘 |
|
|
|
//Assert.isTrue(!heatModuleTrayExist, () -> new AppException(ResultCode.TARGET_HEAT_MODULE_OCCUPIED));//提示被占用 |
|
|
|
Assert.isTrue(!heatModuleTrayExist, () -> new AppException(ResultCode.TARGET_HEAT_MODULE_OCCUPIED));//提示被占用 |
|
|
|
webSocketService.pushCraftsDebug(CraftsDebugGenerator.generateJson(heatModuleCode.toString(), "机械臂移动至加热区", heatModuleCode)); |
|
|
|
log.info("工艺{},加液机械臂上升", heatModuleCode); |
|
|
|
solutionModuleService.solutionMotorMoveZero();//加液机械臂上升 |
|
|
@ -616,7 +617,7 @@ public class CraftsStepService { |
|
|
|
/*获取参数结束*/ |
|
|
|
|
|
|
|
boolean heatTrayExist = deviceSensorService.getTrayStateByHeatModuleCode(heatModuleCode);//获取加热区传感器状态 |
|
|
|
//Assert.isTrue(heatTrayExist, () -> new AppException(ResultCode.CRAFT_TARGET_HEAT_NO_TRAY));//加热区无托盘 |
|
|
|
Assert.isTrue(heatTrayExist, () -> new AppException(ResultCode.CRAFT_TARGET_HEAT_NO_TRAY));//加热区无托盘 |
|
|
|
log.info("工艺{},申请转运模组并等待", heatModuleCode); |
|
|
|
transferModuleService.requestTransferModule(CraftsTransferTypeCode.move_liquid);//申请转运模组并等待 |
|
|
|
log.info("工艺{},加液机械臂上升", heatModuleCode); |
|
|
@ -774,8 +775,11 @@ public class CraftsStepService { |
|
|
|
Double volume = params.getDouble("volume") == null ? 2.0 : params.getDouble("volume");//加水量 |
|
|
|
Integer cycle = params.getInt("cycle");//次数 |
|
|
|
Double height = params.getDouble("height");//下降进入试管的高度 |
|
|
|
if (height > 50) { |
|
|
|
throw new AppException(ResultCode.CRAFT_PARAMS_MISTAKE); |
|
|
|
} |
|
|
|
boolean heatModuleTrayExist = deviceSensorService.getTrayStateByHeatModuleCode(heatModuleCode);//目标加热模块有无托盘 |
|
|
|
//Assert.isTrue(heatModuleTrayExist, () -> new AppException(ResultCode.CRAFT_TARGET_HEAT_NO_TRAY));//提示工艺加热区无托盘 |
|
|
|
Assert.isTrue(heatModuleTrayExist, () -> new AppException(ResultCode.CRAFT_TARGET_HEAT_NO_TRAY));//提示工艺加热区无托盘 |
|
|
|
Point3D heatModuleTrayClawPoint3D = heatModuleService.getHeatModuleTrayClawPoint3D(heatModuleCode);//获取目标加热模块托盘夹取点 |
|
|
|
Double transferModuleXPickTrayMoveDistance = devicePositionService.getPosition(DevicePositionCode.transferModuleXPickTrayMoveDistance).getDistance();//获取转运模块X轴拿取托盘进出卡槽移动距离 |
|
|
|
Point3D liquidAreaTrayPoint3D = devicePositionService.getPosition(DevicePositionCode.liquidAreaTrayPoint).getPoint3D();//获取加液时托盘位置点 |
|
|
@ -808,11 +812,11 @@ public class CraftsStepService { |
|
|
|
transferModuleService.transferZMoveZero();//Z轴抬升至最高 |
|
|
|
log.info("工艺{},机械臂移动至加液区", heatModuleCode); |
|
|
|
webSocketService.pushCraftsDebug(CraftsDebugGenerator.generateJson(heatModuleCode.toString(), "机械臂移动至加液区", liquidAreaTrayPoint3D)); |
|
|
|
transferModuleService.transferMove(liquidAreaTrayPoint3D);//移动至加液时托盘位置点 |
|
|
|
deviceStateService.getDeviceState().getHeatModuleByCode(heatModuleCode).setTrayStatus(false);//加热区托盘状态 |
|
|
|
deviceStateService.getDeviceState().getTrayByHeatModuleCode(heatModuleCode).setInHeatModule(false);//托盘状态 |
|
|
|
deviceStateService.getDeviceState().getTrayByHeatModuleCode(heatModuleCode).setInSolutionPositon(true);//托盘状态 |
|
|
|
deviceStateService.getDeviceState().getSolutionModule().setPumping(true); |
|
|
|
transferModuleService.transferMove(liquidAreaTrayPoint3D);//移动至加液时托盘位置点 |
|
|
|
/*列号开始*/ |
|
|
|
List<Integer> columns = new ArrayList<>(); |
|
|
|
TubeState[] tubes = deviceStateService.getDeviceState().getTrayByHeatModuleCode(heatModuleCode).getTubes(); |
|
|
@ -843,7 +847,11 @@ public class CraftsStepService { |
|
|
|
/*抽液结束*/ |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/*预充开始*/ |
|
|
|
boolean feedTrayExist = deviceSensorService.getSensorStatus(DeviceSensorCode.LIQUID_TRAY_EXIST);//获取传感器状态 |
|
|
|
Assert.isTrue(!feedTrayExist, () -> new AppException(ResultCode.FEED_AREA_EXIST_TRAY));//上料区有托盘 |
|
|
|
log.info("工艺{},清洗-预充开始", heatModuleCode); |
|
|
|
solutionModuleService.solutionMotorMoveZero();//加液机械臂上升 |
|
|
|
transferModuleService.transferXMove(heatArea1TrayClawPoint.getX());//转运模块移动至加热位1 |
|
|
@ -984,7 +992,7 @@ public class CraftsStepService { |
|
|
|
Double temperature = params.getDouble("temperature");//退火温度 |
|
|
|
Integer time = params.getInt("time");//秒 |
|
|
|
boolean heatModuleTrayExist = deviceSensorService.getTrayStateByHeatModuleCode(heatModuleCode); |
|
|
|
//Assert.isTrue(heatModuleTrayExist, () -> new AppException(ResultCode.CRAFT_TARGET_HEAT_NO_TRAY));//提示加热模块无托盘 |
|
|
|
Assert.isTrue(heatModuleTrayExist, () -> new AppException(ResultCode.CRAFT_TARGET_HEAT_NO_TRAY));//提示加热模块无托盘 |
|
|
|
while (deviceSensorService.getTrayStateByHeatModuleCode(HeatModuleCode.heat_module_04)) {//判断退火区是否被占用 |
|
|
|
delay(10);//等待10秒 |
|
|
|
} |
|
|
@ -1053,7 +1061,8 @@ public class CraftsStepService { |
|
|
|
} |
|
|
|
log.info("工艺{},恒温中", HeatModuleCode.heat_module_04); |
|
|
|
delay(seconds); |
|
|
|
|
|
|
|
heatModuleService.heatRodClose(HeatModuleCode.heat_module_04);//关闭加热棒 |
|
|
|
deviceStateService.getDeviceState().getHeatModuleByCode(HeatModuleCode.heat_module_04).setHeatingType(HeatingType.stop); //设置加热区状态 停止加热 |
|
|
|
|
|
|
|
log.info("工艺{},加热完毕", heatModuleCode); |
|
|
|
log.info("工艺{},获取转运模组锁", heatModuleCode); |
|
|
@ -1091,7 +1100,6 @@ public class CraftsStepService { |
|
|
|
log.info("工艺{},散热关闭", heatModuleCode); |
|
|
|
heatModuleService.fanClose(heatModuleCode);//散热关闭 |
|
|
|
deviceStateService.getDeviceState().getHeatModuleByCode(heatModuleCode).setFanOpen(false); //设置加热区风扇关闭 |
|
|
|
deviceStateService.getDeviceState().getHeatModuleByCode(HeatModuleCode.heat_module_04).setHeatingType(HeatingType.stop); //设置加热区状态 加热中 |
|
|
|
deviceLightSoundService.openBeep(CmdBeepMode.info); |
|
|
|
delay(2); |
|
|
|
deviceLightSoundService.closeBeep(); |
|
|
@ -1141,6 +1149,7 @@ public class CraftsStepService { |
|
|
|
trayList.removeIf((tray) -> tray.getHeatModuleCode().equals(heatModuleCode)); |
|
|
|
// moveToFeedModule(heatModuleCode); |
|
|
|
} |
|
|
|
|
|
|
|
/*结束后移动至上料区*/ |
|
|
|
public void moveToFeedModule(HeatModuleCode heatModuleCode) throws Exception { |
|
|
|
try { |
|
|
@ -1188,7 +1197,7 @@ public class CraftsStepService { |
|
|
|
transferModuleService.releaseTransferModule();//转运模组释放 |
|
|
|
} |
|
|
|
List<TrayState> trayList = deviceStateService.getDeviceState().getTrays(); |
|
|
|
trayList.removeIf((tray)->tray.getHeatModuleCode().equals(heatModuleCode)); |
|
|
|
trayList.removeIf((tray) -> tray.getHeatModuleCode().equals(heatModuleCode)); |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|