Browse Source

20221108 chutian huli

yct 2 years ago
parent
commit
c88a0cd0e8

+ 77 - 77
error_code/error_code.cpp

@@ -21,28 +21,28 @@ Error_manager::Error_manager(const Error_manager & error_manager)
 {
     this->m_error_code = error_manager.m_error_code;
     this->m_error_level = error_manager.m_error_level;
-	this->m_error_description=error_manager.m_error_description;
+    this->m_error_description=error_manager.m_error_description;
     return ;
 }
 //赋值构造
 Error_manager::Error_manager(Error_code error_code, Error_level error_level,
-    const char* p_error_description)
+                             const char* p_error_description)
 {
     m_error_code = error_code;
     m_error_level = error_level;
     if(p_error_description!= nullptr)
-	{
-		m_error_description=std::string(p_error_description);
-	}
-	return ;
+    {
+        m_error_description=std::string(p_error_description);
+    }
+    return ;
 }
 //赋值构造
-Error_manager::Error_manager(Error_code error_code, Error_level error_level , std::string & error_aggregate_string)
+Error_manager::Error_manager(Error_code error_code, Error_level error_level , std::string   error_aggregate_string)
 {
     m_error_code = error_code;
     m_error_level = error_level;
     m_error_description=error_aggregate_string;
-	return ;
+    return ;
 }
 //析构函数
 Error_manager::~Error_manager()
@@ -59,14 +59,14 @@ void Error_manager::error_manager_init(Error_code error_code, Error_level error_
 {
     m_error_code = error_code;
     m_error_level = error_level;
-	if(p_error_description!= nullptr)
-	{
-		m_error_description=std::string(p_error_description);
-	}
-	return ;
+    if(p_error_description!= nullptr)
+    {
+        m_error_description=std::string(p_error_description);
+    }
+    return ;
 }
 //初始化
-void Error_manager::error_manager_init(Error_code error_code, Error_level error_level , std::string & error_aggregate_string)
+void Error_manager::error_manager_init(Error_code error_code, Error_level error_level , std::string error_aggregate_string)
 {
     m_error_code = error_code;
     m_error_level = error_level;
@@ -78,26 +78,26 @@ void Error_manager::error_manager_reset(Error_code error_code, Error_level error
 {
     m_error_code = error_code;
     m_error_level = error_level;
-	if(p_error_description!= nullptr)
-	{
-		m_error_description=std::string(p_error_description);
-	}
-	return ;
+    if(p_error_description!= nullptr)
+    {
+        m_error_description=std::string(p_error_description);
+    }
+    return ;
 }
 //重置
-void Error_manager::error_manager_reset(Error_code error_code, Error_level error_level , std::string & error_aggregate_string)
+void Error_manager::error_manager_reset(Error_code error_code, Error_level error_level , std::string error_aggregate_string)
 {
     m_error_code = error_code;
     m_error_level = error_level;
     m_error_description=error_aggregate_string;
-	return;
+    return;
 }
 //重置
 void Error_manager::error_manager_reset(const Error_manager & error_manager)
 {
     this->m_error_code = error_manager.m_error_code;
     this->m_error_level = error_manager.m_error_level;
-	this->m_error_description=error_manager.m_error_description;
+    this->m_error_description=error_manager.m_error_description;
     return ;
 }
 //清除所有内容
@@ -105,27 +105,27 @@ void Error_manager::error_manager_clear_all()
 {
     m_error_code = SUCCESS;
     m_error_level = NORMAL;
-	m_error_description.clear();
-	return;
+    m_error_description.clear();
+    return;
 }
 
 //重载=
 Error_manager& Error_manager::operator=(const Error_manager & error_manager)
 {
     error_manager_reset(error_manager);
-	return *this;
+    return *this;
 }
 //重载=,支持Error_manager和Error_code的直接转化,会清空错误等级和描述
 Error_manager& Error_manager::operator=(Error_code error_code)
 {
     error_manager_clear_all();
     set_error_code(error_code);
-	return *this;
+    return *this;
 }
 //重载==
 bool Error_manager::operator==(const Error_manager & error_manager)
 {
-	return is_equal_error_manager(error_manager);
+    return is_equal_error_manager(error_manager);
 }
 //重载==,支持Error_manager和Error_code的直接比较
 bool Error_manager::operator==(Error_code error_code)
@@ -143,7 +143,7 @@ bool Error_manager::operator==(Error_code error_code)
 //重载!=
 bool Error_manager::operator!=(const Error_manager & error_manager)
 {
-	return (! is_equal_error_manager(error_manager));
+    return (! is_equal_error_manager(error_manager));
 }
 //重载!=,支持Error_manager和Error_code的直接比较
 bool Error_manager::operator!=(Error_code error_code)
@@ -160,8 +160,8 @@ bool Error_manager::operator!=(Error_code error_code)
 //重载<<,支持cout<<
 std::ostream & operator<<(std::ostream &out, Error_manager &error_manager)
 {
-	out << error_manager.to_string();
-	return out;
+    out << error_manager.to_string();
+    return out;
 }
 
 //获取错误码
@@ -189,14 +189,14 @@ void Error_manager::copy_error_description(const char* p_error_description)
     {
         m_error_description=std::string(p_error_description);
     }
-	return;
+    return;
 }
 //复制错误描述,(深拷贝)
 //output:error_description_string     错误描述的string
-void Error_manager::copy_error_description(std::string & error_description_string)
+void Error_manager::copy_error_description(std::string error_description_string)
 {
     m_error_description=error_description_string;
-	return;
+    return;
 }
 
 //设置错误码
@@ -232,17 +232,17 @@ void Error_manager::set_error_level_location(Error_level error_level)
 //设置错误描述
 void Error_manager::set_error_description(const char* p_error_description)
 {
-	if(p_error_description != NULL)
-	{
-		m_error_description=std::string(p_error_description);
-	}
-	return;
+    if(p_error_description != NULL)
+    {
+        m_error_description=std::string(p_error_description);
+    }
+    return;
 }
 //设置错误描述
-void Error_manager::set_error_description(std::string & error_description_string)
+void Error_manager::set_error_description(std::string error_description_string)
 {
-	m_error_description = error_description_string;
-	return ;
+    m_error_description = error_description_string;
+    return ;
 }
 
 //尾部追加错误描述
@@ -254,7 +254,7 @@ void Error_manager::add_error_description(const char* p_error_description)
     }
 }
 //尾部追加错误描述
-void Error_manager::add_error_description(std::string & error_description_string)
+void Error_manager::add_error_description(std::string error_description_string)
 {
     m_error_description+=error_description_string;
 }
@@ -283,7 +283,7 @@ void Error_manager::compare_and_cover_error(const Error_manager & error_manager)
     }
     else if (error_manager.m_error_code == SUCCESS)
     {
-		return;
+        return;
     }
     else
     {
@@ -297,64 +297,64 @@ void Error_manager::compare_and_cover_error(const Error_manager & error_manager)
         }
         else
         {
-			((Error_manager&)error_manager).translate_error_to_string(pt_string_inside);
+            ((Error_manager&)error_manager).translate_error_to_string(pt_string_inside);
             add_error_description(pt_string_inside);
         }
     }
-	return;
+    return;
 }
 //比较并覆盖错误,讲低级错误转为字符串存放于描述中,
 //如果错误相同,则保留this的,将输入参数转入描述。
 void Error_manager::compare_and_cover_error( Error_manager * p_error_manager)
 {
-	if(this->m_error_code == SUCCESS)
-	{
-		error_manager_reset(*p_error_manager);
-	}
-	else if (p_error_manager->m_error_code == SUCCESS)
-	{
-		return;
-	}
-	else
-	{
-		Error_manager t_error_manager_new;
-		std::string pt_string_inside;
-		if(this->m_error_level < p_error_manager->m_error_level)
-		{
-			translate_error_to_string(pt_string_inside);
-			error_manager_reset(*p_error_manager);
-			add_error_description(pt_string_inside);
-		}
-		else
-		{
-			p_error_manager->translate_error_to_string(pt_string_inside);
-			add_error_description(pt_string_inside);
-		}
-	}
+    if(this->m_error_code == SUCCESS)
+    {
+        error_manager_reset(*p_error_manager);
+    }
+    else if (p_error_manager->m_error_code == SUCCESS)
+    {
+        return;
+    }
+    else
+    {
+        Error_manager t_error_manager_new;
+        std::string pt_string_inside;
+        if(this->m_error_level < p_error_manager->m_error_level)
+        {
+            translate_error_to_string(pt_string_inside);
+            error_manager_reset(*p_error_manager);
+            add_error_description(pt_string_inside);
+        }
+        else
+        {
+            p_error_manager->translate_error_to_string(pt_string_inside);
+            add_error_description(pt_string_inside);
+        }
+    }
 }
 
 
 //output:error_description_string     错误汇总的string
-void Error_manager::translate_error_to_string(std::string & error_aggregate_string)
+void Error_manager::translate_error_to_string(std::string error_aggregate_string)
 {
     char t_string_array[255] = {0};
     sprintf(t_string_array, "error_code:0x%08x, error_level:%02d, error_description:",
             m_error_code , m_error_level);
 
     error_aggregate_string = t_string_array ;
-	error_aggregate_string+= m_error_description;
-	return;
+    error_aggregate_string+= m_error_description;
+    return;
 }
 //错误码转字符串的简易版,可支持cout<<
 //return     错误汇总的string
 std::string Error_manager::to_string()
 {
-	char t_string_array[255] = {0};
-	sprintf(t_string_array, "error_code:0x%08x, error_level:%02d, error_description:",
+    char t_string_array[255] = {0};
+    sprintf(t_string_array, "error_code:0x%08x, error_level:%02d, error_description:",
             m_error_code , m_error_level);
     std::string error_aggregate_string = t_string_array ;
-	error_aggregate_string+= m_error_description;
-	return error_aggregate_string;
+    error_aggregate_string+= m_error_description;
+    return error_aggregate_string;
 }
 
 
@@ -376,7 +376,7 @@ void Error_manager::reallocate_memory_and_copy_string(const char* p_error_descri
 
 //重新分配错误描述的内存,并从外部拷贝新的(深拷贝)
 //input:error_aggregate_string     错误描述的string
-void Error_manager::reallocate_memory_and_copy_string(std::string & error_aggregate_string)
+void Error_manager::reallocate_memory_and_copy_string(std::string error_aggregate_string)
 {
     return;
 }

+ 22 - 22
error_code/error_code.h

@@ -598,21 +598,21 @@ enum Error_code
 enum Error_level
 {
 //    正常,没有错误,默认值0
-    NORMAL                = 0,
+            NORMAL                = 0,
 
 
 //    轻微故障,可忽略的故障,NEGLIGIBLE_ERROR
 //    提示作用,不做任何处理,不影响代码的流程,
 //    用作一些不重要的事件,即使出错也不会影响到系统功能,
 //    例如:文件保存错误,等
-    NEGLIGIBLE_ERROR      = 1,
+            NEGLIGIBLE_ERROR      = 1,
 
 
 //    一般故障,MINOR_ERROR
 //    用作底层功能函数的错误返回,表示该功能函数执行失败,
 //    返回给应用层之后,需要做故障分析和处理,
 //    例如:雷达数据传输失败,应用层就需要进行重新扫描,或者重连,或者重置参数等。
-    MINOR_ERROR           = 2,
+            MINOR_ERROR           = 2,
 
 
 //    严重故障,MAJOR_ERROR
@@ -621,7 +621,7 @@ enum Error_level
 //    从一般故障升级为严重故障,然后进行回退流程,回退已经执行的操作,最终回到故障待机状态。
 //    需要外部清除故障,并复位至正常待机状态,才能恢复功能的使用。
 //    例如:雷达扫描任务失败,且无法自动恢复。
-    MAJOR_ERROR           = 3,
+            MAJOR_ERROR           = 3,
 
 
 //    致命故障,CRITICAL_ERROR
@@ -630,7 +630,7 @@ enum Error_level
 //    此时不允许再执行任何函数和任务指令,防止系统故障更加严重。
 //    也不需要做任何错误处理了,快速执行紧急流程。
 //    例如:内存错误,进程挂死,关键设备失控,监控设备报警,等
-    CRITICAL_ERROR        = 4,
+            CRITICAL_ERROR        = 4,
 };
 
 
@@ -645,7 +645,7 @@ public://外部接口函数
     Error_manager(Error_code error_code, Error_level error_level = NORMAL,
                   const char* p_error_description = NULL);
     //赋值构造
-    Error_manager(Error_code error_code, Error_level error_level , std::string & error_aggregate_string);
+    Error_manager(Error_code error_code, Error_level error_level , std::string error_aggregate_string);
     //析构函数
     ~Error_manager();
 
@@ -655,12 +655,12 @@ public://外部接口函数
     void error_manager_init(Error_code error_code, Error_level error_level = NORMAL,
                             const char* p_error_description = NULL);
     //初始化
-    void error_manager_init(Error_code error_code, Error_level error_level , std::string & error_aggregate_string);
+    void error_manager_init(Error_code error_code, Error_level error_level , std::string error_aggregate_string);
     //重置
     void error_manager_reset(Error_code error_code, Error_level error_level = NORMAL,
                              const char* p_error_description = NULL);
     //重置
-    void error_manager_reset(Error_code error_code, Error_level error_level , std::string & error_aggregate_string);
+    void error_manager_reset(Error_code error_code, Error_level error_level , std::string error_aggregate_string);
     //重置
     void error_manager_reset(const Error_manager & error_manager);
     //清除所有内容
@@ -678,8 +678,8 @@ public://外部接口函数
     bool operator!=(const Error_manager & error_manager);
     //重载!=,支持Error_manager和Error_code的直接比较
     bool operator!=(Error_code error_code);
-	//重载<<,支持cout<<
-	friend std::ostream & operator<<(std::ostream &out, Error_manager &error_manager);
+    //重载<<,支持cout<<
+    friend std::ostream & operator<<(std::ostream &out, Error_manager &error_manager);
 
 
     //获取错误码
@@ -695,7 +695,7 @@ public://外部接口函数
     void copy_error_description(const char* p_error_description);
     //复制错误描述,(深拷贝)
     //output:error_description_string     错误描述的string
-    void copy_error_description(std::string & error_description_string);
+    void copy_error_description(std::string error_description_string);
 
     //设置错误码
     void set_error_code(Error_code error_code);
@@ -708,25 +708,25 @@ public://外部接口函数
     //设置错误描述
     void set_error_description(const char* p_error_description);
     //设置错误描述
-    void set_error_description(std::string & error_description_string);
+    void set_error_description(std::string error_description_string);
 
     //尾部追加错误描述
     void add_error_description(const char* p_error_description);
     //尾部追加错误描述
-    void add_error_description(std::string & error_description_string);
+    void add_error_description(std::string error_description_string);
 
     //比较错误是否相同,
     // 注:只比较错误码和等级
-	bool is_equal_error_manager(const Error_manager & error_manager);
-	//比较并覆盖错误,讲低级错误转为字符串存放于描述中,
-	//如果错误相同,则保留this的,将输入参数转入描述。
-	void compare_and_cover_error(const Error_manager & error_manager);
-	//比较并覆盖错误,讲低级错误转为字符串存放于描述中,
-	//如果错误相同,则保留this的,将输入参数转入描述。
-	void compare_and_cover_error( Error_manager * p_error_manager);
+    bool is_equal_error_manager(const Error_manager & error_manager);
+    //比较并覆盖错误,讲低级错误转为字符串存放于描述中,
+    //如果错误相同,则保留this的,将输入参数转入描述。
+    void compare_and_cover_error(const Error_manager & error_manager);
+    //比较并覆盖错误,讲低级错误转为字符串存放于描述中,
+    //如果错误相同,则保留this的,将输入参数转入描述。
+    void compare_and_cover_error( Error_manager * p_error_manager);
 
     //output:error_description_string     错误汇总的string
-    void translate_error_to_string(std::string & error_aggregate_string);
+    void translate_error_to_string(std::string error_aggregate_string);
     //错误码转字符串的简易版,可支持cout<<
     //return     错误汇总的string
     std::string to_string();
@@ -750,7 +750,7 @@ public:
 
     //重新分配错误描述的内存,并从外部拷贝新的(深拷贝)
     //input:error_aggregate_string     错误描述的string
-    void reallocate_memory_and_copy_string(std::string & error_aggregate_string);
+    void reallocate_memory_and_copy_string(std::string error_aggregate_string);
 };
 
 

+ 20 - 2
main.cpp

@@ -56,6 +56,7 @@ int main(int argc,char* argv[])
 {
 	Error_manager t_error;
 	Error_manager t_result ;
+    Error_manager ec;
 
 #ifdef POINT_DEBUG
 	pcl::PointCloud<pcl::PointXYZ>::Ptr t_cloud = pcl::PointCloud<pcl::PointXYZ>::Ptr(new pcl::PointCloud<pcl::PointXYZ>);
@@ -79,6 +80,21 @@ int main(int argc,char* argv[])
 	FLAGS_max_log_size = 1024;            // Set max log file size(GB)
 	FLAGS_stop_logging_if_full_disk = true;
 
+
+//huli test
+//    ec = System_communication_mq::get_instance_references().rabbitmq_init();
+//    if(ec != SUCCESS)
+//    {
+//        LOG(ERROR) << "system communication mq init failed: " << ec.to_string();
+//        return -1;
+//    }
+//
+//    while (true)
+//    {}
+//
+//    return 0;
+
+
 	// std::cout << " huli test :::: " << " wanji_manager_init = " << 1 << std::endl;
 
 	// 定义服务的终端id
@@ -90,7 +106,7 @@ int main(int argc,char* argv[])
 	}
 	std::cout << " huli test :::: " << " t_terminal_id = " << t_terminal_id << std::endl;
 
-	Error_manager ec;
+//	Error_manager ec;
 
 	// 初始化
 	if(WJ_VELO == 0 || WJ_VELO == 2)
@@ -106,9 +122,11 @@ int main(int argc,char* argv[])
 	if(WJ_VELO == 1 || WJ_VELO == 2)
 	{
 		ec = Velodyne_manager::get_instance_references().velodyne_manager_init(t_terminal_id);
-		std::cout << "veodyne_manager = " << Velodyne_manager::get_instance_references().check_status().to_string() << std::endl;
+
 		if (ec != SUCCESS)
 		{
+            std::cout << "veodyne_manager = " << ec.to_string() << std::endl;
+            std::cout << "veodyne_manager = " << Velodyne_manager::get_instance_references().check_status().to_string() << std::endl;
 			LOG(ERROR) << "velodyne_manager init failed: " << ec.to_string();
 			return -1;
 		}

+ 47 - 704
message/measure_message.pb.cc

@@ -60,11 +60,6 @@ class Ground_status_msgDefaultTypeInternal {
   ::google::protobuf::internal::ExplicitlyConstructed<Ground_status_msg>
       _instance;
 } _Ground_status_msg_default_instance_;
-class measure_infoDefaultTypeInternal {
- public:
-  ::google::protobuf::internal::ExplicitlyConstructed<measure_info>
-      _instance;
-} _measure_info_default_instance_;
 class Cloud_coordinateDefaultTypeInternal {
  public:
   ::google::protobuf::internal::ExplicitlyConstructed<Cloud_coordinate>
@@ -191,20 +186,6 @@ static void InitDefaultsGround_status_msg() {
       &protobuf_message_5fbase_2eproto::scc_info_Error_manager.base,
       &protobuf_measure_5fmessage_2eproto::scc_info_Cloud_coordinate.base,}};
 
-static void InitDefaultsmeasure_info() {
-  GOOGLE_PROTOBUF_VERIFY_VERSION;
-
-  {
-    void* ptr = &::message::_measure_info_default_instance_;
-    new (ptr) ::message::measure_info();
-    ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
-  }
-  ::message::measure_info::InitAsDefaultInstance();
-}
-
-::google::protobuf::internal::SCCInfo<0> scc_info_measure_info =
-    {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsmeasure_info}, {}};
-
 static void InitDefaultsCloud_coordinate() {
   GOOGLE_PROTOBUF_VERIFY_VERSION;
 
@@ -275,14 +256,13 @@ void InitDefaults() {
   ::google::protobuf::internal::InitSCC(&scc_info_Ground_detect_request_msg.base);
   ::google::protobuf::internal::InitSCC(&scc_info_Ground_detect_response_msg.base);
   ::google::protobuf::internal::InitSCC(&scc_info_Ground_status_msg.base);
-  ::google::protobuf::internal::InitSCC(&scc_info_measure_info.base);
   ::google::protobuf::internal::InitSCC(&scc_info_Cloud_coordinate.base);
   ::google::protobuf::internal::InitSCC(&scc_info_Cloud_type.base);
   ::google::protobuf::internal::InitSCC(&scc_info_Locate_sift_request_msg.base);
   ::google::protobuf::internal::InitSCC(&scc_info_Locate_sift_response_msg.base);
 }
 
-::google::protobuf::Metadata file_level_metadata[11];
+::google::protobuf::Metadata file_level_metadata[10];
 const ::google::protobuf::EnumDescriptor* file_level_enum_descriptors[7];
 
 const ::google::protobuf::uint32 TableStruct::offsets[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
@@ -380,31 +360,6 @@ const ::google::protobuf::uint32 TableStruct::offsets[] GOOGLE_PROTOBUF_ATTRIBUT
   7,
   3,
   ~0u,
-  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::message::measure_info, _has_bits_),
-  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::message::measure_info, _internal_metadata_),
-  ~0u,  // no _extensions_
-  ~0u,  // no _oneof_case_
-  ~0u,  // no _weak_field_map_
-  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::message::measure_info, cx_),
-  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::message::measure_info, cy_),
-  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::message::measure_info, theta_),
-  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::message::measure_info, length_),
-  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::message::measure_info, width_),
-  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::message::measure_info, height_),
-  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::message::measure_info, wheelbase_),
-  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::message::measure_info, front_theta_),
-  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::message::measure_info, border_statu_),
-  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::message::measure_info, ground_status_),
-  0,
-  1,
-  2,
-  3,
-  4,
-  5,
-  6,
-  7,
-  8,
-  9,
   GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::message::Cloud_coordinate, _has_bits_),
   GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::message::Cloud_coordinate, _internal_metadata_),
   ~0u,  // no _extensions_
