From 37cd0c16e2c1b698498982bb958280c19a890a17 Mon Sep 17 00:00:00 2001
From: Junjie <fallin.jie@qq.com>
Date: 星期三, 19 七月 2023 08:54:55 +0800
Subject: [PATCH] command write

---
 src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java |   22 ++++++++++++++--------
 1 files changed, 14 insertions(+), 8 deletions(-)

diff --git a/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java b/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java
index 925db77..95b3269 100644
--- a/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java
+++ b/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java
@@ -797,7 +797,7 @@
                                     Short endStartCode = Short.parseShort(basDevp.getQrCodeValue());//绔欑偣浜岀淮鐮�
 
                                     //澧炲姞绉诲姩杩涙彁鍗囨満鍛戒护
-                                    ShuttleCommand moveCommand = shuttleThread.getMoveCommand(endStartCode, liftProtocol.getBarcode(), 1400, ShuttleRunDirection.TOP.id, null, null, 500);
+                                    ShuttleCommand moveCommand = shuttleThread.getMoveCommand(endStartCode, liftProtocol.getBarcode(), 1600, ShuttleRunDirection.TOP.id, null, null, 500);
                                     commands.add(moveCommand);
 
                                     //鍒嗛厤鐩爣搴撲綅
@@ -822,7 +822,7 @@
                                 Short distCode = Short.parseShort(basDevp.getQrCodeValue());//鎻愬崌鏈哄彛绔欑偣浜岀淮鐮�
                                 Short runDirection = ShuttleRunDirection.BOTTOM.id;//杩愯鏂瑰悜
                                 //鑾峰彇鍛戒护
-                                ShuttleCommand moveCommand = shuttleThread.getMoveCommand(startCode, distCode, 1400, runDirection, null, null, 500);
+                                ShuttleCommand moveCommand = shuttleThread.getMoveCommand(startCode, distCode, 1600, runDirection, null, null, 500);
                                 commands.add(0, moveCommand);//灏嗚鎸囦护娣诲姞鍒伴槦澶�
 
                                 assignCommand.setCommands(commands);
@@ -849,7 +849,7 @@
 //                                    Short distCode = Short.parseShort(basDevp.getQrCodeValue());//鎻愬崌鏈哄彛绔欑偣浜岀淮鐮�
 //                                    Short runDirection = ShuttleRunDirection.BOTTOM.id;//杩愯鏂瑰悜
 //                                    //鑾峰彇鍛戒护
-//                                    ShuttleCommand moveCommand = shuttleThread.getMoveCommand(startCode, distCode, 1400, runDirection, startCode, 1400, 500);
+//                                    ShuttleCommand moveCommand = shuttleThread.getMoveCommand(startCode, distCode, 1600, runDirection, startCode, 1600, 500);
 //                                    commands.add(0, moveCommand);//灏嗚鎸囦护娣诲姞鍒伴槦澶�
 //                                }
 //                                assignCommand.setCommands(commands);
@@ -872,7 +872,7 @@
 //                                Short endStartCode = Short.parseShort(basDevp.getQrCodeValue());//绔欑偣浜岀淮鐮�
 //
 //                                //澧炲姞绉诲姩杩涙彁鍗囨満鍛戒护
-//                                ShuttleCommand moveCommand = shuttleThread.getMoveCommand(endStartCode, liftProtocol.getBarcode(), 1400, ShuttleRunDirection.TOP.id, endStartCode, 1400, 500);
+//                                ShuttleCommand moveCommand = shuttleThread.getMoveCommand(endStartCode, liftProtocol.getBarcode(), 1600, ShuttleRunDirection.TOP.id, endStartCode, 1600, 500);
 //                                commands.add(moveCommand);
 //
 //                                //鍒嗛厤鐩爣搴撲綅
@@ -1262,7 +1262,7 @@
                             Short endStartCode = Short.parseShort(basDevp.getQrCodeValue());//绔欑偣浜岀淮鐮�
 
                             //澧炲姞绉诲姩杩涙彁鍗囨満鍛戒护
