控制台四向穿梭车增加库位号和层高,提升机参数输出设置
| | |
| | | vo.setCurrentLiftServoLoad(shuttleProtocol.getCurrentLiftServoLoad() == null ? "" : shuttleProtocol.getCurrentLiftServoLoad() + "%");//当前的升降伺服负载率 |
| | | vo.setCurrentLiftServoSpeed(shuttleProtocol.getCurrentLiftServoSpeed());//当前的升降伺服速度 |
| | | vo.setPakMk(shuttleProtocol.getPakMk()?"Y" : "N"); // 作业标记 |
| | | vo.setLocNo(shuttleProtocol.getLocNo());//四向穿梭车当前库位号 |
| | | vo.setLev(Utils.getLev(shuttleProtocol.getLocNo()));//四向穿梭车当前层高 |
| | | } |
| | | return R.ok().add(list); |
| | | } |
| | |
| | | package com.zy.asrs.domain.vo; |
| | | |
| | | import com.zy.core.enums.LiftNotReadyType; |
| | | import com.zy.core.enums.LiftProtocolStatusType; |
| | | import lombok.Data; |
| | | |
| | |
| | | return this.ready ? "Y" : "N"; |
| | | } |
| | | |
| | | public String getNotReady$() { |
| | | return LiftNotReadyType.get((int) this.notReady).desc; |
| | | } |
| | | |
| | | public String getRunning$() { |
| | | return this.running ? "Y" : "N"; |
| | | } |
| | |
| | | */ |
| | | private String currentMoveServoLoad; |
| | | |
| | | /** |
| | | * 四向穿梭车库位号 |
| | | */ |
| | | private String locNo; |
| | | |
| | | /** |
| | | * 四向穿梭车当前所在楼层 |
| | | */ |
| | | private Integer lev; |
| | | |
| | | } |
| | |
| | | BasDevp selectByWrkNo(Integer wrkNo); |
| | | |
| | | BasDevp queryByLocNo(String locNo); |
| | | |
| | | BasDevp queryByQrCode(String qrCodeValue); |
| | | } |
| | |
| | | |
| | | BasDevp queryByLocNo(String locNo); |
| | | |
| | | BasDevp queryByQrCode(String qrCodeValue); |
| | | |
| | | } |
| | |
| | | public BasDevp queryByLocNo(String locNo) { |
| | | return this.baseMapper.queryByLocNo(locNo); |
| | | } |
| | | |
| | | @Override |
| | | public BasDevp queryByQrCode(String qrCodeValue) { |
| | | return this.baseMapper.queryByQrCode(qrCodeValue); |
| | | } |
| | | } |
New file |
| | |
| | | package com.zy.core.enums; |
| | | |
| | | public enum LiftNotReadyType { |
| | | STATUS_0(0, "N"), |
| | | NOT_LEV(1, "不在指定层"), |
| | | NOT_SYNC(2, "四轴不同步"), |
| | | STATUS_3(3, "平台前限光电被挡到(靠近货架)"), |
| | | STATUS_4(4, "平台后限光电被挡到(远离货架)"), |
| | | STATUS_5(5, "平台上限位报警"), |
| | | STATUS_6(6, "平台下限位报警"), |
| | | STATUS_7(7, "电柜急停报警"), |
| | | STATUS_8(8, "输送线前限位被挡到(靠近货架)"), |
| | | STATUS_9(9, "输送线后限位被挡到(远离货架)"), |
| | | STATUS_10(10, "触摸屏紧急停止被按下"), |
| | | STATUS_11(11, "四轴动力线断线"), |
| | | STATUS_12(12, "单机模式"), |
| | | STATUS_13(13, "四轴报警"), |
| | | STATUS_14(14, "位置偏差过大"), |
| | | STATUS_15(15, "扭矩偏差过大"), |
| | | STATUS_16(16, "输送线过载"), |
| | | STATUS_17(17, "进提升机卡托盘"), |
| | | STATUS_18(18, "出提升机卡托盘"), |
| | | ; |
| | | |
| | | public Integer id; |
| | | public String desc; |
| | | |
| | | LiftNotReadyType(Integer id, String desc) { |
| | | this.id = id; |
| | | this.desc = desc; |
| | | } |
| | | |
| | | public static LiftNotReadyType get(Integer id) { |
| | | if (null == id) { |
| | | return null; |
| | | } |
| | | for (LiftNotReadyType type : LiftNotReadyType.values()) { |
| | | if (type.id.equals(id.intValue())) { |
| | | return type; |
| | | } |
| | | } |
| | | return null; |
| | | } |
| | | |
| | | public static LiftNotReadyType get(LiftNotReadyType type) { |
| | | if (null == type) { |
| | | return null; |
| | | } |
| | | for (LiftNotReadyType type2 : LiftNotReadyType.values()) { |
| | | if (type2 == type) { |
| | | return type2; |
| | | } |
| | | } |
| | | return null; |
| | | } |
| | | } |
| | |
| | | package com.zy.core.model.protocol; |
| | | |
| | | import com.core.common.SpringUtils; |
| | | import com.zy.asrs.entity.BasDevp; |
| | | import com.zy.asrs.entity.BasShuttleErr; |
| | | import com.zy.asrs.entity.LocMast; |
| | | import com.zy.asrs.service.BasDevpService; |
| | | import com.zy.asrs.service.BasShuttleErrService; |
| | | import com.zy.asrs.service.BasShuttleService; |
| | | import com.zy.asrs.service.LocMastService; |
| | |
| | | * 当前小车状态(内部自我维护) |
| | | */ |
| | | private Integer protocolStatus; |
| | | |
| | | // /** |
| | | // * 小车当前是否有货 |
| | | // * true:有货,false:无货 |
| | | // */ |
| | | // private Boolean loading = false; |
| | | |
| | | /** |
| | | * 当前小车状态枚举 |
| | |
| | | return basShuttleErr.getErrName(); |
| | | } |
| | | |
| | | public void setCurrentCode(Short currentCode) { |
| | | this.currentCode = currentCode; |
| | | LocMastService locMastService = SpringUtils.getBean(LocMastService.class); |
| | | if (locMastService != null) { |
| | | LocMast locMast = locMastService.queryByQrCode(currentCode.toString()); |
| | | if (locMast == null) { |
| | | //查不到库位号,查询是否为站点 |
| | | BasDevpService basDevpService = SpringUtils.getBean(BasDevpService.class); |
| | | if (basDevpService != null) { |
| | | BasDevp basDevp = basDevpService.queryByLocNo(currentCode.toString()); |
| | | if (basDevp != null) { |
| | | this.locNo = basDevp.getLocNo(); |
| | | } |
| | | } |
| | | }else{ |
| | | this.locNo = locMast.getLocNo(); |
| | | } |
| | | } |
| | | } |
| | | |
| | | } |
| | |
| | | where 1=1 |
| | | and loc_no = #{locNo} |
| | | </select> |
| | | |
| | | <select id="queryByQrCode" resultMap="BaseResultMap"> |
| | | select top 1 * |
| | | from asr_bas_devp |
| | | where 1=1 |
| | | and qr_code_value = #{qrCodeValue} |
| | | </select> |
| | | </mapper> |
| | |
| | | <div style="padding: 10px;height: 100%"> |
| | | <!-- 日志监控板 --> |
| | | <div class="log-board"> |
| | | <div class="command-log" id="commandLogId"> |
| | | <div class="command-log" id="commandLogId" style="width: 10%;"> |
| | | </div> |
| | | <div class="lift-state"> |
| | | <div class="lift-state" style="width: 90%;"> |
| | | <table id="lift-state-table"> |
| | | <thead> |
| | | <tr> |
| | |
| | | setVal(tr.children("td").eq(1), table[i-1].taskNo); |
| | | setVal(tr.children("td").eq(2), table[i-1].protocolStatus); |
| | | setVal(tr.children("td").eq(3), table[i-1].liftLock$); |
| | | setVal(tr.children("td").eq(4), table[i-1].positionArrivalFeedback$); |
| | | setVal(tr.children("td").eq(4), table[i-1].positionArrivalFeedback); |
| | | setVal(tr.children("td").eq(5), table[i-1].ready$); |
| | | setVal(tr.children("td").eq(6), table[i-1].running$); |
| | | setVal(tr.children("td").eq(7), table[i-1].mode$); |
| | |
| | | <th>升降伺服负载</th> |
| | | <th>行走伺服负载</th> |
| | | <th>作业标记</th> |
| | | <th>库位号</th> |
| | | <th>当前楼层</th> |
| | | </tr> |
| | | </thead> |
| | | <tbody> |
| | |
| | | setVal(tr.children("td").eq(7), table[i-1].currentLiftServoLoad); |
| | | setVal(tr.children("td").eq(8), table[i-1].currentMoveServoLoad); |
| | | setVal(tr.children("td").eq(9), table[i-1].pakMk); |
| | | setVal(tr.children("td").eq(10), table[i-1].locNo); |
| | | setVal(tr.children("td").eq(11), table[i-1].lev); |
| | | } |
| | | } else if (res.code === 403){ |
| | | window.location.href = baseUrl+"/login"; |