Experiment with the Line Finder Sensor on different surfaces and different heights
to see how the sensor reacts.
Extension Activity
With the example as a reference, try creating a new sketch to use your Line Finder
Sensor. Remember what you learned from your previous activities and think of
additional creative actions to perform based on the condition of the Line Finder
Sensor.
Real-World Link
There are many uses for a robot that can follow a line. Automated robots are being
developed to follow lines to deliver materials within hospitals. In the future, they
could also move materials around warehouses or transport goods.
Careers: materials engineer, electromechanical technician, software developer
STEM Connections
• Science
Ĕ Light
Ĕ Electromagnetic spectrum
• Technology
Ĕ Guidance system
Ĕ Automation
• Engineering
Ĕ Microcontroller
Ĕ Embedded system
• Math
Ĕ Angles
Ĕ Lines
Block-Text Correlation
void
setup
() {
pulse.
PulseBegin
();
void
loop
() {
if
(pulse.
readLineSensor
(2) == 1) {
pulse.
setRedLED
(LOW);
pulse.
setYellowLED
(HIGH);
}
else if
(pulse.
readLineSensor
(2) == 0) {
pulse.
setRedLED
(HIGH);
pulse.
setYellowLED
(LOW);
Note: All the actions completed in the if () or
if/else () loops are contained within braces.
Arduino Source Code
#include
<
PULSE
.h>
PULSE
pulse;
void
setup
() {
pulse.
PulseBegin
();
}
void
loop
() {
if
(pulse.
readLineSensor
(2) == 1) {
pulse.
setRedLED
(LOW);
pulse.
setYellowLED
(HIGH);
}
else if
(pulse.
readLineSensor
(2) == 0) {
pulse.
setRedLED
(HIGH);
pulse.
setYellowLED
(LOW);
}
}
40
Getting Started Activities
Summary of Contents for tetrix prime
Page 1: ...44301 TETRIX PULSE Robotics Controller Programming Guide...
Page 7: ...PULSE Controller Technology Overview Getting Started 5...
Page 61: ...Step 9 Step 10 Step 12 Step 14 Step 11 Step 13 Building and Coding the PULSE CodeeBot 59...
Page 62: ...Step 18 Step 17 Finished Assembly Step 16 Step 15 60 Building and Coding the PULSE CodeeBot...
Page 73: ...Step 1 0 Step 1 1 Build two like this Building and Coding the PULSE CodeeBot 71...
Page 74: ...Step 1 2 Step 1 3 72 Building and Coding the PULSE CodeeBot...
Page 75: ...Step 1 4 Building and Coding the PULSE CodeeBot 73...
Page 78: ...Step 2 2 Step 2 3 76 Building and Coding the PULSE CodeeBot...
Page 79: ...Step 2 4 Step 2 5 Building and Coding the PULSE CodeeBot 77...
Page 80: ...Step 2 6 Step 2 7 78 Building and Coding the PULSE CodeeBot...
Page 81: ...Step 2 8 Building and Coding the PULSE CodeeBot 79...
Page 83: ...Step 3 0 Step 3 1 Building and Coding the PULSE CodeeBot 81...
Page 84: ...Step 3 2 82 Building and Coding the PULSE CodeeBot...
Page 85: ...Step 3 3 Building and Coding the PULSE CodeeBot 83...
Page 87: ...Step 4 0 Step 4 1 Building and Coding the PULSE CodeeBot 85...
Page 88: ...Step 4 2 86 Building and Coding the PULSE CodeeBot...
Page 89: ...Finished assembly should look like this Building and Coding the PULSE CodeeBot 87...
Page 131: ...GS Activity 4 extension GS Activity 5 extension Appendix 129...
Page 144: ...142 Notes...
Page 145: ......