AURobotServers
4
|
#include <ureactivepath.h>
Public Attributes | |
UAvoidParams | par |
Protected Attributes | |
UAvoidPath2 | avoidPaths [MAX_PATHS_IN_POOL] |
int | avoidPathsCnt |
int | pathBest |
UReactivePath | paths [MAX_PATHS_IN_POOL] |
int | pathsCnt |
Static Protected Attributes | |
static const int | MAX_PATHS_IN_POOL = 20 |
UAvoidPathPool holds an array of path alternatives and the functionality to select one of these as the best choice.
UAvoidPathPool::UAvoidPathPool | ( | ) |
Constructor
UAvoidPathPool::~UAvoidPathPool | ( | ) |
Destructor
UReactivePath * UAvoidPathPool::findPathToHere | ( | UPoseV | exitPose, |
UReacObstGrps * | obsts, | ||
UReacRoadLines * | roads, | ||
bool | ignoreObstacles, | ||
bool | directTestOnly, | ||
bool | driveon, | ||
double | turnRad | ||
) |
Find path to this destination, avoiding obstacles and road edges
directTestOnly | test only |
driveon | when true, replaces the pose destination with a line destination - as the drive and driveon commands. |
turnRad | is the drive-on turn radius |
References UReactivePath::clear(), UReactivePath::findObstAvoidRoute(), UReactivePath::getManSeq(), UReactivePath::getManTime(), UReactivePath::isACrash(), UReactivePath::isValid(), ULock::lock(), UReactivePath::setExitPose(), and UReactivePath::setPathUsed().
Referenced by UResAvoid::findPathToHere().
UAvoidPath2 * UAvoidPathPool::findPathToHere2 | ( | UPoseV | exitPose, |
UReacObstGrps * | obsts, | ||
UReacRoadLines * | roads, | ||
bool | ignoreObstacles, | ||
bool | debugDump | ||
) |
Find path to this destination, avoiding obstacles (and road edges) using a new method more directly based on visibility graph (simplified)
debugDump | is a flag, that will generate some data-dump to logfile (if open). |
References UAvoidPath2::clear(), UAvoidPath2::findObstAvoidRoute(), UReacObstGrps::getGroup(), UReacObstGrps::getGroupsCnt(), UAvoidPath2::getManSeq(), UAvoidPath2::isACrash(), UAvoidPath2::isValid(), ULock::lock(), UAvoidPath2::setPar(), UAvoidPath2::setPathUsed(), and UAvoidPath2::setValid().
Referenced by UResAvoid::findPathToHere().
|
inline |
Get specific (rev2) path. (NB! no range check)
Referenced by UFunctionAvoid::sendCurrentAvoidPath().
|
inline |
Get number of calculated (rev2) paths
Referenced by UFunctionAvoid::sendCurrentAvoidPath().
|
inline |
Is crashed paths to survive for analysis
Referenced by UReactivePath::avoidObst(), and UReactivePath::findObstAvoidRoute().
|
inline |
Set other limiting parameters for the path evaluation. Units are in SI units (meter and sec) Get max lateral acceleration
Referenced by UReactivePath::findObstAvoidRoute().
|
inline |
Get max obstacle avoidance loops when finding new mid-poses
Referenced by UReactivePath::avoidObst().
|
inline |
Get max nested levels when searching a path left and right around obstacles
Referenced by UReactivePath::avoidObst().
|
inline |
Get max spawnned paths when searching for an obstacle avoidance path
Referenced by UReactivePath::avoidObst().
|
inline |
Get max turn acceleration
Referenced by UReactivePath::findObstAvoidRoute().
|
inline |
Get minimum turn radius - fail manoeuvre if less is needed
Referenced by UReactivePath::findObstAvoidRoute().
UAvoidPath2 * UAvoidPathPool::getNewAvoidPath | ( | ) |
Get pointer to new unused UAvoidPathPool entry. A path may be used by e.g. implementation process. This function will then try the next available unlocked path entry. The path will be unlocked once implemented or discarded for other reasons.
References UAvoidPath2::getManSeq(), UAvoidPath2::isValid(), UAvoidPath2::setPathUsed(), UAvoidPath2::setValid(), ULock::tryLock(), and ULock::unlock().
UReactivePath * UAvoidPathPool::getNewPath | ( | ) |
Get pointer to an unused path
References UReactivePath::getManSeq(), UReactivePath::isValid(), UReactivePath::setPathUsed(), UReactivePath::setValid(), ULock::tryLock(), and ULock::unlock().
Referenced by UReactivePath::avoidObst().
|
inline |
Get minimum distance to obstacle
Referenced by UReactivePath::avoidObst().
|
inline |
Get minimum distance to obstacle
Referenced by UReactivePath::avoidObst().
|
inline |
Get pointer to obstacle avoidance parameters - to assign new values
Referenced by UResAvoid::findPathToHere().
|
inline |
Get specific path. (NB! no range check)
Referenced by UFunctionAvoid::sendCurrentPath().
|
inline |
Get number of calculated paths
Referenced by UFunctionAvoid::sendCurrentPath().
|
inline |
Get the start pose for all paths
UPoseV UAvoidPathPool::getStartPoseVel | ( | ) |
Get start pose and velocity
References UPoseV::set().
Referenced by UReactivePath::findObstAvoidRoute().
int UAvoidPathPool::getValidAvoidPathsCnt | ( | ) |
Get number valid paths of type UAvoidPath (rev2 path). Invalid paths do not count.
References UAvoidPath2::isValid().
Referenced by UResAvoid::findPathToHere(), and UFunctionAvoid::sendCurrentAvoidPath().
int UAvoidPathPool::getValidPathsCnt | ( | ) |
Get number valid paths. Invalid paths do not count.
References UReactivePath::isValid().
Referenced by UResAvoid::findPathToHere(), and UFunctionAvoid::sendCurrentPath().
|
inline |
Set the start pose for all paths
|
inline |
Set safety distance limits
|
inline |
Set most limiting front-left position
|
inline |
Set most limiting front-right position
|
inline |
Set the start pose for all paths
|
protected |
New avoid path method
|
protected |
Number of used paths
|
staticprotected |
Number of alternative paths in path pool
UAvoidParams UAvoidPathPool::par |
Parameters for obstacle avoidance
Referenced by UResAvoid::closeLogAvoid(), UResAvoid::findPathToHere(), UResAvoid::isLogAvoidOpen(), UResAvoid::methodCall(), UResAvoid::methodCallV(), UResAvoid::openLogAvoid(), and UResAvoid::UResAvoidInit().
|
protected |
Best path
|
protected |
Pool of alternative paths
|
protected |
Number of used paths