Forráskód Böngészése

22-9-13 front_theta<5.0, check wb 100->130

yct 2 éve
szülő
commit
48bb3648fa

+ 2 - 2
terminor/terminal_command_executor.cpp

@@ -509,8 +509,8 @@ Error_manager Terminor_Command_Executor::scanning_measuring() {
     float offset_width = fabs(dj_locate_information.locate_width - wj_locate_information.locate_width);
     float offset_wheel_base = fabs(
             dj_locate_information.locate_wheel_base - wj_locate_information.locate_wheel_base);
-    if (offset_x > 100 || offset_y > 150 || offset_angle > 2.5 || offset_wheel_base > 550 || offset_width > 250) {
-        LOG(WARNING) << "chekc failed. (offset x>100, y>150, angle>2.5, wheel_base>550, width>250): " << offset_x
+    if (offset_x > 100 || offset_y > 150 || offset_angle > 2.5 || offset_wheel_base > 130 || offset_width > 250) {
+        LOG(WARNING) << "chekc failed. (offset x>100, y>150, angle>2.5, wheel_base>130, width>250): " << offset_x
                      << " " << offset_y << " " << offset_angle << " " << offset_wheel_base << " " << offset_width;
         return Error_manager(TERMINOR_CHECK_RESULTS_ERROR, NORMAL, "check results failed ");
     }

+ 4 - 2
wj_lidar/detect_wheel_ceres.cpp

@@ -685,7 +685,8 @@ bool detect_wheel_ceres::Solve(Detect_result &detect_result, Loss_result &loss_r
 //        LOG(WARNING) <<"总loss过大 "<<loss;
         return false;
     }
-    if (detect_result.width < 1.25 || detect_result.width > 2.000 || detect_result.wheel_base > 3.15 || detect_result.wheel_base < 2.200)
+    // 20220831 wb changed by yct from 3150 to 3105
+    if (detect_result.width < 1.25 || detect_result.width > 2.000 || detect_result.wheel_base > 3.105 || detect_result.wheel_base < 2.200)
     {
         error_info.append(std::string("宽度(1.25, 2.00) 轴距(2.20, 3.15): ").append(std::to_string(detect_result.width).append(", ").append(std::to_string(detect_result.wheel_base)).append("\t")));
 //        LOG(WARNING) <<"宽度(1.35, 2.00) 轴距(2.20, 3.30): "<<detect_result.width<<", "<<detect_result.wheel_base;
@@ -703,7 +704,8 @@ bool detect_wheel_ceres::Solve(Detect_result &detect_result, Loss_result &loss_r
 //        LOG(WARNING) <<"总角度错误 "<<detect_result.theta;
         return false;
     }
-    if(fabs(detect_result.front_theta)>35)
+
+    if(fabs(detect_result.front_theta)>5.0)
     {
         error_info.append("前轮角度错误 ").append(std::to_string(detect_result.front_theta)).append("\t");
 //        LOG(WARNING) <<"前轮角度错误 "<<detect_result.front_theta;

+ 1 - 1
wj_lidar/region_worker.cpp

@@ -183,7 +183,7 @@ void Region_worker::detect_loop(Region_worker *worker)
             double x,y,angle,wheelbase,width,front_theta;
             std::string t_error_info_str="";
             Error_manager result = worker->m_detector->detect(worker->m_cloud, x, y, angle, front_theta, wheelbase, width, t_error_info_str, false);
-//            LOG(WARNING) << "worker id: " << worker->get_id()<<" width: "<<width;
+//            LOG_IF(WARNING, worker->get_id() == 3) << "worker id: " << worker->get_id()<<" front: "<<front_theta <<", "<<t_error_info_str;
             if(worker->mp_verify_handle == nullptr)
             {
                 LOG(WARNING) << "verify handle null pointer";