# Lesson 1: Robotics with ScoutRiders

## Access Teacher Guide

Welcome! Each lesson includes a brief background story for context. Then you will be guided through a series of checkpoints which include instructions to help you learn about robotics. Lessons may also have challenges which are opportunities to take on more difficult tasks. Have fun and enjoy the world of robotics!

### Introducing ScoutRider

Hi! My name is ScoutRider. I landed on Mars before a manned space mission to set up equipment and investigate the landing site. Unfortunately, I had a hard landing and some important equipment got scattered. These need to be collected. To make matters worse, my battery level is low. Fortunately, some extra batteries were not damaged by the collision. If I can reach them I can get extra power and use that to collect the equipment. I’ll need to make my decisions carefully so I don’t run out of power before I collect everything we need!

### Quest Guide

• ScoutRider starts the mission with 3 units of energy.
• Collecting a battery gives you 3 more units of energy.
• Moving consumes 1 unit of energy.
• Each 90° turn consumes 1 unit of energy.
• When ScoutRider runs out of energy, it stops responding to commands.

There are three puzzles to solve which increase in difficulty:

1. Collect the Red cable
2. Collect the Red cable + Green circuit boards
3. Collect the Red cable + Green circuit boards + Blue gears

### Robot Commands

1. robot.move_forward() – Move 1 tile forward.
2. robot.move_backward() – Move 1 tile backward.
3. robot.turn_right() – Rotate 90° clockwise.
4. robot.turn_left() – Rotate 90° counter clockwise.

### Checkpoints

Checkpoint #1 – Getting Started

1. Start the simulation by selecting Start under SIMULATION in the Project Tree to the left.

2.   You should see the situation as shown in the image below.

Checkpoint #2 – Move the robot

• Open the python code file by clicking Node: user_code under NODES in the Project Tree.
•
• Try adding the following code under
robot.move_forward()
• Now run the simulation again by selecting Reset under SIMULATION in the Project Tree.
• You will see ScoutRider move one step forward and stop.

Checkpoint #3 – Rotate the robot

• Let’s add a second line of code below our existing code:
robot.turn_right()
• Reset again.
• You will see ScoutRider move one step forward and turn right.

Checkpoint #4 – Solve the Red Puzzle

Try to collect the Red cable. This is a simple challenge but pay attention to the battery power level in the status bar. You will need to change your code.

Checkpoint #5 – Solve the Red + Green Puzzle

Now see if you can collect the Red cable and all the Green circuit boards. Don’t forget your robot has a command to move backwards.

Checkpoint #6 – Solve the Red + Green + Blue Puzzle

Now things can get challenging. See if you can collect the Red cable, Green circuit boads, and Blue gears

### Challenge

For a difficult challenge, you can write an automatic algorithm to find the solution to these puzzles. You will need to input the positions of the items to your code. If it works your algorithm should generate all of the correct moves. You may not know how to solve this problem right now, but you will learn these skills in the next few months. You can start thinking about how this algorithm should work without doing any actual coding.