Unit 10 · lesson

Drive a Path on Paper or in Simulation

A path is a sequence of poses, not just a list of motor commands.

A pose combines position and orientation.

For a flat floor, we often represent pose as:

x, y, heading

Path plan

Suppose the robot must:

  1. start at (0, 0, 0°);
  2. drive to (1, 0, 0°);
  3. turn left;
  4. drive to (1, 1, 90°).

A command list might achieve that, but the path specification tells us what success means.

Mark checkpoints

Create checkpoints that can be measured.

CheckpointExpected xExpected yExpected heading
start0.00.0
after segment 11.00.0
after turn1.00.090°
finish1.01.090°

Now a simulation or physical trial can produce comparable evidence.

Failure case: correcting from the final point only

Suppose the robot finishes close to (1,1) but takes a huge arc through an obstacle zone.

Final position alone says "good." Path evidence says "unsafe."

A robotics test should measure what the mission actually constrains.

Run the mission

Use graph paper, a spreadsheet model, a simulator, or supervised robot data.

Create:

  • planned path;
  • at least four pose checkpoints;
  • observed/simulated path;
  • largest deviation;
  • likely cause.

If using paper only, deliberately add one wheel-distance error and propagate it through the later checkpoints.

You will see an important robotics pattern: small motion errors accumulate into pose errors.

Predict the pose before running the path

A useful path test starts with a known pose.

start: x = 0 m, y = 0 m, heading = 0°

Now define three segments:

  1. drive straight 1.0 m;
  2. rotate 90° left;
  3. drive straight 0.5 m.

The expected final pose is approximately:

x = 1.0 m
y = 0.5 m
heading = 90°

That answer gives you something concrete to compare with simulation or physical data.

Separate path error from control error

If the robot finishes at (0.90, 0.42), several causes are possible:

  • wheel-distance conversion is wrong;
  • a wheel slipped;
  • turn control undershot;
  • starting pose was not actually zero;
  • the motion command was wrong;
  • pose estimation accumulated error.

Do not immediately rewrite the path.

Record checkpoints after each segment. If segment 1 is already short, the turn is not the first problem. If position is correct before the rotation and wrong afterward, investigate the turn and heading estimate.

A path becomes diagnosable when you can locate where the error first appears.