Section5.2Landmarks, Range Sensors, and Feature-Based Mapping
To combat encoder drift, robots must continuously look out at external landmarks in their environment using range sensors (e.g., LiDAR, Ultrasonic, or Vision sensors).
Picture a robot whose wheel encoders currently report a pose of \((x=3.0, y=1.0)\text{.}\) It detects a known landmark, a column or wall corner, at a distance reading of \(d = 2.1\) meters. Because the landmarkβs true position is already known, this single reading resets the accumulated drift and corrects the robotβs pose to \((x=3.1, y=0.9)\)βindependent of however much error had built up in the encoders beforehand.
Subsection5.2.2Feature-Based Mapping vs. Occupancy Grids
In Chapter 3, we studied Occupancy Grid Maps, which divide space into a fixed grid of cells. In contrast, Feature-Based Mapping represents the world as a geometric list of discrete landmark coordinates:
Instead of storing thousands of empty or full grid cells, the robot only maintains the positions of high-confidence landmark features, significantly reducing computational memory usage.
Real-World Example (Self-Driving Cars & LiDAR Mapping): Self-driving vehicles match live LiDAR point clouds against pre-mapped 3D features (such as retroreflective highway signs and traffic light poles). When the carβs wheel odometry drifts slightly, detecting a known landmark immediately recalibrates the carβs position back to millimeter precision.
VEX Robotics Example (VEX AI Vision & AprilTag Tracking): A VEX robot equipped with a VEX AI Vision Sensor can identify known colored game elements or AprilTags posted on field walls. When the robot detects an AprilTag at a known position \((x_{\text{tag}}, y_{\text{tag}})\text{,}\) it calculates its distance and angle to that tag, instantly resetting any accumulated wheel encoder drift before making a turn.
Subsubsection5.2.4.1Exercise 5.2.2: Parsons Problem β Feature Map Lookup Function
Reorder the Python code blocks below to construct a function that searches a feature map and finds the nearest landmark to a robotβs estimated position.