when the robot get close to the object, global planner changes and donot detour the object!

asked 2022-02-28 05:39:12 -0600

Delbina gravatar image

hi everyone,

I want to do autonomous navigation, I have used rtabmap, and activated icp_odometry. then i gaved the odometry output of rtabmap into move_base. I have used dwa local, planner and global planner. I want that the vehicle do object detection and detour it, I have static objects. first I launch rtabmap and move- base, and move forward to a location to extract its coordinate, and then return back to initial location. when i send the goal, in rviz i can see that the global-path detour the object, but when the vehcile starts moving the global planner starts changing and when it is near the object, the planner shows in a way that wants to hit it, it seems that it cannot see the objects any more. I have used these file: https://kaiyuzheng.me/documents/navgu... , but i did not get the result yet. I would be grateful if anybody can help as it is urgent for me.

move_base
<launch>
  <arg name="odom_frame_id"   default="icp_odom"/>
  <arg name="base_frame_id"   default="base_link"/>
  <arg name="global_frame_id" default="map"/>
  <arg name="odom_topic" default="/rtabmap/odom" />               

  <node pkg="move_base" type="move_base" respawn="false" name="move_base" output="screen">
    <rosparam file="$(find warthog_sim_2dnav)/para_dynamic_indoor/costmap_common_params.yaml" command="load" ns="global_costmap" />
    <rosparam file="$(find warthog_sim_2dnav)/para_dynamic_indoor/costmap_common_params.yaml" command="load" ns="local_costmap" />   
    <rosparam file="$(find warthog_sim_2dnav)/para_dynamic_indoor/local_costmap_params.yaml" command="load" /> 
    <rosparam file="$(find warthog_sim_2dnav)/para_dynamic_indoor/global_costmap_params.yaml" command="load" />
    <rosparam file="$(find warthog_sim_2dnav)/para_dynamic_indoor/move_base_params.yaml" command="load" />

    <rosparam file="$(find warthog_sim_2dnav)/para_dynamic_indoor/global_planner_params.yaml" command="load" />
    <rosparam file="$(find warthog_sim_2dnav)/para_dynamic_indoor/dwa_local_planner_params.yaml" command="load" />

    <!-- reset frame_id parameters using user input data -->
    <param name="global_costmap/global_frame" value="$(arg global_frame_id)" />
    <param name="global_costmap/robot_base_frame" value="$(arg base_frame_id)" />
    <param name="local_costmap/global_frame" value="$(arg odom_frame_id)" />
    <param name="local_costmap/robot_base_frame" value="$(arg base_frame_id)" />
    <param name="DWAPlannerROS/global_frame_id" value="$(arg odom_frame_id)" />

    <param name="base_global_planner" value="global_planner/GlobalPlanner" />
    <param name="base_local_planner" value="dwa_local_planner/DWAPlannerROS" />


    <remap from="odom" to="$(arg odom_topic)" />

  </node>
</launch>

...........................................................................................................

global_planner:
GlobalPlanner:                              
  old_navfn_behavior: false                  
  use_quadratic: true                          
  use_dijkstra: false                       
  use_grid_path: true                         

  allow_unknown: true                             
  planner_window_x: 0.0                    
  planner_window_y: 0.0                    
  default_tolerance: 0.0                   

  publish_scale: 100                        
  planner_costmap_publish_frequency: 0.0        

  lethal_cost: 253                             
  neutral_cost: 66                             
  cost_factor: 0.55                              
  publish_potential: true

.........................................................................................................

    DWAPlannerROS:

    # Robot Configuration Parameters
      max_vel_x: 0.3  
      min_vel_x: 0.0  

      max_vel_y: 0.0
      min_vel_y: 0.0

      # The velocity when robot is moving in a straight line
      max_trans_vel:  1.0   
      min_trans_vel:  0.1     
      trans_stopped_vel: 0.1

      max_rot_vel: 0.2     
      min_rot_vel: 0.0    
      rot_stopped_vel: 0.8

      acc_lim_x: 1.5    
      acc_lim_theta: 3.2   
      acc_lim_y: 0.0

    # Goal Tolerance Parametes
      yaw_goal_tolerance: 1.3   
      xy_goal_tolerance: 1.35   
      latch_xy_goal_tolerance: false   

    # Forward Simulation Parameters
      sim_time: 3.5    
      vx_samples: 20
      vy_samples: 1    
      vtheta_samples: 40

    # Trajectory Scoring Parameters
      path_distance_bias: 20.0    
      goal_distance_bias: 5.0  
      occdist_scale: 0.2  
      forward_point_distance: 0.0
      stop_time_buffer: 0.2
      scaling_speed: 0.25
      max_scaling_factor: 0.2

    # Oscillation Prevention Parameters
      oscillation_reset_dist: 0.05

    # Debugging
      publish_traj_pc : true
      publish_cost_grid_pc: true
      global_frame_id: odom
      sim_granularity: 0.025
.....................................................................................................
cost common-param ...
(more)
edit retag flag offensive close merge delete

Comments

I would suggest to show the local and global costmap when you are close to the object. Also show the velodyne point cloud to see if the object is actually seen by the lidar.

matlabbe gravatar image matlabbe  ( 2022-03-06 17:20:10 -0600 )edit