ROS Navigation-----dwa_planner_ros类

类的成员变量:
private:
tf::TransformListener* tf_; ///< @brief Used for transforming point clouds
ros::Publisher g_plan_pub_, l_plan_pub_; // for visualisation, publishers of global and local plan
base_local_planner::LocalPlannerUtil planner_util_; //该帮助接口提供了通用的接口可供所有规划器使用。它管理当前的全局规划,当前的运动约束,以及当前的代价地图(感知障碍物的局部代价地图)。
boost::shared_ptr dp_; ///< @brief The trajectory controller
costmap_2d::Costmap2DROS* costmap_ros_;
dynamic_reconfigure::Server *dsrv_;
dwa_local_planner::DWAPlannerConfig default_config_;
bool setup_;
tf::Stamped current_pose_;
base_local_planner::LatchedStopRotateController latchedStopRotateController_; //当机器人足够靠近目标时可以迅速启用。 该控制器将执行完全停止操作,让机器人停在目标允许的公差范围内。
bool initialized_;
base_local_planner::OdometryHelperRos odom_helper_;
std::string odom_topic_;

类的成员函数:
public:
1. DWAPlannerROS();
/**
* @brief Constructor for DWAPlannerROS wrapper
*/
2. void initialize(std::string name, tf::TransformListener* tf,
costmap_2d::Costmap2DROS* costmap_ros);
/**
* @brief Constructs the ros wrapper
* @param name The name to give this instance of the trajectory planner
* @param tf A pointer to a transform listener
* @param costmap The cost map to use for assigning costs to trajectories
*/
3. ~DWAPlannerROS();
4. bool computeVelocityCommands(geometry_msgs::Twist& cmd_vel);
5. bool dwaComputeVelocityCommands(tf::Stamped& global_pose, geometry_msgs::Twist& cmd_vel);
6. bool setPlan(const std::vector& orig_global_plan);
/**
* @brief Set the plan that the controller is following
* @param orig_global_plan The plan to pass to the controller
* @return True if the plan was updated successfully, false otherwise
*/
7. bool isGoalReached();
8. bool isInitialized() {return initialized_;}

private:
/**
* @brief Callback to update the local planner’s parameters based on dynamic reconfigure
*/
void reconfigureCB(DWAPlannerConfig &config, uint32_t level);

  void publishLocalPlan(std::vector<geometry_msgs::PoseStamped>& path);

  void publishGlobalPlan(std::vector<geometry_msgs::PoseStamped>& path);
  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值