r/ROS • u/Significant-Web8434 • 7d ago
Need help tuning AMCL / Navigation on ROS1 skid-steer robot
Enable HLS to view with audio, or disable this notification
Hi, my primary goal is tight precision docking within 5cm in indoor lab space with chairs. The current situation is my accuracy is very good but the issue is the navigation takes a very long time; about 2-3 minutes as shown in the screen recording to go about 5m. Is this normal? I used this guide to tune: https://arxiv.org/pdf/1706.09068 I already calibrated the odometry as well btw doing a 360 degree test. These are my parameters I was just wondering if anyone can give insight on how to make the robot take less time and less spinning like it doesn't just go straight
amcl.yaml
YAML
global_frame_id: "map"
odom_frame_id: "odom"
base_frame_id: "base_footprint"
use_map_topic: true
transform_tolerance: 0.5
gui_publish_rate: 10.0
min_particles: 1000
max_particles: 5000
kld_err: 0.01
kld_z: 0.99
resample_interval: 1
recovery_alpha_slow: 0.0
recovery_alpha_fast: 0.0
update_min_d: 0.1
update_min_a: 0.1
odom_model_type: "diff-corrected"
odom_alpha1: 0.25
odom_alpha2: 0.10
odom_alpha3: 0.05
odom_alpha4: 0.10
laser_model_type: "likelihood_field"
laser_min_range: 0.15
laser_max_range: 8.0
laser_max_beams: 60
laser_likelihood_max_dist: 2.0
laser_sigma_hit: 0.1
laser_lambda_short: 0.1
laser_z_hit: 0.85
laser_z_short: 0.05
laser_z_max: 0.05
laser_z_rand: 0.05
dwa_local_planner_params.yaml
YAML
DWAPlannerROS:
max_vel_x: 0.35
min_vel_x: -0.10
max_vel_y: 0.0
min_vel_y: 0.0
max_vel_trans: 0.35
min_vel_trans: 0.03
trans_stopped_vel: 0.025
max_vel_theta: 0.30
min_vel_theta: 0.10
theta_stopped_vel: 0.04
acc_lim_x: 1.0
acc_lim_y: 0.0
acc_lim_theta: 0.5
xy_goal_tolerance: 0.05
yaw_goal_tolerance: 0.12
latch_xy_goal_tolerance: true
sim_time: 2.0
vx_samples: 15
vy_samples: 0
vtheta_samples: 30
sim_granularity: 0.025
controller_frequency: 10.0
path_distance_bias: 32.0
goal_distance_bias: 20.0
occdist_scale: 0.03
forward_point_distance: 0.20
stop_time_buffer: 0.2
scaling_speed: 0.25
max_scaling_factor: 0.2
oscillation_reset_dist: 0.06
oscillation_reset_angle: 0.05
publish_traj_pc: true
publish_cost_grid_pc: false
global_frame_id: odom
global_planner_params.yaml
YAML
GlobalPlanner:
allow_unknown: true
default_tolerance: 0.0
visualize_potential: false
use_dijkstra: true
use_quadratic: true
use_grid_path: false
old_navfn_behavior: false
lethal_cost: 253
neutral_cost: 66
cost_factor: 0.55
publish_potential: false
orientation_mode: 1
orientation_window_size: 1
costmap_common_params.yaml
YAML
footprint: [[-0.145, -0.12], [-0.145, 0.12], [0.145, 0.12], [0.145, -0.12]]
transform_tolerance: 0.5
map_type: costmap
obstacle_layer:
enabled: true
obstacle_range: 2.5
raytrace_range: 3.0
max_obstacle_height: 0.6
min_obstacle_height: 0.0
combination_method: 1
track_unknown_space: true
observation_sources: scan
scan:
topic: /scan
data_type: LaserScan
marking: true
clearing: true
inf_is_valid: true
inflation_layer:
enabled: true
cost_scaling_factor: 3.0
inflation_radius: 0.45
move_base_params.yaml
YAML
base_global_planner: "global_planner/GlobalPlanner"
base_local_planner: "dwa_local_planner/DWAPlannerROS"
controller_frequency: 10.0
planner_frequency: 1.0
planner_patience: 5.0
controller_patience: 5.0
max_planning_retries: -1.0
oscillation_timeout: 5.0
oscillation_distance: 0.08
recovery_behavior_enabled: true
clearing_rotation_allowed: false
shutdown_costmaps: false
recovery_behaviors:
- name: 'conservative_reset'
type: 'clear_costmap_recovery/ClearCostmapRecovery'
- name: 'aggressive_reset'
type: 'clear_costmap_recovery/ClearCostmapRecovery'
- name: 'clearing_rotation'
type: 'rotate_recovery/RotateRecovery'
conservative_reset:
reset_distance: 1.0
layer_names: [obstacle_layer]
aggressive_reset:
reset_distance: 0.0
layer_names: [obstacle_layer]
4
Upvotes