diff --git a/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/maGang/MaGangConveyorDeviceDriver.java b/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/maGang/MaGangConveyorDeviceDriver.java index 4008f8a..2199740 100644 --- a/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/maGang/MaGangConveyorDeviceDriver.java +++ b/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/maGang/MaGangConveyorDeviceDriver.java @@ -294,7 +294,7 @@ public class MaGangConveyorDeviceDriver extends AbstractOpcDeviceDriver implemen String opcservcerid = this.getDevice().getOpc_server_id(); Server server = ReadUtil.getServer(opcservcerid); Map itemMap = new HashMap(); - itemMap.put(param, value); + itemMap.put(param, Integer.parseInt(value)); ReadUtil.write(itemMap, server); log.info("设备号{},kep点位名称{},下发信号{}", this.getDevice().getDevice_code(), param, value); } diff --git a/acs/nladmin-system/src/main/java/org/nl/modules/quartz/task/QueryXZAgvDeviceStatus.java b/acs/nladmin-system/src/main/java/org/nl/modules/quartz/task/QueryXZAgvDeviceStatus.java index 5a01e58..8f79835 100644 --- a/acs/nladmin-system/src/main/java/org/nl/modules/quartz/task/QueryXZAgvDeviceStatus.java +++ b/acs/nladmin-system/src/main/java/org/nl/modules/quartz/task/QueryXZAgvDeviceStatus.java @@ -102,10 +102,10 @@ public class QueryXZAgvDeviceStatus { String kepStatus = String.valueOf(maGangAgvDeviceDriver.getStatus()); String kepType = String.valueOf(maGangAgvDeviceDriver.getType()); if (!StrUtil.equals(kepStatus, status)) { - maGangAgvDeviceDriver.writing("status", status); + maGangAgvDeviceDriver.writing("status", Integer.parseInt(status)); } if (!StrUtil.equals(kepType, task_type)) { - maGangAgvDeviceDriver.writing("type", task_type); + maGangAgvDeviceDriver.writing("type", Integer.parseInt(task_type)); } maGangAgvDeviceDriver.writing("x_coordinate", hisFormat.format(x)); maGangAgvDeviceDriver.writing("y_coordinate", hisFormat.format(y)); @@ -135,7 +135,7 @@ public class QueryXZAgvDeviceStatus { MaGangLedDeviceDriver maGangLedDeviceDriver; if (device.getDeviceDriver() instanceof MaGangLedDeviceDriver) { maGangLedDeviceDriver = (MaGangLedDeviceDriver) device.getDeviceDriver(); - maGangLedDeviceDriver.writing("D01", "1"); + maGangLedDeviceDriver.writing("D01", 1); } } else { String name = jsonObject.getString("name"); @@ -146,7 +146,7 @@ public class QueryXZAgvDeviceStatus { MaGangLedDeviceDriver maGangLedDeviceDriver; if (device.getDeviceDriver() instanceof MaGangLedDeviceDriver) { maGangLedDeviceDriver = (MaGangLedDeviceDriver) device.getDeviceDriver(); - maGangLedDeviceDriver.writing("D01", "0"); + maGangLedDeviceDriver.writing("D01", 0); } } }