@@ -463,11 +418,10 @@ static const ::google::protobuf::internal::MigrationSchema schemas[] GOOGLE_PROT
   { 43, 51, sizeof(::message::Ground_detect_request_msg)},
   { 54, 64, sizeof(::message::Ground_detect_response_msg)},
   { 69, 84, sizeof(::message::Ground_status_msg)},
-  { 94, 109, sizeof(::message::measure_info)},
-  { 119, 127, sizeof(::message::Cloud_coordinate)},
-  { 130, 136, sizeof(::message::Cloud_type)},
-  { 137, 147, sizeof(::message::Locate_sift_request_msg)},
-  { 152, 163, sizeof(::message::Locate_sift_response_msg)},
+  { 94, 102, sizeof(::message::Cloud_coordinate)},
+  { 105, 111, sizeof(::message::Cloud_type)},
+  { 112, 122, sizeof(::message::Locate_sift_request_msg)},
+  { 127, 138, sizeof(::message::Locate_sift_response_msg)},
 };
 
 static ::google::protobuf::Message const * const file_default_instances[] = {
@@ -477,7 +431,6 @@ static ::google::protobuf::Message const * const file_default_instances[] = {
   reinterpret_cast<const ::google::protobuf::Message*>(&::message::_Ground_detect_request_msg_default_instance_),
   reinterpret_cast<const ::google::protobuf::Message*>(&::message::_Ground_detect_response_msg_default_instance_),
   reinterpret_cast<const ::google::protobuf::Message*>(&::message::_Ground_status_msg_default_instance_),
-  reinterpret_cast<const ::google::protobuf::Message*>(&::message::_measure_info_default_instance_),
   reinterpret_cast<const ::google::protobuf::Message*>(&::message::_Cloud_coordinate_default_instance_),
   reinterpret_cast<const ::google::protobuf::Message*>(&::message::_Cloud_type_default_instance_),
   reinterpret_cast<const ::google::protobuf::Message*>(&::message::_Locate_sift_request_msg_default_instance_),
@@ -499,7 +452,7 @@ void protobuf_AssignDescriptorsOnce() {
 void protobuf_RegisterTypes(const ::std::string&) GOOGLE_PROTOBUF_ATTRIBUTE_COLD;
 void protobuf_RegisterTypes(const ::std::string&) {
   protobuf_AssignDescriptorsOnce();
-  ::google::protobuf::internal::RegisterAllTypes(file_level_metadata, 11);
+  ::google::protobuf::internal::RegisterAllTypes(file_level_metadata, 10);
 }
 
 void AddDescriptorsImpl() {
@@ -545,54 +498,49 @@ void AddDescriptorsImpl() {
       "round_statu\022\025\n\rborder_status\030\010 \002(\005\022-\n\rer"
       "ror_manager\030\t \002(\0132\026.message.Error_manage"
       "r\022(\n\005cloud\030\n \003(\0132\031.message.Cloud_coordin"
-      "ate\"\271\001\n\014measure_info\022\n\n\002cx\030\001 \002(\002\022\n\n\002cy\030\002"
-      " \002(\002\022\r\n\005theta\030\003 \002(\002\022\016\n\006length\030\004 \002(\002\022\r\n\005w"
-      "idth\030\005 \002(\002\022\016\n\006height\030\006 \002(\002\022\021\n\twheelbase\030"
-      "\007 \002(\002\022\023\n\013front_theta\030\010 \002(\002\022\024\n\014border_sta"
-      "tu\030\t \002(\005\022\025\n\rground_status\030\n \002(\005\"3\n\020Cloud"
-      "_coordinate\022\t\n\001x\030\001 \002(\002\022\t\n\001y\030\002 \002(\002\022\t\n\001z\030\003"
-      " \002(\002\"\032\n\nCloud_type\022\014\n\004type\030\001 \002(\005\"\304\001\n\027Loc"
-      "ate_sift_request_msg\022%\n\tbase_info\030\001 \002(\0132"
-      "\022.message.Base_info\022\023\n\013command_key\030\002 \002(\t"
-      "\022%\n\tid_struct\030\003 \002(\0132\022.message.Id_struct\022"
-      "\020\n\010lidar_id\030\004 \002(\005\0224\n\021cloud_coordinates\030\005"
-      " \003(\0132\031.message.Cloud_coordinate\"\347\001\n\030Loca"
-      "te_sift_response_msg\022%\n\tbase_info\030\001 \002(\0132"
-      "\022.message.Base_info\022\023\n\013command_key\030\002 \002(\t"
-      "\022%\n\tid_struct\030\003 \002(\0132\022.message.Id_struct\022"
-      "\020\n\010lidar_id\030\004 \002(\005\022\'\n\ncloud_type\030\005 \003(\0132\023."
-      "message.Cloud_type\022-\n\rerror_manager\030\006 \002("
-      "\0132\026.message.Error_manager*\237\001\n\024Laser_mana"
-      "ger_status\022\030\n\024LASER_MANAGER_UNKNOW\020\000\022\027\n\023"
-      "LASER_MANAGER_READY\020\001\022\035\n\031LASER_MANAGER_I"
-      "SSUED_TASK\020\002\022\034\n\030LASER_MANAGER_WAIT_REPLY"
-      "\020\003\022\027\n\023LASER_MANAGER_FAULT\020\004*U\n\013Laser_sta"
-      "tu\022\024\n\020LASER_DISCONNECT\020\000\022\017\n\013LASER_READY\020"
-      "\001\022\016\n\nLASER_BUSY\020\002\022\017\n\013LASER_FAULT\020\003*\261\001\n\025L"
-      "ocate_manager_status\022\031\n\025LOCATE_MANAGER_U"
-      "NKNOW\020\000\022\030\n\024LOCATE_MANAGER_READY\020\001\022\027\n\023LOC"
-      "ATE_MANAGER_SIFT\020\002\022\026\n\022LOCATE_MANAGER_CAR"
-      "\020\003\022\030\n\024LOCATE_MANAGER_WHEEL\020\004\022\030\n\024LOCATE_M"
-      "ANAGER_FAULT\020\005*\367\001\n\024Wanji_manager_status\022"
-      "\031\n\025WANJI_MANAGER_UNKNOWN\020\000\022\027\n\023WANJI_MANA"
-      "GER_READY\020\001\022\026\n\022WANJI_MANAGER_BUSY\020\002\022\035\n\031W"
-      "ANJI_MANAGER_ISSUED_SCAN\020\003\022\033\n\027WANJI_MANA"
-      "GER_WAIT_SCAN\020\004\022\037\n\033WANJI_MANAGER_ISSUED_"
-      "DETECT\020\005\022\035\n\031WANJI_MANAGER_WAIT_DETECT\020\006\022"
-      "\027\n\023WANJI_MANAGER_FAULT\020\n*\267\001\n\031Wanji_lidar"
-      "_device_status\022\036\n\032WANJI_LIDAR_DEVICE_UNK"
-      "NOWN\020\000\022\034\n\030WANJI_LIDAR_DEVICE_READY\020\001\022!\n\035"
-      "WANJI_LIDAR_DEVICE_DISCONNECT\020\002\022\033\n\027WANJI"
-      "_LIDAR_DEVICE_BUSY\020\003\022\034\n\030WANJI_LIDAR_DEVI"
-      "CE_FAULT\020\n*{\n\024Region_worker_status\022\031\n\025RE"
-      "GION_WORKER_UNKNOWN\020\000\022\027\n\023REGION_WORKER_R"
-      "EADY\020\001\022\026\n\022REGION_WORKER_BUSY\020\002\022\027\n\023REGION"
-      "_WORKER_FAULT\020\n*O\n\014Ground_statu\022\013\n\007Nothi"
-      "ng\020\000\022\t\n\005Noise\020\001\022\017\n\013Car_correct\020\002\022\026\n\022Car_"
-      "border_reached\020\003"
+      "ate\"3\n\020Cloud_coordinate\022\t\n\001x\030\001 \002(\002\022\t\n\001y\030"
+      "\002 \002(\002\022\t\n\001z\030\003 \002(\002\"\032\n\nCloud_type\022\014\n\004type\030\001"
+      " \002(\005\"\304\001\n\027Locate_sift_request_msg\022%\n\tbase"
+      "_info\030\001 \002(\0132\022.message.Base_info\022\023\n\013comma"
+      "nd_key\030\002 \002(\t\022%\n\tid_struct\030\003 \002(\0132\022.messag"
+      "e.Id_struct\022\020\n\010lidar_id\030\004 \002(\005\0224\n\021cloud_c"
+      "oordinates\030\005 \003(\0132\031.message.Cloud_coordin"
+      "ate\"\347\001\n\030Locate_sift_response_msg\022%\n\tbase"
+      "_info\030\001 \002(\0132\022.message.Base_info\022\023\n\013comma"
+      "nd_key\030\002 \002(\t\022%\n\tid_struct\030\003 \002(\0132\022.messag"
+      "e.Id_struct\022\020\n\010lidar_id\030\004 \002(\005\022\'\n\ncloud_t"
+      "ype\030\005 \003(\0132\023.message.Cloud_type\022-\n\rerror_"
+      "manager\030\006 \002(\0132\026.message.Error_manager*\237\001"
+      "\n\024Laser_manager_status\022\030\n\024LASER_MANAGER_"
+      "UNKNOW\020\000\022\027\n\023LASER_MANAGER_READY\020\001\022\035\n\031LAS"
+      "ER_MANAGER_ISSUED_TASK\020\002\022\034\n\030LASER_MANAGE"
+      "R_WAIT_REPLY\020\003\022\027\n\023LASER_MANAGER_FAULT\020\004*"
+      "U\n\013Laser_statu\022\024\n\020LASER_DISCONNECT\020\000\022\017\n\013"
+      "LASER_READY\020\001\022\016\n\nLASER_BUSY\020\002\022\017\n\013LASER_F"
+      "AULT\020\003*\261\001\n\025Locate_manager_status\022\031\n\025LOCA"
+      "TE_MANAGER_UNKNOW\020\000\022\030\n\024LOCATE_MANAGER_RE"
+      "ADY\020\001\022\027\n\023LOCATE_MANAGER_SIFT\020\002\022\026\n\022LOCATE"
+      "_MANAGER_CAR\020\003\022\030\n\024LOCATE_MANAGER_WHEEL\020\004"
+      "\022\030\n\024LOCATE_MANAGER_FAULT\020\005*\367\001\n\024Wanji_man"
+      "ager_status\022\031\n\025WANJI_MANAGER_UNKNOWN\020\000\022\027"
+      "\n\023WANJI_MANAGER_READY\020\001\022\026\n\022WANJI_MANAGER"
+      "_BUSY\020\002\022\035\n\031WANJI_MANAGER_ISSUED_SCAN\020\003\022\033"
+      "\n\027WANJI_MANAGER_WAIT_SCAN\020\004\022\037\n\033WANJI_MAN"
+      "AGER_ISSUED_DETECT\020\005\022\035\n\031WANJI_MANAGER_WA"
+      "IT_DETECT\020\006\022\027\n\023WANJI_MANAGER_FAULT\020\n*\267\001\n"
+      "\031Wanji_lidar_device_status\022\036\n\032WANJI_LIDA"
+      "R_DEVICE_UNKNOWN\020\000\022\034\n\030WANJI_LIDAR_DEVICE"
+      "_READY\020\001\022!\n\035WANJI_LIDAR_DEVICE_DISCONNEC"
+      "T\020\002\022\033\n\027WANJI_LIDAR_DEVICE_BUSY\020\003\022\034\n\030WANJ"
+      "I_LIDAR_DEVICE_FAULT\020\n*{\n\024Region_worker_"
+      "status\022\031\n\025REGION_WORKER_UNKNOWN\020\000\022\027\n\023REG"
+      "ION_WORKER_READY\020\001\022\026\n\022REGION_WORKER_BUSY"
+      "\020\002\022\027\n\023REGION_WORKER_FAULT\020\n*O\n\014Ground_st"
+      "atu\022\013\n\007Nothing\020\000\022\t\n\005Noise\020\001\022\017\n\013Car_corre"
+      "ct\020\002\022\026\n\022Car_border_reached\020\003"
   };
   ::google::protobuf::DescriptorPool::InternalAddGeneratedFile(
-      descriptor, 3376);
+      descriptor, 3188);
   ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile(
     "measure_message.proto", &protobuf_RegisterTypes);
   ::protobuf_message_5fbase_2eproto::AddDescriptors();
@@ -3815,608 +3763,6 @@ void Ground_status_msg::InternalSwap(Ground_status_msg* other) {
 }
 
 
-// ===================================================================
-
-void measure_info::InitAsDefaultInstance() {
-}
-#if !defined(_MSC_VER) || _MSC_VER >= 1900
-const int measure_info::kCxFieldNumber;
-const int measure_info::kCyFieldNumber;
-const int measure_info::kThetaFieldNumber;
-const int measure_info::kLengthFieldNumber;
-const int measure_info::kWidthFieldNumber;
-const int measure_info::kHeightFieldNumber;
-const int measure_info::kWheelbaseFieldNumber;
-const int measure_info::kFrontThetaFieldNumber;
-const int measure_info::kBorderStatuFieldNumber;
-const int measure_info::kGroundStatusFieldNumber;
-#endif  // !defined(_MSC_VER) || _MSC_VER >= 1900
-
-measure_info::measure_info()
-  : ::google::protobuf::Message(), _internal_metadata_(NULL) {
-  ::google::protobuf::internal::InitSCC(
-      &protobuf_measure_5fmessage_2eproto::scc_info_measure_info.base);
-  SharedCtor();
-  // @@protoc_insertion_point(constructor:message.measure_info)
-}
-measure_info::measure_info(const measure_info& from)
-  : ::google::protobuf::Message(),
-      _internal_metadata_(NULL),
-      _has_bits_(from._has_bits_) {
-  _internal_metadata_.MergeFrom(from._internal_metadata_);
-  ::memcpy(&cx_, &from.cx_,
-    static_cast<size_t>(reinterpret_cast<char*>(&ground_status_) -
-    reinterpret_cast<char*>(&cx_)) + sizeof(ground_status_));
-  // @@protoc_insertion_point(copy_constructor:message.measure_info)
-}
-
-void measure_info::SharedCtor() {
-  ::memset(&cx_, 0, static_cast<size_t>(
-      reinterpret_cast<char*>(&ground_status_) -
-      reinterpret_cast<char*>(&cx_)) + sizeof(ground_status_));
-}
-
-measure_info::~measure_info() {
-  // @@protoc_insertion_point(destructor:message.measure_info)
-  SharedDtor();
-}
-
-void measure_info::SharedDtor() {
-}
-
-void measure_info::SetCachedSize(int size) const {
-  _cached_size_.Set(size);
-}
-const ::google::protobuf::Descriptor* measure_info::descriptor() {
-  ::protobuf_measure_5fmessage_2eproto::protobuf_AssignDescriptorsOnce();
-  return ::protobuf_measure_5fmessage_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
-}
-
-const measure_info& measure_info::default_instance() {
-  ::google::protobuf::internal::InitSCC(&protobuf_measure_5fmessage_2eproto::scc_info_measure_info.base);
-  return *internal_default_instance();
-}
-
-
-void measure_info::Clear() {
-// @@protoc_insertion_point(message_clear_start:message.measure_info)
-  ::google::protobuf::uint32 cached_has_bits = 0;
-  // Prevent compiler warnings about cached_has_bits being unused
-  (void) cached_has_bits;
-
-  cached_has_bits = _has_bits_[0];
-  if (cached_has_bits & 255u) {
-    ::memset(&cx_, 0, static_cast<size_t>(
-        reinterpret_cast<char*>(&front_theta_) -
-        reinterpret_cast<char*>(&cx_)) + sizeof(front_theta_));
-  }
-  if (cached_has_bits & 768u) {
-    ::memset(&border_statu_, 0, static_cast<size_t>(
-        reinterpret_cast<char*>(&ground_status_) -
-        reinterpret_cast<char*>(&border_statu_)) + sizeof(ground_status_));
-  }
-  _has_bits_.Clear();
-  _internal_metadata_.Clear();
-}
-
-bool measure_info::MergePartialFromCodedStream(
-    ::google::protobuf::io::CodedInputStream* input) {
-#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
-  ::google::protobuf::uint32 tag;
-  // @@protoc_insertion_point(parse_start:message.measure_info)
-  for (;;) {
-    ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
-    tag = p.first;
-    if (!p.second) goto handle_unusual;
-    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
-      // required float cx = 1;
-      case 1: {
-        if (static_cast< ::google::protobuf::uint8>(tag) ==
-            static_cast< ::google::protobuf::uint8>(13u /* 13 & 0xFF */)) {
-          set_has_cx();
-          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
-                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
-                 input, &cx_)));
-        } else {
-          goto handle_unusual;
-        }
-        break;
-      }
-
-      // required float cy = 2;
-      case 2: {
-        if (static_cast< ::google::protobuf::uint8>(tag) ==
-            static_cast< ::google::protobuf::uint8>(21u /* 21 & 0xFF */)) {
-          set_has_cy();
-          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
-                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
-                 input, &cy_)));
-        } else {
-          goto handle_unusual;
-        }
-        break;
-      }
-
-      // required float theta = 3;
-      case 3: {
-        if (static_cast< ::google::protobuf::uint8>(tag) ==
-            static_cast< ::google::protobuf::uint8>(29u /* 29 & 0xFF */)) {
-          set_has_theta();
-          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
-                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
-                 input, &theta_)));
-        } else {
-          goto handle_unusual;
-        }
-        break;
-      }
-
-      // required float length = 4;
-      case 4: {
-        if (static_cast< ::google::protobuf::uint8>(tag) ==
-            static_cast< ::google::protobuf::uint8>(37u /* 37 & 0xFF */)) {
-          set_has_length();
-          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
-                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
-                 input, &length_)));
-        } else {
-          goto handle_unusual;
-        }
-        break;
-      }
-
-      // required float width = 5;
-      case 5: {
-        if (static_cast< ::google::protobuf::uint8>(tag) ==
-            static_cast< ::google::protobuf::uint8>(45u /* 45 & 0xFF */)) {
-          set_has_width();
-          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
-                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
-                 input, &width_)));
-        } else {
-          goto handle_unusual;
-        }
-        break;
-      }
-
-      // required float height = 6;
-      case 6: {
-        if (static_cast< ::google::protobuf::uint8>(tag) ==
-            static_cast< ::google::protobuf::uint8>(53u /* 53 & 0xFF */)) {
-          set_has_height();
-          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
-                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
-                 input, &height_)));
-        } else {
-          goto handle_unusual;
-        }
-        break;
-      }
-
-      // required float wheelbase = 7;
-      case 7: {
-        if (static_cast< ::google::protobuf::uint8>(tag) ==
-            static_cast< ::google::protobuf::uint8>(61u /* 61 & 0xFF */)) {
-          set_has_wheelbase();
-          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
-                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
-                 input, &wheelbase_)));
-        } else {
-          goto handle_unusual;
-        }
-        break;
-      }
-
-      // required float front_theta = 8;
-      case 8: {
-        if (static_cast< ::google::protobuf::uint8>(tag) ==
-            static_cast< ::google::protobuf::uint8>(69u /* 69 & 0xFF */)) {
-          set_has_front_theta();
-          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
-                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
-                 input, &front_theta_)));
-        } else {
-          goto handle_unusual;
-        }
-        break;
-      }
-
-      // required int32 border_statu = 9;
-      case 9: {
-        if (static_cast< ::google::protobuf::uint8>(tag) ==
-            static_cast< ::google::protobuf::uint8>(72u /* 72 & 0xFF */)) {
-          set_has_border_statu();
-          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
-                   ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
-                 input, &border_statu_)));
-        } else {
-          goto handle_unusual;
-        }
-        break;
-      }
-
-      // required int32 ground_status = 10;
-      case 10: {
-        if (static_cast< ::google::protobuf::uint8>(tag) ==
-            static_cast< ::google::protobuf::uint8>(80u /* 80 & 0xFF */)) {
-          set_has_ground_status();
-          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
-                   ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
-                 input, &ground_status_)));
-        } else {
-          goto handle_unusual;
-        }
-        break;
-      }
-
-      default: {
-      handle_unusual:
-        if (tag == 0) {
-          goto success;
-        }
-        DO_(::google::protobuf::internal::WireFormat::SkipField(
-              input, tag, _internal_metadata_.mutable_unknown_fields()));
-        break;
-      }
-    }
-  }
-success:
-  // @@protoc_insertion_point(parse_success:message.measure_info)
-  return true;
-failure:
-  // @@protoc_insertion_point(parse_failure:message.measure_info)
-  return false;
-#undef DO_
-}
-
-void measure_info::SerializeWithCachedSizes(
-    ::google::protobuf::io::CodedOutputStream* output) const {
-  // @@protoc_insertion_point(serialize_start:message.measure_info)
-  ::google::protobuf::uint32 cached_has_bits = 0;
-  (void) cached_has_bits;
-
-  cached_has_bits = _has_bits_[0];
-  // required float cx = 1;
-  if (cached_has_bits & 0x00000001u) {
-    ::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->cx(), output);
-  }
-
-  // required float cy = 2;
-  if (cached_has_bits & 0x00000002u) {
-    ::google::protobuf::internal::WireFormatLite::WriteFloat(2, this->cy(), output);
-  }
-
-  // required float theta = 3;
-  if (cached_has_bits & 0x00000004u) {
-    ::google::protobuf::internal::WireFormatLite::WriteFloat(3, this->theta(), output);
-  }
-
-  // required float length = 4;
-  if (cached_has_bits & 0x00000008u) {
-    ::google::protobuf::internal::WireFormatLite::WriteFloat(4, this->length(), output);
-  }
-
-  // required float width = 5;
-  if (cached_has_bits & 0x00000010u) {
-    ::google::protobuf::internal::WireFormatLite::WriteFloat(5, this->width(), output);
-  }
-
-  // required float height = 6;
-  if (cached_has_bits & 0x00000020u) {
-    ::google::protobuf::internal::WireFormatLite::WriteFloat(6, this->height(), output);
-  }
-
-  // required float wheelbase = 7;
-  if (cached_has_bits & 0x00000040u) {
-    ::google::protobuf::internal::WireFormatLite::WriteFloat(7, this->wheelbase(), output);
-  }
-
-  // required float front_theta = 8;
-  if (cached_has_bits & 0x00000080u) {
-    ::google::protobuf::internal::WireFormatLite::WriteFloat(8, this->front_theta(), output);
-  }
-
-  // required int32 border_statu = 9;
-  if (cached_has_bits & 0x00000100u) {
-    ::google::protobuf::internal::WireFormatLite::WriteInt32(9, this->border_statu(), output);
-  }
-
-  // required int32 ground_status = 10;
-  if (cached_has_bits & 0x00000200u) {
-    ::google::protobuf::internal::WireFormatLite::WriteInt32(10, this->ground_status(), output);
-  }
-
-  if (_internal_metadata_.have_unknown_fields()) {
-    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
-        _internal_metadata_.unknown_fields(), output);
-  }
-  // @@protoc_insertion_point(serialize_end:message.measure_info)
-}
-
-::google::protobuf::uint8* measure_info::InternalSerializeWithCachedSizesToArray(
-    bool deterministic, ::google::protobuf::uint8* target) const {
-  (void)deterministic; // Unused
-  // @@protoc_insertion_point(serialize_to_array_start:message.measure_info)
-  ::google::protobuf::uint32 cached_has_bits = 0;
-  (void) cached_has_bits;
-
-  cached_has_bits = _has_bits_[0];
-  // required float cx = 1;
-  if (cached_has_bits & 0x00000001u) {
-    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->cx(), target);
-  }
-
-  // required float cy = 2;
-  if (cached_has_bits & 0x00000002u) {
-    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(2, this->cy(), target);
-  }
-
-  // required float theta = 3;
-  if (cached_has_bits & 0x00000004u) {
-    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(3, this->theta(), target);
-  }
-
-  // required float length = 4;
-  if (cached_has_bits & 0x00000008u) {
-    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(4, this->length(), target);
-  }
-
-  // required float width = 5;
-  if (cached_has_bits & 0x00000010u) {
-    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(5, this->width(), target);
-  }
-
-  // required float height = 6;
-  if (cached_has_bits & 0x00000020u) {
-    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(6, this->height(), target);
-  }
-
-  // required float wheelbase = 7;
-  if (cached_has_bits & 0x00000040u) {
-    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(7, this->wheelbase(), target);
-  }
-
-  // required float front_theta = 8;
-  if (cached_has_bits & 0x00000080u) {
-    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(8, this->front_theta(), target);
-  }
-
-  // required int32 border_statu = 9;
-  if (cached_has_bits & 0x00000100u) {
-    target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(9, this->border_statu(), target);
-  }
-
-  // required int32 ground_status = 10;
-  if (cached_has_bits & 0x00000200u) {
-    target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(10, this->ground_status(), target);
-  }
-
-  if (_internal_metadata_.have_unknown_fields()) {
-    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
-        _internal_metadata_.unknown_fields(), target);
-  }
-  // @@protoc_insertion_point(serialize_to_array_end:message.measure_info)
-  return target;
-}
-
-size_t measure_info::RequiredFieldsByteSizeFallback() const {
-// @@protoc_insertion_point(required_fields_byte_size_fallback_start:message.measure_info)
-  size_t total_size = 0;
-
-  if (has_cx()) {
-    // required float cx = 1;
-    total_size += 1 + 4;
-  }
-
-  if (has_cy()) {
-    // required float cy = 2;
-    total_size += 1 + 4;
-  }
-
-  if (has_theta()) {
-    // required float theta = 3;
-    total_size += 1 + 4;
-  }
-
-  if (has_length()) {
-    // required float length = 4;
-    total_size += 1 + 4;
-  }
-
-  if (has_width()) {
-    // required float width = 5;
-    total_size += 1 + 4;
-  }
-
-  if (has_height()) {
-    // required float height = 6;
-    total_size += 1 + 4;
-  }
-
-  if (has_wheelbase()) {
-    // required float wheelbase = 7;
-    total_size += 1 + 4;
-  }
-
-  if (has_front_theta()) {
-    // required float front_theta = 8;
-    total_size += 1 + 4;
-  }
-
-  if (has_border_statu()) {
-    // required int32 border_statu = 9;
-    total_size += 1 +
-      ::google::protobuf::internal::WireFormatLite::Int32Size(
-        this->border_statu());
-  }
-
-  if (has_ground_status()) {
-    // required int32 ground_status = 10;
-    total_size += 1 +
-      ::google::protobuf::internal::WireFormatLite::Int32Size(
-        this->ground_status());
-  }
-
-  return total_size;
-}
-size_t measure_info::ByteSizeLong() const {
-// @@protoc_insertion_point(message_byte_size_start:message.measure_info)
-  size_t total_size = 0;
-
-  if (_internal_metadata_.have_unknown_fields()) {
-    total_size +=
-      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
-        _internal_metadata_.unknown_fields());
-  }
-  if (((_has_bits_[0] & 0x000003ff) ^ 0x000003ff) == 0) {  // All required fields are present.
-    // required float cx = 1;
-    total_size += 1 + 4;
-
-    // required float cy = 2;
-    total_size += 1 + 4;
-
-    // required float theta = 3;
-    total_size += 1 + 4;
-
-    // required float length = 4;
-    total_size += 1 + 4;
-
-    // required float width = 5;
-    total_size += 1 + 4;
-
-    // required float height = 6;
-    total_size += 1 + 4;
-
-    // required float wheelbase = 7;
-    total_size += 1 + 4;
-
-    // required float front_theta = 8;
-    total_size += 1 + 4;
-
-    // required int32 border_statu = 9;
-    total_size += 1 +
-      ::google::protobuf::internal::WireFormatLite::Int32Size(
-        this->border_statu());
-
-    // required int32 ground_status = 10;
-    total_size += 1 +
-      ::google::protobuf::internal::WireFormatLite::Int32Size(
-        this->ground_status());
-
-  } else {
-    total_size += RequiredFieldsByteSizeFallback();
-  }
-  int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
-  SetCachedSize(cached_size);
-  return total_size;
-}
-
-void measure_info::MergeFrom(const ::google::protobuf::Message& from) {
-// @@protoc_insertion_point(generalized_merge_from_start:message.measure_info)
-  GOOGLE_DCHECK_NE(&from, this);
-  const measure_info* source =
-      ::google::protobuf::internal::DynamicCastToGenerated<const measure_info>(
-          &from);
-  if (source == NULL) {
-  // @@protoc_insertion_point(generalized_merge_from_cast_fail:message.measure_info)
-    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
-  } else {
-  // @@protoc_insertion_point(generalized_merge_from_cast_success:message.measure_info)
-    MergeFrom(*source);
-  }
-}
-
-void measure_info::MergeFrom(const measure_info& from) {
-// @@protoc_insertion_point(class_specific_merge_from_start:message.measure_info)
-  GOOGLE_DCHECK_NE(&from, this);
-  _internal_metadata_.MergeFrom(from._internal_metadata_);
-  ::google::protobuf::uint32 cached_has_bits = 0;
-  (void) cached_has_bits;
-
-  cached_has_bits = from._has_bits_[0];
-  if (cached_has_bits & 255u) {
-    if (cached_has_bits & 0x00000001u) {
-      cx_ = from.cx_;
-    }
-    if (cached_has_bits & 0x00000002u) {
-      cy_ = from.cy_;
-    }
-    if (cached_has_bits & 0x00000004u) {
-      theta_ = from.theta_;
-    }
-    if (cached_has_bits & 0x00000008u) {
-      length_ = from.length_;
-    }
-    if (cached_has_bits & 0x00000010u) {
-      width_ = from.width_;
-    }
-    if (cached_has_bits & 0x00000020u) {
-      height_ = from.height_;
-    }
-    if (cached_has_bits & 0x00000040u) {
-      wheelbase_ = from.wheelbase_;
-    }
-    if (cached_has_bits & 0x00000080u) {
-      front_theta_ = from.front_theta_;
-    }
-    _has_bits_[0] |= cached_has_bits;
-  }
-  if (cached_has_bits & 768u) {
-    if (cached_has_bits & 0x00000100u) {
-      border_statu_ = from.border_statu_;
-    }
-    if (cached_has_bits & 0x00000200u) {
-      ground_status_ = from.ground_status_;
-    }
-    _has_bits_[0] |= cached_has_bits;
-  }
-}
-
-void measure_info::CopyFrom(const ::google::protobuf::Message& from) {
-// @@protoc_insertion_point(generalized_copy_from_start:message.measure_info)
-  if (&from == this) return;
-  Clear();
-  MergeFrom(from);
-}
-
-void measure_info::CopyFrom(const measure_info& from) {
-// @@protoc_insertion_point(class_specific_copy_from_start:message.measure_info)
-  if (&from == this) return;
-  Clear();
-  MergeFrom(from);
-}
-
-bool measure_info::IsInitialized() const {
-  if ((_has_bits_[0] & 0x000003ff) != 0x000003ff) return false;
-  return true;
-}
-
-void measure_info::Swap(measure_info* other) {
-  if (other == this) return;
-  InternalSwap(other);
-}
-void measure_info::InternalSwap(measure_info* other) {
-  using std::swap;
-  swap(cx_, other->cx_);
-  swap(cy_, other->cy_);
-  swap(theta_, other->theta_);
-  swap(length_, other->length_);
-  swap(width_, other->width_);
-  swap(height_, other->height_);
-  swap(wheelbase_, other->wheelbase_);
-  swap(front_theta_, other->front_theta_);
-  swap(border_statu_, other->border_statu_);
-  swap(ground_status_, other->ground_status_);
-  swap(_has_bits_[0], other->_has_bits_[0]);
-  _internal_metadata_.Swap(&other->_internal_metadata_);
-}
-
-::google::protobuf::Metadata measure_info::GetMetadata() const {
-  protobuf_measure_5fmessage_2eproto::protobuf_AssignDescriptorsOnce();
-  return ::protobuf_measure_5fmessage_2eproto::file_level_metadata[kIndexInFileMessages];
-}
-
-
 // ===================================================================
 
 void Cloud_coordinate::InitAsDefaultInstance() {
@@ -6021,9 +5367,6 @@ template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::message::Ground_detect_response_
 template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::message::Ground_status_msg* Arena::CreateMaybeMessage< ::message::Ground_status_msg >(Arena* arena) {
   return Arena::CreateInternal< ::message::Ground_status_msg >(arena);
 }
-template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::message::measure_info* Arena::CreateMaybeMessage< ::message::measure_info >(Arena* arena) {
-  return Arena::CreateInternal< ::message::measure_info >(arena);
-}
 template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::message::Cloud_coordinate* Arena::CreateMaybeMessage< ::message::Cloud_coordinate >(Arena* arena) {
   return Arena::CreateInternal< ::message::Cloud_coordinate >(arena);
 }

+ 5 - 462
message/measure_message.pb.h

@@ -40,7 +40,7 @@ namespace protobuf_measure_5fmessage_2eproto {
 struct TableStruct {
   static const ::google::protobuf::internal::ParseTableField entries[];
   static const ::google::protobuf::internal::AuxillaryParseTableField aux[];
-  static const ::google::protobuf::internal::ParseTable schema[11];
+  static const ::google::protobuf::internal::ParseTable schema[10];
   static const ::google::protobuf::internal::FieldMetadata field_metadata[];
   static const ::google::protobuf::internal::SerializationTable serialization_table[];
   static const ::google::protobuf::uint32 offsets[];
@@ -78,9 +78,6 @@ extern Measure_response_msgDefaultTypeInternal _Measure_response_msg_default_ins
 class Measure_status_msg;
 class Measure_status_msgDefaultTypeInternal;
 extern Measure_status_msgDefaultTypeInternal _Measure_status_msg_default_instance_;
-class measure_info;
-class measure_infoDefaultTypeInternal;
-extern measure_infoDefaultTypeInternal _measure_info_default_instance_;
 }  // namespace message
 namespace google {
 namespace protobuf {
@@ -94,7 +91,6 @@ template<> ::message::Locate_sift_response_msg* Arena::CreateMaybeMessage<::mess
 template<> ::message::Measure_request_msg* Arena::CreateMaybeMessage<::message::Measure_request_msg>(Arena*);
 template<> ::message::Measure_response_msg* Arena::CreateMaybeMessage<::message::Measure_response_msg>(Arena*);
 template<> ::message::Measure_status_msg* Arena::CreateMaybeMessage<::message::Measure_status_msg>(Arena*);
-template<> ::message::measure_info* Arena::CreateMaybeMessage<::message::measure_info>(Arena*);
 }  // namespace protobuf
 }  // namespace google
 namespace message {
@@ -1350,213 +1346,6 @@ class Ground_status_msg : public ::google::protobuf::Message /* @@protoc_inserti
 };
 // -------------------------------------------------------------------
 
-class measure_info : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:message.measure_info) */ {
- public:
-  measure_info();
-  virtual ~measure_info();
-
-  measure_info(const measure_info& from);
-
-  inline measure_info& operator=(const measure_info& from) {
-    CopyFrom(from);
-    return *this;
-  }
-  #if LANG_CXX11
-  measure_info(measure_info&& from) noexcept
-    : measure_info() {
-    *this = ::std::move(from);
-  }
-
-  inline measure_info& operator=(measure_info&& from) noexcept {
-    if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) {
-      if (this != &from) InternalSwap(&from);
-    } else {
-      CopyFrom(from);
-    }
-    return *this;
-  }
-  #endif
-  inline const ::google::protobuf::UnknownFieldSet& unknown_fields() const {
-    return _internal_metadata_.unknown_fields();
-  }
-  inline ::google::protobuf::UnknownFieldSet* mutable_unknown_fields() {
-    return _internal_metadata_.mutable_unknown_fields();
-  }
-
-  static const ::google::protobuf::Descriptor* descriptor();
-  static const measure_info& default_instance();
-
-  static void InitAsDefaultInstance();  // FOR INTERNAL USE ONLY
-  static inline const measure_info* internal_default_instance() {
-    return reinterpret_cast<const measure_info*>(
-               &_measure_info_default_instance_);
-  }
-  static constexpr int kIndexInFileMessages =
-    6;
-
-  void Swap(measure_info* other);
-  friend void swap(measure_info& a, measure_info& b) {
-    a.Swap(&b);
-  }
-
-  // implements Message ----------------------------------------------
-
-  inline measure_info* New() const final {
-    return CreateMaybeMessage<measure_info>(NULL);
-  }
-
-  measure_info* New(::google::protobuf::Arena* arena) const final {
-    return CreateMaybeMessage<measure_info>(arena);
-  }
-  void CopyFrom(const ::google::protobuf::Message& from) final;
-  void MergeFrom(const ::google::protobuf::Message& from) final;
-  void CopyFrom(const measure_info& from);
-  void MergeFrom(const measure_info& from);
-  void Clear() final;
-  bool IsInitialized() const final;
-
-  size_t ByteSizeLong() const final;
-  bool MergePartialFromCodedStream(
-      ::google::protobuf::io::CodedInputStream* input) final;
-  void SerializeWithCachedSizes(
-      ::google::protobuf::io::CodedOutputStream* output) const final;
-  ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
-      bool deterministic, ::google::protobuf::uint8* target) const final;
-  int GetCachedSize() const final { return _cached_size_.Get(); }
-
-  private:
-  void SharedCtor();
-  void SharedDtor();
-  void SetCachedSize(int size) const final;
-  void InternalSwap(measure_info* other);
-  private:
-  inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
-    return NULL;
-  }
-  inline void* MaybeArenaPtr() const {
-    return NULL;
-  }
-  public:
-
-  ::google::protobuf::Metadata GetMetadata() const final;
-
-  // nested types ----------------------------------------------------
-
-  // accessors -------------------------------------------------------
-
-  // required float cx = 1;
-  bool has_cx() const;
-  void clear_cx();
-  static const int kCxFieldNumber = 1;
-  float cx() const;
-  void set_cx(float value);
-
-  // required float cy = 2;
-  bool has_cy() const;
-  void clear_cy();
-  static const int kCyFieldNumber = 2;
-  float cy() const;
-  void set_cy(float value);
-
-  // required float theta = 3;
-  bool has_theta() const;
-  void clear_theta();
-  static const int kThetaFieldNumber = 3;
-  float theta() const;
-  void set_theta(float value);
-
-  // required float length = 4;
-  bool has_length() const;
-  void clear_length();
-  static const int kLengthFieldNumber = 4;
-  float length() const;
-  void set_length(float value);
-
-  // required float width = 5;
-  bool has_width() const;
-  void clear_width();
-  static const int kWidthFieldNumber = 5;
-  float width() const;
-  void set_width(float value);
-
-  // required float height = 6;
-  bool has_height() const;
-  void clear_height();
-  static const int kHeightFieldNumber = 6;
-  float height() const;
-  void set_height(float value);
-
-  // required float wheelbase = 7;
-  bool has_wheelbase() const;
-  void clear_wheelbase();
-  static const int kWheelbaseFieldNumber = 7;
-  float wheelbase() const;
-  void set_wheelbase(float value);
-
-  // required float front_theta = 8;
-  bool has_front_theta() const;
-  void clear_front_theta();
-  static const int kFrontThetaFieldNumber = 8;
-  float front_theta() const;
-  void set_front_theta(float value);
-
-  // required int32 border_statu = 9;
-  bool has_border_statu() const;
-  void clear_border_statu();
-  static const int kBorderStatuFieldNumber = 9;
-  ::google::protobuf::int32 border_statu() const;
-  void set_border_statu(::google::protobuf::int32 value);
-
-  // required int32 ground_status = 10;
-  bool has_ground_status() const;
-  void clear_ground_status();
-  static const int kGroundStatusFieldNumber = 10;
-  ::google::protobuf::int32 ground_status() const;
-  void set_ground_status(::google::protobuf::int32 value);
-
-  // @@protoc_insertion_point(class_scope:message.measure_info)
- private:
-  void set_has_cx();
-  void clear_has_cx();
-  void set_has_cy();
-  void clear_has_cy();
-  void set_has_theta();
-  void clear_has_theta();
-  void set_has_length();
-  void clear_has_length();
-  void set_has_width();
-  void clear_has_width();
-  void set_has_height();
-  void clear_has_height();
-  void set_has_wheelbase();
-  void clear_has_wheelbase();
-  void set_has_front_theta();
-  void clear_has_front_theta();
-  void set_has_border_statu();
-  void clear_has_border_statu();
-  void set_has_ground_status();
-  void clear_has_ground_status();
-
-  // helper for ByteSizeLong()
-  size_t RequiredFieldsByteSizeFallback() const;
-
-  ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
-  ::google::protobuf::internal::HasBits<1> _has_bits_;
-  mutable ::google::protobuf::internal::CachedSize _cached_size_;
-  float cx_;
-  float cy_;
-  float theta_;
-  float length_;
-  float width_;
-  float height_;
-  float wheelbase_;
-  float front_theta_;
-  ::google::protobuf::int32 border_statu_;
-  ::google::protobuf::int32 ground_status_;
-  friend struct ::protobuf_measure_5fmessage_2eproto::TableStruct;
-};
-// -------------------------------------------------------------------
-
 class Cloud_coordinate : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:message.Cloud_coordinate) */ {
  public:
   Cloud_coordinate();
@@ -1599,7 +1388,7 @@ class Cloud_coordinate : public ::google::protobuf::Message /* @@protoc_insertio
                &_Cloud_coordinate_default_instance_);
   }
   static constexpr int kIndexInFileMessages =
-    7;
+    6;
 
   void Swap(Cloud_coordinate* other);
   friend void swap(Cloud_coordinate& a, Cloud_coordinate& b) {
@@ -1736,7 +1525,7 @@ class Cloud_type : public ::google::protobuf::Message /* @@protoc_insertion_poin
                &_Cloud_type_default_instance_);
   }
   static constexpr int kIndexInFileMessages =
-    8;
+    7;
 
   void Swap(Cloud_type* other);
   friend void swap(Cloud_type& a, Cloud_type& b) {
@@ -1850,7 +1639,7 @@ class Locate_sift_request_msg : public ::google::protobuf::Message /* @@protoc_i
                &_Locate_sift_request_msg_default_instance_);
   }
   static constexpr int kIndexInFileMessages =
-    9;
+    8;
 
   void Swap(Locate_sift_request_msg* other);
   friend void swap(Locate_sift_request_msg& a, Locate_sift_request_msg& b) {
@@ -2028,7 +1817,7 @@ class Locate_sift_response_msg : public ::google::protobuf::Message /* @@protoc_
                &_Locate_sift_response_msg_default_instance_);
   }
   static constexpr int kIndexInFileMessages =
-    10;
+    9;
 
   void Swap(Locate_sift_response_msg* other);
   friend void swap(Locate_sift_response_msg& a, Locate_sift_response_msg& b) {
@@ -3743,250 +3532,6 @@ Ground_status_msg::cloud() const {
 
 // -------------------------------------------------------------------
 
-// measure_info
-
-// required float cx = 1;
-inline bool measure_info::has_cx() const {
-  return (_has_bits_[0] & 0x00000001u) != 0;
-}
-inline void measure_info::set_has_cx() {
-  _has_bits_[0] |= 0x00000001u;
-}
-inline void measure_info::clear_has_cx() {
-  _has_bits_[0] &= ~0x00000001u;
-}
-inline void measure_info::clear_cx() {
-  cx_ = 0;
-  clear_has_cx();
-}
-inline float measure_info::cx() const {
-  // @@protoc_insertion_point(field_get:message.measure_info.cx)
-  return cx_;
-}
-inline void measure_info::set_cx(float value) {
-  set_has_cx();
-  cx_ = value;
-  // @@protoc_insertion_point(field_set:message.measure_info.cx)
-}
-
-// required float cy = 2;
-inline bool measure_info::has_cy() const {
-  return (_has_bits_[0] & 0x00000002u) != 0;
-}
-inline void measure_info::set_has_cy() {
-  _has_bits_[0] |= 0x00000002u;
-}
-inline void measure_info::clear_has_cy() {
-  _has_bits_[0] &= ~0x00000002u;
-}
-inline void measure_info::clear_cy() {
-  cy_ = 0;
-  clear_has_cy();
-}
-inline float measure_info::cy() const {
-  // @@protoc_insertion_point(field_get:message.measure_info.cy)
-  return cy_;
-}
-inline void measure_info::set_cy(float value) {
-  set_has_cy();
-  cy_ = value;
-  // @@protoc_insertion_point(field_set:message.measure_info.cy)
-}
-
-// required float theta = 3;
-inline bool measure_info::has_theta() const {
-  return (_has_bits_[0] & 0x00000004u) != 0;
-}
-inline void measure_info::set_has_theta() {
-  _has_bits_[0] |= 0x00000004u;
-}
-inline void measure_info::clear_has_theta() {
-  _has_bits_[0] &= ~0x00000004u;
-}
-inline void measure_info::clear_theta() {
-  theta_ = 0;
-  clear_has_theta();
-}
-inline float measure_info::theta() const {
-  // @@protoc_insertion_point(field_get:message.measure_info.theta)
-  return theta_;
-}
-inline void measure_info::set_theta(float value) {
-  set_has_theta();
-  theta_ = value;
-  // @@protoc_insertion_point(field_set:message.measure_info.theta)
-}
-
-// required float length = 4;
-inline bool measure_info::has_length() const {
-  return (_has_bits_[0] & 0x00000008u) != 0;
-}
-inline void measure_info::set_has_length() {
-  _has_bits_[0] |= 0x00000008u;
-}
-inline void measure_info::clear_has_length() {
-  _has_bits_[0] &= ~0x00000008u;
-}
-inline void measure_info::clear_length() {
-  length_ = 0;
-  clear_has_length();
-}
-inline float measure_info::length() const {
-  // @@protoc_insertion_point(field_get:message.measure_info.length)
-  return length_;
-}
-inline void measure_info::set_length(float value) {
-  set_has_length();
-  length_ = value;
-  // @@protoc_insertion_point(field_set:message.measure_info.length)
-}
-
-// required float width = 5;
-inline bool measure_info::has_width() const {
-  return (_has_bits_[0] & 0x00000010u) != 0;
-}
-inline void measure_info::set_has_width() {
-  _has_bits_[0] |= 0x00000010u;
-}
-inline void measure_info::clear_has_width() {
-  _has_bits_[0] &= ~0x00000010u;
-}
-inline void measure_info::clear_width() {
-  width_ = 0;
-  clear_has_width();
-}
-inline float measure_info::width() const {
-  // @@protoc_insertion_point(field_get:message.measure_info.width)
-  return width_;
-}
-inline void measure_info::set_width(float value) {
-  set_has_width();
-  width_ = value;
-  // @@protoc_insertion_point(field_set:message.measure_info.width)
-}
-
-// required float height = 6;
-inline bool measure_info::has_height() const {
-  return (_has_bits_[0] & 0x00000020u) != 0;
-}
-inline void measure_info::set_has_height() {
-  _has_bits_[0] |= 0x00000020u;
-}
-inline void measure_info::clear_has_height() {
-  _has_bits_[0] &= ~0x00000020u;
-}
-inline void measure_info::clear_height() {
-  height_ = 0;
-  clear_has_height();
-}
-inline float measure_info::height() const {
-  // @@protoc_insertion_point(field_get:message.measure_info.height)
-  return height_;
-}
-inline void measure_info::set_height(float value) {
-  set_has_height();
-  height_ = value;
-  // @@protoc_insertion_point(field_set:message.measure_info.height)
-}
-
-// required float wheelbase = 7;
-inline bool measure_info::has_wheelbase() const {
-  return (_has_bits_[0] & 0x00000040u) != 0;
-}
-inline void measure_info::set_has_wheelbase() {
-  _has_bits_[0] |= 0x00000040u;
-}
-inline void measure_info::clear_has_wheelbase() {
-  _has_bits_[0] &= ~0x00000040u;
-}
-inline void measure_info::clear_wheelbase() {
-  wheelbase_ = 0;
-  clear_has_wheelbase();
-}
-inline float measure_info::wheelbase() const {
-  // @@protoc_insertion_point(field_get:message.measure_info.wheelbase)
-  return wheelbase_;
-}
-inline void measure_info::set_wheelbase(float value) {
-  set_has_wheelbase();
-  wheelbase_ = value;
-  // @@protoc_insertion_point(field_set:message.measure_info.wheelbase)
-}
-
-// required float front_theta = 8;
-inline bool measure_info::has_front_theta() const {
-  return (_has_bits_[0] & 0x00000080u) != 0;
-}
-inline void measure_info::set_has_front_theta() {
-  _has_bits_[0] |= 0x00000080u;
-}
-inline void measure_info::clear_has_front_theta() {
-  _has_bits_[0] &= ~0x00000080u;
-}
-inline void measure_info::clear_front_theta() {
-  front_theta_ = 0;
-  clear_has_front_theta();
-}
-inline float measure_info::front_theta() const {
-  // @@protoc_insertion_point(field_get:message.measure_info.front_theta)
-  return front_theta_;
-}
-inline void measure_info::set_front_theta(float value) {
-  set_has_front_theta();
-  front_theta_ = value;
-  // @@protoc_insertion_point(field_set:message.measure_info.front_theta)
-}
-
-// required int32 border_statu = 9;
-inline bool measure_info::has_border_statu() const {
-  return (_has_bits_[0] & 0x00000100u) != 0;
-}
-inline void measure_info::set_has_border_statu() {
-  _has_bits_[0] |= 0x00000100u;
-}
-inline void measure_info::clear_has_border_statu() {
-  _has_bits_[0] &= ~0x00000100u;
-}
-inline void measure_info::clear_border_statu() {
-  border_statu_ = 0;
-  clear_has_border_statu();
-}
-inline ::google::protobuf::int32 measure_info::border_statu() const {
-  // @@protoc_insertion_point(field_get:message.measure_info.border_statu)
-  return border_statu_;
-}
-inline void measure_info::set_border_statu(::google::protobuf::int32 value) {
-  set_has_border_statu();
-  border_statu_ = value;
-  // @@protoc_insertion_point(field_set:message.measure_info.border_statu)
-}
-
-// required int32 ground_status = 10;
-inline bool measure_info::has_ground_status() const {
-  return (_has_bits_[0] & 0x00000200u) != 0;
-}
-inline void measure_info::set_has_ground_status() {
-  _has_bits_[0] |= 0x00000200u;
-}
-inline void measure_info::clear_has_ground_status() {
-  _has_bits_[0] &= ~0x00000200u;
-}
-inline void measure_info::clear_ground_status() {
-  ground_status_ = 0;
-  clear_has_ground_status();
-}
-inline ::google::protobuf::int32 measure_info::ground_status() const {
-  // @@protoc_insertion_point(field_get:message.measure_info.ground_status)
-  return ground_status_;
-}
-inline void measure_info::set_ground_status(::google::protobuf::int32 value) {
-  set_has_ground_status();
-  ground_status_ = value;
-  // @@protoc_insertion_point(field_set:message.measure_info.ground_status)
-}
-
-// -------------------------------------------------------------------
-
 // Cloud_coordinate
 
 // required float x = 1;
@@ -4628,8 +4173,6 @@ inline void Locate_sift_response_msg::set_allocated_error_manager(::message::Err
 
 // -------------------------------------------------------------------
 
-// -------------------------------------------------------------------
-
 
 // @@protoc_insertion_point(namespace_scope)
 

+ 15 - 12
message/measure_message.proto

@@ -152,18 +152,21 @@ message Ground_status_msg
 }
 
 /*测量信息*/
-message measure_info {
-  required float cx=1;
-  required float cy=2;
-  required float theta=3;
-  required float length=4;
-  required float width=5;
-  required float height=6;
-  required float wheelbase=7;
-  required float front_theta=8;
-  required int32 border_statu=9;
-  required int32 ground_status=10; // 电子围栏状态, 0 ok, 1 nothing, 2 noise, 3 border
-}
+//20221102, huli move to message.proto
+/*
+//message measure_info {
+//  required float cx=1;
+//  required float cy=2;
+//  required float theta=3;
+//  required float length=4;
+//  required float width=5;
+//  required float height=6;
+//  required float wheelbase=7;
+//  required float front_theta=8;
+//  required int32 border_statu=9;
+//  required int32 ground_status=10; // 电子围栏状态, 0 ok, 1 nothing, 2 noise, 3 border
+//}
+*/
 
 //点云坐标
 message Cloud_coordinate

+ 149 - 0
message/message.proto

@@ -0,0 +1,149 @@
+syntax = "proto3";
+
+/*测量信息*/
+message measure_info {
+  float cx=1;
+  float cy=2;
+  float theta=3;
+  float length=4;
+  float width=5;
+  float height=6;
+  float wheelbase=7;
+  float front_theta=8;
+  int32 border_statu=9;
+  int32 ground_status=10;                   //0  ok 1,nothing 2,noise  3,border
+}
+
+/*分配的车位信息*/
+message parkspace_info{
+  int32 id=1;
+  int32 unit_id=2;  //单元号
+  int32 floor=3;    //楼层号
+  int32 room_id=4;    //同层编号
+}
+
+enum STATU{
+  eNormal=0;
+  eError=1;
+}
+
+/*
+表单执行状态
+ */
+message table_statu{
+  STATU execute_statu=1;    //执行状态
+  string statu_description=2; //状态描述
+}
+
+/*
+停车表单
+ */
+message park_table{
+  table_statu statu=1;  //表单状态
+  int32 queue_id=2;        //指令排队编号
+
+  string car_number=3;
+  int32 unit_id=4;
+  int32 terminal_id=5;
+  string primary_key=6;
+
+  measure_info entrance_measure_info=7;   //入口测量信息
+
+
+  parkspace_info allocated_space_info=8;       //分配的车位信息
+
+  measure_info actually_measure_info=9;   //实际测量信息或者叫二次测量信息
+
+  parkspace_info actually_space_info=10;      //实际停放的车位
+
+
+}
+
+/*
+取车表单
+ */
+message pick_table{
+  table_statu statu=1;  //表单状态
+  int32 queue_id=2;        //指令排队编号
+
+  string car_number=3;
+  int32 unit_id=4;
+  int32 terminal_id=5;
+  string primary_key=6;
+
+  parkspace_info actually_space_info=7; //实际停放的车位信息
+
+  measure_info actually_measure_info=8; //存车时的实际测量信息(轴距)
+
+  int32 export_id=9;            //分配出口
+  bool  is_leaved=10;         //是否离开
+
+
+}
+
+
+
+/*
+以下是状态消息
+ */
+
+/*
+单片机节点状态
+ */
+message out_mcpu_statu{     //数值+1后
+  int32 door_statu=1;       //外门状态       0无效, 1无效, 2开到位, 3 关到位, 4开关中, 5 故障
+  int32 outside_safety=2;    //是否有车      0无效, 1无车, 2有车
+}
+
+message in_mcpu_statu{      //数值+1后
+  int32 door_statu=1;       //外门状态       0无效, 1无效, 2开到位, 3 关到位, 4开关中, 5 故障
+  int32 back_io=2;          //后超界       0无效, 1后超界, 2正常
+  int32 is_occupy=3;        //是否有车      0无效, 1无车, 2有车
+  int32 heighth=4;          //车高状态      0无效, 1无效, 2小车, 3中车, 4大车, 5故障, 6故障
+}
+/*
+测量节点状态
+ */
+message measure_statu{
+  measure_info info=1;
+}
+
+//搬运器状态枚举
+enum CarrierStatu{
+  eIdle=0;
+  eBusy=1;
+  eFault=2;
+}
+
+//调度入口汽车范围的修正信息
+message dispatch_region_info
+{
+    int32 terminal_id=1;                //入口终端编号, 1~6
+    float turnplate_angle_min=2;        //转盘角度最小值, 负值, 例如 -5度
+    float turnplate_angle_max=3;        //转盘角度最大值, 正值, 例如 +5度
+}
+
+/*
+搬运器状态消息
+ */
+message dispatch_node_statu{
+  CarrierStatu statu=1;
+  int32 idle_stop_floor=2;  //空闲时停留位置
+  park_table  running_pack_info=3;  //正在执行的停车表单
+  pick_table  running_pick_info=4;  //正在执行的取车表单
+
+    int32                                   unit_id = 5;                            //单元号, 1~3
+    int32                                   plc_heartbeat = 6;                      //plc心跳信息
+    int32                                   plc_status_info = 7;                    //plc状态的集合
+                                                                                    		//0 bit, 手动模式
+                                                                                    		//1 bit, 自动模式
+                                                                                    		//2 bit, 自动运行中
+                                                                                    		//3 bit, 复位
+                                                                                    		//4 bit, 1号口可以进车
+                                                                                    		//5 bit, 2号口可以进车
+                                                                                    		//6 bit, 预留
+                                                                                    		//7 bit, 预留
+    repeated dispatch_region_info           dispatch_region_info_vector = 8;        //调度入口汽车范围的修正信息
+
+}
+

+ 6 - 4
rabbitmq/rabbitmq.proto

@@ -29,14 +29,16 @@ message Rabbitmq_channel_queue_consume
                                                             //1表示消息被消费者接受后,就自动删除消息, 当接收端断连后,队列也会删除,
                                                             //0表示消息被消费者接受后,不会自动删除消息, 需要手动ack才会删除消息, 队列不会删除
                                                             //一般情况下设为0,然后让接受者手动删除.
+     optional int32 queue_meassage_ttl = 11[default = 0];   //队列配置的扩展参数, x-message-ttl 队列接受消息 的超时时间 (单位毫秒)
+                                                            //默认写0, 不配置超时, 一般在状态消息的临时队列写入1000ms
 
 
-    optional string consume_name = 11;                       //消费者名称,必写, 不能相同
-    optional int32 consume_no_local = 12[default = 0];      //是否非本地, 默认0,表示本地
-    optional int32 consume_no_ack = 13[default = 0];        //是否确认应答,默认0,表示接收后需要应答
+    optional string consume_name = 12;                       //消费者名称,必写, 不能相同
+    optional int32 consume_no_local = 13[default = 0];      //是否非本地, 默认0,表示本地
+    optional int32 consume_no_ack = 14[default = 0];        //是否确认应答,默认0,表示接收后需要应答
                                                             //请求消息必须写0, 必须应答之后才能接受下一条
                                                             //状态消息必须写1, 可以无限循环接受,收到的瞬间,服务器就会删除这一条消息
-    optional int32 consume_exclusive = 14;                  //是否独立,默认0
+    optional int32 consume_exclusive = 15;                  //是否独立,默认0
 
 }
 

