Little Red Robot
Lab 3 - Wolf Detecting Algorithm

Teacher Portal

Implementing VEX 123 STEM Labs

STEM Labs are designed to be the online teacher’s manual for VEX 123. Like a printed teacher’s manual, the teacher-facing content of the STEM Labs provides all of the resources, materials, and information needed to be able to plan, teach, and assess with VEX 123. The Lab Image Slideshows are the student-facing companion to this material. For more detailed information about how to implement a STEM Lab in your classroom, see the Implementing VEX 123 STEM Labs article.

# Goals and Standards

## Goals

Students will apply

• Using the "If red", "Else", and "End if" Coder cards together in a project to make the 123 Robot perform different behaviors based on the color detected by the Eye Sensor.
• Using the "Go to start" Coder card to repeat a project to create a 'Wolf Detecting Algorithm'.
• Taking turns with a partner to build, test, and iterate on a project with the 123 Robot, Coder, and Coder cards.

Students will make meaning of

• How to code a robot to solve a problem, such as performing different behaviors depending on the color of an object that is detected.

Students will be skilled at

• Waking the 123 Robot.
• Connecting the 123 Robot to the Coder.
• Inserting and removing Coder cards from the Coder.
• Sequencing Coder cards in a project.
• Using the "If red", "Else", and "End if" Coder cards in a project.
• Using the "Go to start" Coder card in a project

Students will know

• How the Eye Sensor on the 123 Robot can be used to detect the color of an object if it is red, blue, or green.
• That the "If red", "Else", and "End if" Coder cards work together with the Eye Sensor to make the robot perform different behaviors based on the color detected.
• How to use the "Go to start" Coder card in a project to have the 123 Robot repeat the project forever.

## Objective(s)

### Objective

1. Students will collaborate in groups to work toward a common goal.
2. Students will identify that the Eye Sensor can detect the color of an object if it is red, green, or blue.
3. Students will use the "If red", "Else", "End if", and "Go to start" Coder cards to develop an algorithm that makes the 123 Robot drive until an object is detected, and perform different behaviors depending on the color of that object.

### Activity

1. During Play Part 1, students will collaborate in their groups to build and test their projects using the "If red", "Else", and "End if" Coder cards. They will take turns placing the 123 Robot and the red Wolf and starting the Coder each time. During Play Part 2, students will work together to test their algorithm to both scare away the Wolf and get to Grandmother's house.
2. During the Engage section, students are introduced to the "If red" Coder card, and how it can be used in a project to make the robot perform a behavior based on the color detected. During Play Part 1, students build a project using the "If red", "Else", and "End if" Coder cards to have the robot perform different behaviors depending on the color detected by the Eye Sensor.
3. During Play Part 2, students build onto their project from Play Part 1 to add the "Go to start" Coder card, so that the robot continually repeats the behaviors of driving to an object, detecting the color, and performing a different behavior based on that color, so that the robot can both drive and scare away the Wolf, and drive to Grandmother's house successfully.

### Assessment

1. In the Share section, students will share their projects and describe how they collaborated to test their 'Wolf Detecting Algorithm', and tell the story of what their robot is doing in relation to the Little Red Riding Hood story.
2. In the Mid-Play Break discussions, students will identify the decision that the robot is making based on the color detected. As the teacher steps through the project, students will make predictions about the robot's behavior, and will justify their predictions based on what they have learned about the If-else conditional in their projects.
3. During the Share section, students will discuss how their 'Wolf Detecting Algorithm' functions to allow the robot to detect the difference between the Wolf and Grandmother's house, so that they can effective scare away the Wolf and get to Grandmother's as the algorithm runs.