| | |
| | | basShuttle.setShuttleNo(slave.getId()); |
| | | shuttleService.insert(basShuttle); |
| | | } |
| | | //工作模式 |
| | | basShuttle.setWorkingMode(shuttleProtocol.getWorkingMode()); |
| | | //运行状态 |
| | | basShuttle.setFree(shuttleProtocol.getFree()); |
| | | //当前速度 |
| | | basShuttle.setSpeed(shuttleProtocol.getSpeed()); |
| | | //负载状态 |
| | | basShuttle.setLoadState(shuttleProtocol.getLoadState()); |
| | | //管制状态 |
| | | basShuttle.setSuspendState(shuttleProtocol.getSuspendState()); |
| | | //顶升位置 |
| | | basShuttle.setLiftPosition(shuttleProtocol.getLiftPosition()); |
| | | //运行方向 |
| | | basShuttle.setRunDir(shuttleProtocol.getRunDir()); |
| | | //运行方向 |
| | | basShuttle.setRunDir2(shuttleProtocol.getRunDir2()); |
| | | //充电状态 |
| | | basShuttle.setChargState(shuttleProtocol.getChargState()); |
| | | //电池电量 |
| | | basShuttle.setPowerPercent(shuttleProtocol.getPowerPercent()); |
| | | //最高电芯电压 |
| | | basShuttle.setMaxCellVoltage(shuttleProtocol.getMaxCellVoltage()); |
| | | //电池电压 |
| | | basShuttle.setVoltage(shuttleProtocol.getVoltage()); |
| | | //充放电循环次数 |
| | | basShuttle.setChargeCycleTimes(shuttleProtocol.getChargeCycleTimes()); |
| | | //剩余电量 |
| | | basShuttle.setSurplusQuantity(shuttleProtocol.getSurplusQuantity()); |
| | | //总电量 |
| | | basShuttle.setCountQuantity(shuttleProtocol.getCountQuantity()); |
| | | //实际库位 |
| | | basShuttle.setPoint(JSONObject.toJSONString(shuttleProtocol.getPoint())); |
| | | //实际坐标 |
| | | basShuttle.setCoord(JSONObject.toJSONString(shuttleProtocol.getCoord())); |
| | | //任务目的库位 |
| | | basShuttle.setTask(JSONObject.toJSONString(shuttleProtocol.getTask())); |
| | | //任务状态 |
| | | basShuttle.setTaskState(shuttleProtocol.getTaskState()); |
| | | //故障状态 |
| | | basShuttle.setErrState(shuttleProtocol.getErrState()); |
| | | //总里程数 |
| | | basShuttle.setStatusSum(JSONObject.toJSONString(shuttleProtocol.getStatusSum())); |
| | | //非自动状态时间计时 |
| | | basShuttle.setErrTime(shuttleProtocol.getErrTime()); |
| | | //任务号 |
| | | basShuttle.setWrkNo(shuttleProtocol.getTaskNo().intValue()); |
| | | //修改时间 |
| | | basShuttle.setUpdateTime(new Date()); |
| | | //作业标记 |
| | | basShuttle.setPakMk(shuttleProtocol.getPakMk()); |
| | | basShuttle.setDeviceStatus(JSON.toJSONString(basShuttle)); |
| | | if (shuttleService.updateById(basShuttle)) { |
| | | OutputQueue.SHUTTLE.offer(MessageFormat.format("【{0}】[id:{1}] <<<<< 实时数据更新成功",DateUtils.convert(new Date()), slave.getId())); |
| | | // log.info(MessageFormat.format("【{0}】[id:{1}] <<<<< 实时数据更新成功",DateUtils.convert(new Date()), slave.getId())); |