YARP
Yet Another Robot Platform
yarp::dev::Nav2D::INavigation2D Class Referenceabstract

An interface to control the navigation of a mobile robot in a 2D environment. More...

#include <yarp/dev/INavigation2D.h>

+ Inheritance diagram for yarp::dev::Nav2D::INavigation2D:

Public Member Functions

virtual ~INavigation2D ()
 Destructor. More...
 
virtual bool gotoTargetByLocationName (std::string location_or_area_name)=0
 Ask the robot to reach a previously stored location/area. More...
 
virtual bool checkInsideArea (std::string area_name)=0
 Check if the robot is currently inside the specified area. More...
 
virtual bool checkInsideArea (Nav2D::Map2DArea area)=0
 Check if the robot is currently inside the specified area. More...
 
virtual bool checkNearToLocation (Nav2D::Map2DLocation loc, double linear_tolerance, double angular_tolerance=std::numeric_limits< double >::infinity())=0
 Check if the robot is currently near to the specified area. More...
 
virtual bool checkNearToLocation (std::string location_name, double linear_tolerance, double angular_tolerance=std::numeric_limits< double >::infinity())=0
 Check if the robot is currently near to the specified area. More...
 
virtual bool getNameOfCurrentTarget (std::string &location_name)=0
 Gets the name of the current target, if available (set by gotoTargetByLocationName) More...
 
virtual bool storeCurrentPosition (std::string location_name)=0
 Store the current location of the robot. More...
 
virtual bool storeLocation (std::string location_name, Nav2D::Map2DLocation loc)=0
 Store a location specified by the user in the world reference frame. More...
 
virtual bool getLocation (std::string location_name, Nav2D::Map2DLocation &loc)=0
 Retrieves a location previously stored by the user. More...
 
virtual bool getArea (std::string area_name, Nav2D::Map2DArea &area)=0
 Retrieves an area previously stored by the user. More...
 
virtual bool getLocationsList (std::vector< std::string > &locations)=0
 Get a list of all stored locations. More...
 
virtual bool deleteLocation (std::string location_name)=0
 Delete a location. More...
 
virtual bool clearAllLocations ()=0
 Delete all stored locations. More...
 
- Public Member Functions inherited from yarp::dev::Nav2D::INavigation2DTargetActions
virtual ~INavigation2DTargetActions ()
 Destructor. More...
 
virtual bool gotoTargetByAbsoluteLocation (yarp::dev::Nav2D::Map2DLocation loc)=0
 Ask the robot to reach a position defined in the world reference frame. More...
 
virtual bool getAbsoluteLocationOfCurrentTarget (yarp::dev::Nav2D::Map2DLocation &loc)=0
 Gets the last navigation target in the world reference frame. More...
 
virtual bool gotoTargetByRelativeLocation (double x, double y)=0
 Ask the robot to reach a position defined in the robot reference frame. More...
 
virtual bool gotoTargetByRelativeLocation (double x, double y, double theta)=0
 Ask the robot to reach a position defined in the robot reference frame. More...
 
virtual bool getRelativeLocationOfCurrentTarget (double &x, double &y, double &theta)=0
 Gets the last navigation target in the robot reference frame. More...
 
virtual bool applyVelocityCommand (double x_vel, double y_vel, double theta_vel, double timeout=0.1)=0
 Apply a velocity command. More...
 
- Public Member Functions inherited from yarp::dev::Nav2D::INavigation2DControlActions
virtual ~INavigation2DControlActions ()
 Destructor. More...
 
virtual bool getNavigationStatus (NavigationStatusEnum &status)=0
 Gets the current status of the navigation task. More...
 
virtual bool stopNavigation ()=0
 Terminates the current navigation task. More...
 
virtual bool suspendNavigation (const double time_s=std::numeric_limits< double >::infinity())=0
 Ask to the robot to suspend the current navigation task for a defined amount of time. More...
 
virtual bool resumeNavigation ()=0
 Resume a previously suspended navigation task. More...
 
virtual bool recomputeCurrentNavigationPath ()=0
 Forces the navigation system to recompute the path from the current robot position to the current goal. More...
 
virtual bool getAllNavigationWaypoints (yarp::dev::Nav2D::TrajectoryTypeEnum trajectory_type, yarp::dev::Nav2D::Map2DPath &waypoints)=0
 Returns the list of waypoints generated by the navigation algorithm. More...
 
virtual bool getCurrentNavigationWaypoint (yarp::dev::Nav2D::Map2DLocation &curr_waypoint)=0
 Returns the current waypoint pursued by the navigation algorithm. More...
 
virtual bool getCurrentNavigationMap (yarp::dev::Nav2D::NavigationMapTypeEnum map_type, yarp::dev::Nav2D::MapGrid2D &map)=0
 Returns the current navigation map processed by the navigation algorithm. More...
 
- Public Member Functions inherited from yarp::dev::Nav2D::ILocalization2D
virtual ~ILocalization2D ()
 Destructor. More...
 
virtual bool startLocalizationService ()=0
 Starts the localization service. More...
 
virtual bool stopLocalizationService ()=0
 Stops the localization service. More...
 
virtual bool getLocalizationStatus (LocalizationStatusEnum &status)=0
 Gets the current status of the localization task. More...
 
virtual bool getEstimatedPoses (std::vector< yarp::dev::Nav2D::Map2DLocation > &poses)=0
 Gets a set of pose estimates computed by the localization algorithm. More...
 
virtual bool getCurrentPosition (yarp::dev::Nav2D::Map2DLocation &loc)=0
 Gets the current position of the robot w.r.t world reference frame. More...
 
