Skip to content

Commit 5fae611

Browse files
xgroleauEtienne
andauthored
Feat/swarinfo 317/dwa planner (#72)
* Simulation launch file update - Removed communication broker - Added a garage world for more realistic obstacle avoidance - Added dependency to the turlebot3_gazebo that contains the garage map * Removed Teleop pluggin in Rviz - The teleop pluggin issues null cmd vel all the time even when the move_base is moving around. It has the behavior to slow down the behavior move_base and prevent it to working correctly * Updated rviz config to support dwa - Changed local plan and global plan name * Add DWA Planner - Added DWA planner params - Added move_base config file for conveniancy - Adjusted navigation.launch to support DWA * Resolution and base global planner - Include base Global planner - Decreased the cell sizes of the costmap (increase resolution) * WIP planner frequency and increased footprint * Footprint clearing and local map decrease -Removed the behavior of footprint clearing since sometimes some obstacle - Decreased local map size to remove an oscillation problem * Reduce costmap, disable footprint clearing and re adding global planner * Bump roboclaw with velocity fix * Bump roboclaw * Fix name of the namespace of the global planner param * bump submodules * Added comm broker back * Added comment back Co-authored-by: Etienne <vile2094@usherbrooke.ca>
1 parent 37a57ff commit 5fae611

18 files changed

Lines changed: 156 additions & 124 deletions

contrib/roboclaw

src/swarmus_ros_navigation/config/base_global_planner_params.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
1-
BaseGlobalPlanner:
1+
GlobalPlanner:
22
allow_unknow: True # Specifies if the unknow grid cells should be use to plan the trajectory
33
default_tolerance: 0.0 # Tolerance around the goal
44

5-
use_dijkstra: false # If true, use Dijkstra's algorithm. Otherwise, use A*.
5+
use_dijkstra: false # If true, use Dijkstra's algorithm. Otherwise, use A*.
66
use_quadratic: true # If true, use the quadratic approximation of the potential. Otherwise, use a simpler calculation
77
use_grid_path: false # If true, create a path that follows the grid boundaries. Otherwise, use a gradient descent method
88
old_navfn_behavior: false # If true, the planner will mirror the behavior of navfn
99

1010
lethal_cost: 253 # Lethal cost (can be changed with dynamic reconfiguring)
11-
neutral_cost : 50 # Neutral Cost
11+
neutral_cost : 66 # Neutral Cost
1212
cost_factor: 0.8 # Factor to multiply each cost from costmap by (can be changed with dynamic reconfiguring)
1313

1414
publish_potential: true # Publish Potential Costmap (can be changed with dynamic reconfiguring)

src/swarmus_ros_navigation/config/base_local_planner_params.yaml

Lines changed: 0 additions & 50 deletions
This file was deleted.

src/swarmus_ros_navigation/config/costmap_common_params.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
#---(in meters)---
2-
footprint: [ [-0.3425,-0.195], [0.1425,-0.195], [0.1425,0.195], [-0.3425,0.195] ]
2+
footprint: [ [-0.3625,-0.215], [0.1625,-0.215], [0.1625,0.215], [-0.3625,0.215] ]
33

44
obstacle_layer:
55
enabled: true
66
obstacle_range: 2.5
77
raytrace_range: 3.0
88
track_unknown_space: false
9-
footprint_clearing_enabled: true
9+
footprint_clearing_enabled: false
1010
combination_method: 1
1111

1212
observation_sources: laser_scan_sensor
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
# See here for documentation: http://wiki.ros.org/dwa_local_planner
2+
DWAPlannerROS:
3+
4+
# Robot Configuration Parameters
5+
max_vel_x: 0.3
6+
min_vel_x: -0.2
7+
8+
max_vel_y: 0.0
9+
min_vel_y: 0.0
10+
11+
# The velocity when robot is moving in a straight line
12+
max_vel_trans: 0.3
13+
min_vel_trans: 0.06
14+
15+
# weirdly enough, parameters don't work with names given in documentation
16+
max_vel_theta: 1.0
17+
min_vel_theta: 0.05
18+
19+
acc_lim_x: 0.6
20+
acc_lim_y: 0.0
21+
acc_lim_theta: 3.7
22+
23+
# Goal Tolerance Parametes
24+
xy_goal_tolerance: 0.1
25+
yaw_goal_tolerance: 0.2
26+
latch_xy_goal_tolerance: true
27+
28+
# Forward Simulation Parameters
29+
sim_time: 2.0
30+
vx_samples: 10
31+
vy_samples: 0
32+
vth_samples: 40
33+
sim_granularity: 0.025
34+
controller_frequency: 20.0
35+
36+
# Trajectory Scoring Parameters
37+
path_distance_bias: 32.0
38+
goal_distance_bias: 20.0
39+
occdist_scale: 0.02
40+
forward_point_distance: 0.325
41+
stop_time_buffer: 0.15
42+
scaling_speed: 0.2
43+
max_scaling_factor: 0.2
44+
prune_plan: true
45+
46+
# Oscillation Prevention Parameters
47+
oscillation_reset_dist: 0.01
48+
49+
# Debugging
50+
publish_traj_pc : false
51+
publish_cost_grid: true

src/swarmus_ros_navigation/config/global_costmap_params.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ global_costmap:
66
rolling_window: true
77
width: 10.0
88
height: 10.0
9-
resolution: 0.05
9+
resolution: 0.025
1010
transform_tolerance: 0.5
1111

1212
plugins:

src/swarmus_ros_navigation/config/global_costmap_with_map_params.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ global_costmap:
66
rolling_window: false
77
width: 10.0
88
height: 10.0
9-
resolution: 0.05
9+
resolution: 0.025
1010
transform_tolerance: 0.5
1111

1212
plugins:

src/swarmus_ros_navigation/config/local_costmap_params.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@ local_costmap:
55
publish_frequency: 10
66
static_map: false
77
rolling_window: true
8-
width: 6.0
9-
height: 6.0
10-
resolution: 0.05
8+
width: 3.0
9+
height: 3.0
10+
resolution: 0.025
1111
transform_tolerance: 0.5
1212

1313
plugins:
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
shutdown_costmaps: false
2+
controller_frequency: 20.0
3+
planner_patience: 5.0
4+
controller_patience: 15.0
5+
conservative_reset_dist: 3.0
6+
planner_frequency: 0 #1
7+
oscillation_timeout: 15.0
8+
oscillation_distance: 0.05
9+
holonomic_robot: false

src/swarmus_ros_navigation/launch/navigation.launch

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@
66
<!-- Navigation -->
77
<node pkg="move_base" type="move_base" respawn="false" name="move_base" output="screen">
88
<!-- Load common parameters of the local and global planner-->
9+
<param name="base_local_planner" value="dwa_local_planner/DWAPlannerROS"/>
10+
<param name="base_global_planner" value="global_planner/GlobalPlanner"/>
11+
912
<rosparam file="$(find swarmus_ros_navigation)/config/costmap_common_params.yaml" command="load" ns="global_costmap" subst_value="true"/>
1013
<rosparam file="$(find swarmus_ros_navigation)/config/costmap_common_params.yaml" command="load" ns="local_costmap" subst_value="true"/>
1114

@@ -14,9 +17,9 @@
1417

1518
<rosparam file="$(find swarmus_ros_navigation)/config/local_costmap_params.yaml" command="load" subst_value="true"/>
1619

17-
<rosparam file="$(find swarmus_ros_navigation)/config/base_local_planner_params.yaml" command="load" subst_value="true"/>
20+
<rosparam file="$(find swarmus_ros_navigation)/config/move_base_params_pioneer.yaml" command="load" />
1821

1922
<rosparam file="$(find swarmus_ros_navigation)/config/base_global_planner_params.yaml" command="load" subst_value="true"/>
20-
23+
<rosparam file="$(find swarmus_ros_navigation)/config/dwa_local_planner_params_pioneer.yaml" command="load"/>
2124
</node>
2225
</launch>

0 commit comments

Comments
 (0)