Presentation is loading. Please wait.

Presentation is loading. Please wait.

Using the Distance sensor

Similar presentations


Presentation on theme: "Using the Distance sensor"— Presentation transcript:

1

2 Using the Distance sensor
LESSON 06 Using the Distance sensor

3 Lesson introduction The purpose of this lesson is to introduce students to the Distance Sensor and how it can be used in a program.

4 The Distance Sensor Learning objective: Students will understand how the Distance Sensor works using ultrasonic waves

5 The Distance Sensor Task 1: The build – Fitting the Distance Sensor
Learning objective: Students will understand how to attach the Distance Sensor to the Basebot Task 1: The build – Fitting the Distance Sensor Fit the Distance Sensor as shown on the picture opposite. This can be done using four of the 1x1 connector pins. Once in position on the robot, connect the Distance Sensor to the Brain using a Smart Cable of appropriate length. Fit the Distance Sensor cable into Port 2 of the Brain

6 Programming using ROBOTC
Learning objective: Students will be able to program the Basebot using the Distance Sensor

7 Distance Sensor Test Task 1: Using the ‘getDistanceValue’ command
Learning objective: Students will know how Distance Sensors can be used in robotic control systems and how to program the Basebot using the ‘getDistanceValue’ command. Task 1: Using the ‘getDistanceValue’ command Complete the Task 1 experiment changing the distance value Task 2: The ‘getDistanceValue’ command and Power Complete the Task 2 experiment adjusting the Power value What can you conclude from the results?

8 Mine Field Challenge The challenge: On a flat surface set up a small maze with cubes as obstacles, these are the mines and must not be hit! You need to design a program using the distance sensor to navigate through the maze without touching the Mines from a starting point to an end point.

9 Mine Field Challenge

10 Mine Field Challenge Sample Solution

11 Lesson - Plenary As a class, let us consider the following questions?
A. How does the Distance Sensor work? B. Did the power settings effect the stopped distance? C. Was the distance stopped always consistent? D. As well as in a Minefield, where else might the use of a Distance sensor be useful?

12 Summary Today you have:
Learning objective: Students will know how distance sensors can be used in robotic control systems and how they work. Students will understand how to attach the Distance Sensor to the Basebot and then program the Basebot using the ‘getDistanceValue’ command. Students will be able to design a program for the Basebot to take part in the Mine Field Challenge. Today you have: Learned how to control the robot using a Distance sensor Looked at how power effects the distance sensor / robot precision Programmed the Basebot using the ‘getDistanceValue’ command


Download ppt "Using the Distance sensor"

Similar presentations


Ads by Google