+ 65 - 37
rabbitmq/rabbitmq_base.cpp

@@ -1,5 +1,6 @@
 
 #include "rabbitmq_base.h"
+#include "../tool/time_tool.h"
 
 Rabbitmq_base::Rabbitmq_base()
 {
@@ -94,7 +95,7 @@ Error_manager Rabbitmq_base::rabbitmq_init_from_protobuf(Rabbitmq_proto::Rabbitm
 	if ( t_status != AMQP_STATUS_OK )
 	{
 		return Error_manager(Error_code::RABBITMQ_AMQP_SOCKET_OPEN_ERROR, Error_level::MINOR_ERROR,
-							 amqp_error_to_string(t_status, "amqp_socket_open").c_str() );
+							 amqp_error_to_string(t_status, "amqp_socket_open") );
 	}
 
 	//amqp_login() 登录代理服务器,
@@ -114,7 +115,7 @@ Error_manager Rabbitmq_base::rabbitmq_init_from_protobuf(Rabbitmq_proto::Rabbitm
 	if ( t_reply.reply_type != AMQP_RESPONSE_NORMAL )
 	{
 		return Error_manager(Error_code::RABBITMQ_AMQP_LOGIN_ERROR, Error_level::MINOR_ERROR,
-							 amqp_error_to_string(t_reply, "amqp_login").c_str() );
+							 amqp_error_to_string(t_reply, "amqp_login") );
 	}
 
 	//清除channel_map, 通道的缓存,防止重复开启, (channel允许重复使用, 但是不能重复初始化)
@@ -122,7 +123,6 @@ Error_manager Rabbitmq_base::rabbitmq_init_from_protobuf(Rabbitmq_proto::Rabbitm
 
 	//创建通道队列消费者, (交换机和永久队列不在代码里创建,请在服务器上手动创建)
 	t_error = rabbitmq_new_channel_queue_consume(rabbitmq_parameter_all);
-	std::cout<<"rabbitmq config: "<<rabbitmq_parameter_all.DebugString()<<std::endl;
 	if ( t_error != Error_code::SUCCESS )
 	{
 		return t_error;
@@ -161,7 +161,7 @@ Error_manager Rabbitmq_base::rabbitmq_new_channel_queue_consume(Rabbitmq_proto::
 			if ( t_reply.reply_type != AMQP_RESPONSE_NORMAL )
 			{
 				return Error_manager(Error_code::RABBITMQ_AMQP_CHANNEL_OPEN_ERROR, Error_level::MINOR_ERROR,
-									 amqp_error_to_string(t_reply, "amqp_channel_open").c_str() );
+									 amqp_error_to_string(t_reply, "amqp_channel_open") );
 			}
 			if ( t_inf.consume_no_ack() == 0 )
 			{
@@ -178,22 +178,55 @@ Error_manager Rabbitmq_base::rabbitmq_new_channel_queue_consume(Rabbitmq_proto::
 		//临时队列需要代码创建, 永久队列需要在服务器上提前手动创建
 		if ( t_inf.queue_durable() == 0 )
 		{
-			//amqp_queue_declare() 队列声明, 就是创建新的队列.
-			//输入 amqp_connection_state_t state 连接状态参数的结构体
-			//输入 amqp_channel_t channel 连接通道的编号
-			//输入 amqp_bytes_t queue 队列名称,可以手动命名,如果写空,系统就会自动分配, 手动写amqp_cstring_bytes("abcdefg"), 默认空 amqp_empty_bytes
-			//输入 amqp_boolean_t passive 是否被动,默认0
-			//输入 amqp_boolean_t durable 是否持久,默认0, 节点代码可以创建临时队列(所有权归节点), 服务器手动创建永久队列(所有权归服务器)
-			//		1表示永久队列,当节点死掉,队列在服务器保留,仍然可以接受数据,节点上线后,可以接受掉线期间的所有数据
-			//		0表示临时队列,当节点死掉,队列消失,不再接受数据,直到下次恢复正常
-			//输入 amqp_boolean_t exclusive 是否独立,默认0
-			//输入 amqp_boolean_t auto_delete 是否自动删除,默认0, 1表示消息被消费者接受后,就自动删除消息, 当接收端断连后,队列也会才删除,
-			// 													一般情况下设为0,然后让接受者手动删除.
-			//输入 amqp_table_t arguments 预留参数,默认空 amqp_empty_table
-			//返回 amqp_queue_declare_ok_t *	返回结果
-			amqp_queue_declare(mp_connect, t_inf.channel(), amqp_cstring_bytes(t_inf.queue_name().c_str()),
-							   t_inf.queue_passive(), t_inf.queue_durable(), t_inf.queue_exclusive(),
-							   t_inf.queue_auto_delete(), amqp_empty_table);
+			//目前只填充超时时间,  x-message-ttl 队列接受消息 的超时时间 (单位毫秒)
+			if ( t_inf.queue_meassage_ttl() != 0 )
+			{
+				amqp_table_t t_arguments;		//队列的扩展属性 num_entries 是map长度, amqp_table_entry_t_ 是map指针
+				//目前只填充超时时间,  x-message-ttl 队列接受消息 的超时时间 (单位毫秒)
+				t_arguments.num_entries = 1;
+				amqp_table_entry_t_ t_map_arg;
+				t_map_arg.key = amqp_cstring_bytes("x-message-ttl");		//需要配置的参数
+				t_map_arg.value.kind = AMQP_FIELD_KIND_U16;								//需要配置的数据类型, 如果是字符串, 写 AMQP_FIELD_KIND_UTF8
+				t_map_arg.value.value.u16 = t_inf.queue_meassage_ttl();					//需要配置的数值
+				t_arguments.entries = &t_map_arg;
+
+				//amqp_queue_declare() 队列声明, 就是创建新的队列.
+				//输入 amqp_connection_state_t state 连接状态参数的结构体
+				//输入 amqp_channel_t channel 连接通道的编号
+				//输入 amqp_bytes_t queue 队列名称,可以手动命名,如果写空,系统就会自动分配, 手动写amqp_cstring_bytes("abcdefg"), 默认空 amqp_empty_bytes
+				//输入 amqp_boolean_t passive 是否被动,默认0
+				//输入 amqp_boolean_t durable 是否持久,默认0, 节点代码可以创建临时队列(所有权归节点), 服务器手动创建永久队列(所有权归服务器)
+				//		1表示永久队列,当节点死掉,队列在服务器保留,仍然可以接受数据,节点上线后,可以接受掉线期间的所有数据
+				//		0表示临时队列,当节点死掉,队列消失,不再接受数据,直到下次恢复正常
+				//输入 amqp_boolean_t exclusive 是否独立,默认0
+				//输入 amqp_boolean_t auto_delete 是否自动删除,默认0, 1表示消息被消费者接受后,就自动删除消息, 当接收端断连后,队列也会才删除,
+				// 													一般情况下设为0,然后让接受者手动删除.
+				//输入 amqp_table_t arguments 预留参数,默认空 amqp_empty_table
+				//返回 amqp_queue_declare_ok_t *	返回结果
+				amqp_queue_declare(mp_connect, t_inf.channel(), amqp_cstring_bytes(t_inf.queue_name().c_str()),
+								   t_inf.queue_passive(), t_inf.queue_durable(), t_inf.queue_exclusive(),
+								   t_inf.queue_auto_delete(), t_arguments);
+			}
+			else
+			{
+				//amqp_queue_declare() 队列声明, 就是创建新的队列.
+				//输入 amqp_connection_state_t state 连接状态参数的结构体
+				//输入 amqp_channel_t channel 连接通道的编号
+				//输入 amqp_bytes_t queue 队列名称,可以手动命名,如果写空,系统就会自动分配, 手动写amqp_cstring_bytes("abcdefg"), 默认空 amqp_empty_bytes
+				//输入 amqp_boolean_t passive 是否被动,默认0
+				//输入 amqp_boolean_t durable 是否持久,默认0, 节点代码可以创建临时队列(所有权归节点), 服务器手动创建永久队列(所有权归服务器)
+				//		1表示永久队列,当节点死掉,队列在服务器保留,仍然可以接受数据,节点上线后,可以接受掉线期间的所有数据
+				//		0表示临时队列,当节点死掉,队列消失,不再接受数据,直到下次恢复正常
+				//输入 amqp_boolean_t exclusive 是否独立,默认0
+				//输入 amqp_boolean_t auto_delete 是否自动删除,默认0, 1表示消息被消费者接受后,就自动删除消息, 当接收端断连后,队列也会才删除,
+				// 													一般情况下设为0,然后让接受者手动删除.
+				//输入 amqp_table_t arguments 预留参数,默认空 amqp_empty_table
+				//返回 amqp_queue_declare_ok_t *	返回结果
+				amqp_queue_declare(mp_connect, t_inf.channel(), amqp_cstring_bytes(t_inf.queue_name().c_str()),
+								   t_inf.queue_passive(), t_inf.queue_durable(), t_inf.queue_exclusive(),
+								   t_inf.queue_auto_delete(), amqp_empty_table);
+			}
+
 
 			//amqp_queue_bind 队列绑定, 将队列加载到服务器的交换机下面, 交换机收到消息后,就会检查key,然后放到指定的队列.
 			//输入 amqp_connection_state_t state 连接状态参数的结构体
@@ -212,7 +245,7 @@ Error_manager Rabbitmq_base::rabbitmq_new_channel_queue_consume(Rabbitmq_proto::
 			if ( t_reply.reply_type != AMQP_RESPONSE_NORMAL )
 			{
 				return Error_manager(Error_code::RABBITMQ_AMQP_QUEUE_BIND_ERROR, Error_level::MINOR_ERROR,
-									 amqp_error_to_string(t_reply, "amqp_queue_bind").c_str() );
+									 amqp_error_to_string(t_reply, "amqp_queue_bind") );
 			}
 		}
 
@@ -234,7 +267,7 @@ Error_manager Rabbitmq_base::rabbitmq_new_channel_queue_consume(Rabbitmq_proto::
 		if ( t_reply.reply_type != AMQP_RESPONSE_NORMAL )
 		{
 			return Error_manager(Error_code::RABBITMQ_AMQP_NEW_CONSUME_ERROR, Error_level::MINOR_ERROR,
-								 amqp_error_to_string(t_reply, "amqp_basic_consume").c_str() );
+								 amqp_error_to_string(t_reply, "amqp_basic_consume") );
 		}
 	}
 
@@ -255,7 +288,7 @@ Error_manager Rabbitmq_base::rabbitmq_new_channel_queue_consume(Rabbitmq_proto::
 			if ( t_reply.reply_type != AMQP_RESPONSE_NORMAL )
 			{
 				return Error_manager(Error_code::RABBITMQ_AMQP_CHANNEL_OPEN_ERROR, Error_level::MINOR_ERROR,
-									 amqp_error_to_string(t_reply, "amqp_channel_open").c_str() );
+									 amqp_error_to_string(t_reply, "amqp_channel_open") );
 			}
 			m_channel_map[t_inf1.channel()] = true;
 		}
@@ -278,7 +311,7 @@ Error_manager Rabbitmq_base::rabbitmq_new_channel_queue_consume(Rabbitmq_proto::
 			if ( t_reply.reply_type != AMQP_RESPONSE_NORMAL )
 			{
 				return Error_manager(Error_code::RABBITMQ_AMQP_CHANNEL_OPEN_ERROR, Error_level::MINOR_ERROR,
-									 amqp_error_to_string(t_reply, "amqp_channel_open").c_str() );
+									 amqp_error_to_string(t_reply, "amqp_channel_open") );
 			}
 			m_channel_map[t_inf2.channel()] = true;
 		}
@@ -429,7 +462,7 @@ Error_manager Rabbitmq_base::rabbitmq_reconnnect()
 	if ( t_status != AMQP_STATUS_OK )
 	{
 		return Error_manager(Error_code::RABBITMQ_AMQP_SOCKET_OPEN_ERROR, Error_level::MINOR_ERROR,
-							 amqp_error_to_string(t_status, "amqp_socket_open").c_str() );
+							 amqp_error_to_string(t_status, "amqp_socket_open") );
 	}
 
 	//amqp_login() 登录代理服务器,
@@ -449,7 +482,7 @@ Error_manager Rabbitmq_base::rabbitmq_reconnnect()
 	if ( t_reply.reply_type != AMQP_RESPONSE_NORMAL )
 	{
 		return Error_manager(Error_code::RABBITMQ_AMQP_LOGIN_ERROR, Error_level::MINOR_ERROR,
-							 amqp_error_to_string(t_reply, "amqp_login").c_str() );
+							 amqp_error_to_string(t_reply, "amqp_login") );
 	}
 
 	//清除channel_map, 通道的缓存,防止重复开启, (channel允许重复使用, 但是不能重复初始化)
