37 #ifndef POSE_FOLLOWER_POSE_FOLLOWER_H_ 38 #define POSE_FOLLOWER_POSE_FOLLOWER_H_ 45 #include <geometry_msgs/PoseStamped.h> 46 #include <geometry_msgs/Twist.h> 47 #include <nav_msgs/Odometry.h> 48 #include <pose_follower/PoseFollowerConfig.h> 49 #include <dynamic_reconfigure/server.h> 59 bool setPlan(
const std::vector<geometry_msgs::PoseStamped>& global_plan);
63 inline double sign(
double n){
64 return n < 0.0 ? -1.0 : 1.0;
68 geometry_msgs::Twist
limitTwist(
const geometry_msgs::Twist& twist);
69 double headingDiff(
double pt_x,
double pt_y,
double x,
double y,
double heading);
73 std::vector<geometry_msgs::PoseStamped>& transformed_plan);
75 void odomCallback(
const nav_msgs::Odometry::ConstPtr& msg);
78 void reconfigureCB(pose_follower::PoseFollowerConfig &config, uint32_t level);
90 dynamic_reconfigure::Server<pose_follower::PoseFollowerConfig> *
dsrv_;
void odomCallback(const nav_msgs::Odometry::ConstPtr &msg)
ros::Publisher global_plan_pub_
ros::Subscriber odom_sub_
base_local_planner::TrajectoryPlannerROS collision_planner_
unsigned int current_waypoint_
bool turn_in_place_first_
ros::Time goal_reached_time_
void publishPlan(const std::vector< geometry_msgs::PoseStamped > &path, const ros::Publisher &pub)
double max_heading_diff_before_moving_
double trans_stopped_velocity_
double headingDiff(double pt_x, double pt_y, double x, double y, double heading)
tf::TransformListener * tf_
bool setPlan(const std::vector< geometry_msgs::PoseStamped > &global_plan)
TFSIMD_FORCE_INLINE const tfScalar & y() const
std::vector< geometry_msgs::PoseStamped > global_plan_
double tolerance_timeout_
bool transformGlobalPlan(const tf::TransformListener &tf, const std::vector< geometry_msgs::PoseStamped > &global_plan, const costmap_2d::Costmap2DROS &costmap, const std::string &global_frame, std::vector< geometry_msgs::PoseStamped > &transformed_plan)
void reconfigureCB(pose_follower::PoseFollowerConfig &config, uint32_t level)
bool computeVelocityCommands(geometry_msgs::Twist &cmd_vel)
TFSIMD_FORCE_INLINE const tfScalar & x() const
double in_place_trans_vel_
void initialize(std::string name, tf::TransformListener *tf, costmap_2d::Costmap2DROS *costmap_ros)
double rot_stopped_velocity_
dynamic_reconfigure::Server< pose_follower::PoseFollowerConfig > * dsrv_
geometry_msgs::Twist diff2D(const tf::Pose &pose1, const tf::Pose &pose2)
geometry_msgs::Twist limitTwist(const geometry_msgs::Twist &twist)
double min_in_place_vel_th_
costmap_2d::Costmap2DROS * costmap_ros_
nav_msgs::Odometry base_odom_