Skip to main content

Section 5.5 ActiveCode Challenge: Wheel Slip Drift and Landmark Correction

In this hands-on exercise, you will run and experiment with a Python simulation of a robot attempting to navigate along a straight line.
You will observe how uncorrected wheel encoder drift accumulates over time, causing the robot’s perceived position (odometry) to diverge significantly from its true position in the physical world.

Subsection 5.5.1 Section 5.5 Interactive Exercises

Subsubsection 5.5.1.1 Exercise 5.5.1: Encoder Drift Simulation ActiveCode

Below is a 1D/2D kinematic simulation tracking both the Estimated Pose (calculated from wheel encoders) and the True Pose (including wheel slip and friction).
Task:
  1. Run the simulation with slip_rate = 0.08 (8% wheel slip). Note how far the actual robot ends up from its estimated target after 10 steps.
  2. Modify slip_rate to 0.02 and 0.15 to observe how slip severity impacts overall error growth.
  3. Challenge: Enable landmark correction by setting ENABLE_LANDMARK_CORRECTION = True. Notice how periodic external landmark scans reset the accumulated drift error back near zero!
You have attempted of activities on this page.