@@ -507,7 +540,8 @@ void Rabbitmq_base::receive_analysis_thread()
 		m_receive_analysis_condition.wait();
 		if ( m_receive_analysis_condition.is_alive() )
 		{
-			std::this_thread::yield();
+            std::this_thread::sleep_for(std::chrono::microseconds(100));
+            std::this_thread::yield();
 
 			amqp_rpc_reply_t t_reply;		//运行结果
 			amqp_envelope_t t_envelope;		//数据包, 含有一些包裹属性和数据内容
@@ -537,6 +571,8 @@ void Rabbitmq_base::receive_analysis_thread()
 
 			if ( AMQP_RESPONSE_NORMAL == t_reply.reply_type )//正常接受到消息
 			{
+
+
 				m_rabbitmq_status = RABBITMQ_STATUS_READY;
 				//从t_envelope数据包里面提取信息
 				std::string t_receive_string = std::string((char*)t_envelope.message.body.bytes, t_envelope.message.body.len);
@@ -564,7 +600,7 @@ void Rabbitmq_base::receive_analysis_thread()
 							//处理消息
 							if ( execute_msg(&t_rabbitmq_message) == SUCCESS )
 							{
-								//...............
+
 							}
 							//else不做处理
 						}
@@ -675,7 +711,7 @@ Error_manager Rabbitmq_base::ack_msg(Rabbitmq_message* p_msg)
 	if ( ack_result != 0 )
 	{
 		return Error_manager(Error_code::RABBITMQ_AMQP_BASIC_ACK_ERROR, Error_level::MINOR_ERROR,
-							 amqp_error_to_string(ack_result, "amqp_basic_ack").c_str() );
+							 amqp_error_to_string(ack_result, "amqp_basic_ack") );
 	}
 	return Error_code::SUCCESS;
 }