-                            ShuttleCommand moveCommand = shuttleThread.getMoveCommand(endStartCode, liftProtocol.getBarcode(), 1400, ShuttleRunDirection.TOP.id, null, null, 500);
+                            ShuttleCommand moveCommand = shuttleThread.getMoveCommand(endStartCode, liftProtocol.getBarcode(), 1600, ShuttleRunDirection.TOP.id, null, null, 500);
                             commands.add(moveCommand);
 
                             //鐩爣搴撲綅
@@ -1303,7 +1303,7 @@
                         short startCode = liftProtocol.getBarcode();//鎻愬崌鏈哄唴閮ㄤ簩缁寸爜
                         Short distCode = commands.get(0).getStartCodeNum();//鐩爣浜岀淮鐮�
                         //鑾峰彇绉诲姩鍛戒护
-                        ShuttleCommand moveCommand = shuttleThread.getMoveCommand(startCode, distCode, 1400, commands.get(0).getRunDirection(), null, null, 500);
+                        ShuttleCommand moveCommand = shuttleThread.getMoveCommand(startCode, distCode, 1600, commands.get(0).getRunDirection(), null, null, 500);
                         commands.add(0, moveCommand);//灏嗚鎸囦护娣诲姞鍒伴槦澶�
 
                         //鍒嗛厤鐩爣搴撲綅
@@ -1817,6 +1817,12 @@
 
                     //鍒ゆ柇鎻愬崌鏈烘槸鍚﹀埌浣�
                     StaProtocol staProtocol = devpThread.getStation().get(Utils.levToOutInStaNo(wrkMastLocNoLey >= 2 ? wrkMastLocNoLey + 1 : wrkMastLocNoLey));//璧峰绔欑偣
+                    //鍒ゆ柇杈撻�佺珯鐐规槸鍚︽湁鐗╋紝鍙湁鏃犵墿鎯呭喌鎵嶈兘缁х画璋冨害鎻愬崌鏈�
+                    if (staProtocol.isLoading()) {
+                        //鏈夌墿绂佹璋冨害
+                        continue;
+                    }
+
                     if (liftLev != wrkMastLocNoLey && !staProtocol.isLiftArrival()) {
                         //鎻愬崌鏈轰笉鍦ㄥ伐浣滄。婧愬簱浣嶆ゼ灞傦紝璋冨害鎻愬崌鏈�
                         LiftCommand command1 = liftThread.getLiftUpDownCommand(liftProtocol.getLiftNo(), liftProtocol.getTaskNo(), wrkMastLocNoLey);
@@ -2825,7 +2831,7 @@
                     Short basDevpQrCode = Short.parseShort(basDevp.getQrCodeValue());//绔欑偣浜岀淮鐮�
 
                     //澧炲姞绉诲姩杩涙彁鍗囨満鍛戒护
-                    ShuttleCommand moveCommand = shuttleThread.getMoveCommand(basDevpQrCode, liftProtocol.getBarcode(), 1400, ShuttleRunDirection.TOP.id, basDevpQrCode, 1400, 500);
+                    ShuttleCommand moveCommand = shuttleThread.getMoveCommand(basDevpQrCode, liftProtocol.getBarcode(), 1600, ShuttleRunDirection.TOP.id, basDevpQrCode, 1600, 500);
                     commands.add(moveCommand);
 
                     //鍒嗛厤鐩爣搴撲綅
@@ -2915,7 +2921,7 @@
                 Short distCode = Short.parseShort(basDevp.getQrCodeValue());//鎻愬崌鏈哄彛绔欑偣浜岀淮鐮�
                 Short runDirection = ShuttleRunDirection.BOTTOM.id;//杩愯鏂瑰悜
                 //鑾峰彇鍛戒护
-                ShuttleCommand moveCommand = shuttleThread.getMoveCommand(startCode, distCode, 1400, runDirection, startCode, 1400, 500);
+                ShuttleCommand moveCommand = shuttleThread.getMoveCommand(startCode, distCode, 1600, runDirection, startCode, 1600, 500);
                 commands.add(0, moveCommand);//灏嗚鎸囦护娣诲姞鍒伴槦澶�
 
                 //杩涜鍏呯數涓�

--
Gitblit v1.9.1