Lesson: 20L ESR Motoring Along the Line

Printer-friendly version

In this lesson, students learn to create a simple straight-line follower using Motor Blocks and a Switch-Loop using the Color Sensor to make decisions over-and-over.

1) Watch this video to learn how to use a Motor Blocks inside a Switch-Loop and have Riley follow a straight line using the Color Sensor:

2) Start the video again and pause so you can add a downward-facing Color Sensor to Port 3 and follow along to program Riley to follow the line.

3) Can you get Riley to follow the line for only 10 seconds?
(Hint: change the Loop Block default infinity/unlimited setting.

4) Try changing the values in the Motor Blocks to see what this does to Riley's behavior.

5) Answer these questions:

How is Riley able to follow the line with Color mode?
Why does Riley not follow the center of the line?

Education Level: 
Scope & Sequence: 
HW Platform: 
SW Platform: 
Interactivity Style: