|
@ -256,80 +256,78 @@ public class LnshPalletizingManipulatorSiteDeviceDriver extends AbstractOpcDevic |
|
|
String message = null; |
|
|
String message = null; |
|
|
try { |
|
|
try { |
|
|
device_code = this.getDeviceCode(); |
|
|
device_code = this.getDeviceCode(); |
|
|
|
|
|
mode = this.itemProtocol.getMode(); |
|
|
mode = this.itemProtocol.getMode(); |
|
|
error = this.itemProtocol.getError(); |
|
|
error = this.itemProtocol.getError(); |
|
|
move = this.itemProtocol.getMove(); |
|
|
move = this.itemProtocol.getMove(); |
|
|
task = this.itemProtocol.getTask(); |
|
|
task = this.itemProtocol.getTask(); |
|
|
hasGoods = this.itemProtocol.getMove(); |
|
|
hasGoods = this.itemProtocol.getMove(); |
|
|
io_action = this.itemProtocol.getIoAction(); |
|
|
io_action = this.itemProtocol.getIoAction(); |
|
|
action = this.itemProtocol.getAction(); |
|
|
action = this.itemProtocol.getAction(); |
|
|
weight = this.itemProtocol.getWeight(); |
|
|
weight = this.itemProtocol.getWeight(); |
|
|
material = this.itemProtocol.getMaterial(); |
|
|
material = this.itemProtocol.getMaterial(); |
|
|
barcode = this.itemProtocol.getBarcode(); |
|
|
barcode = this.itemProtocol.getBarcode(); |
|
|
AlongSide = this.itemProtocol.getAlongSide(); |
|
|
AlongSide = this.itemProtocol.getAlongSide(); |
|
|
BshortSide = this.itemProtocol.getBshortSide(); |
|
|
BshortSide = this.itemProtocol.getBshortSide(); |
|
|
Htrapezoidal = this.itemProtocol.getHtrapezoidal(); |
|
|
Htrapezoidal = this.itemProtocol.getHtrapezoidal(); |
|
|
Wthickness = this.itemProtocol.getWthickness(); |
|
|
Wthickness = this.itemProtocol.getWthickness(); |
|
|
encoder_qty = this.itemProtocol.getEncoder_qty(); |
|
|
encoder_qty = this.itemProtocol.getEncoder_qty(); |
|
|
unqualified_qty = this.itemProtocol.getUnqualified_qty(); |
|
|
unqualified_qty = this.itemProtocol.getUnqualified_qty(); |
|
|
|
|
|
|
|
|
product_code = this.itemProtocol.getProduct_code(); |
|
|
product_code = this.itemProtocol.getProduct_code(); |
|
|
AlongSide = this.itemProtocol.getAlongSide(); |
|
|
AlongSide = this.itemProtocol.getAlongSide(); |
|
|
BshortSide = this.itemProtocol.getBshortSide(); |
|
|
BshortSide = this.itemProtocol.getBshortSide(); |
|
|
Htrapezoidal = this.itemProtocol.getHtrapezoidal(); |
|
|
Htrapezoidal = this.itemProtocol.getHtrapezoidal(); |
|
|
Wthickness = this.itemProtocol.getWthickness(); |
|
|
Wthickness = this.itemProtocol.getWthickness(); |
|
|
tray_qty = this.itemProtocol.getTray_qty(); |
|
|
tray_qty = this.itemProtocol.getTray_qty(); |
|
|
tray_high = this.itemProtocol.getTray_high(); |
|
|
tray_high = this.itemProtocol.getTray_high(); |
|
|
crib_category = this.itemProtocol.getCrib_category(); |
|
|
crib_category = this.itemProtocol.getCrib_category(); |
|
|
palletX1_line = this.itemProtocol.getPalletX1_line(); |
|
|
palletX1_line = this.itemProtocol.getPalletX1_line(); |
|
|
palletY1_row = this.itemProtocol.getPalletY1_row(); |
|
|
palletY1_row = this.itemProtocol.getPalletY1_row(); |
|
|
palletA1_angle = this.itemProtocol.getPalletA1_angle(); |
|
|
palletA1_angle = this.itemProtocol.getPalletA1_angle(); |
|
|
palletX2_line = this.itemProtocol.getPalletX2_line(); |
|
|
palletX2_line = this.itemProtocol.getPalletX2_line(); |
|
|
palletY2_row = this.itemProtocol.getPalletY2_row(); |
|
|
palletY2_row = this.itemProtocol.getPalletY2_row(); |
|
|
palletA2_angle = this.itemProtocol.getPalletA2_angle(); |
|
|
palletA2_angle = this.itemProtocol.getPalletA2_angle(); |
|
|
palletX3_line = this.itemProtocol.getPalletX3_line(); |
|
|
palletX3_line = this.itemProtocol.getPalletX3_line(); |
|
|
palletY3_row = this.itemProtocol.getPalletY3_row(); |
|
|
palletY3_row = this.itemProtocol.getPalletY3_row(); |
|
|
palletA3_angle = this.itemProtocol.getPalletA3_angle(); |
|
|
palletA3_angle = this.itemProtocol.getPalletA3_angle(); |
|
|
pressCribX1_line = this.itemProtocol.getPressCribX1_line(); |
|
|
pressCribX1_line = this.itemProtocol.getPressCribX1_line(); |
|
|
pressCribY1_row = this.itemProtocol.getPressCribY1_row(); |
|
|
pressCribY1_row = this.itemProtocol.getPressCribY1_row(); |
|
|
pressCribA1_angle = this.itemProtocol.getPressCribA1_angle(); |
|
|
pressCribA1_angle = this.itemProtocol.getPressCribA1_angle(); |
|
|
pressCribX2_line = this.itemProtocol.getPressCribX2_line(); |
|
|
pressCribX2_line = this.itemProtocol.getPressCribX2_line(); |
|
|
pressCribY2_row = this.itemProtocol.getPressCribY2_row(); |
|
|
pressCribY2_row = this.itemProtocol.getPressCribY2_row(); |
|
|
pressCribA2_angle = this.itemProtocol.getPressCribA2_angle(); |
|
|
pressCribA2_angle = this.itemProtocol.getPressCribA2_angle(); |
|
|
pressCribX3_line = this.itemProtocol.getPressCribX3_line(); |
|
|
pressCribX3_line = this.itemProtocol.getPressCribX3_line(); |
|
|
pressCribY3_row = this.itemProtocol.getPressCribY3_row(); |
|
|
pressCribY3_row = this.itemProtocol.getPressCribY3_row(); |
|
|
pressCribA3_angle = this.itemProtocol.getPressCribA3_angle(); |
|
|
pressCribA3_angle = this.itemProtocol.getPressCribA3_angle(); |
|
|
Zoffset = this.itemProtocol.getZoffset(); |
|
|
Zoffset = this.itemProtocol.getZoffset(); |
|
|
pallet_layerQty = this.itemProtocol.getPallet_layerQty(); |
|
|
pallet_layerQty = this.itemProtocol.getPallet_layerQty(); |
|
|
pressCrib_layerQty = this.itemProtocol.getPressCrib_layerQty(); |
|
|
pressCrib_layerQty = this.itemProtocol.getPressCrib_layerQty(); |
|
|
codeLayerX1_interval = this.itemProtocol.getCodeLayerX1_interval(); |
|
|
codeLayerX1_interval = this.itemProtocol.getCodeLayerX1_interval(); |
|
|
codeLayerY1_interval = this.itemProtocol.getCodeLayerY1_interval(); |
|
|
codeLayerY1_interval = this.itemProtocol.getCodeLayerY1_interval(); |
|
|
codeLayerX2_interval = this.itemProtocol.getCodeLayerX2_interval(); |
|
|
codeLayerX2_interval = this.itemProtocol.getCodeLayerX2_interval(); |
|
|
codeLayerY2_interval = this.itemProtocol.getCodeLayerY2_interval(); |
|
|
codeLayerY2_interval = this.itemProtocol.getCodeLayerY2_interval(); |
|
|
codeLayerX3_interval = this.itemProtocol.getCodeLayerX3_interval(); |
|
|
codeLayerX3_interval = this.itemProtocol.getCodeLayerX3_interval(); |
|
|
codeLayerY3_interval = this.itemProtocol.getcodeLayerY3_interval(); |
|
|
codeLayerY3_interval = this.itemProtocol.getcodeLayerY3_interval(); |
|
|
codeLayerX1_offset = this.itemProtocol.getCodeLayerX1_offset(); |
|
|
codeLayerX1_offset = this.itemProtocol.getCodeLayerX1_offset(); |
|
|
codeLayerY1_offset = this.itemProtocol.getCodeLayerY1_offset(); |
|
|
codeLayerY1_offset = this.itemProtocol.getCodeLayerY1_offset(); |
|
|
codeLayerX2_offset = this.itemProtocol.getCodeLayerX2_offset(); |
|
|
codeLayerX2_offset = this.itemProtocol.getCodeLayerX2_offset(); |
|
|
codeLayerY2_offset = this.itemProtocol.getCodeLayerY2_offset(); |
|
|
codeLayerY2_offset = this.itemProtocol.getCodeLayerY2_offset(); |
|
|
codeLayerX3_offset = this.itemProtocol.getCodeLayerX3_offset(); |
|
|
codeLayerX3_offset = this.itemProtocol.getCodeLayerX3_offset(); |
|
|
codeLayerY3_offset = this.itemProtocol.getCodeLayerY3_offset(); |
|
|
codeLayerY3_offset = this.itemProtocol.getCodeLayerY3_offset(); |
|
|
pressLayerX1_interval = this.itemProtocol.getPressLayerX1_interval(); |
|
|
pressLayerX1_interval = this.itemProtocol.getPressLayerX1_interval(); |
|
|
pressLayerY1_interval = this.itemProtocol.getPressLayerY1_interval(); |
|
|
pressLayerY1_interval = this.itemProtocol.getPressLayerY1_interval(); |
|
|
pressLayerX2_interval = this.itemProtocol.getPressLayerX2_interval(); |
|
|
pressLayerX2_interval = this.itemProtocol.getPressLayerX2_interval(); |
|
|
pressLayerY2_interval = this.itemProtocol.getPressLayerY2_interval(); |
|
|
pressLayerY2_interval = this.itemProtocol.getPressLayerY2_interval(); |
|
|
pressLayerX3_interval = this.itemProtocol.getPressLayerX3_interval(); |
|
|
pressLayerX3_interval = this.itemProtocol.getPressLayerX3_interval(); |
|
|
pressLayerY3_interval = this.itemProtocol.getPressLayerY3_interval(); |
|
|
pressLayerY3_interval = this.itemProtocol.getPressLayerY3_interval(); |
|
|
pressLayerX1_offset = this.itemProtocol.getPressLayerX1_offset(); |
|
|
pressLayerX1_offset = this.itemProtocol.getPressLayerX1_offset(); |
|
|
pressLayerY1_offset = this.itemProtocol.getPressLayerY1_offset(); |
|
|
pressLayerY1_offset = this.itemProtocol.getPressLayerY1_offset(); |
|
|
pressLayerX2_offset = this.itemProtocol.getPressLayerX2_offset(); |
|
|
pressLayerX2_offset = this.itemProtocol.getPressLayerX2_offset(); |
|
|
pressLayerY2_offset = this.itemProtocol.getPressLayerY2_offset(); |
|
|
pressLayerY2_offset = this.itemProtocol.getPressLayerY2_offset(); |
|
|
pressLayerX3_offset = this.itemProtocol.getPressLayerX3_offset(); |
|
|
pressLayerX3_offset = this.itemProtocol.getPressLayerX3_offset(); |
|
|
pressLayerY3_offset = this.itemProtocol.getPressLayerY3_offset(); |
|
|
pressLayerY3_offset = this.itemProtocol.getPressLayerY3_offset(); |
|
|
tool_coordinate = this.itemProtocol.getTool_coordinate(); |
|
|
tool_coordinate = this.itemProtocol.getTool_coordinate(); |
|
|
tool_coordinate = this.itemProtocol.getTool_coordinate(); |
|
|
tool_coordinate = this.itemProtocol.getTool_coordinate(); |
|
|
|
|
|
|
|
|
|
|
|
if (mode != last_mode) { |
|
|
if (mode != last_mode) { |
|
|
this.setRequireSucess(false); |
|
|
this.setRequireSucess(false); |
|
|
logServer.deviceItemValue(this.device_code, "mode", String.valueOf(mode)); |
|
|
logServer.deviceItemValue(this.device_code, "mode", String.valueOf(mode)); |
|
@ -830,7 +828,6 @@ public class LnshPalletizingManipulatorSiteDeviceDriver extends AbstractOpcDevic |
|
|
public synchronized boolean apply_take_full_vehicle() { |
|
|
public synchronized boolean apply_take_full_vehicle() { |
|
|
if(move > 0) { |
|
|
if(move > 0) { |
|
|
ApplyTaskRequest request = new ApplyTaskRequest(); |
|
|
ApplyTaskRequest request = new ApplyTaskRequest(); |
|
|
ApplyDeviceDto applyDeviceDto=new ApplyDeviceDto(); |
|
|
|
|
|
request.setDevice_code(this.getDevice_code()); |
|
|
request.setDevice_code(this.getDevice_code()); |
|
|
request.setRequest_medthod_code(Thread.currentThread().getStackTrace()[1].getMethodName()); |
|
|
request.setRequest_medthod_code(Thread.currentThread().getStackTrace()[1].getMethodName()); |
|
|
request.setRequest_medthod_name(RequestMethodEnum.getName(Thread.currentThread().getStackTrace()[1].getMethodName())); |
|
|
request.setRequest_medthod_name(RequestMethodEnum.getName(Thread.currentThread().getStackTrace()[1].getMethodName())); |
|
@ -850,14 +847,17 @@ public class LnshPalletizingManipulatorSiteDeviceDriver extends AbstractOpcDevic |
|
|
List<String> getDeviceCodeList = this.getExtraDeviceCodes("link_device_code"); |
|
|
List<String> getDeviceCodeList = this.getExtraDeviceCodes("link_device_code"); |
|
|
LnshPalletizingManipulatorSiteDeviceDriver lnshPalletizingManipulatorSiteDeviceDriver; |
|
|
LnshPalletizingManipulatorSiteDeviceDriver lnshPalletizingManipulatorSiteDeviceDriver; |
|
|
for (int i = 0; i < getDeviceCodeList.size(); i++) { |
|
|
for (int i = 0; i < getDeviceCodeList.size(); i++) { |
|
|
if(device.getDeviceDriver() instanceof LnshPalletizingManipulatorSiteDeviceDriver){ |
|
|
ApplyDeviceDto applyDeviceDto=new ApplyDeviceDto(); |
|
|
lnshPalletizingManipulatorSiteDeviceDriver=(LnshPalletizingManipulatorSiteDeviceDriver) getDevice().getDeviceDriver(); |
|
|
Device getDevice = deviceAppService.findDeviceByCode(getDeviceCodeList.get(i).toString()); |
|
|
|
|
|
if(getDevice.getDeviceDriver() instanceof LnshPalletizingManipulatorSiteDeviceDriver){ |
|
|
|
|
|
lnshPalletizingManipulatorSiteDeviceDriver=(LnshPalletizingManipulatorSiteDeviceDriver) getDevice.getDeviceDriver(); |
|
|
applyDeviceDto.setQty(String.valueOf(lnshPalletizingManipulatorSiteDeviceDriver.getEncoder_qty())); |
|
|
applyDeviceDto.setQty(String.valueOf(lnshPalletizingManipulatorSiteDeviceDriver.getEncoder_qty())); |
|
|
applyDeviceDto.setDevice_code(String.valueOf(lnshPalletizingManipulatorSiteDeviceDriver.getBarcode())); |
|
|
applyDeviceDto.setDevice_code(String.valueOf(lnshPalletizingManipulatorSiteDeviceDriver.getDevice_code())); |
|
|
|
|
|
applyDeviceDto.setVehicle_code(String.valueOf(lnshPalletizingManipulatorSiteDeviceDriver.getBarcode())); |
|
|
} |
|
|
} |
|
|
|
|
|
listDto.add(applyDeviceDto); |
|
|
|
|
|
request.setList(listDto); |
|
|
} |
|
|
} |
|
|
listDto.add(applyDeviceDto); |
|
|
|
|
|
request.setList(listDto); |
|
|
|
|
|
} |
|
|
} |
|
|
ApplyTaskResponse resp = JSON.toJavaObject(JSONObject.parseObject(acsToWmsService.applyTask(request)),ApplyTaskResponse.class); |
|
|
ApplyTaskResponse resp = JSON.toJavaObject(JSONObject.parseObject(acsToWmsService.applyTask(request)),ApplyTaskResponse.class); |
|
|
message = RequestMethodEnum.getName("apply_take_full_vehicle") + "apply_take_full_vehicle 接口请求LMS..."; |
|
|
message = RequestMethodEnum.getName("apply_take_full_vehicle") + "apply_take_full_vehicle 接口请求LMS..."; |
|
|