@@ -849,14 +885,6 @@ Error_manager Rabbitmq_base::encapsulate_task_msg(std::string message, int vecto
 //手动封装状态消息, 系统会使用rabbitmq.proto的配置参数,
 Error_manager Rabbitmq_base::encapsulate_status_msg(std::string message, int vector_index)
 {
-	if(m_rabbitmq_parameter_all.rabbitmq_parameters().rabbitmq_sender_status_vector_size() <= vector_index)
-	{
-		std::cout<<"msg vector size error: "<<m_rabbitmq_parameter_all.rabbitmq_parameters().rabbitmq_sender_status_vector_size()<<std::endl;
-		return Error_manager(Error_code::PARAMETER_ERROR, Error_level::MINOR_ERROR,
-							 (std::string(" Communication_socket_base::encapsulate_msg vector index limit ")
-							 +std::to_string(m_rabbitmq_parameter_all.rabbitmq_parameters().rabbitmq_sender_status_vector_size())).c_str());
-	}
-
 	int channel = m_rabbitmq_parameter_all.rabbitmq_parameters().rabbitmq_sender_status_vector(vector_index).channel();
 	std::string exchange_name = m_rabbitmq_parameter_all.rabbitmq_parameters().rabbitmq_sender_status_vector(vector_index).exchange_name();
 	std::string routing_key = m_rabbitmq_parameter_all.rabbitmq_parameters().rabbitmq_sender_status_vector(vector_index).routing_key();

+ 1 - 1
rabbitmq/rabbitmq_base.h

@@ -33,7 +33,7 @@
 //#else
 //#include <sys/time.h>
 //#endif
-#include <string>
+
 #include <rabbitmq-c/amqp.h>
 #include <rabbitmq-c/tcp_socket.h>
 #include <assert.h>

+ 79 - 0
rabbitmq/胡力的rabbitmq-c说明文档.md

@@ -0,0 +1,79 @@
+
+
+安装 rabbitMQ-c 的注意事项:(这里只介绍C语言版本的客户端)
+
+1.代码下载
+	rabbitMQ官网 		https://www.rabbitmq.com/
+	各种语言支持			https://www.rabbitmq.com/devtools.html
+		里面有C/C++的支持
+	github上源码			https://github.com/alanxz/rabbitmq-c
+
+2.安装方式
+	终端指令:注意了,要用sudo使用管理员权限
+	git clone https://github.com/alanxz/rabbitmq-c  
+	cd rabbitmq-c
+	mkdir build
+	cd build
+	sudo cmake ..
+	sudo cmake --build .
+	sudo make 
+	sudo make install
+
+	详情参考		https://blog.csdn.net/caicaiatnbu/article/details/98099779?ops_request_misc=&request_id=&biz_id=102&utm_term=RabbitMQ-C&utm_medium=distribute.pc_search_result.none-task-blog-2~all~sobaiduweb~default-3-98099779.nonecase&spm=1018.2226.3001.4187
+
+	如果提示openssl有报错,卸载并重装openssl
+	详情参考		https://blog.csdn.net/Cai181191/article/details/120648055?ops_request_misc=&request_id=&biz_id=102&utm_term=%E5%8D%B8%E8%BD%BDopenssl&utm_medium=distribute.pc_search_result.none-task-blog-2~all~sobaiduweb~default-1-120648055.142^v41^pc_rank_34,185^v2^control&spm=1018.2226.3001.4187
+
+3.examples代码编译
+	方案一:不建议
+	打开		./rabbitmq-c/CMakeLists.txt
+		找到		option(BUILD_EXAMPLES "Build Examples" OFF)
+		修改为	option(BUILD_EXAMPLES "Build Examples" ON)
+	然后重新编译 ./rabbitmq-c/CMakeLists.txt  就是把上面第二步再做一遍
+		cd ./rabbitmq-c/build
+		sudo cmake ..
+		sudo cmake --build .
+		sudo make 
+	然后就可以看到	./rabbitmq-c/build/examples 路径下面出现了样例的执行文件
+
+	方案二:强烈推荐
+	进入		./rabbitmq-c/examples 文件夹	,后面的操作都在这个文件夹里面
+	打开		./rabbitmq-c/examples/CMakeLists.txt
+	全局替换		rabbitmq::rabbitmq   改为	rabbitmq
+	就是删除 rabbitmq::
+	然后 编译 ./rabbitmq-c/examples/CMakeLists.txt
+		cd ./rabbitmq-c/examples/
+		mkdir build
+		cd build
+		cmake ..
+		make 
+	然后就可以看到	./rabbitmq-c/examples/build 路径下面出现了样例的执行文件
+
+4.自己开发rabbitMQ-c代码
+	在自己的  CMakeLists.txt  里面 增加系统头文件和库文件的目录.
+	例如:
+		include_directories(
+        /usr/local/include
+		)
+		link_directories("/usr/local/lib")
+
+	在自己的  CMakeLists.txt  里面 target_link_libraries 追加 rabbitmq
+	例如:	
+		target_link_libraries(xxx工程名		rabbitmq )
+
+	具体的函数使用,参考examples里面的amqp_listen.c和amqp_sendstring.c
+
+5.服务器网站配置
+	登录服务器   http://127.0.0.1:15672/     或者     http://192.168.2.39:15672/
+		默认账号密码   guest   guest    (注, guest只能本机访问,其他电脑需要新建账户)
+	
+	终端指令: 使用sudo
+		创建用户 rabbitmqctl add_user admin admin
+		设置管理员 rabbitmqctl set_user_tags admin administrator
+		设置权限  rabbitmqctl set_permissions -p/admin ".*"".*"".*"
+		查看用户  rabbitmqctl list_users
+		详见  https://blog.csdn.net/z446981439/article/details/103634524?ops_request_misc=%257B%2522request%255Fid%2522%253A%2522166141324016782388032414%2522%252C%2522scm%2522%253A%252220140713.130102334..%2522%257D&request_id=166141324016782388032414&biz_id=0&utm_medium=distribute.pc_search_result.none-task-blog-2~all~sobaiduend~default-2-103634524-null-null.142^v42^pc_rank_34,185^v2^control&utm_term=rabbitmq%20%E7%94%A8%E6%88%B7&spm=1018.2226.3001.4187
+
+		个人建议:只在终端上创建账户,然后使用guest在网站上面配置权限.
+	
+	

+ 109 - 0
setting/rabbitmq (copy).prototxt

@@ -0,0 +1,109 @@
+
+
+rabbitmq_parameters
+{
+    ip:"192.168.1.233"
+    port:5672
+    user:"zx"
+    password:"zx123456"
+
+    rabbitmq_reciever_vector
+    {
+       channel:401
+       exchange_name:"statu_ex"
+
+       binding_key:"dispatch_1_statu_port"
+       queue_name:"dispatch_1_statu_queue_for_measure"
+       queue_passive:0
+       queue_durable:0
+       queue_exclusive:0
+       queue_auto_delete:1
+       queue_meassage_ttl:1000
+       consume_name:"dispatch_1_statu_consume_for_measure"
+       consume_no_local:0
+       consume_no_ack:1
+       consume_exclusive:0
+    }
+
+    rabbitmq_reciever_vector
+    {
+       channel:402
+       exchange_name:"statu_ex"
+
+       binding_key:"dispatch_2_statu_port"
+       queue_name:"dispatch_2_statu_queue_for_measure"
+       queue_passive:0
+       queue_durable:0
+       queue_exclusive:0
+       queue_auto_delete:1
+       queue_meassage_ttl:1000
+       consume_name:"dispatch_2_statu_consume_for_measure"
+       consume_no_local:0
+       consume_no_ack:1
+       consume_exclusive:0
+    }
+
+    rabbitmq_reciever_vector
+    {
+       channel:403
+       exchange_name:"statu_ex"
+
+       binding_key:"dispatch_3_statu_port"
+       queue_name:"dispatch_3_statu_queue_for_measure"
+       queue_passive:0
+       queue_durable:0
+       queue_exclusive:0
+       queue_auto_delete:1
+       queue_meassage_ttl:1000
+       consume_name:"dispatch_3_statu_consume_for_measure"
+       consume_no_local:0
+       consume_no_ack:1
+       consume_exclusive:0
+    }
+
+
+
+    rabbitmq_sender_status_vector
+    {
+        channel:411
+        exchange_name:"statu_ex"
+        routing_key:"measure_1_statu_port"
+        timeout_ms:0
+    }
+    rabbitmq_sender_status_vector
+    {
+        channel:411
+        exchange_name:"statu_ex"
+        routing_key:"measure_2_statu_port"
+        timeout_ms:0
+    }
+    rabbitmq_sender_status_vector
+    {
+        channel:411
+        exchange_name:"statu_ex"
+        routing_key:"measure_3_statu_port"
+        timeout_ms:0
+    }
+    rabbitmq_sender_status_vector
+    {
+        channel:411
+        exchange_name:"statu_ex"
+        routing_key:"measure_4_statu_port"
+        timeout_ms:0
+    }
+    rabbitmq_sender_status_vector
+    {
+        channel:411
+        exchange_name:"statu_ex"
+        routing_key:"measure_5_statu_port"
+        timeout_ms:0
+    }
+    rabbitmq_sender_status_vector
+    {
+        channel:411
+        exchange_name:"statu_ex"
+        routing_key:"measure_6_statu_port"
+        timeout_ms:0
+    }
+}
+

+ 50 - 30
setting/rabbitmq.prototxt

@@ -7,41 +7,61 @@ rabbitmq_parameters
     user:"zx"
     password:"zx123456"
 
+    rabbitmq_reciever_vector
+    {
+       channel:401
+       exchange_name:"statu_ex"
+
+       binding_key:"dispatch_1_statu_port"
+       queue_name:"dispatch_1_statu_queue_for_measure"
+       queue_passive:0
+       queue_durable:0
+       queue_exclusive:0
+       queue_auto_delete:1
+       queue_meassage_ttl:1000
+       consume_name:"dispatch_1_statu_consume_for_measure"
+       consume_no_local:0
+       consume_no_ack:1
+       consume_exclusive:0
+    }
+
+    rabbitmq_reciever_vector
+    {
+       channel:402
+       exchange_name:"statu_ex"
 
-#    rabbitmq_reciever_vector
-#     {
-#         channel:401
-#         exchange_name:"command_ex"
+       binding_key:"dispatch_2_statu_port"
+       queue_name:"dispatch_2_statu_queue_for_measure"
+       queue_passive:0
+       queue_durable:0
+       queue_exclusive:0
+       queue_auto_delete:1
+       queue_meassage_ttl:1000
+       consume_name:"dispatch_2_statu_consume_for_measure"
+       consume_no_local:0
+       consume_no_ack:1
+       consume_exclusive:0
+    }
 
-#         binding_key:"count_command_signal_1_port"
-#         queue_name:"count_command_signal_1_queue"
-#         queue_passive:0
-#         queue_durable:1
-#         queue_exclusive:0
-#         queue_auto_delete:0
-#         consume_name:"count_command_signal_1_consume"
-#         consume_no_local:0
-#         consume_no_ack:0
-#         consume_exclusive:0
-#     }
+    rabbitmq_reciever_vector
+    {
+       channel:403
+       exchange_name:"statu_ex"
 
+       binding_key:"dispatch_3_statu_port"
+       queue_name:"dispatch_3_statu_queue_for_measure"
+       queue_passive:0
+       queue_durable:0
+       queue_exclusive:0
+       queue_auto_delete:1
+       queue_meassage_ttl:1000
+       consume_name:"dispatch_3_statu_consume_for_measure"
+       consume_no_local:0
+       consume_no_ack:1
+       consume_exclusive:0
+    }
 
-#     rabbitmq_reciever_vector
-#     {
-#         channel:402
-#         exchange_name:"command_ex"
 
-#         binding_key:"post_command_1_port"
-#         queue_name:"post_command_1_queue"
-#         queue_passive:0
-#         queue_durable:1
-#         queue_exclusive:0
-#         queue_auto_delete:0
-#         consume_name:"post_command_1_consume"
-#         consume_no_local:0
-#         consume_no_ack:0
-#         consume_exclusive:0
-#     }
 
     rabbitmq_sender_status_vector
     {

+ 478 - 0
setting/velodyne_manager (copy).prototxt

@@ -0,0 +1,478 @@
+fence_data_path:"/home/zx/data/ground_detect/"
+#fence_log_path:"/home/zx/yct/MainStructure/new_electronic_fence/log"
+left_model_path:"/home/zx/yct/chutian_measure_2021/setting/left_model.txt"
+right_model_path:"/home/zx/yct/chutian_measure_2021/setting/right_model.txt"
+distribution_mode:false
+
+#-----------------------------------lidars, id 0-6 from A1-C2
+
+ # 6 lidar 192.168.1.201
+velodyne_lidars
+{
+    ip:""
+    port:2368
+    model:"VLP16"
+    calibrationFile:"../setting/VLP16db.yaml"
+    lidar_id:6
+    max_range:8.0
+    min_range:0.1
+    min_angle:0
+    max_angle:360
+    rpm:600
+    calib
+    {
+         r:-0.276397
+         p:-0.11717
+         y:88.703  #89.6003
+         cz:0.05467
+        #r:-0.623165
+        #p:0.601821
+        #y:87.0198
+        #cz:0.101527
+    }
+}
+
+# 5 lidar 192.168.1.202
+velodyne_lidars
+{
+    ip:""
+    port:2369
+    model:"VLP16"
+    calibrationFile:"../setting/VLP16db.yaml"
+    lidar_id:5
+    max_range:8.0
+    min_range:0.1
+    min_angle:0
+    max_angle:360
+    rpm:600
+    calib
+    {
+        r:-0.202484
+        p:-0.106456
+        y:88.58717
+        cz:0.071634
+        #r:0.462994
+        #p:1.29624
+        #y:96.0048
+        #cz:0.09496
+    }
+}
+
+# 4 lidar 192.168.1.203
+velodyne_lidars
+{
+    ip:""
+    port:2370
+    model:"VLP16"
+    calibrationFile:"../setting/VLP16db.yaml"
+    lidar_id:4
+    max_range:8.0
+    min_range:0.1
+    min_angle:0
+    max_angle:360
+    rpm:600
+    calib
+    {
+        r:-0.038115
+        p:-0.577136
+        y:91.2659
+        cz:0.06
+    }
+}
+
+# 3 lidar 192.168.1.204
+velodyne_lidars
+{
+    ip:""
+    port:2371
+    model:"VLP16"
+    calibrationFile:"../setting/VLP16db.yaml"
+    lidar_id:3
+    max_range:8.0
+    min_range:0.1
+    min_angle:0
+    max_angle:360
+    rpm:600
+    calib
+    {
+        r:-0.06283
+        p:0.48588
+        y:91.4077
+        cz:0.071
+    }
+}
+
+# 2 lidar 192.168.1.205
+velodyne_lidars
+{
+    ip:""
+    port:2372
+    model:"VLP16"
+    calibrationFile:"../setting/VLP16db.yaml"
+    lidar_id:2
+    max_range:8.0
+    min_range:0.1
+    min_angle:0
+    max_angle:360
+    rpm:600
+    calib
+    {
+        r:-0.1073
+        p:0.65674
+        y:86.3796
+        cz:0.04
+    }
+}
+
+# 1 lidar 192.168.1.206
+velodyne_lidars
+{
+    ip:""
+    port:2373
+    model:"VLP16"
+    calibrationFile:"../setting/VLP16db.yaml"
+    lidar_id:1
+    max_range:8.0
+    min_range:0.1
+    min_angle:0
+    max_angle:360
+    rpm:600
+    calib
+    {
+        r:-0.01438
+        p:0.108841
+        y:91.3879
+        cz:0.0686
+    }
+}
+
+# 0 lidar 192.168.1.207
+# p:0.68354 - 0.4092
+velodyne_lidars
+{
+    ip:""
+    port:2374
+    model:"VLP16"
+    calibrationFile:"../setting/VLP16db.yaml"
+    lidar_id:0
+    max_range:8.0
+    min_range:0.1
+    min_angle:0
+    max_angle:360
+    rpm:600
+    calib
+    {
+        r:0.03026
+        # p:0.68354
+        p:0
+        y:90.6538
+        cz:0.07697
+    }
+}
+
+#-----------------------------------regions, 0-5 from A1 to C2
+
+# 5 region
+region
+{
+    minx:-1.6
+	maxx:1.6
+	miny:-2.6
+	maxy:2.6
+	minz:0.025
+	maxz:0.5
+    region_id:5
+    turnplate_cx:0.0
+    turnplate_cy:0.0
+    border_minx:-1.2
+    border_maxx:1.2
+    plc_offsetx:1.913
+    plc_offsety:-6.078
+    plc_offset_degree:-89.5
+    plc_border_miny:1.2
+    plc_border_maxy:1.28
+    car_min_width:1.55
+    car_max_width:1.92
+    car_min_wheelbase:2.3
+    car_max_wheelbase:3.15
+    turnplate_angle_limit_anti_clockwise:5.3
+    turnplate_angle_limit_clockwise:5.3
+
+    lidar_exts
+    {
+        lidar_id:6
+        calib
+        {
+            cx:1.89004
+            cy:0
+        }
+    }
+    lidar_exts
+    {
+        lidar_id:5
+        calib
+        {
+            #cx:-4.021775
+            #cy:-0.039429
+            cx:-1.89004
+            cy:0
+        }
+    }
+}
+
+# 4 region
+# 利用共用雷达标定plc偏移量
+# plc_4 = plc_5 + calib5in5 - calib5in4
+# plc_4x = 1.913 + (-1.9018) - (1.9095) = -1.8983
+# plc_4y = 5.998 + (0.0175) - (-0.019388) = 6.03489
+# 20211209 x+(1cm)
+region
+{
+    minx:-1.42
+	maxx:1.5
+	miny:-2.6
+	maxy:2.3
+	minz:0.03
+	maxz:0.5
+    region_id:4
+    turnplate_cx:0.0
+    turnplate_cy:0.0
+    border_minx:-1.2
+    border_maxx:1.2
+    # -1.8683
+    plc_offsetx:-1.865
+    plc_offsety:-6.11489
+    plc_offset_degree:-89.5
+    plc_border_miny:1.2
+    plc_border_maxy:1.28
+    car_min_width:1.55
+    car_max_width:1.92
+    car_min_wheelbase:2.3
+    car_max_wheelbase:3.15
+    turnplate_angle_limit_anti_clockwise:5.3
+    turnplate_angle_limit_clockwise:5.3
+
+    # 4-->5: -3.81895 0.038776
+    lidar_exts
+    {
+        lidar_id:5
+        calib
+        {
+            cx:1.9095
+            cy:-0.019388
+        }
+    }
+    lidar_exts
+    {
+        lidar_id:4
+        calib
+        {
+            cx:-1.9095
+            cy:0.019388
+        }
+    }
+}
+
+# 3 region
+region
+{
+    minx:-1.3
+	maxx:1.37
+	miny:-2.6
+	maxy:2.35
+	minz:0.03
+	maxz:0.5
+    region_id:3
+    turnplate_cx:0.0
+    turnplate_cy:0.0
+    border_minx:-1.2
+    border_maxx:1.2
+    plc_offsetx:1.926
+    plc_offsety:-6.135
+    plc_offset_degree:-89.5
+    plc_border_miny:1.2
+    plc_border_maxy:1.28
+    car_min_width:1.55
+    car_max_width:1.92
+    car_min_wheelbase:2.3
+    car_max_wheelbase:3.15
+    turnplate_angle_limit_anti_clockwise:5.3
+    turnplate_angle_limit_clockwise:5.3
+
+    # 3-->4: -3.80394 (-0.01385+0.02)
+    lidar_exts
+    {
+        lidar_id:4
+        calib
+        {
+            cx:1.902
+            cy:-0.0031
+            cz:0.015
+        }
+    }
+    lidar_exts
+    {
+        lidar_id:3
+        calib
+        {
+            cx:-1.902
+            cy:0.0031
+        }
+    }
+}
+
+# 2 region
+region
+{
+    minx:-1.3
+	maxx:1.37
+	miny:-2.6
+	maxy:2.35
+	minz:0.03
+	maxz:0.5
+    region_id:2
+    turnplate_cx:0.0
+    turnplate_cy:0.0
+    border_minx:-1.2
+    border_maxx:1.2
+    # 0.02
+    plc_offsetx:-1.871
+    # -0.34
+    plc_offsety:-6.135
+    plc_offset_degree:-89.1
+    plc_border_miny:1.2
+    plc_border_maxy:1.28
+    car_min_width:1.55
+    car_max_width:1.92
+    car_min_wheelbase:2.3
+    car_max_wheelbase:3.15
+    turnplate_angle_limit_anti_clockwise:5.3
+    turnplate_angle_limit_clockwise:5.3
+
+    # 2-->3: -3.87778 (-0.052905-0.025)
+    # 20220215 宽度调整 x-0.02
+    lidar_exts
+    {
+        lidar_id:3
+        calib
+        {
+            cx:1.9289
+            cy:0.01395
+        }
+    }
+    lidar_exts
+    {
+        lidar_id:2
+        calib
+        {
+            # cx-1.9389+0.04 cy-0.01395+0.03
+            cx:-1.89
+            cy:0.016
+            cz:0.08
+            p:-1.5
+        }
+    }
+}
+
+# 1 region
+# plcx + -0.06
+region
+{
+    minx:-1.5
+	maxx:1.3
+	miny:-2.6
+	maxy:2.3
+	minz:0.032
+	maxz:0.5
+    region_id:1
+    turnplate_cx:0.0
+    turnplate_cy:0.0
+    border_minx:-1.2
+    border_maxx:1.2
+    plc_offsetx:1.93
+    plc_offsety:-6.1368  
+    plc_offset_degree:-89.5
+    plc_border_miny:1.2
+    plc_border_maxy:1.28
+    car_min_width:1.55
+    car_max_width:1.92
+    car_min_wheelbase:2.3
+    car_max_wheelbase:3.15
+    turnplate_angle_limit_anti_clockwise:5.3
+    turnplate_angle_limit_clockwise:5.3
+
+    # 2-->1: 3.82222438  -0.106852
+    # 20220215 宽度调整 x-0.04
+    lidar_exts
+    {
+        lidar_id:2
+        calib
+        {
+            cx:1.89911#1.91111219
+            cy:-0.053426
+            cz:-0.005
+            p:-1.5
+            # y:1.0
+        }
+    }
+    lidar_exts
+    {
+        lidar_id:1
+        calib
+        {
+            cx:-1.89911#-1.91111219
+            cy:0.053426
+            # p:0.5
+        }
+    }
+}
+
+# 0 region
+# center -0.03, 0.4653  --->  -1.89, -5.6415
+# pcly + -0.03
+region
+{
+    minx:-1.5
+	maxx:1.5
+	miny:-2.6
+	maxy:2.3
+	minz:0.032
+	maxz:0.5
+    region_id:0
+    turnplate_cx:0.0
+    turnplate_cy:0.0
+    border_minx:-1.2
+    border_maxx:1.2
+    plc_offsetx:-1.86
+    plc_offsety:-6.1368
+    plc_offset_degree:-89.5
+    plc_border_miny:1.2
+    plc_border_maxy:1.28
+    car_min_width:1.55
+    car_max_width:1.92
+    car_min_wheelbase:2.3
+    car_max_wheelbase:3.15
+    turnplate_angle_limit_anti_clockwise:5.3
+    turnplate_angle_limit_clockwise:5.3
+
+    # 1-->0: 3.8173811 -0.0273465
+    # 20220215 宽度调整 x-0.015
+    lidar_exts
+    {
+        lidar_id:1
+        calib
+        {
+            cx:1.9012
+            cy:-0.01367
+        }
+    }
+    lidar_exts
+    {
+        lidar_id:0
+        calib
+        {
+            cx:-1.9012
+            cy:0.01367
+        }
+    }
+}

+ 14 - 8
setting/velodyne_manager.prototxt

@@ -189,7 +189,8 @@ region
     plc_offsetx:1.913
     plc_offsety:-6.078
     plc_offset_degree:-89.5
-    plc_border_miny:-7.51
+    plc_border_miny:1.2
+    plc_border_maxy:1.28
     car_min_width:1.55
     car_max_width:1.92
     car_min_wheelbase:2.3
@@ -242,7 +243,8 @@ region
     plc_offsetx:-1.865
     plc_offsety:-6.11489
     plc_offset_degree:-89.5
-    plc_border_miny:-7.51
+    plc_border_miny:1.2
+    plc_border_maxy:1.28
     car_min_width:1.55
     car_max_width:1.92
     car_min_wheelbase:2.3
@@ -288,7 +290,8 @@ region
     plc_offsetx:1.926
     plc_offsety:-6.135
     plc_offset_degree:-89.5
-    plc_border_miny:-7.38
+    plc_border_miny:1.2
+    plc_border_maxy:1.28
     car_min_width:1.55
     car_max_width:1.92
     car_min_wheelbase:2.3
@@ -337,7 +340,8 @@ region
     # -0.34
     plc_offsety:-6.135
     plc_offset_degree:-89.1
-    plc_border_miny:-7.38
+    plc_border_miny:1.2
+    plc_border_maxy:1.28
     car_min_width:1.55
     car_max_width:1.92
     car_min_wheelbase:2.3
@@ -386,9 +390,10 @@ region
     border_minx:-1.2
     border_maxx:1.2
     plc_offsetx:1.93
-    plc_offsety:-6.1368  
+    plc_offsety:-6.1368
     plc_offset_degree:-89.5
-    plc_border_miny:-7.45
+    plc_border_miny:1.2
+    plc_border_maxy:1.28
     car_min_width:1.55
     car_max_width:1.92
     car_min_wheelbase:2.3
@@ -441,7 +446,8 @@ region
     plc_offsetx:-1.86
     plc_offsety:-6.1368
     plc_offset_degree:-89.5
-    plc_border_miny:-7.45
+    plc_border_miny:1.2
+    plc_border_maxy:1.28
     car_min_width:1.55
     car_max_width:1.92
     car_min_wheelbase:2.3
@@ -469,4 +475,4 @@ region
             cy:0.01367
         }
     }
-}
+}

