Class WaypointFollower
Defined in File waypoint_follower.hpp
Inheritance Relationships
Base Type
public nav2_util::LifecycleNode
Class Documentation
An action server that uses behavior tree for navigating a robot to its goal position.
Public Types
Public Functions
A constructor for nav2_waypoint_follower::WaypointFollower class.
- Parameters:
options – Additional options to control creation of the node.
A destructor for nav2_waypoint_follower::WaypointFollower class.
Protected Functions
Configures member variables.
Initializes action server for “follow_waypoints”
- Parameters:
state – Reference to LifeCycle node state
- Returns:
SUCCESS or FAILURE
Activates action server.
- Parameters:
state – Reference to LifeCycle node state
- Returns:
SUCCESS or FAILURE
Deactivates action server.
- Parameters:
state – Reference to LifeCycle node state
- Returns:
SUCCESS or FAILURE
Resets member variables.
- Parameters:
state – Reference to LifeCycle node state
- Returns:
SUCCESS or FAILURE
Called when in shutdown state.
- Parameters:
state – Reference to LifeCycle node state
- Returns:
SUCCESS or FAILURE
Templated function to perform internal logic behind waypoint following, Both GPS and non GPS waypoint following callbacks makes use of this function when a client asked to do so. Callbacks fills in appropriate types for the tempelated types, see followWaypointCallback funtions for details.
- Template Parameters:
T – action_server
V – feedback
Z – result
- Parameters:
action_server –
poses –
feedback –
result –
Action server callbacks.
send robot through each of GPS point , which are converted to map frame first then using a client to
FollowWaypoints
action.- Parameters:
waypoints, acquired – from action client
Action client result callback.
- Parameters:
result – Result of action server updated asynchronously
Action client goal response callback.
- Parameters:
goal – Response of action server updated asynchronously
given some gps_poses, converts them to map frame using robot_localization’s service
fromLL
. Constructs a vector of stamped poses in map frame and returns them.- Parameters:
gps_poses, from – the action server
- Returns:
std::vector<geometry_msgs::msg::PoseStamped>
get the latest poses on the action server goal. If they are GPS poses, convert them to the global cartesian frame using /fromLL robot localization server
- Parameters:
action_server, to – which the goal was sent
- Returns:
std::vector<geometry_msgs::msg::PoseStamped>
Callback executed when a parameter change is detected.
- Parameters:
event – ParameterEvent message
Protected Attributes