2 Komitmen b2b4ff3cd1 ... 779ee22da9

Pembuat SHA1 Pesan Tanggal
  gf 779ee22da9 1.测试git改动12_19_10_27 1 tahun lalu
  gf 50b25a3355 1.添加任务完成后回复 1 tahun lalu
4 mengubah file dengan 17 tambahan dan 19 penghapusan
  1. 2 0
      RobotData.py
  2. 1 1
      count.json
  3. 1 1
      map.json
  4. 13 17
      test.py

+ 2 - 0
RobotData.py

@@ -186,6 +186,8 @@ class Robot(MqttAsync):
     '''
 
     def Navigatting(self, begId, targetId, autoDirect, wheelbase=0, task_type="None"):
+        if wheelbase < 2.4 or wheelbase > 3.2:
+            return print("wheelbase is out of range!\n")
         print("nav")
 
         # self.ExecPathNodes(autoDirect)

+ 1 - 1
count.json

@@ -1 +1 @@
-{"load_count": 824, "single_count": 2516}
+{"load_count": 863, "single_count": 2575}

+ 1 - 1
map.json

@@ -55,7 +55,7 @@
       -0.32, 1.0, 90
     ],
     "S65": [
-      -16.665, -1.120, 89.15
+      -16.665, -0.980, 89.15
     ],
     "S145": [
       -8.57, -13.48, -89.15

+ 13 - 17
test.py

@@ -57,7 +57,7 @@ from mytool.RabbitMq_helper import async_communication as rabitmq
 
 
 # ===============================================================================
-
+# test 12_19_10_27
 
 class MainWindow(QMainWindow):
     """docstring for Mainwindow"""
@@ -132,14 +132,6 @@ class MainWindow(QMainWindow):
 
     def recv_park_request(self, msg):
         print("Recv_park_request------------------\n", msg)
-        # time.sleep(30)
-        # # self.g_rabbitmq.publish("command_ex", "user_pick_command_request_port",
-        # # tf.MessageToString(table, as_utf8=True))
-        # self.g_rabbitmq.publish("command_ex", "agv_park_command_response_port",
-        #                         msg)
-        # print("Publish_park_response------------------\n", msg)
-        # return True
-
         park_table = message.park_table()
         try:
             tf.Parse(msg, park_table)
@@ -151,13 +143,6 @@ class MainWindow(QMainWindow):
     def recv_pick_request(self, msg):
         print("Recv_pick_request------------------\n", msg)
         pick_table = message.pick_table()
-        # time.sleep(30)
-        # self.g_rabbitmq.publish("command_ex", "user_pick_command_request_port",
-        # tf.MessageToString(table, as_utf8=True))
-        # self.g_rabbitmq.publish("command_ex", "agv_pick_command_response_port",
-        #                         msg)
-        # print("Publish_pick_response------------------\n", msg)
-        # return True
 
         try:
             tf.Parse(msg, pick_table)
@@ -359,7 +344,11 @@ class MainWindow(QMainWindow):
 
         threadPool.shutdown(wait=True)
 
-        self.g_rabbitmq.publish()
+        # 反馈
+        self.g_rabbitmq.publish("command_ex", "agv_park_command_response_port",
+                                tf.MessageToString(park_table, as_utf8=True))
+        print("Publish_park_response------------------\n", park_table)
+        return True
 
     def updateMap_pick(self, export_id, type):  # 0:前车轨迹,1:后车轨迹,2:添加整车轨迹
 
@@ -466,6 +455,13 @@ class MainWindow(QMainWindow):
                           export_id, "BInput_R1100", True, wheel_base)
         threadPool.shutdown(wait=True)
 
+        # 反馈
+        self.g_rabbitmq.publish("command_ex", "agv_pick_command_response_port",
+                                tf.MessageToString(pick_table, as_utf8=True))
+        print("Publish_park_response------------------\n", pick_table)
+        return True
+
+
     def ComputeStreetNode(self, s_id, s_x, s_y, s_theta):
         """