Skip to main content

Practice

In the last section, you learned how the Optical Sensor works and how you can use data from this sensor in your code to have your robot make decisions. Now, you are going to apply what you have learned to code your Simple Clawbot with an Optical Sensor to complete the Eye Spy Treasure activity. 

In this activity, your robot will drive to two different IQ Cubes and use the Optical Sensor to detect the color of each cube. If the cube is red, your robot should collect it with the claw and move it to the Home Zone.

Watch the video below to see how you can apply what you have learned to complete the Eye Spy Treasure practice activity. 

Now it's your turn to complete the Eye Spy Treasure practice activity!

In this animation, the robot moves autonomously to check each cube with the Optical Sensor, moving in the same pattern as the previous animation. The robot grasps the red cube, and drives to deliver it to the Home Zone on the opposite wall. Watch this animation to see one possible path your robot could take to complete the Eye Spy Treasure practice activity.

Follow the steps in this document to complete this activity.

Google / .docx / .pdf

Video file

As you complete the Eye Spy Treasure practice activity, document your findings in your engineering notebook.

  • Think about the distances that the robot will need to travel to drive to each of the cubes. 
  • Think about what the robot will need to do when it detects a red cube. 

View this image for an example of how you can record your results.

Engineering notebook page with Treasure Hunt - Claw with Sensor handwritten at the top. There is a sketch of the Activity Setup, with colored arrows and squiggly lines indicating notes about how the robot should move to complete the activity. Beneath the sketch are numbered steps.

Prepare for the Challenge Activity

In Compete (on the next page), you will code your robot to autonomously check cubes and collect only the red cube in the Home Zone. Learn how to compete in the Treasure Mover Challenge, check your understanding, then practice for the challenge. Watch this animation to see an example of how your robot could move in a successful run of the challenge.

In this animation, the Simple Clawbot begins along the left wall of the Field. There are five cubes places against the wall to the left of the robot, at each black line. The second cube is red. The robot repeatedly drives forward to the black line, turns left, and drives forward to detect the color of the cube. If the cube is not red, the robot reverses, turns right, and continues its pattern. If the cube is red, the robot grasps it in its claw, reverses, turns around, and drives to deliver the cube to the opposite wall. The timer runs until the robot has checked the color of all five cubes, about 32 seconds.

The goal of this challenge is to have your robot autonomously drive to check the cubes on the Field, and collect the red cube to the Home Zone in the fastest time. 

This animation shows just one possible path your robot could take to complete the Treasure Mover Challenge.

Follow the steps in this document to learn more about how to complete this activity. Google / .docx / .pdf

Video file

Check Your Understanding

Before beginning the challenge, ensure that you understand the rules and set up by answering the questions in the document below in your engineering notebook. 

Check Your Understanding questions Google / .docx / .pdf

After completing the questions, practice for the challenge.


Select Next >  to compete in the Treasure Mover Challenge.