[mrpt-nav]
Overview
Autonomous navigation, path planning
Library mrpt-nav
This library is part of MRPT and can be installed in Debian-based systems with:
sudo apt install libmrpt-nav-dev
Read also how to import MRPT into your CMake scripts.
Overview
mrpt-nav provides reactive and planned navigation for mobile robots. The architecture is layered:
CAbstractNavigator ← base state machine (IDLE / NAVIGATING / SUSPENDED / NAV_ERROR) └── CWaypointsNavigator ← waypoint sequencing on top of single-goal navigation └── CAbstractPTGBasedReactive ← TP-Space reactive core ├── CReactiveNavigationSystem ← 2-D robots └── CReactiveNavigationSystem3D ← multi-level 3-D robots
Reactive navigation
Navigator state machine
mrpt::nav::CAbstractNavigator drives a state machine with four states (mrpt::nav::CAbstractNavigator::TState):
State |
Meaning |
No active navigation goal Actively navigating toward target Navigation paused (call An unrecoverable error occurred; query
Code Meaning ==== =====================================
No error Robot stopped due to safety violation Timeout: robot not approaching target Unclassified exception
Class Algorithm ============================= =========================================================================================
mrpt::nav::CHolonomicVFF Virtual Force Fields — repulsive forces from obstacles + attractive force toward target mrpt::nav::CHolonomicND Nearness Diagram — gap-based obstacle avoidance (Minguez & Montano, 2004) mrpt::nav::CHolonomicFullEval Full-evaluation scoring across all TP-Space directions ============================= =========================================================================================
The navigation situation selected by CHolonomicND is recorded in CLogFileRecord_ND::situation (mrpt::nav::CHolonomicND::TSituations):
Value |
Meaning |
Straight free path to target Narrow gap selected Wide gap selected No traversable gap; robot stops
Class Robot kinematics ===== =========================================================
Differential drive — circular arc Differential drive — circular arc + straight Differential drive — two circular arcs (same direction) Differential drive — two arcs + straight Differential drive — trapezoidal steering Holonomic robot with velocity blending
(default) Allow reverse motions to escape near-collision Reject any motion when robot is already in near-collision
Class Algorithm ============================= ==============================================
mrpt::nav::PlannerSimple2D Simple 2-D A* on an occupancy grid mrpt::nav::PlannerRRT_SE2_TPS RRT planner in SE(2) using PTG-space expansion ============================= ==============================================
Robot interface
Users must implement mrpt::nav::CRobot2NavInterface, providing:
getCurrentPoseAndSpeeds()— current robot pose and velocitychangeSpeed()/stop()— velocity commandsEvent callbacks:
sendNavigationStartEvent(),sendNavigationEndEvent(), etc.
mrpt::nav::CRobot2NavInterfaceForSimulator offers a ready-made implementation backed by a kinematic simulator.