自动化立体仓库 - WCS系统
Junjie
2023-06-26 7cd8c743cb1f377a3102d9a154669fb2bc10535c
src/main/java/com/zy/core/model/protocol/LiftProtocol.java
@@ -268,9 +268,68 @@
        return res;
    }
    // 是否处于空闲待命状态,不判断任务号
    public Boolean isIdleNoTask() {
        if(this.taskNo == null
                || this.liftLock == null
                || this.ready == null
                || this.running == null
                || this.mode == null
                || this.pakMk == null
        ){
            return false;
        }
        boolean res = !this.liftLock
//                && this.ready
                && !this.running
                && this.mode
                && this.pakMk
                && !this.securityMk
                ;
        return res;
    }
    public void setPositionArrivalFeedback(Short position) {
        this.lev = position;//层高
        Short lev = null;
        switch (position) {
            case 1:
                lev = 1;
                break;
            case 4:
                lev = 2;
                break;
            case 8:
                lev = 3;
                break;
            case 16:
                lev = 4;
                break;
        }
        this.lev = lev;//层高
        this.positionArrivalFeedback = position;//位置到达反馈
    }
    public Integer getPositionArrivalFeedback$() {
        if (this.positionArrivalFeedback == null) {
            return null;
        }
        switch (this.positionArrivalFeedback) {
            case 1:
                return 1;
            case 2:
                return 2;
            case 4:
                return 3;
            case 8:
                return 4;
            case 16:
                return 5;
        }
        return null;
    }
}