Robot move in little jerks

asked 2019-09-07 07:53:42 -0500

FabioZ96 gravatar image

updated 2019-09-07 07:57:39 -0500

Hi, I'm using Navigation Stack and in particulary rviz to navigate the robot.

I can see cost map and trajectory generated by DWAPlanner

This is my move_base launch file:

<launch>

  <node pkg="move_base" type="move_base" respawn="false" name="move_base" output="screen">

    <rosparam file="$(find robot)/param/costmap_common_params.yaml" command="load" ns="global_costmap" />
    <rosparam file="$(find robot)/param/costmap_common_params.yaml" command="load" ns="local_costmap" />

    <rosparam file="$(find robot)/param/global_costmap_params.yaml" command="load" />
    <rosparam file="$(find robot)/param/local_costmap_params.yaml" command="load" />
    <param name="base_local_planner" value="dwa_local_planner/DWAPlannerROS" />
    <param name="base_global_planner" value="navfn/NavfnROS"/>
    <rosparam file="$(find robot)/param/dwa_local_planner_params.yaml" command="load" />
    <remap from="cmd_vel" to="/cmd_vel"/>
    <remap from="odom" to="odom"/>
  </node>

</launch>

I'm also tring to tune DWA Planner parameter and for now they are these:

DWAPlannerROS:

  max_vel_x: 0.8 
  min_vel_x: 0.4

  max_vel_y: 0.0  # diff drive robot
  min_vel_y: 0.0  # diff drive robot

  max_vel_trans: 0.4 # choose slightly less than the base's capability
  min_vel_trans: 0.1  # this is the min trans velocity when there is negligible rotational velocity
#  trans_vel_stopped: 2.1

  max_vel_theta: 0.4  # choose slightly less than the base's capability
  min_vel_theta: 0.1  # this is the min angular velocity when there is negligible translational velocity
#  theta_stopped_vel: 0.2

  acc_lim_x: 1.0 # maximum is theoretically 2.0, but we
  acc_lim_theta: 2.0
  acc_lim_y: 0.0      # diff drive robot

# Goal Tolerance Parameters
#  yaw_goal_tolerance: 0.4  # 0.05
#  xy_goal_tolerance: 0.25  # 0.10
  # latch_xy_goal_tolerance: false

# Forward Simulation Parameters
  sim_time: 1.0       # 1.7
  vx_samples: 20       # 3
  vy_samples: 1       # diff drive robot, there is only one sample
  vtheta_samples: 20  # 20

# Trajectory Scoring Parameters
#  path_distance_bias: 128.0      # 32.0   - weighting for how much it should stick to the global path plan
#  goal_distance_bias: 36.0      # 24.0   - wighting for how much it should attempt to reach its goal
#  occdist_scale: 0.50           # 0.01   - weighting for how much the controller should avoid obstacles
#  forward_point_distance: 0.325 # 0.325  - how far along to place an additional scoring point
#  stop_time_buffer: 0.2         # 0.2    - amount of time a robot must stop in before colliding for a valid traj.
#  scaling_speed: 0.25           # 0.25   - absolute velocity at which to start scaling the robot's footprint
#  max_scaling_factor: 0.2       # 0.2    - how much to scale the robot's footprint when at speed.

# Oscillation Prevention Parameters
#  oscillation_reset_dist: 0.05  # 0.05   - how far to travel before resetting oscillation flags

As you can see in the picture: https://pasteboard.co/Iwj38Bp.png 1. The global plan is generated (RED) 2. The local plan is generated too (GREEN) But the linear and angular velocity have jerks and the robot doesn't move continuosly.

How can I solve this? If you can get me also any suggest to tune these params I will appreciate

edit retag flag offensive close merge delete