Main MRPT website > C++ reference
MRPT logo

CAbstractHolonomicReactiveMethod.h

Go to the documentation of this file.
00001 /* +---------------------------------------------------------------------------+
00002    |          The Mobile Robot Programming Toolkit (MRPT) C++ library          |
00003    |                                                                           |
00004    |                   http://mrpt.sourceforge.net/                            |
00005    |                                                                           |
00006    |   Copyright (C) 2005-2011  University of Malaga                           |
00007    |                                                                           |
00008    |    This software was written by the Machine Perception and Intelligent    |
00009    |      Robotics Lab, University of Malaga (Spain).                          |
00010    |    Contact: Jose-Luis Blanco  <jlblanco@ctima.uma.es>                     |
00011    |                                                                           |
00012    |  This file is part of the MRPT project.                                   |
00013    |                                                                           |
00014    |     MRPT is free software: you can redistribute it and/or modify          |
00015    |     it under the terms of the GNU General Public License as published by  |
00016    |     the Free Software Foundation, either version 3 of the License, or     |
00017    |     (at your option) any later version.                                   |
00018    |                                                                           |
00019    |   MRPT is distributed in the hope that it will be useful,                 |
00020    |     but WITHOUT ANY WARRANTY; without even the implied warranty of        |
00021    |     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         |
00022    |     GNU General Public License for more details.                          |
00023    |                                                                           |
00024    |     You should have received a copy of the GNU General Public License     |
00025    |     along with MRPT.  If not, see <http://www.gnu.org/licenses/>.         |
00026    |                                                                           |
00027    +---------------------------------------------------------------------------+ */
00028 #ifndef CAbstractHolonomicReactiveMethod_H
00029 #define CAbstractHolonomicReactiveMethod_H
00030 
00031 #include <mrpt/utils.h>
00032 #include <mrpt/poses.h>
00033 #include "CHolonomicLogFileRecord.h"
00034 
00035 namespace mrpt
00036 {
00037         namespace reactivenav
00038         {
00039                 using namespace mrpt::utils;
00040                 using namespace mrpt::poses;
00041 
00042         /** A base class for holonomic reactive navigation methods.
00043          *  \sa CHolonomicVFF,CHolonomicND, CReactiveNavigationSystem
00044          */
00045         class REACTIVENAV_IMPEXP CAbstractHolonomicReactiveMethod
00046         {
00047          public:
00048                  /** This method performs the holonomic navigation itself.
00049                    *  \param target [IN] The relative location (x,y) of target point.
00050                    *  \param obstacles [IN] Distance to obstacles from robot location (0,0). First index refers to -PI direction, and last one to +PI direction. Distances can be dealed as "meters", although they are "pseudometers", see note below, but normalized in the range [0,1]
00051                    *  \param maxRobotSpeed [IN] Maximum robot speed, in "pseudometers/sec". See note below.
00052                    *  \param desiredDirection [OUT] The desired motion direction, in the range [-PI,PI]
00053                    *  \param desiredSpeed [OUT] The desired motion speed in that direction, in "pseudometers"/sec. (See note below)
00054                    *  \param logRecord [IN/OUT] A placeholder for a pointer to a log record with extra info about the execution. Set to NULL if not required. User <b>must free memory</b> using "delete logRecord" after using it.
00055                    *
00056                    *  NOTE: With "pseudometers" we refer to the distance unit in TP-Space, thus:
00057                    *     <br><center><code>pseudometer<sup>2</sup>= meter<sup>2</sup> + (rad ยท r)<sup>2</sup></code><br></center>
00058                    */
00059                  virtual void  navigate(        poses::CPoint2D &target,
00060                                                                 vector_double   &obstacles,
00061                                                                 double                  maxRobotSpeed,
00062                                                                 double                  &desiredDirection,
00063                                                                 double                  &desiredSpeed,
00064                                                                 CHolonomicLogFileRecordPtr &logRecord) = 0;
00065 
00066         /** Virtual destructor
00067           */
00068         virtual ~CAbstractHolonomicReactiveMethod() { };
00069 
00070                  /**  Initialize the parameters of the navigator.
00071                    */
00072                  virtual void  initialize( const mrpt::utils::CConfigFileBase &INI_FILE  ) = 0;
00073 
00074 
00075         };
00076   }
00077 }
00078 
00079 
00080 #endif
00081 



Page generated by Doxygen 1.7.3 for MRPT 0.9.4 SVN:exported at Tue Jan 25 21:56:31 UTC 2011