actionlib server that plans and executes paths for the robot base More...
#include <pathPlanner.h>
actionlib server that plans and executes paths for the robot base
This class implements an actionlib server to plan paths for the robot base. The paths are planned by constructing a costmap with costmap2d and using the A* algorithm in navfn. Once a path is planned, it will be followed until the goal is reached, or until a new goal is given.
Definition at line 57 of file pathPlanner.h.
pathPlanner::pathPlanner | ( | std::string | name | ) |
Constructor to initialize parameters, publishers, and subscribers
name | the name of the action server |
Definition at line 14 of file pathPlanner.cpp.
Destructor
Definition at line 84 of file pathPlanner.cpp.
void pathPlanner::executePathPlanning | ( | const youbot_overhead_localization::PlanPathGoalConstPtr & | goal | ) |
Callback for the action lib service for path planning and following
goal | the location to move the robot to |
Definition at line 93 of file pathPlanner.cpp.
void pathPlanner::followPath | ( | ) |
Follow the planned path
Definition at line 171 of file pathPlanner.cpp.
bool pathPlanner::getCost | ( | youbot_overhead_localization::GetCost::Request & | req, |
youbot_overhead_localization::GetCost::Response & | res | ||
) |
Service handler to return the costmap cost at a given point
req | service request |
res | service response |
Definition at line 519 of file pathPlanner.cpp.
void pathPlanner::localizationCallback | ( | const youbot_overhead_localization::Pose2d & | newPose | ) |
Callback to update the localization
newPose | the new position of the robot |
Definition at line 294 of file pathPlanner.cpp.
int pathPlanner::makePlanAstar | ( | ) |
Calculate a path using Astar
Definition at line 363 of file pathPlanner.cpp.
void pathPlanner::mapserverCallback | ( | const nav_msgs::OccupancyGridConstPtr & | newMap | ) |
Load a new map into the costmap object and initialize the nav functions with the new map
newMap | the new map to be converted into a cost map |
Definition at line 312 of file pathPlanner.cpp.
void pathPlanner::printCostmap | ( | ) |
Print out the cost map to a text file for debugging
Definition at line 571 of file pathPlanner.cpp.
void pathPlanner::printOccupancyGrid | ( | ) |
Print out the occupancy grid to a text file for debugging
Definition at line 535 of file pathPlanner.cpp.
std::string pathPlanner::actionName |
Definition at line 72 of file pathPlanner.h.
Definition at line 119 of file pathPlanner.h.
Definition at line 71 of file pathPlanner.h.
Definition at line 73 of file pathPlanner.h.
Definition at line 74 of file pathPlanner.h.
geometry_msgs::Twist pathPlanner::baseCommand |
Definition at line 122 of file pathPlanner.h.
Definition at line 62 of file pathPlanner.h.
double pathPlanner::circumRadius |
Definition at line 105 of file pathPlanner.h.
Definition at line 97 of file pathPlanner.h.
Definition at line 91 of file pathPlanner.h.
Definition at line 67 of file pathPlanner.h.
Definition at line 63 of file pathPlanner.h.
Definition at line 106 of file pathPlanner.h.
Definition at line 68 of file pathPlanner.h.
Definition at line 78 of file pathPlanner.h.
float pathPlanner::goalx |
Definition at line 86 of file pathPlanner.h.
float pathPlanner::goaly |
Definition at line 87 of file pathPlanner.h.
double pathPlanner::inflationRadius |
Definition at line 107 of file pathPlanner.h.
double pathPlanner::inRadius |
Definition at line 108 of file pathPlanner.h.
Definition at line 101 of file pathPlanner.h.
Definition at line 65 of file pathPlanner.h.
std::vector<unsigned char> pathPlanner::mapData |
Definition at line 116 of file pathPlanner.h.
std::string pathPlanner::mapDebugLocation |
Definition at line 83 of file pathPlanner.h.
std::string pathPlanner::mapFileName |
Definition at line 82 of file pathPlanner.h.
unsigned int pathPlanner::mapHeight |
Definition at line 103 of file pathPlanner.h.
double pathPlanner::mapOriginx |
Definition at line 109 of file pathPlanner.h.
double pathPlanner::mapOriginy |
Definition at line 110 of file pathPlanner.h.
double pathPlanner::mapResolution |
Definition at line 111 of file pathPlanner.h.
Definition at line 66 of file pathPlanner.h.
unsigned int pathPlanner::mapWidth |
Definition at line 104 of file pathPlanner.h.
Definition at line 112 of file pathPlanner.h.
Definition at line 61 of file pathPlanner.h.
Definition at line 98 of file pathPlanner.h.
Definition at line 94 of file pathPlanner.h.
double pathPlanner::obstacleRange |
Definition at line 113 of file pathPlanner.h.
Definition at line 88 of file pathPlanner.h.
Definition at line 64 of file pathPlanner.h.
Definition at line 77 of file pathPlanner.h.
float pathPlanner::prevError |
Definition at line 128 of file pathPlanner.h.
timespec pathPlanner::prevPointTime |
Definition at line 125 of file pathPlanner.h.
Definition at line 129 of file pathPlanner.h.
double pathPlanner::raytraceRange |
Definition at line 114 of file pathPlanner.h.
float pathPlanner::totalError |
Definition at line 130 of file pathPlanner.h.
Definition at line 131 of file pathPlanner.h.
Definition at line 115 of file pathPlanner.h.
Definition at line 102 of file pathPlanner.h.
bool pathPlanner::useSim |
Definition at line 79 of file pathPlanner.h.