+ 45 - 2
system/system_communication mq.cpp

@@ -15,7 +15,15 @@
 
 System_communication_mq::System_communication_mq()
 {
-
+    //1~6
+    for (int j = 1; j < 7; ++j)
+    {
+        dispatch_region_info t_dispatch_region_info;
+        t_dispatch_region_info.set_terminal_id(j);
+        t_dispatch_region_info.set_turnplate_angle_min(0);
+        t_dispatch_region_info.set_turnplate_angle_max(0);
+        dispatch_region_info_map[j] = t_dispatch_region_info;
+    }
 }
 
 System_communication_mq::~System_communication_mq()
@@ -39,16 +47,51 @@ Error_manager System_communication_mq::check_executer(Rabbitmq_message*  p_msg)
 //处理消息, 需要子类重载
 Error_manager System_communication_mq::execute_msg(Rabbitmq_message* p_msg)
 {
-	return SUCCESS;
+//    return SUCCESS;
+    return execute_dispatch_status_msg(p_msg);
 }
 
 //定时封装发送消息, 一般为心跳和状态信息, 需要子类重载
 Error_manager System_communication_mq::auto_encapsulate_status()
 {
+//    return SUCCESS;
 	return System_executor::get_instance_references().encapsulate_send_mq_status();
 }
 
+Error_manager System_communication_mq::execute_dispatch_status_msg(Rabbitmq_message* p_msg)
+{
+    std::unique_lock<std::mutex> t_lock(m_lock);
+
+    if ( p_msg->m_routing_key == "dispatch_1_statu_port" ||
+         p_msg->m_routing_key == "dispatch_2_statu_port" ||
+         p_msg->m_routing_key == "dispatch_3_statu_port" )
+    {
+        dispatch_node_statu t_dispatch_node_statu;
+        if(google::protobuf::TextFormat::ParseFromString(p_msg->m_message_buf, &t_dispatch_node_statu))
+        {
+//            std::cout<< "hulixxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" << t_dispatch_node_statu.DebugString() << std::endl;
+//            LOG(INFO) << "hulixxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" << t_dispatch_node_statu.DebugString() << this;
+
+            for (int j = 0; j < t_dispatch_node_statu.dispatch_region_info_vector_size() ; ++j)
+            {
+                int t_terminal = t_dispatch_node_statu.dispatch_region_info_vector(j).terminal_id();
+                dispatch_region_info_map[t_terminal] = t_dispatch_node_statu.dispatch_region_info_vector(j);
+
+//                LOG(INFO) << "hulixxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx t_terminal = " << t_terminal << "  ";
+//                LOG(INFO) << "hulixxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx " << dispatch_region_info_map[t_terminal].terminal_id() << "  ";
+//                LOG(INFO) << "hulixxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx " << dispatch_region_info_map[t_terminal].turnplate_angle_min()<< "  ";
+//                LOG(INFO) << "hulixxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx " << dispatch_region_info_map[t_terminal].turnplate_angle_max()<< "  ";
 
+            }
+        }
+    }
+
+
+
+
+
+    return SUCCESS;
+}
 
 
 

