Ops Manager Extension: Line Follower Explained

6. Calibration step 2

To help you calibrate your robot, you have access to a pre-written template function called calibrate().

          • Amend the code in the Test & Calibration Code cell so that this function (highlighted in red) is un-commented and everything else is commented out.
          • Click on Run Selected Cell.

Cell containing the calibrate() call

The robot will:

      1. take a reference reading for black [1],
      2. drive forward 5cm [2]
      3. take a reference reading for white [3].

All being well, you should see the following summary statistics for black and white reported in the Notebook under the Test & Calibration cell (your numbers will be different):

BLACK: AVERAGE = 0.07    MINIMUM = 0.03    MAXIMUM = 0.11

WHITE: AVERAGE = 0.76    MINIMUM = 0.63    MAXIMUM = 0.86

A good average value reported for black is less than 0.25. If your reading is greater than this value, perhaps your print contrast is low. You can improve things by coloring in the black line on the sheet with a black marker, re-positioning the robot and re-running the above calibration process. Has the average black value dropped significantly?

A good average value reported for white is greater than 0.75. If your reading is less than this value, how can you improve the environment to help with proper line detection?

Investigate what can be done with the next steps.