自动化立体仓库 - WCS系统
#
luxiaotao1123
2022-12-08 e74add6a913a5fd6ea1de5fc62379e3f9b24b228
src/main/java/com/zy/core/model/protocol/SteProtocol.java
@@ -70,6 +70,12 @@
     */
    public Float charge = 0.0F;
    public void setCharge(Float charge) {
        if (charge >= 0) {
            this.charge = charge;
        }
    }
    /**
     * 满电
     */
@@ -185,6 +191,17 @@
     */
    public Short crnAllowRun;
    /**
     * 充电状态  1:在充电;0:不在充电
     */
    private Short chargeStatus;
    // 入库取空
    private Boolean inEmpty;
    // 出库取空
    private Boolean outEmpty;
    public void setStatus(Short status){
        this.status = status;
        this.statusType = SteStatusType.get(status);
@@ -246,8 +263,12 @@
    // 是否处于空闲待命状态
    public Boolean isIdle() {
        boolean res = this.statusType.equals(SteStatusType.IDLE)
                && this.mode == 1
                && this.pakMk.equals("N")
                && !isAlarm();
                && !isAlarm()
                && this.chargeStatus == 0
                && isEnable()
                ;
        if (!res) {
            return res;
        } else {
@@ -267,4 +288,11 @@
        return this.alarm > 1;
    }
    public Boolean isEnable() {
        if (Cools.isEmpty(row, bay, lev)) {
            return false;
        }
        return row > 0 && bay > 0 && lev > 0;
    }
}