This is the base class for any reactive navigation system.
Here is defined the interface that users will use with derived classes where algorithms are really implemented.
Changes history:
16/SEP/2004: Totally redesigned.
How to use:
Definition at line 102 of file CAbstractReactiveNavigationSystem.h.
#include <mrpt/nav/reactive/CAbstractReactiveNavigationSystem.h>
Classes | |
struct | TNavigationParams |
The struct for configuring navigation requests. More... | |
Public Types | |
enum | TState { IDLE =0 , NAVIGATING , SUSPENDED , NAV_ERROR } |
The different states for the navigation system. More... | |
Public Member Functions | |
CAbstractReactiveNavigationSystem (CReactiveInterfaceImplementation &react_iterf_impl) | |
Constructor. More... | |
virtual | ~CAbstractReactiveNavigationSystem () |
Destructor. More... | |
void | cancel () |
Cancel current navegacion. More... | |
void | resume () |
Continues with suspended navigation. More... | |
void | navigationStep () |
This method must be called periodically in order to effectively run the navigation. More... | |
virtual void | navigate (const TNavigationParams *params)=0 |
Navigation request. More... | |
virtual void | suspend () |
Suspend current navegation. More... | |
TState | getCurrentState () const |
Returns the current navigator state. More... | |
Static Public Member Functions | |
static void | printf_debug (const char *frmt,...) |
Sends a formated text to "debugOut" if not NULL, or to cout otherwise. More... | |
Protected Member Functions | |
virtual void | performNavigationStep ()=0 |
To be implemented in derived classes. More... | |
Protected Attributes | |
TState | m_navigationState |
Current internal state of navigator: More... | |
TNavigationParams * | m_navigationParams |
Current navigation parameters. More... | |
CReactiveInterfaceImplementation & | m_robot |
The navigator-robot interface. More... | |
Private Attributes | |
TState | m_lastNavigationState |
Last internal state of navigator: More... | |
The different states for the navigation system.
Enumerator | |
---|---|
IDLE | |
NAVIGATING | |
SUSPENDED | |
NAV_ERROR |
Definition at line 145 of file CAbstractReactiveNavigationSystem.h.
mrpt::nav::CAbstractReactiveNavigationSystem::CAbstractReactiveNavigationSystem | ( | CReactiveInterfaceImplementation & | react_iterf_impl | ) |
Constructor.
|
virtual |
Destructor.
void mrpt::nav::CAbstractReactiveNavigationSystem::cancel | ( | ) |
Cancel current navegacion.
|
inline |
Returns the current navigator state.
Definition at line 154 of file CAbstractReactiveNavigationSystem.h.
|
pure virtual |
Navigation request.
It starts a new navigation.
[in] | params | Pointer to structure with navigation info (its contents will be copied, so the original can be freely destroyed upon return.) |
Implemented in mrpt::nav::CAbstractPTGBasedReactive.
void mrpt::nav::CAbstractReactiveNavigationSystem::navigationStep | ( | ) |
This method must be called periodically in order to effectively run the navigation.
|
protectedpure virtual |
To be implemented in derived classes.
Implemented in mrpt::nav::CAbstractPTGBasedReactive.
|
staticinherited |
Sends a formated text to "debugOut" if not NULL, or to cout otherwise.
Referenced by mrpt::math::CLevenbergMarquardtTempl< VECTORTYPE, USERPARAM >::execute().
void mrpt::nav::CAbstractReactiveNavigationSystem::resume | ( | ) |
Continues with suspended navigation.
|
virtual |
Suspend current navegation.
|
private |
Last internal state of navigator:
Definition at line 157 of file CAbstractReactiveNavigationSystem.h.
|
protected |
Current navigation parameters.
Definition at line 164 of file CAbstractReactiveNavigationSystem.h.
|
protected |
Current internal state of navigator:
Definition at line 163 of file CAbstractReactiveNavigationSystem.h.
|
protected |
The navigator-robot interface.
Definition at line 167 of file CAbstractReactiveNavigationSystem.h.
Page generated by Doxygen 1.9.2 for MRPT 1.4.0 SVN: at Mon Sep 20 00:36:32 UTC 2021 |