Nav2 Navigation Stack - jazzy
jazzy
ROS 2 Navigation Stack
|
An action server Behavior for spinning in. More...
#include <nav2_behaviors/include/nav2_behaviors/plugins/drive_on_heading.hpp>
Public Member Functions | |
DriveOnHeading () | |
A constructor for nav2_behaviors::DriveOnHeading. | |
ResultStatus | onRun (const std::shared_ptr< const typename ActionT::Goal > command) override |
Initialization to run behavior. More... | |
ResultStatus | onCycleUpdate () override |
Loop function to run behavior. More... | |
CostmapInfoType | getResourceInfo () override |
Method to determine the required costmap info. More... | |
![]() | |
TimedBehavior () | |
A TimedBehavior constructor. | |
virtual void | onCleanup () |
virtual void | onActionCompletion (std::shared_ptr< typename ActionT::Result >) |
void | configure (const rclcpp_lifecycle::LifecycleNode::WeakPtr &parent, const std::string &name, std::shared_ptr< tf2_ros::Buffer > tf, std::shared_ptr< nav2_costmap_2d::CostmapTopicCollisionChecker > local_collision_checker, std::shared_ptr< nav2_costmap_2d::CostmapTopicCollisionChecker > global_collision_checker) override |
void | cleanup () override |
Method to cleanup resources used on shutdown. | |
void | activate () override |
Method to active Behavior and any threads involved in execution. | |
void | deactivate () override |
Method to deactive Behavior and any threads involved in execution. | |
![]() | |
virtual | ~Behavior () |
Virtual destructor. | |
Protected Member Functions | |
bool | isCollisionFree (const double &distance, const geometry_msgs::msg::Twist &cmd_vel, geometry_msgs::msg::Pose2D &pose2d) |
Check if pose is collision free. More... | |
void | onConfigure () override |
Configuration of behavior action. | |
![]() | |
void | execute () |
void | stopRobot () |
Protected Attributes | |
ActionT::Feedback::SharedPtr | feedback_ |
geometry_msgs::msg::PoseStamped | initial_pose_ |
double | command_x_ |
double | command_speed_ |
rclcpp::Duration | command_time_allowance_ {0, 0} |
rclcpp::Time | end_time_ |
double | simulate_ahead_time_ |
![]() | |
rclcpp_lifecycle::LifecycleNode::WeakPtr | node_ |
std::string | behavior_name_ |
std::unique_ptr< nav2_util::TwistPublisher > | vel_pub_ |
std::shared_ptr< ActionServer > | action_server_ |
std::shared_ptr< nav2_costmap_2d::CostmapTopicCollisionChecker > | local_collision_checker_ |
std::shared_ptr< nav2_costmap_2d::CostmapTopicCollisionChecker > | global_collision_checker_ |
std::shared_ptr< tf2_ros::Buffer > | tf_ |
double | cycle_frequency_ |
double | enabled_ |
std::string | local_frame_ |
std::string | global_frame_ |
std::string | robot_base_frame_ |
double | transform_tolerance_ |
rclcpp::Duration | elasped_time_ |
rclcpp::Clock::SharedPtr | clock_ |
rclcpp::Logger | logger_ |
Additional Inherited Members | |
![]() | |
using | ActionServer = nav2_util::SimpleActionServer< nav2_msgs::action::DriveOnHeading > |
![]() | |
using | Ptr = std::shared_ptr< Behavior > |
An action server Behavior for spinning in.
Definition at line 37 of file drive_on_heading.hpp.
|
inlineoverridevirtual |
Method to determine the required costmap info.
Implements nav2_core::Behavior.
Definition at line 156 of file drive_on_heading.hpp.
|
inlineprotected |
Check if pose is collision free.
distance | Distance to check forward |
cmd_vel | current commanded velocity |
pose2d | Current pose |
Definition at line 166 of file drive_on_heading.hpp.
Referenced by nav2_behaviors::DriveOnHeading< ActionT >::onCycleUpdate().
|
inlineoverridevirtual |
Loop function to run behavior.
Implements nav2_behaviors::TimedBehavior< nav2_msgs::action::DriveOnHeading >.
Definition at line 97 of file drive_on_heading.hpp.
References nav2_behaviors::DriveOnHeading< ActionT >::isCollisionFree().
|
inlineoverridevirtual |
Initialization to run behavior.
command | Goal to execute |
Implements nav2_behaviors::TimedBehavior< nav2_msgs::action::DriveOnHeading >.
Definition at line 61 of file drive_on_heading.hpp.