Class ConstrainedSmoother

Inheritance Relationships

Base Type

  • public nav2_core::Smoother

Class Documentation

class ConstrainedSmoother : public nav2_core::Smoother

Regulated pure pursuit controller plugin.

Public Functions

ConstrainedSmoother() = default

Constructor for nav2_constrained_smoother::ConstrainedSmoother.

~ConstrainedSmoother() override = default

Destrructor for nav2_constrained_smoother::ConstrainedSmoother.

void configure(const rclcpp_lifecycle::LifecycleNode::WeakPtr &parent, std::string name, std::shared_ptr<tf2_ros::Buffer> tf, std::shared_ptr<nav2_costmap_2d::CostmapSubscriber> costmap_sub, std::shared_ptr<nav2_costmap_2d::FootprintSubscriber> footprint_sub) override

Configure smoother parameters and member variables.

Parameters:
  • parent – WeakPtr to node

  • name – Name of plugin

  • tf – TF buffer

  • costmap_ros – Costmap2DROS object of environment

virtual void cleanup() override

Cleanup controller state machine.

virtual void activate() override

Activate controller state machine.

virtual void deactivate() override

Deactivate controller state machine.

virtual bool smooth(nav_msgs::msg::Path &path, const rclcpp::Duration &max_time) override

Method to smooth given path.

Parameters:
  • path – In-out path to be optimized

  • max_time – Maximum duration smoothing should take

Returns:

Smoothed path

Protected Attributes

std::shared_ptr<tf2_ros::Buffer> tf_
std::string plugin_name_
std::shared_ptr<nav2_costmap_2d::CostmapSubscriber> costmap_sub_
rclcpp::Logger logger_ = {rclcpp::get_logger("ConstrainedSmoother")}
std::unique_ptr<nav2_constrained_smoother::Smoother> smoother_
SmootherParams smoother_params_
OptimizerParams optimizer_params_