| | |
| | | } |
| | | //门作业 无 |
| | | //自动、空闲、右门关闭、 Other左门关闭 |
| | | if (jarProtocol.isAutoing() && jarProtocol.jarErr==0 |
| | | && jarProtocol.leftDoorOpen==0 && jarProtocol.leftDoorClose==0 && jarProtocol.rightDoorOpen==0 && jarProtocol.rightDoorClose==0){ |
| | | if (jarProtocol.isAutoing() && jarProtocol.jarErr==0){ |
| | | if (jarWrkMastExecuteGenerate5(jarSlave,sign)){ |
| | | signExecute[jarSlave.getId()-5] = true; |
| | | return signExecute; |
| | | //冷却完成上输送线 |
| | | } |
| | | continue; |
| | | } |
| | | } catch (Exception e){ |
| | | log.error("{}号硫化罐JarWrkMastExecute任务创建异常,异常原因={}",jarSlave.getId(),e.getMessage()); |
| | |
| | | return signExecute; |
| | | } |
| | | |
| | | // public synchronized boolean[] jarWrkMastExecuteGenerateSte(boolean[] signExecute,Integer sign) { |
| | | // for (JarSlave jarSlave : slaveProperties.getJar()) { |
| | | // if (jarSlave.getId()<5){ |
| | | // continue; |
| | | // } |
| | | // try{ |
| | | // if (signExecute[jarSlave.getId()-5]){ |
| | | // continue; |
| | | // } |
| | | // if (wrkMastExecuteService.getWrkMastExecuteByJarIdCount(jarSlave.getId())!=0){ |
| | | // continue; |
| | | // } |
| | | // |
| | | // // 获取硫化罐信息 |
| | | // JarThread jarThread = (JarThread) SlaveConnection.get(SlaveType.Jar, jarSlave.getId()); |
| | | // JarProtocol jarProtocol = jarThread.getJarProtocol(); |
| | | // if (jarProtocol == null) { |
| | | // continue; |
| | | // } |
| | | // if (jarProtocol.modeType != JarModeType.AUTO){ |
| | | // continue; |
| | | // } |
| | | // if (jarProtocol.getJarTemperature()>jarTemperature){ |
| | | // log.error("{}号硫化罐查询设备温度过高,等待降温....!!!",jarProtocol.getJarNo()); |
| | | // continue; |
| | | // } |
| | | // |
| | | // JarThread jarOtherThread = (JarThread) SlaveConnection.get(SlaveType.Jar, jarSlave.getJarOtherId()); |
| | | // JarProtocol jarOtherProtocol = jarOtherThread.getJarProtocol(); |
| | | // if (jarOtherProtocol == null) { |
| | | // continue; |
| | | // } |
| | | //// if (jarOtherProtocol.modeType != JarModeType.AUTO){ |
| | | //// continue; |
| | | //// } |
| | | // |
| | | // BasJar basJar = basJarMapper.selectById(jarProtocol.getJarNo()); |
| | | // if (Cools.isEmpty(basJar)){ |
| | | // log.error("{}号硫化罐查询设备档案无信息!!!",jarProtocol.getJarNo()); |
| | | // continue; |
| | | // } |
| | | // //门作业 无 |
| | | // //自动、空闲、右门关闭、 Other左门关闭 |
| | | // if (jarProtocol.isAutoing() && jarProtocol.jarErr==0 |
| | | // && jarProtocol.leftDoorOpen==0 && jarProtocol.leftDoorClose==0 && jarProtocol.rightDoorOpen==0 && jarProtocol.rightDoorClose==0){ |
| | | // switch (sign){ |
| | | // case 5: |
| | | // if (jarWrkMastExecuteGenerate5(jarSlave,sign)){ |
| | | // signExecute[jarSlave.getId()-5] = true; |
| | | // break; |
| | | // } |
| | | public synchronized boolean[] jarWrkMastExecuteGenerateSte(boolean[] signExecute,Integer sign) { |
| | | for (JarSlave jarSlave : slaveProperties.getJar()) { |
| | | if (jarSlave.getId()<5){ |
| | | continue; |
| | | } |
| | | try{ |
| | | if (signExecute[jarSlave.getId()-5]){ |
| | | continue; |
| | | } |
| | | if (wrkMastExecuteService.getWrkMastExecuteByJarIdCount(jarSlave.getId())!=0){ |
| | | continue; |
| | | } |
| | | |
| | | // 获取硫化罐信息 |
| | | JarThread jarThread = (JarThread) SlaveConnection.get(SlaveType.Jar, jarSlave.getId()); |
| | | JarProtocol jarProtocol = jarThread.getJarProtocol(); |
| | | if (jarProtocol == null) { |
| | | continue; |
| | | } |
| | | if (jarProtocol.modeType != JarModeType.AUTO){ |
| | | continue; |
| | | } |
| | | if (jarProtocol.getJarTemperature()>jarTemperature){ |
| | | log.error("{}号硫化罐查询设备温度过高,等待降温....!!!",jarProtocol.getJarNo()); |
| | | continue; |
| | | } |
| | | |
| | | JarThread jarOtherThread = (JarThread) SlaveConnection.get(SlaveType.Jar, jarSlave.getJarOtherId()); |
| | | JarProtocol jarOtherProtocol = jarOtherThread.getJarProtocol(); |
| | | if (jarOtherProtocol == null) { |
| | | continue; |
| | | } |
| | | // if (jarOtherProtocol.modeType != JarModeType.AUTO){ |
| | | // continue; |
| | | // } |
| | | // } |
| | | // } catch (Exception e){ |
| | | // log.error("{}号硫化罐JarWrkMastExecute任务创建异常,异常原因={}",jarSlave.getId(),e.getMessage()); |
| | | // } |
| | | // } |
| | | // return signExecute; |
| | | // } |
| | | |
| | | BasJar basJar = basJarMapper.selectById(jarProtocol.getJarNo()); |
| | | if (Cools.isEmpty(basJar)){ |
| | | log.error("{}号硫化罐查询设备档案无信息!!!",jarProtocol.getJarNo()); |
| | | continue; |
| | | } |
| | | //门作业 无 |
| | | //自动、空闲、右门关闭、 Other左门关闭 |
| | | if (jarProtocol.isAutoing() && jarProtocol.jarErr==0 |
| | | && jarProtocol.leftDoorOpen==0 && jarProtocol.leftDoorClose==0 && jarProtocol.rightDoorOpen==0 && jarProtocol.rightDoorClose==0){ |
| | | switch (sign){ |
| | | case 5: |
| | | if (jarWrkMastExecuteGenerate5(jarSlave,sign)){ |
| | | signExecute[jarSlave.getId()-5] = true; |
| | | break;//出硫化罐 ===》 入冷却槽 |
| | | } |
| | | } |
| | | } |
| | | } catch (Exception e){ |
| | | log.error("{}号硫化罐JarWrkMastExecute任务创建异常,异常原因={}",jarSlave.getId(),e.getMessage()); |
| | | } |
| | | } |
| | | return signExecute; |
| | | } |
| | | |
| | | /** |
| | | * JarWrkMastExecute任务创建 //完成 |