Browse Source

add 反馈agv状态接口

master
汪菘 2 years ago
parent
commit
134f3719c8
  1. 10
      acs/nladmin-system/src/main/java/org/nl/acs/device_driver/basedriver/agv/ndcone/AgvNdcOneDeviceDriver.java
  2. 10
      acs/nladmin-system/src/main/java/org/nl/modules/quartz/task/ToAgvDevice.java

10
acs/nladmin-system/src/main/java/org/nl/acs/device_driver/basedriver/agv/ndcone/AgvNdcOneDeviceDriver.java

@ -455,19 +455,19 @@ public class AgvNdcOneDeviceDriver extends AbstractDeviceDriver implements Devic
} else if (phase == 0x67) {//agv异常
error = ikey;
data = NDCAgvService.sendAgvOneModeInst(phase, index, 0);
} else if (phase == 0x71) {
} else if (phase == 0x70) {
//x坐标
x = ikey;
} else if (phase == 0x72) {
} else if (phase == 0x71) {
//y坐标
y = ikey;
} else if (phase == 0x73) {
} else if (phase == 0x72) {
//车辆角度
angle = ikey;
} else if (phase == 0x74) {
} else if (phase == 0x73) {
//agv电量
electric_qty = ikey;
} else if (phase == 0x75) {
} else if (phase == 0x74) {
//三色灯状态
status = ikey;
}

10
acs/nladmin-system/src/main/java/org/nl/modules/quartz/task/ToAgvDevice.java

@ -52,17 +52,17 @@ public class ToAgvDevice {
request.put("REQCODE", IdUtil.simpleUUID());
request.put("TASKCODE", IdUtil.simpleUUID());
//电量
request.put("AGVBATTERY", "80");
request.put("AGVBATTERY", agvNdcOneDeviceDriver.getElectric_qty());
//X
request.put("POSX", "60");
request.put("POSX", agvNdcOneDeviceDriver.getX());
//Y
request.put("POSY", "80");
request.put("POSY", agvNdcOneDeviceDriver.getY());
//ip
request.put("AGVIP", "127.0.0.1");
request.put("AGVIP", ObjectUtil.isEmpty(agvNdcOneDeviceDriver.getDevice().getExtraValue()) ? "" : agvNdcOneDeviceDriver.getDevice().getExtraValue().get("ip_address"));
//车号
request.put("AGVCODE", device.getDevice_code());
//角度
request.put("AGVDIR", "90");
request.put("AGVDIR", agvNdcOneDeviceDriver.getAngle());
request.put("REQTIME", DateUtil.now());
log.info("atrQueryAgvStatus 请求参数:"+request.toJSONString());
String str = new RTMSAGVSERVICE().getBasicHttpBindingIRTMSAGVSERVICE().atrQueryAgvStatus(request.toJSONString());

Loading…
Cancel
Save