fix: 添加堆垛机,下发信号日志
This commit is contained in:
@@ -184,6 +184,7 @@ public class TwoNDCSocketConnectionAutoRun extends AbstractAutoRunnable {
|
|||||||
if (ObjectUtil.isEmpty(inst)) {
|
if (ObjectUtil.isEmpty(inst)) {
|
||||||
log.info("未找到指令号{}对应的指令", ikey);
|
log.info("未找到指令号{}对应的指令", ikey);
|
||||||
} else {
|
} else {
|
||||||
|
if("1".equals(inst.getInstruction_type()) || "2".equals(inst.getInstruction_type()) || "3".equals(inst.getInstruction_type())) {
|
||||||
String agvcar = inst.getCarno();
|
String agvcar = inst.getCarno();
|
||||||
Device agvDevice = deviceAppService.findDeviceByCode(agvcar);
|
Device agvDevice = deviceAppService.findDeviceByCode(agvcar);
|
||||||
if (agvDevice != null) {
|
if (agvDevice != null) {
|
||||||
@@ -202,6 +203,7 @@ public class TwoNDCSocketConnectionAutoRun extends AbstractAutoRunnable {
|
|||||||
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0);
|
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
//请求删除任务
|
//请求删除任务
|
||||||
//(需要WCS反馈)
|
//(需要WCS反馈)
|
||||||
else if (phase == 0x30) {
|
else if (phase == 0x30) {
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ import java.util.LinkedList;
|
|||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 油漆线
|
* 纸管库
|
||||||
*/
|
*/
|
||||||
@Service
|
@Service
|
||||||
public class PaperTubeConveyor2Defination implements OpcDeviceDriverDefination {
|
public class PaperTubeConveyor2Defination implements OpcDeviceDriverDefination {
|
||||||
|
|||||||
@@ -320,7 +320,7 @@ public class BeltConveyorDeviceDriver extends AbstractOpcDeviceDriver implements
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 3:
|
case 3:
|
||||||
log.info("运行中");
|
log.info(this.device_code + ",运行中");
|
||||||
break;
|
break;
|
||||||
case 4:
|
case 4:
|
||||||
//申请出货
|
//申请出货
|
||||||
|
|||||||
@@ -125,7 +125,7 @@ public class AbstractOpcDeviceDriver extends AbstractDeviceDriver implements Opc
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (i >= 2) {
|
if (i >= 2) {
|
||||||
log.info("写入次数超过3次而失败");
|
log.info(itemValues + "写入次数超过3次而失败");
|
||||||
throw new RuntimeException("写入次数超过3次而失败");
|
throw new RuntimeException("写入次数超过3次而失败");
|
||||||
}
|
}
|
||||||
++i;
|
++i;
|
||||||
|
|||||||
@@ -410,6 +410,7 @@ public class ConveyorWithScannerWeightDeviceDriver extends AbstractOpcDeviceDriv
|
|||||||
}
|
}
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
this.iserror = true;
|
this.iserror = true;
|
||||||
|
log.error("空指针:{}", e);
|
||||||
String extracted = DeviceErrorUtil.extracted(e);
|
String extracted = DeviceErrorUtil.extracted(e);
|
||||||
LuceneLogDto logDto = LuceneLogDto.builder()
|
LuceneLogDto logDto = LuceneLogDto.builder()
|
||||||
.device_code(device_code)
|
.device_code(device_code)
|
||||||
|
|||||||
@@ -229,6 +229,7 @@ public class ReturnGoodManipulatorDeviceDriver extends AbstractOpcDeviceDriver i
|
|||||||
|
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
this.iserror = true;
|
this.iserror = true;
|
||||||
|
log.error("空指针:{}",e);
|
||||||
String extracted = DeviceErrorUtil.extracted(e);
|
String extracted = DeviceErrorUtil.extracted(e);
|
||||||
LuceneLogDto logDto = LuceneLogDto.builder()
|
LuceneLogDto logDto = LuceneLogDto.builder()
|
||||||
.device_code(device_code)
|
.device_code(device_code)
|
||||||
|
|||||||
@@ -1046,7 +1046,9 @@ public class StandardStackerDeviceDriver extends AbstractOpcDeviceDriver impleme
|
|||||||
"有货或未联机,无法下发指令!指令号:" + inst.getInstruction_code();
|
"有货或未联机,无法下发指令!指令号:" + inst.getInstruction_code();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
log.info(next_device_code + "设备mode:" + beltConveyorDeviceDriver.getMode() + ",move:" + beltConveyorDeviceDriver.getMove());
|
||||||
}
|
}
|
||||||
|
|
||||||
List list = new ArrayList();
|
List list = new ArrayList();
|
||||||
pakageCommand(list, inst.getInstruction_code());
|
pakageCommand(list, inst.getInstruction_code());
|
||||||
packagePlcCoordinate(startDevice, list, "1");
|
packagePlcCoordinate(startDevice, list, "1");
|
||||||
|
|||||||
Reference in New Issue
Block a user