From 1f290b785adec6e9409adf2c9241bdd01eacf0ee Mon Sep 17 00:00:00 2001 From: Junjie <fallin.jie@qq.com> Date: 星期二, 25 七月 2023 09:02:58 +0800 Subject: [PATCH] 捡料 --- src/main/java/com/zy/core/model/protocol/LiftProtocol.java | 47 ++++++++++++++++++++++++++++++++++++++++++++++- 1 files changed, 46 insertions(+), 1 deletions(-) diff --git a/src/main/java/com/zy/core/model/protocol/LiftProtocol.java b/src/main/java/com/zy/core/model/protocol/LiftProtocol.java index fd78a3c..a080395 100644 --- a/src/main/java/com/zy/core/model/protocol/LiftProtocol.java +++ b/src/main/java/com/zy/core/model/protocol/LiftProtocol.java @@ -22,7 +22,7 @@ /** * 鎻愬崌鏈哄唴閮ㄤ簩缁寸爜 */ - private Short barcode = 1699; + private Short barcode = 1661; /** * 浠诲姟鍙� @@ -246,6 +246,29 @@ } // 鏄惁澶勪簬绌洪棽寰呭懡鐘舵�� + public Boolean isIdle(Short taskNo) { + if(this.taskNo == null + || this.liftLock == null + || this.ready == null + || this.running == null + || this.mode == null + || this.pakMk == null + ){ + return false; + } + + boolean res = (this.taskNo == 0 || this.taskNo.intValue() == taskNo.intValue()) + && !this.liftLock +// && this.ready + && !this.running + && this.mode + && this.pakMk.equals(true) + && !this.securityMk + ; + return res; + } + + // 鏄惁澶勪簬绌洪棽寰呭懡鐘舵�� public Boolean isIdle() { if(this.taskNo == null || this.liftLock == null @@ -268,6 +291,28 @@ 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) { Short lev = null; switch (position) { -- Gitblit v1.9.1