virtual bool getCurrentPosition (yarp::dev::Nav2D::Map2DLocation &loc, yarp::sig::Matrix &cov)=0
 Gets the current position of the robot w.r.t world reference frame, plus the covariance. More...
 
virtual bool getEstimatedOdometry (yarp::dev::OdometryData &odom)=0
 Gets the estimated odometry the robot, including its velocity expressed in the world and in the local reference frame. More...
 
virtual bool setInitialPose (const yarp::dev::Nav2D::Map2DLocation &loc)=0
 Sets the initial pose for the localization algorithm which estimates the current position of the robot w.r.t world reference frame. More...
 
virtual bool setInitialPose (const yarp::dev::Nav2D::Map2DLocation &loc, const yarp::sig::Matrix &cov)=0
 Sets the initial pose for the localization algorithm which estimates the current position of the robot w.r.t world reference frame. More...
 

Detailed Description

An interface to control the navigation of a mobile robot in a 2D environment.

Definition at line 198 of file INavigation2D.h.

Constructor & Destructor Documentation

◆ ~INavigation2D()

virtual yarp::dev::Nav2D::INavigation2D::~INavigation2D ( )
inlinevirtual

Destructor.

Definition at line 206 of file INavigation2D.h.

Member Function Documentation

◆ checkInsideArea() [1/2]

virtual bool yarp::dev::Nav2D::INavigation2D::checkInsideArea ( Nav2D::Map2DArea  area)
pure virtual

Check if the robot is currently inside the specified area.

Parameters
areathe area to be checked
Returns
true/false

Implemented in Navigation2DClient.

◆ checkInsideArea() [2/2]

virtual bool yarp::dev::Nav2D::INavigation2D::checkInsideArea ( std::string  area_name)
pure virtual

Check if the robot is currently inside the specified area.

Parameters
area_namethe name of an area previously saved
Returns
true/false

Implemented in Navigation2DClient.

◆ checkNearToLocation() [1/2]

virtual bool yarp::dev::Nav2D::INavigation2D::checkNearToLocation ( Nav2D::Map2DLocation  loc,
double  linear_tolerance,
double  angular_tolerance = std::numeric_limits< double >::infinity() 
)
pure virtual

Check if the robot is currently near to the specified area.

Parameters
locthe location to be checked
linear_tolerancelinear tolerance [m]
angular_tolerance[deg 0-360]
Returns
true/false

Implemented in Navigation2DClient.

◆ checkNearToLocation() [2/2]

virtual bool yarp::dev::Nav2D::INavigation2D::checkNearToLocation ( std::string  location_name,
double  linear_tolerance,
double  angular_tolerance = std::numeric_limits< double >::infinity() 
)
pure virtual

Check if the robot is currently near to the specified area.

Parameters
location_namethe name of the location: it will be searched in the server
linear_tolerancelinear tolerance [m]
angular_tolerance[deg]
Returns
true/false

Implemented in Navigation2DClient.

◆ clearAllLocations()

virtual bool yarp::dev::Nav2D::INavigation2D::clearAllLocations ( )
pure virtual

Delete all stored locations.

Returns
true/false

Implemented in Navigation2DClient.

◆ deleteLocation()

virtual bool yarp::dev::Nav2D::INavigation2D::deleteLocation ( std::string  location_name)
pure virtual

Delete a location.

Parameters
location_namethe name of the location
Returns
true/false

Implemented in Navigation2DClient.

◆ getArea()

virtual bool yarp::dev::Nav2D::INavigation2D::getArea ( std::string  area_name,
Nav2D::Map2DArea area 
)
pure virtual

Retrieves an area previously stored by the user.

Parameters
area_namethe name of the area
areathe area on the map
Returns
true/false

Implemented in Navigation2DClient.

◆ getLocation()

virtual bool yarp::dev::Nav2D::INavigation2D::getLocation ( std::string  location_name,
Nav2D::Map2DLocation loc 
)
pure virtual

Retrieves a location previously stored by the user.

Parameters
location_namethe name of the location
locthe location on the map
Returns
true/false

Implemented in Navigation2DClient.

◆ getLocationsList()

virtual bool yarp::dev::Nav2D::INavigation2D::getLocationsList ( std::vector< std::string > &  locations)
pure virtual

Get a list of all stored locations.

Parameters
thereturned list of locations
Returns
true/false

Implemented in Navigation2DClient.

◆ getNameOfCurrentTarget()

virtual bool yarp::dev::Nav2D::INavigation2D::getNameOfCurrentTarget ( std::string &  location_name)
pure virtual

Gets the name of the current target, if available (set by gotoTargetByLocationName)

Parameters
location_namethe name of the current target
Returns
true/false

Implemented in Navigation2DClient.

◆ gotoTargetByLocationName()

virtual bool yarp::dev::Nav2D::INavigation2D::gotoTargetByLocationName ( std::string  location_or_area_name)
pure virtual

Ask the robot to reach a previously stored location/area.

Parameters
location_namethe name of a location/area previously saved
Returns
true/false

Implemented in Navigation2DClient.

◆ storeCurrentPosition()

virtual bool yarp::dev::Nav2D::INavigation2D::storeCurrentPosition ( std::string  location_name)
pure virtual

Store the current location of the robot.

Parameters
location_namethe name of the location
Returns
true/false

Implemented in Navigation2DClient.

◆ storeLocation()

virtual bool yarp::dev::Nav2D::INavigation2D::storeLocation ( std::string  location_name,
Nav2D::Map2DLocation  loc 
)
pure virtual

Store a location specified by the user in the world reference frame.

Parameters
location_namethe name of the location
locthe location of the robot
Returns
true/false

Implemented in Navigation2DClient.


The documentation for this class was generated from the following file: