Humble to Iron¶
Moving from ROS 2 Humble to Iron, a number of stability improvements were added that we will not specifically address here.
Added Collision Monitor¶
PR 2982 adds new safety layer operating independently of Nav2 stack which ensures the robot to control the collisions with near obstacles, obtained from different sensors (LaserScan, PointCloud, IR, Sonars, etc…). See Collision Monitor for more details. It is not included in the default bringup batteries included from nav2_bringup
.
Removed use_sim_time from yaml¶
PR #3131 makes it possible to set the use_sim_time parameter from the launch file for multiple nodes instead of individually via the yaml files. If using the Nav2 launch files, you can optionally remove the use_sim_time parameter from your yaml files and set it via a launch argument.
Run-time Speed up of Smac Planner¶
The core data structure of the graph implementation in the Smac Planner framework was swapped out in PR 3201 to using a specialized unordered map implementation. This speeds up the planner by 10% on trivial requests and reports up to 30% on complex plans that involve numerous rehashings.
Recursive Refinement of Smac and Simple Smoothers¶
The number of recursive refinements for the Simple and Smac Planner Smoothers have been exposed under the refinement_num
parameter. Previous behavior had this hardcoded if do_refinement = True
to 4
. Now, default is 2
to help decrease out-of-the-box over smoothing reducing in paths closer to collision than probably ideal, but old behavior can be achieved by changing this to 4
.
Simple Commander Python API¶
PR 3159 and follow-up PRs add in Costmap API in Python3 simple commander to receive OccupancyGrid
messages from Nav2 and be able to work with them natively in Python3, analog to the C++ Costmap API. It also includes a line iterator and collision checking object to perform footprint or other collision checking in Python3. See the Simple Commander API for more details.
Smac Planner Start Pose Included in Path¶
PR 3168 adds the starting pose to the Smac Planners that was previously excluded during backtracing.
Parameterizable Collision Checking in RPP¶
PR 3204 adds makes collision checking for RPP optional (default on).
Expanded Planner Benchmark Tests¶
PR 3218 adds launch files and updated scripts for performing objective random planning tests across the planners in Nav2 for benchmarking and metric computation.
Smac Planner Path Tolerances¶
PR 3219 adds path tolerances to Hybrid-A* and State Lattice planners to return approximate paths if exact paths cannot be found, within a configurable tolerance aroun the goal pose.
costmap_2d_node default constructor¶
PR #3222 changes the constructor used by the standalone costmap node. The new constructor does not set a name and namespace internally so it can be set via the launch file.
Costmap Filters¶
Costmap Filters now are have an ability to be enabled/disabled in run-time by calling toggle_filter
service for appropriate filter (PR #3229).
Added new binary flip filter, allowing e.g. to turn off camera in sensitive areas, turn on headlights/leds/other safety things or switch operating mode when robot is inside marked on mask areas (PR #3228).
Savitzky-Golay Smoother¶
Adding a new smoother algorithm, the Savitzky-Golay smoother to the smoother server plugin list. See the configuration guide Savitzky-Golay Smoother for more details.
Changes to Map yaml file path for map_server node in Launch¶
PR #3174 adds a way to set the path to map yaml file for the map_server node either from the yaml file or using the launch configuration parameter map
giving priority to the launch configuration parameter. yaml_filename
is no longer strictly required to be present in nav2_params.yaml
.
SmootherSelector BT Node¶
PR #3283 adds a BT node to set the smoother based on a topic or a default. See the configuration guide SimpleSmoother for more details.
Publish Costmap Layers¶
PR #3320 adds the ability for the nav2_costmap_2d package to publish out costmap data associated with each layer.
Give Behavior Server Access to Both Costmaps¶
PR #3255 addes the ability for a behavior to access the local and global costmap.
To update behaviors, any reference to the global_frame must be updated to the local_frame parameter
along with the configuration
method which now takes in the local and global collision checkers.
Lastly, getResourceInfo
must be overriden to return CostmapInfoType::LOCAL
. Other options include GLOBAL
if the behavior useses global costmap and/or footprint)
or BOTH
if both are required. This allows us to only create and maintain the minimum amount of expensive resources.
New Model Predictive Path Integral Controller¶
The new Nav2 MPPI Controller is a predictive controller - a successor to TEB and pure path tracking MPC controllers - with Nav2. It uses a sampling based approach to select optimal trajectories, optimizing between successive iterations. It contains plugin-based objective functions for customization and extension for various behaviors and behavioral attributes.
See the README.md and Model Predictive Path Integral Controller page for more detail.
Behavior Tree Uses Error Codes¶
PR #3324 adds three new condition nodes to check for error codes on the blackboard set by action BT nodes which contain them.
The AreErrorCodesPresent
condition node allows the user to specify the error code from the server along with the error codes to match against.
The WouldAControllerRecoveryHelp
checks if the active error code is UNKNOWN, PATIENCE_EXCEEDED, FAILED_TO_MAKE_PROGRESS or NO_VALID_CONTROL.
If the error code is a match, the condition returns SUCCESS
.
These error code are potentially able to be cleared by a controller recovery.
The WouldAPlannerRecoveryHelp
checks if the active error code is UNKNOWN, NO_VALID_CONTROL, or TIMEOUT.
If the error code is a match, the condition returns SUCCESS
.
These error code are potentially able to be cleared by a planner recovery.
The WouldASmootherRecoveryHelp
checks if the active error code is UNKNOWN, TIMEOUT, FAILED_TO_SMOOTH_PATH, or SMOOTHED_PATH_IN_COLLISION.
If the error code is a match, the condition returns SUCCESS
.
These error code are potentially able to be cleared by a smoother recovery.
DWB Forward vs Reverse Pruning¶
PR #3374 adds a new forward_prune_distance
parameter in the DWB controller. It replaces the prune_distance
for forward path shortening, enabled through the shorten_transformed_plan
boolean parameter. This change allows to use different values for forward and backward path shortening.
More stable regulation on curves for long lookahead distances¶
PR #3414 adds a new use_fixed_curvature_lookahead
parameter to the RPP controller. This makes slowing down on curve not dependent on the instantaneous lookahead point, but instead on a fixed distance set by the parameter curvature_lookahead_dist
.