Documentation / v1.0 / Core / Movement Tracker

From emss Framework - iRobot Create C++ Framework

Jump to: navigation, search

You are here: Documentation / v1.0 / Core / Movement Tracker


[edit] Movement Tracker

Files:

MovementTracker/MovementTracker.h Licensed under GPLv3
MovementTracker/MovementTracker.cpp Licensed under GPLv3

Responsible for tracking movements of the robot, and in turn performing the localization, a Movement Tracker accepts signals from the active Controller and translates them accordingly. Furthermore, Trackers also forward changes about the robot position to other components, especially the Maps, in forms of signals. The Movement Tracker is an abstract class which needs to be defined by subclasses. The only significant variable is transformation, which is a Trafo2D object. The input slots, i.e. signals received from the Controller, are registerMovedDistance(distance), registerChangedAngle(angle), registerCollision(), and registerObjectDetected(distance,angle). The current emss software offers only one implementation of Movement Tracker, namely the Raw Movement Tracker. However, in the future other, more advanced, Movement Trackers will be implemented in order to increase the localization precision.

[edit] Raw Movement Tracker

Files:

MovementTracker/RawMovementTracker.h Licensed under GPLv3
MovementTracker/RawMovementTracker.cpp Licensed under GPLv3

The Raw Movement Tracker tracks the robot’s movement by geometrically interpreting the sensor data sent back from the robot. This method remains accurate (at least as accurate as the sensor data) as long as the robot’s movement is linear, meaning that the wheels were not differentially driven. When a differential steering system is made use of, the accuracy of the tracker declines as the sensor interval increases. However, we have found that this implementation of the tracker is surprisingly sufficient, as shown in Figure 4-6.

  void RawMovementTracker::registerChangedAngle(double angle){
         if(angle != 0) {
                  transformation = transformation * Trafo2D::rot(Rad(angle));
                  emit moved(this->x(), this->y(), this->rotation());
         }
  }


Figure 4-6: Raw Movement Tracker Accuracy Test Composition