+ 9 - 1
system/system_communication_mq.h

@@ -15,6 +15,9 @@
 
 #include "../tool/singleton.h"
 #include "../rabbitmq/rabbitmq_base.h"
+#include "../message/message.pb.h"
+#include <map>
+#include <mutex>
 
 class System_communication_mq:public Singleton<System_communication_mq>, public Rabbitmq_base
 {
@@ -40,12 +43,17 @@ public://API functions
 	//定时封装发送消息, 一般为心跳和状态信息, 需要子类重载
 	virtual Error_manager auto_encapsulate_status();
 
+	//get dispatch status, save local
+    Error_manager execute_dispatch_status_msg(Rabbitmq_message* p_msg);
+
 public://get or set member variable
 
     
 protected://member variable 
+public:
+    std::mutex                              	m_lock;        						//锁,
 
-    
+    std::map<int, dispatch_region_info>         dispatch_region_info_map;
 private:
     
 };

+ 1 - 1
system/system_executor.cpp

@@ -630,7 +630,7 @@ Error_manager System_executor::encapsulate_send_mq_status()
 			t_multi_status_msg.id_struct().terminal_id() == 2)
 		{
 			// rabbitmq new measure info
-			message::measure_info t_multi_measure_info_msg;
+			measure_info t_multi_measure_info_msg;
 			t_multi_measure_info_msg.set_cx(t_car_wheel_information.car_center_x);
 			t_multi_measure_info_msg.set_cy(t_car_wheel_information.car_center_y);
 			t_multi_measure_info_msg.set_theta(t_car_wheel_information.car_angle);

+ 1 - 0
system/system_executor.h

@@ -13,6 +13,7 @@
 #include "../tool/common_data.h"
 #include "../tool/measure_filter.h"
 #include "../message/measure_message.pb.h"
+#include "../message/message.pb.h"
 #include "../system/system_communication.h"
 #include "../system/system_communication_mq.h"
 

+ 65 - 7
velodyne_lidar/ground_region.cpp

@@ -17,6 +17,7 @@
 
 // 增加车辆停止状态判断
 #include "../tool/region_status_checker.h"
+#include "../system/system_communication_mq.h"
 
 //欧式聚类*******************************************************
 std::vector<pcl::PointCloud<pcl::PointXYZ>::Ptr> Ground_region::segmentation(pcl::PointCloud<pcl::PointXYZ>::Ptr sor_cloud)
@@ -667,11 +668,26 @@ int Ground_region::outOfRangeDetection(pcl::PointCloud<pcl::PointXYZ>::Ptr cloud
     car_uniform_center.x() = car_center.x() * cos(theta_rad) - car_center.y() * sin(theta_rad);
     car_uniform_center.y() = car_center.x() * sin(theta_rad) + car_center.y() * cos(theta_rad);
     // 车位位于y负方向,判断后轮超界情况
-    double rear_wheel_y = car_uniform_center.y() + m_region.plc_offsety() - 0.5 * measure_result.car_wheel_base;
-    if(rear_wheel_y < m_region.plc_border_miny())
+
+    //yct old program 20221101
+//    double rear_wheel_y = car_uniform_center.y() + m_region.plc_offsety() - 0.5 * measure_result.car_wheel_base;
+//    if(rear_wheel_y < m_region.plc_border_miny())
+//    {
+//        res |= Range_status::Range_back;
+//    }
+    //huli new program 20221101
+    double t_center_y = 0.0 - (car_uniform_center.y() + m_region.plc_offsety()); // 汽车中心y, 参照plc坐标,并且进行偏移, 绝对值。结果大约为 5~6左右
+    if( t_center_y - 4.88 + 0.5*(measure_result.car_wheel_base - 2.7) < m_region.plc_border_maxy()    &&
+            t_center_y - 4.88 - 0.5*(measure_result.car_wheel_base - 2.7) < m_region.plc_border_miny() )
+    {
+        //normal
+    } else
     {
         res |= Range_status::Range_back;
     }
+
+
+
     // 判断车辆宽度超界情况
     if (measure_result.car_wheel_width < m_region.car_min_width() || measure_result.car_wheel_width > m_region.car_max_width())
     {
@@ -682,16 +698,51 @@ int Ground_region::outOfRangeDetection(pcl::PointCloud<pcl::PointXYZ>::Ptr cloud
     {
         res |= Range_status::Range_car_wheelbase;
     }
+
+
+    //yct old program 20221103 , 使用 velodyne_manager.prototxt 里面的 turnplate_angle_limit 来做边界判断
     // 判断车辆旋转角超界情况
-    double dtheta = 90-measure_result.car_angle;
-    if (dtheta > m_region.turnplate_angle_limit_anti_clockwise())
+//    double dtheta = 90-measure_result.car_angle;
+//    if (dtheta > m_region.turnplate_angle_limit_anti_clockwise())
+//    {
+//        res |= Range_status::Range_angle_clock;
+//    }
+//    if (dtheta < -m_region.turnplate_angle_limit_clockwise())
+//    {
+//        res |= Range_status::Range_angle_anti_clock;
+//    }
+    //huli new program 20221103, 使用 plc  dispatch_1_statu_port 里面的  来做边界判断
+//    double t_dtheta = 90-measure_result.car_angle;    // 车身的旋转角, 修正到正负5度,
+    double t_dtheta = measure_result.car_angle + m_region.plc_offset_degree();    // 车身的旋转角, 修正到正5度, (m_region.plc_offset_degree():-89)
+    int t_terminal_id = m_region.region_id() +1;        //region_id:0~5,   terminal_id:1~6
+    //turnplate_angle_min = -5, turnplate_angle_max = 5,
+    if (t_dtheta > System_communication_mq::get_instance_references().dispatch_region_info_map[t_terminal_id].turnplate_angle_max())
     {
-        res |= Range_status::Range_angle_clock;
+        res |= Range_status::Range_angle_anti_clock;
     }
-    if (dtheta < -m_region.turnplate_angle_limit_clockwise())
+    if (t_dtheta < System_communication_mq::get_instance_references().dispatch_region_info_map[t_terminal_id].turnplate_angle_min())
     {
-        res |= Range_status::Range_angle_anti_clock;
+        res |= Range_status::Range_angle_clock;
     }
+
+//    if (t_terminal_id == 3)
+//    {
+//
+//        LOG(INFO) << "hulixxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx t_terminal_id = " << t_terminal_id << "  ";
+//
+//        LOG(INFO) << "hulixxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx m_region.plc_offset_degree() = " << m_region.plc_offset_degree() << "  ";
+//
+//
+//        LOG(INFO) << "hulixxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx t_dtheta = " << t_dtheta << "  ";
+//        LOG(INFO) << "hulixxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx turnplate_angle_min = " << System_communication_mq::get_instance_references().dispatch_region_info_map[t_terminal_id].turnplate_angle_min() << "  ";
+//        LOG(INFO) << "hulixxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx turnplate_angle_max = " << System_communication_mq::get_instance_references().dispatch_region_info_map[t_terminal_id].turnplate_angle_max() << "  ";
+//
+//    }
+
+
+
+
+
     // // 判断车辆前轮角回正情况
     // if (fabs(measure_result.car_front_theta) > 8.0)
     // {
@@ -826,6 +877,13 @@ void Ground_region::thread_measure_func()
                 m_car_wheel_information.uniform_car_y += m_region.plc_offsety();
                 m_car_wheel_information.car_angle += m_region.plc_offset_degree();
 
+//                LOG(INFO) << "yyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy t_result.theta = " << t_result.theta << "  ";
+//                LOG(INFO) << "yyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy m_region.plc_offset_degree() = " << m_region.plc_offset_degree() << "  ";
+//                LOG(INFO) << "yyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy  m_car_wheel_information.car_angle= " <<   m_car_wheel_information.car_angle << "  ";
+
+
+
+
                 t_wheel_info_stamped.wheel_data = m_car_wheel_information;
                 t_wheel_info_stamped.measure_time = m_detect_update_time;
                 Measure_filter::get_instance_references().update_data(m_region.region_id(), t_wheel_info_stamped);

+ 2 - 0
velodyne_lidar/ground_region.h

@@ -162,6 +162,8 @@ private:
    int outOfRangeDetection(pcl::PointCloud<pcl::PointXYZ>::Ptr cloud, Common_data::Car_wheel_information measure_result, double plate_cx=0.0, double plate_cy=0.0, double theta=0.0);
 
 private:
+
+
    velodyne::Region m_region; // 区域配置
    detect_wheel_ceres3d *m_detector; // 检测器
    Ground_region_status m_region_status; // 区域状态

+ 113 - 74
velodyne_lidar/velodyne_config.pb.cc

@@ -236,6 +236,7 @@ const ::google::protobuf::uint32 TableStruct::offsets[] GOOGLE_PROTOBUF_ATTRIBUT
   GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::velodyne::Region, plc_offsety_),
   GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::velodyne::Region, plc_offset_degree_),
   GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::velodyne::Region, plc_border_miny_),
+  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::velodyne::Region, plc_border_maxy_),
   GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::velodyne::Region, car_min_width_),
   GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::velodyne::Region, car_max_width_),
   GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::velodyne::Region, car_min_wheelbase_),
@@ -264,13 +265,14 @@ const ::google::protobuf::uint32 TableStruct::offsets[] GOOGLE_PROTOBUF_ATTRIBUT
   18,
   19,
   20,
+  21,
 };
 static const ::google::protobuf::internal::MigrationSchema schemas[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
   { 0, 12, sizeof(::velodyne::velodyneManagerParams)},
   { 19, 35, sizeof(::velodyne::velodyneLidarParams)},
   { 46, 57, sizeof(::velodyne::CalibParameter)},
   { 63, 70, sizeof(::velodyne::lidarExtrinsic)},
-  { 72, 99, sizeof(::velodyne::Region)},
+  { 72, 100, sizeof(::velodyne::Region)},
 };
 
 static ::google::protobuf::Message const * const file_default_instances[] = {
@@ -320,7 +322,7 @@ void AddDescriptorsImpl() {
       "\002:\0010\022\014\n\001p\030\002 \001(\002:\0010\022\014\n\001y\030\003 \001(\002:\0010\022\r\n\002cx\030\004"
       " \001(\002:\0010\022\r\n\002cy\030\005 \001(\002:\0010\022\r\n\002cz\030\006 \001(\002:\0010\"K\n"
       "\016lidarExtrinsic\022\020\n\010lidar_id\030\001 \002(\005\022\'\n\005cal"
-      "ib\030\002 \001(\0132\030.velodyne.CalibParameter\"\214\004\n\006R"
+      "ib\030\002 \001(\0132\030.velodyne.CalibParameter\"\245\004\n\006R"
       "egion\022\014\n\004minx\030\001 \002(\002\022\014\n\004maxx\030\002 \002(\002\022\014\n\004min"
       "y\030\003 \002(\002\022\014\n\004maxy\030\004 \002(\002\022\014\n\004minz\030\005 \002(\002\022\014\n\004m"
       "axz\030\006 \002(\002\022\021\n\tregion_id\030\007 \002(\005\022,\n\nlidar_ex"
@@ -329,15 +331,15 @@ void AddDescriptorsImpl() {
       "\n\013border_minx\030\013 \002(\002\022\023\n\013border_maxx\030\014 \002(\002"
       "\022\023\n\013plc_offsetx\030\r \002(\002\022\023\n\013plc_offsety\030\016 \002"
       "(\002\022\031\n\021plc_offset_degree\030\017 \002(\002\022\027\n\017plc_bor"
-      "der_miny\030\020 \002(\002\022\025\n\rcar_min_width\030\021 \002(\002\022\025\n"
-      "\rcar_max_width\030\022 \002(\002\022\031\n\021car_min_wheelbas"
-      "e\030\023 \002(\002\022\031\n\021car_max_wheelbase\030\024 \002(\002\022,\n$tu"
-      "rnplate_angle_limit_anti_clockwise\030\025 \002(\002"
-      "\022\'\n\037turnplate_angle_limit_clockwise\030\026 \002("
-      "\002"
+      "der_miny\030\020 \002(\002\022\027\n\017plc_border_maxy\030\021 \002(\002\022"
+      "\025\n\rcar_min_width\030\022 \002(\002\022\025\n\rcar_max_width\030"
+      "\023 \002(\002\022\031\n\021car_min_wheelbase\030\024 \002(\002\022\031\n\021car_"
+      "max_wheelbase\030\025 \002(\002\022,\n$turnplate_angle_l"
+      "imit_anti_clockwise\030\026 \002(\002\022\'\n\037turnplate_a"
+      "ngle_limit_clockwise\030\027 \002(\002"
   };
   ::google::protobuf::DescriptorPool::InternalAddGeneratedFile(
-      descriptor, 1281);
+      descriptor, 1306);
   ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile(
     "velodyne_config.proto", &protobuf_RegisterTypes);
 }
@@ -2378,6 +2380,7 @@ const int Region::kPlcOffsetxFieldNumber;
 const int Region::kPlcOffsetyFieldNumber;
 const int Region::kPlcOffsetDegreeFieldNumber;
 const int Region::kPlcBorderMinyFieldNumber;
+const int Region::kPlcBorderMaxyFieldNumber;
 const int Region::kCarMinWidthFieldNumber;
 const int Region::kCarMaxWidthFieldNumber;
 const int Region::kCarMinWheelbaseFieldNumber;
@@ -2448,13 +2451,13 @@ void Region::Clear() {
   }
   if (cached_has_bits & 65280u) {
     ::memset(&turnplate_cy_, 0, static_cast<size_t>(
-        reinterpret_cast<char*>(&car_min_width_) -
-        reinterpret_cast<char*>(&turnplate_cy_)) + sizeof(car_min_width_));
+        reinterpret_cast<char*>(&plc_border_maxy_) -
+        reinterpret_cast<char*>(&turnplate_cy_)) + sizeof(plc_border_maxy_));
   }
-  if (cached_has_bits & 2031616u) {
-    ::memset(&car_max_width_, 0, static_cast<size_t>(
+  if (cached_has_bits & 4128768u) {
+    ::memset(&car_min_width_, 0, static_cast<size_t>(
         reinterpret_cast<char*>(&turnplate_angle_limit_clockwise_) -
-        reinterpret_cast<char*>(&car_max_width_)) + sizeof(turnplate_angle_limit_clockwise_));
+        reinterpret_cast<char*>(&car_min_width_)) + sizeof(turnplate_angle_limit_clockwise_));
   }
   _has_bits_.Clear();
   _internal_metadata_.Clear();
@@ -2692,80 +2695,94 @@ bool Region::MergePartialFromCodedStream(
         break;
       }
 
-      // required float car_min_width = 17;
+      // required float plc_border_maxy = 17;
       case 17: {
         if (static_cast< ::google::protobuf::uint8>(tag) ==
             static_cast< ::google::protobuf::uint8>(141u /* 141 & 0xFF */)) {
-          set_has_car_min_width();
+          set_has_plc_border_maxy();
           DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                    float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
-                 input, &car_min_width_)));
+                 input, &plc_border_maxy_)));
         } else {
           goto handle_unusual;
         }
         break;
       }
 
-      // required float car_max_width = 18;
+      // required float car_min_width = 18;
       case 18: {
         if (static_cast< ::google::protobuf::uint8>(tag) ==
             static_cast< ::google::protobuf::uint8>(149u /* 149 & 0xFF */)) {
-          set_has_car_max_width();
+          set_has_car_min_width();
           DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                    float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
-                 input, &car_max_width_)));
+                 input, &car_min_width_)));
         } else {
           goto handle_unusual;
         }
         break;
       }
 
-      // required float car_min_wheelbase = 19;
+      // required float car_max_width = 19;
       case 19: {
         if (static_cast< ::google::protobuf::uint8>(tag) ==
             static_cast< ::google::protobuf::uint8>(157u /* 157 & 0xFF */)) {
-          set_has_car_min_wheelbase();
+          set_has_car_max_width();
           DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                    float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
-                 input, &car_min_wheelbase_)));
+                 input, &car_max_width_)));
         } else {
           goto handle_unusual;
         }
         break;
       }
 
-      // required float car_max_wheelbase = 20;
+      // required float car_min_wheelbase = 20;
       case 20: {
         if (static_cast< ::google::protobuf::uint8>(tag) ==
             static_cast< ::google::protobuf::uint8>(165u /* 165 & 0xFF */)) {
-          set_has_car_max_wheelbase();
+          set_has_car_min_wheelbase();
           DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                    float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
-                 input, &car_max_wheelbase_)));
+                 input, &car_min_wheelbase_)));
         } else {
           goto handle_unusual;
         }
         break;
       }
 
-      // required float turnplate_angle_limit_anti_clockwise = 21;
+      // required float car_max_wheelbase = 21;
       case 21: {
         if (static_cast< ::google::protobuf::uint8>(tag) ==
             static_cast< ::google::protobuf::uint8>(173u /* 173 & 0xFF */)) {
-          set_has_turnplate_angle_limit_anti_clockwise();
+          set_has_car_max_wheelbase();
           DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                    float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
-                 input, &turnplate_angle_limit_anti_clockwise_)));
+                 input, &car_max_wheelbase_)));
         } else {
           goto handle_unusual;
         }
         break;
       }
 
