Function-object for handling the path from Planner Server.
More...
#include <nav2_core/include/nav2_core/path_handler.hpp>
|
| virtual void | initialize (const nav2::LifecycleNode::WeakPtr &parent, const rclcpp::Logger &logger, const std::string &plugin_name, const std::shared_ptr< nav2_costmap_2d::Costmap2DROS > costmap_ros, nav2::TransformBuffer::SharedPtr tf)=0 |
| | Initialize parameters. More...
|
| |
| virtual void | setPlan (const nav_msgs::msg::Path &path)=0 |
| | Set new reference plan. More...
|
| |
| virtual PathSegment | findPlanSegment (const geometry_msgs::msg::PoseStamped &pose)=0 |
| | Determines the portion of the global plan to be used for local control. This function locates the start and end iterators of the global plan segment that is relevant for controller computation based on the robot's current pose and local costmap. More...
|
| |
| virtual nav_msgs::msg::Path | transformLocalPlan (const PathIterator &closest_point, const PathIterator &pruned_plan_end)=0 |
| | Transforms a predefined segment of the global plan into the costmap global frame. More...
|
| |
| virtual geometry_msgs::msg::PoseStamped | getTransformedGoal (const builtin_interfaces::msg::Time &stamp)=0 |
| | Get the global goal pose transformed to the costmap global frame. More...
|
| |
Function-object for handling the path from Planner Server.
This class defines the plugin interface used by the Controller Server to manage the path received from the Planner Server. Its primary responsibilities are pruning path segments the robot has already traversed and transforming the remaining, relevant portion of the path into the costmap's global or base frame.
Definition at line 43 of file path_handler.hpp.
◆ findPlanSegment()
| virtual PathSegment nav2_core::PathHandler::findPlanSegment |
( |
const geometry_msgs::msg::PoseStamped & |
pose | ) |
|
|
pure virtual |
Determines the portion of the global plan to be used for local control. This function locates the start and end iterators of the global plan segment that is relevant for controller computation based on the robot's current pose and local costmap.
- Parameters
-
| pose | Robot pose in odom frame |
- Returns
- PathSegment A pair of iterators defining the start and end of the selected plan segment.
Implemented in nav2_controller::FeasiblePathHandler.
◆ getTransformedGoal()
| virtual geometry_msgs::msg::PoseStamped nav2_core::PathHandler::getTransformedGoal |
( |
const builtin_interfaces::msg::Time & |
stamp | ) |
|
|
pure virtual |
Get the global goal pose transformed to the costmap global frame.
- Parameters
-
| stamp | Time to get the goal pose at |
- Returns
- Transformed goal pose
Implemented in nav2_controller::FeasiblePathHandler.
◆ initialize()
| virtual void nav2_core::PathHandler::initialize |
( |
const nav2::LifecycleNode::WeakPtr & |
parent, |
|
|
const rclcpp::Logger & |
logger, |
|
|
const std::string & |
plugin_name, |
|
|
const std::shared_ptr< nav2_costmap_2d::Costmap2DROS > |
costmap_ros, |
|
|
nav2::TransformBuffer::SharedPtr |
tf |
|
) |
| |
|
pure virtual |
Initialize parameters.
- Parameters
-
| parent | Lifecycle node pointer |
| logger | Node logging interface |
| plugin_name | Name of the plugin |
| costmap_ros | Costmap2DROS object |
| tf | Shared ptr of TF2 buffer |
Implemented in nav2_controller::FeasiblePathHandler.
◆ setPlan()
| virtual void nav2_core::PathHandler::setPlan |
( |
const nav_msgs::msg::Path & |
path | ) |
|
|
pure virtual |
◆ transformLocalPlan()
| virtual nav_msgs::msg::Path nav2_core::PathHandler::transformLocalPlan |
( |
const PathIterator & |
closest_point, |
|
|
const PathIterator & |
pruned_plan_end |
|
) |
| |
|
pure virtual |
Transforms a predefined segment of the global plan into the costmap global frame.
- Parameters
-
| closest_point | Iterator to the starting pose of the path segment. |
| pruned_plan_end | Iterator to the ending pose of the path segment. |
- Returns
- nav_msgs::msg::Path The transformed local plan segment in the costmap global frame.
Implemented in nav2_controller::FeasiblePathHandler.
The documentation for this class was generated from the following file: