Meet MRPT: The C++ Robotic Destination

BY Priya Ravindran

0
968

You wake up in the morning and your cup of hot, steaming coffee is brought right up to your bed. Breakfast is just the way you like it, the house is clean and your car is ready for you. Your 24/7 staff at the office is all charged up and working at a pace you can only begin to comprehend. Everything is in its right place, your schedule fixed and presentations complete. Sounds like your personal assistant is too good to be true! Right?

But what if this is not a scene out of the page of the life of the businessman on the cover of Forbes? What if all you need to do is put together some hardware, play around with a few lines of code, lo and behold, you have someone who can do anything you ask it to do?

mobile robot programming toolkit specs

 

Oh yes, we are taking about the robot you have always dreamt of!

This article discusses Mobile Robot Programming Toolkit (MRPT), a cross-platform and open source C++ library designed to help you program your dream robotics application. Earlier distributed under GPL licence, versions 1.0 and above now come under the new BSD licence. MRPT is based on OpenMORA, the Open Mobile Robot Architecture for mobile robots.

Portable, well-tested applications and libraries come as part of MRPT package, which covers data structures and algorithms employed in common robotics research areas. While dealing with robotics, basic functioning can be broadly grouped into location, vision and motion. Advanced techniques for each of the above is what forms the basis of MRPT.

READ
Touch-skin to Operate your Smartwatch
MRPT particle filter localisation using ROS
Fig. 1: MRPT particle filter localisation using ROS

Go the fast and furious way

Ask a robotics engineer and he will tell you about one of the classic robotic problems: the navigation problem. The more creative ones call it the piano mover’s problem. Complicated though it sounds, it is not too difficult to comprehend—just imagine trying to make your robot play the Harry Potter theme song.

Pause and dissect.

Motion planning involves breaking up motion into discrete steps, each satisfying movement constraints and even maybe optimises some aspects of the same. Be it in autonomy, automation, animation, video games or robotic surgery, this is what is done. MRPT uses holonomic algorithms for depicting nearness diagrams and virtual force fields to help set your robot into action.

Plan and connect.

Path of the robot is fixed by you via planning algorithms and path planning with occupancy grid maps that iterate to find the shortest route possible. The robot is aware of its path with the reactive navigation mechanism kicking in on encountering an obstacle. All of this can be observed clearly on your computer screen with help from Navigation Viewer, making analysis all the more easy.

You can even export the robot trajectory and point clouds of obstacles to MATLAB for generating high-quality graphs. Metric map can be represented as landmark map, beacon map, coloured point map or even gas concentration map to aid you to convert observations into meaningful data.

Enhance the viewing perimeter

Computer Vision (CV) is one feature no robotics application is complete without. Understanding digital images and video, and translating data to process automatic visual tasks forms the core of CV, and this task of MRPT is largely supported by OpenCV. Images can be stored as gray-scale or RGB bitmaps; tracking video feature lets you detect and track features of a video stream in real time.

READ
Electric Brain Stimulation Needs Caution

Post better pictures on Instagram.

A commonly disregarded fact is the radial and tangential distortion introduced by cameras. With interest in photography on the rise, everyone wants ideal projective camera images, and this is easily recovered by performing an undistortion of image pixels. The same applies even for video files, which are sequences of images, afterall.

You can calibrate camera sensors using tools like Program camera-calib, Complete Kinect calibration and Program stereo-calib-gui, which help calibrate individual cameras, accurately reconstruct depth and RGB information, and calibrate stereo cameras, respectively. Do you want to rectify stereo maps? Worry not, as MRPT lets you do that, too!

The CMesh
Fig. 2: The CMesh

Locate and map on the same shot

Simultaneous Localisation and Mapping, commonly called SLAM in robotic circles, is defined by Wikipedia as the computational problem of constructing or updating a map of an unknown environment, while simultaneously keeping track of an agent’s location within it. The way to do this is, of course, to use algorithms for a given time and environment.

The purpose defines the choice.

MRPT provides you with a set of algorithms that can be readily applied to different environments, to achieve operational compliance rather than perfection. Choose the right SLAM algorithm for your purpose depending on the kind of observation to be made, that is, sensor data and map type required. The sensor could be anything, like a 2D laser scanner or a range-only sensor, while mapping types range across occupancy grids, point maps, landmark maps and even graphical representations.

LEAVE A REPLY

Please enter your comment!
Please enter your name here