-      // required float turnplate_angle_limit_clockwise = 22;
+      // required float turnplate_angle_limit_anti_clockwise = 22;
       case 22: {
         if (static_cast< ::google::protobuf::uint8>(tag) ==
             static_cast< ::google::protobuf::uint8>(181u /* 181 & 0xFF */)) {
+          set_has_turnplate_angle_limit_anti_clockwise();
+          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
+                   float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
+                 input, &turnplate_angle_limit_anti_clockwise_)));
+        } else {
+          goto handle_unusual;
+        }
+        break;
+      }
+
+      // required float turnplate_angle_limit_clockwise = 23;
+      case 23: {
+        if (static_cast< ::google::protobuf::uint8>(tag) ==
+            static_cast< ::google::protobuf::uint8>(189u /* 189 & 0xFF */)) {
           set_has_turnplate_angle_limit_clockwise();
           DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                    float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
@@ -2887,34 +2904,39 @@ void Region::SerializeWithCachedSizes(
     ::google::protobuf::internal::WireFormatLite::WriteFloat(16, this->plc_border_miny(), output);
   }
 
-  // required float car_min_width = 17;
+  // required float plc_border_maxy = 17;
   if (cached_has_bits & 0x00008000u) {
-    ::google::protobuf::internal::WireFormatLite::WriteFloat(17, this->car_min_width(), output);
+    ::google::protobuf::internal::WireFormatLite::WriteFloat(17, this->plc_border_maxy(), output);
   }
 
-  // required float car_max_width = 18;
+  // required float car_min_width = 18;
   if (cached_has_bits & 0x00010000u) {
-    ::google::protobuf::internal::WireFormatLite::WriteFloat(18, this->car_max_width(), output);
+    ::google::protobuf::internal::WireFormatLite::WriteFloat(18, this->car_min_width(), output);
   }
 
-  // required float car_min_wheelbase = 19;
+  // required float car_max_width = 19;
   if (cached_has_bits & 0x00020000u) {
-    ::google::protobuf::internal::WireFormatLite::WriteFloat(19, this->car_min_wheelbase(), output);
+    ::google::protobuf::internal::WireFormatLite::WriteFloat(19, this->car_max_width(), output);
   }
 
-  // required float car_max_wheelbase = 20;
+  // required float car_min_wheelbase = 20;
   if (cached_has_bits & 0x00040000u) {
-    ::google::protobuf::internal::WireFormatLite::WriteFloat(20, this->car_max_wheelbase(), output);
+    ::google::protobuf::internal::WireFormatLite::WriteFloat(20, this->car_min_wheelbase(), output);
   }
 
-  // required float turnplate_angle_limit_anti_clockwise = 21;
+  // required float car_max_wheelbase = 21;
   if (cached_has_bits & 0x00080000u) {
-    ::google::protobuf::internal::WireFormatLite::WriteFloat(21, this->turnplate_angle_limit_anti_clockwise(), output);
+    ::google::protobuf::internal::WireFormatLite::WriteFloat(21, this->car_max_wheelbase(), output);
   }
 
-  // required float turnplate_angle_limit_clockwise = 22;
+  // required float turnplate_angle_limit_anti_clockwise = 22;
   if (cached_has_bits & 0x00100000u) {
-    ::google::protobuf::internal::WireFormatLite::WriteFloat(22, this->turnplate_angle_limit_clockwise(), output);
+    ::google::protobuf::internal::WireFormatLite::WriteFloat(22, this->turnplate_angle_limit_anti_clockwise(), output);
+  }
+
+  // required float turnplate_angle_limit_clockwise = 23;
+  if (cached_has_bits & 0x00200000u) {
+    ::google::protobuf::internal::WireFormatLite::WriteFloat(23, this->turnplate_angle_limit_clockwise(), output);
   }
 
   if (_internal_metadata_.have_unknown_fields()) {
@@ -3015,34 +3037,39 @@ void Region::SerializeWithCachedSizes(
     target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(16, this->plc_border_miny(), target);
   }
 
-  // required float car_min_width = 17;
+  // required float plc_border_maxy = 17;
   if (cached_has_bits & 0x00008000u) {
-    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(17, this->car_min_width(), target);
+    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(17, this->plc_border_maxy(), target);
   }
 
-  // required float car_max_width = 18;
+  // required float car_min_width = 18;
   if (cached_has_bits & 0x00010000u) {
-    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(18, this->car_max_width(), target);
+    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(18, this->car_min_width(), target);
   }
 
-  // required float car_min_wheelbase = 19;
+  // required float car_max_width = 19;
   if (cached_has_bits & 0x00020000u) {
-    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(19, this->car_min_wheelbase(), target);
+    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(19, this->car_max_width(), target);
   }
 
-  // required float car_max_wheelbase = 20;
+  // required float car_min_wheelbase = 20;
   if (cached_has_bits & 0x00040000u) {
-    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(20, this->car_max_wheelbase(), target);
+    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(20, this->car_min_wheelbase(), target);
   }
 
-  // required float turnplate_angle_limit_anti_clockwise = 21;
+  // required float car_max_wheelbase = 21;
   if (cached_has_bits & 0x00080000u) {
-    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(21, this->turnplate_angle_limit_anti_clockwise(), target);
+    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(21, this->car_max_wheelbase(), target);
   }
 
-  // required float turnplate_angle_limit_clockwise = 22;
+  // required float turnplate_angle_limit_anti_clockwise = 22;
   if (cached_has_bits & 0x00100000u) {
-    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(22, this->turnplate_angle_limit_clockwise(), target);
+    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(22, this->turnplate_angle_limit_anti_clockwise(), target);
+  }
+
+  // required float turnplate_angle_limit_clockwise = 23;
+  if (cached_has_bits & 0x00200000u) {
+    target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(23, this->turnplate_angle_limit_clockwise(), target);
   }
 
   if (_internal_metadata_.have_unknown_fields()) {
@@ -3134,33 +3161,38 @@ size_t Region::RequiredFieldsByteSizeFallback() const {
     total_size += 2 + 4;
   }
 
+  if (has_plc_border_maxy()) {
+    // required float plc_border_maxy = 17;
+    total_size += 2 + 4;
+  }
+
   if (has_car_min_width()) {
-    // required float car_min_width = 17;
+    // required float car_min_width = 18;
     total_size += 2 + 4;
   }
 
   if (has_car_max_width()) {
-    // required float car_max_width = 18;
+    // required float car_max_width = 19;
     total_size += 2 + 4;
   }
 
   if (has_car_min_wheelbase()) {
-    // required float car_min_wheelbase = 19;
+    // required float car_min_wheelbase = 20;
     total_size += 2 + 4;
   }
 
   if (has_car_max_wheelbase()) {
-    // required float car_max_wheelbase = 20;
+    // required float car_max_wheelbase = 21;
     total_size += 2 + 4;
   }
 
   if (has_turnplate_angle_limit_anti_clockwise()) {
-    // required float turnplate_angle_limit_anti_clockwise = 21;
+    // required float turnplate_angle_limit_anti_clockwise = 22;
     total_size += 2 + 4;
   }
 
   if (has_turnplate_angle_limit_clockwise()) {
-    // required float turnplate_angle_limit_clockwise = 22;
+    // required float turnplate_angle_limit_clockwise = 23;
     total_size += 2 + 4;
   }
 
@@ -3175,7 +3207,7 @@ size_t Region::ByteSizeLong() const {
       ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
         _internal_metadata_.unknown_fields());
   }
-  if (((_has_bits_[0] & 0x001fffff) ^ 0x001fffff) == 0) {  // All required fields are present.
+  if (((_has_bits_[0] & 0x003fffff) ^ 0x003fffff) == 0) {  // All required fields are present.
     // required float minx = 1;
     total_size += 1 + 4;
 
@@ -3223,22 +3255,25 @@ size_t Region::ByteSizeLong() const {
     // required float plc_border_miny = 16;
     total_size += 2 + 4;
 
-    // required float car_min_width = 17;
+    // required float plc_border_maxy = 17;
+    total_size += 2 + 4;
+
+    // required float car_min_width = 18;
     total_size += 2 + 4;
 
-    // required float car_max_width = 18;
+    // required float car_max_width = 19;
     total_size += 2 + 4;
 
-    // required float car_min_wheelbase = 19;
+    // required float car_min_wheelbase = 20;
     total_size += 2 + 4;
 
-    // required float car_max_wheelbase = 20;
+    // required float car_max_wheelbase = 21;
     total_size += 2 + 4;
 
-    // required float turnplate_angle_limit_anti_clockwise = 21;
+    // required float turnplate_angle_limit_anti_clockwise = 22;
     total_size += 2 + 4;
 
-    // required float turnplate_angle_limit_clockwise = 22;
+    // required float turnplate_angle_limit_clockwise = 23;
     total_size += 2 + 4;
 
   } else {
@@ -3334,24 +3369,27 @@ void Region::MergeFrom(const Region& from) {
       plc_border_miny_ = from.plc_border_miny_;
     }
     if (cached_has_bits & 0x00008000u) {
-      car_min_width_ = from.car_min_width_;
+      plc_border_maxy_ = from.plc_border_maxy_;
     }
     _has_bits_[0] |= cached_has_bits;
   }
-  if (cached_has_bits & 2031616u) {
+  if (cached_has_bits & 4128768u) {
     if (cached_has_bits & 0x00010000u) {
-      car_max_width_ = from.car_max_width_;
+      car_min_width_ = from.car_min_width_;
     }
     if (cached_has_bits & 0x00020000u) {
-      car_min_wheelbase_ = from.car_min_wheelbase_;
+      car_max_width_ = from.car_max_width_;
     }
     if (cached_has_bits & 0x00040000u) {
-      car_max_wheelbase_ = from.car_max_wheelbase_;
+      car_min_wheelbase_ = from.car_min_wheelbase_;
     }
     if (cached_has_bits & 0x00080000u) {
-      turnplate_angle_limit_anti_clockwise_ = from.turnplate_angle_limit_anti_clockwise_;
+      car_max_wheelbase_ = from.car_max_wheelbase_;
     }
     if (cached_has_bits & 0x00100000u) {
+      turnplate_angle_limit_anti_clockwise_ = from.turnplate_angle_limit_anti_clockwise_;
+    }
+    if (cached_has_bits & 0x00200000u) {
       turnplate_angle_limit_clockwise_ = from.turnplate_angle_limit_clockwise_;
     }
     _has_bits_[0] |= cached_has_bits;
@@ -3373,7 +3411,7 @@ void Region::CopyFrom(const Region& from) {
 }
 
 bool Region::IsInitialized() const {
-  if ((_has_bits_[0] & 0x001fffff) != 0x001fffff) return false;
+  if ((_has_bits_[0] & 0x003fffff) != 0x003fffff) return false;
   if (!::google::protobuf::internal::AllAreInitialized(this->lidar_exts())) return false;
   return true;
 }
@@ -3400,6 +3438,7 @@ void Region::InternalSwap(Region* other) {
   swap(plc_offsety_, other->plc_offsety_);
   swap(plc_offset_degree_, other->plc_offset_degree_);
   swap(plc_border_miny_, other->plc_border_miny_);
+  swap(plc_border_maxy_, other->plc_border_maxy_);
   swap(car_min_width_, other->car_min_width_);
   swap(car_max_width_, other->car_max_width_);
   swap(car_min_wheelbase_, other->car_min_wheelbase_);

+ 70 - 36
velodyne_lidar/velodyne_config.pb.h

@@ -1040,45 +1040,52 @@ class Region : public ::google::protobuf::Message /* @@protoc_insertion_point(cl
   float plc_border_miny() const;
   void set_plc_border_miny(float value);
 
-  // required float car_min_width = 17;
+  // required float plc_border_maxy = 17;
+  bool has_plc_border_maxy() const;
+  void clear_plc_border_maxy();
+  static const int kPlcBorderMaxyFieldNumber = 17;
+  float plc_border_maxy() const;
+  void set_plc_border_maxy(float value);
+
+  // required float car_min_width = 18;
   bool has_car_min_width() const;
   void clear_car_min_width();
-  static const int kCarMinWidthFieldNumber = 17;
+  static const int kCarMinWidthFieldNumber = 18;
   float car_min_width() const;
   void set_car_min_width(float value);
 
-  // required float car_max_width = 18;
+  // required float car_max_width = 19;
   bool has_car_max_width() const;
   void clear_car_max_width();
-  static const int kCarMaxWidthFieldNumber = 18;
+  static const int kCarMaxWidthFieldNumber = 19;
   float car_max_width() const;
   void set_car_max_width(float value);
 
-  // required float car_min_wheelbase = 19;
+  // required float car_min_wheelbase = 20;
   bool has_car_min_wheelbase() const;
   void clear_car_min_wheelbase();
-  static const int kCarMinWheelbaseFieldNumber = 19;
+  static const int kCarMinWheelbaseFieldNumber = 20;
   float car_min_wheelbase() const;
   void set_car_min_wheelbase(float value);
 
-  // required float car_max_wheelbase = 20;
+  // required float car_max_wheelbase = 21;
   bool has_car_max_wheelbase() const;
   void clear_car_max_wheelbase();
-  static const int kCarMaxWheelbaseFieldNumber = 20;
+  static const int kCarMaxWheelbaseFieldNumber = 21;
   float car_max_wheelbase() const;
   void set_car_max_wheelbase(float value);
 
-  // required float turnplate_angle_limit_anti_clockwise = 21;
+  // required float turnplate_angle_limit_anti_clockwise = 22;
   bool has_turnplate_angle_limit_anti_clockwise() const;
   void clear_turnplate_angle_limit_anti_clockwise();
-  static const int kTurnplateAngleLimitAntiClockwiseFieldNumber = 21;
+  static const int kTurnplateAngleLimitAntiClockwiseFieldNumber = 22;
   float turnplate_angle_limit_anti_clockwise() const;
   void set_turnplate_angle_limit_anti_clockwise(float value);
 
-  // required float turnplate_angle_limit_clockwise = 22;
+  // required float turnplate_angle_limit_clockwise = 23;
   bool has_turnplate_angle_limit_clockwise() const;
   void clear_turnplate_angle_limit_clockwise();
-  static const int kTurnplateAngleLimitClockwiseFieldNumber = 22;
+  static const int kTurnplateAngleLimitClockwiseFieldNumber = 23;
   float turnplate_angle_limit_clockwise() const;
   void set_turnplate_angle_limit_clockwise(float value);
 
@@ -1114,6 +1121,8 @@ class Region : public ::google::protobuf::Message /* @@protoc_insertion_point(cl
   void clear_has_plc_offset_degree();
   void set_has_plc_border_miny();
   void clear_has_plc_border_miny();
+  void set_has_plc_border_maxy();
+  void clear_has_plc_border_maxy();
   void set_has_car_min_width();
   void clear_has_car_min_width();
   void set_has_car_max_width();
@@ -1149,6 +1158,7 @@ class Region : public ::google::protobuf::Message /* @@protoc_insertion_point(cl
   float plc_offsety_;
   float plc_offset_degree_;
   float plc_border_miny_;
+  float plc_border_maxy_;
   float car_min_width_;
   float car_max_width_;
   float car_min_wheelbase_;
@@ -2572,16 +2582,40 @@ inline void Region::set_plc_border_miny(float value) {
   // @@protoc_insertion_point(field_set:velodyne.Region.plc_border_miny)
 }
 
-// required float car_min_width = 17;
-inline bool Region::has_car_min_width() const {
+// required float plc_border_maxy = 17;
+inline bool Region::has_plc_border_maxy() const {
   return (_has_bits_[0] & 0x00008000u) != 0;
 }
-inline void Region::set_has_car_min_width() {
+inline void Region::set_has_plc_border_maxy() {
   _has_bits_[0] |= 0x00008000u;
 }
-inline void Region::clear_has_car_min_width() {
+inline void Region::clear_has_plc_border_maxy() {
   _has_bits_[0] &= ~0x00008000u;
 }
+inline void Region::clear_plc_border_maxy() {
+  plc_border_maxy_ = 0;
+  clear_has_plc_border_maxy();
+}
+inline float Region::plc_border_maxy() const {
+  // @@protoc_insertion_point(field_get:velodyne.Region.plc_border_maxy)
+  return plc_border_maxy_;
+}
+inline void Region::set_plc_border_maxy(float value) {
+  set_has_plc_border_maxy();
+  plc_border_maxy_ = value;
+  // @@protoc_insertion_point(field_set:velodyne.Region.plc_border_maxy)
+}
+
+// required float car_min_width = 18;
+inline bool Region::has_car_min_width() const {
+  return (_has_bits_[0] & 0x00010000u) != 0;
+}
+inline void Region::set_has_car_min_width() {
+  _has_bits_[0] |= 0x00010000u;
+}
+inline void Region::clear_has_car_min_width() {
+  _has_bits_[0] &= ~0x00010000u;
+}
 inline void Region::clear_car_min_width() {
   car_min_width_ = 0;
   clear_has_car_min_width();
@@ -2596,15 +2630,15 @@ inline void Region::set_car_min_width(float value) {
   // @@protoc_insertion_point(field_set:velodyne.Region.car_min_width)
 }
 
-// required float car_max_width = 18;
+// required float car_max_width = 19;
 inline bool Region::has_car_max_width() const {
-  return (_has_bits_[0] & 0x00010000u) != 0;
+  return (_has_bits_[0] & 0x00020000u) != 0;
 }
 inline void Region::set_has_car_max_width() {
-  _has_bits_[0] |= 0x00010000u;
+  _has_bits_[0] |= 0x00020000u;
 }
 inline void Region::clear_has_car_max_width() {
-  _has_bits_[0] &= ~0x00010000u;
+  _has_bits_[0] &= ~0x00020000u;
 }
 inline void Region::clear_car_max_width() {
   car_max_width_ = 0;
@@ -2620,15 +2654,15 @@ inline void Region::set_car_max_width(float value) {
   // @@protoc_insertion_point(field_set:velodyne.Region.car_max_width)
 }
 
-// required float car_min_wheelbase = 19;
+// required float car_min_wheelbase = 20;
 inline bool Region::has_car_min_wheelbase() const {
-  return (_has_bits_[0] & 0x00020000u) != 0;
+  return (_has_bits_[0] & 0x00040000u) != 0;
 }
 inline void Region::set_has_car_min_wheelbase() {
-  _has_bits_[0] |= 0x00020000u;
+  _has_bits_[0] |= 0x00040000u;
 }
 inline void Region::clear_has_car_min_wheelbase() {
-  _has_bits_[0] &= ~0x00020000u;
+  _has_bits_[0] &= ~0x00040000u;
 }
 inline void Region::clear_car_min_wheelbase() {
   car_min_wheelbase_ = 0;
@@ -2644,15 +2678,15 @@ inline void Region::set_car_min_wheelbase(float value) {
   // @@protoc_insertion_point(field_set:velodyne.Region.car_min_wheelbase)
 }
 
-// required float car_max_wheelbase = 20;
+// required float car_max_wheelbase = 21;
 inline bool Region::has_car_max_wheelbase() const {
-  return (_has_bits_[0] & 0x00040000u) != 0;
+  return (_has_bits_[0] & 0x00080000u) != 0;
 }
 inline void Region::set_has_car_max_wheelbase() {
-  _has_bits_[0] |= 0x00040000u;
+  _has_bits_[0] |= 0x00080000u;
 }
 inline void Region::clear_has_car_max_wheelbase() {
-  _has_bits_[0] &= ~0x00040000u;
+  _has_bits_[0] &= ~0x00080000u;
 }
 inline void Region::clear_car_max_wheelbase() {
   car_max_wheelbase_ = 0;
@@ -2668,15 +2702,15 @@ inline void Region::set_car_max_wheelbase(float value) {
   // @@protoc_insertion_point(field_set:velodyne.Region.car_max_wheelbase)
 }
 
-// required float turnplate_angle_limit_anti_clockwise = 21;
+// required float turnplate_angle_limit_anti_clockwise = 22;
 inline bool Region::has_turnplate_angle_limit_anti_clockwise() const {
-  return (_has_bits_[0] & 0x00080000u) != 0;
+  return (_has_bits_[0] & 0x00100000u) != 0;
 }
 inline void Region::set_has_turnplate_angle_limit_anti_clockwise() {
-  _has_bits_[0] |= 0x00080000u;
+  _has_bits_[0] |= 0x00100000u;
 }
 inline void Region::clear_has_turnplate_angle_limit_anti_clockwise() {
-  _has_bits_[0] &= ~0x00080000u;
+  _has_bits_[0] &= ~0x00100000u;
 }
 inline void Region::clear_turnplate_angle_limit_anti_clockwise() {
   turnplate_angle_limit_anti_clockwise_ = 0;
@@ -2692,15 +2726,15 @@ inline void Region::set_turnplate_angle_limit_anti_clockwise(float value) {
   // @@protoc_insertion_point(field_set:velodyne.Region.turnplate_angle_limit_anti_clockwise)
 }
 
-// required float turnplate_angle_limit_clockwise = 22;
+// required float turnplate_angle_limit_clockwise = 23;
 inline bool Region::has_turnplate_angle_limit_clockwise() const {
-  return (_has_bits_[0] & 0x00100000u) != 0;
+  return (_has_bits_[0] & 0x00200000u) != 0;
 }
 inline void Region::set_has_turnplate_angle_limit_clockwise() {
-  _has_bits_[0] |= 0x00100000u;
+  _has_bits_[0] |= 0x00200000u;
 }
 inline void Region::clear_has_turnplate_angle_limit_clockwise() {
-  _has_bits_[0] &= ~0x00100000u;
+  _has_bits_[0] &= ~0x00200000u;
 }
 inline void Region::clear_turnplate_angle_limit_clockwise() {
   turnplate_angle_limit_clockwise_ = 0;

+ 7 - 6
velodyne_lidar/velodyne_config.proto

@@ -61,10 +61,11 @@ message Region
     required float plc_offsety=14; // plc偏移y
     required float plc_offset_degree=15; // plc偏移角度
     required float plc_border_miny=16;// plc后夹持y方向极限值
-    required float car_min_width=17; // 最小车宽
-    required float car_max_width=18; // 最大车宽
-    required float car_min_wheelbase=19; // 最小轴距
-    required float car_max_wheelbase=20; // 最大轴距
-    required float turnplate_angle_limit_anti_clockwise=21; // 转盘逆时针角度极限
-    required float turnplate_angle_limit_clockwise=22; // 转盘顺时针角度极限
+    required float plc_border_maxy=17;// plc后夹持y方向极限值
+    required float car_min_width=18; // 最小车宽
+    required float car_max_width=19; // 最大车宽
+    required float car_min_wheelbase=20; // 最小轴距
+    required float car_max_wheelbase=21; // 最大轴距
+    required float turnplate_angle_limit_anti_clockwise=22; // 转盘逆时针角度极限
+    required float turnplate_angle_limit_clockwise=23; // 转盘顺时针角度极限
 }

+ 2 - 0
velodyne_lidar/velodyne_driver/velodyne_lidar_device.cpp

@@ -110,6 +110,8 @@ Error_manager Velodyne_lidar_device::init(velodyne::velodyneLidarParams params)
 	t_error = m_input_socket.init(t_ip, t_port) == true ? SUCCESS : Error_manager(VELODYNE_LIDAR_CONNECT_FAILED, MINOR_ERROR, "socket connect failed");
 	if (t_error != SUCCESS)
 	{
+        LOG(ERROR) << "Velodyne_lidar_device::init failed: ip =  " << t_ip << " : " << t_port;
+        LOG(ERROR) << "Velodyne_lidar_device::init failed: error =  " << t_error.to_string();
 		return t_error;
 	}
 	m_velodyne_socket_status = E_READY;