Return to Top
copies of the Lighten Up!
student activity for each student to have one.
Reflection Stands (See A Note on Materials
StartLight program into slot #5 of an RCX. This program must run at least one
time before you can get light sensor readings from View on the display window.
(See Important Note in the box, page 6-2.) The StartLight program has 3 light
sensor watchers, one for each port. By running this program once, you configure
all three ports for a light sensor.
Roverbot to track a line
(If you choose to
demonstrate in Whole Class Activity).
Suggestion: We recommend doing this part of the Prepare
Ahead section after you have had a chance to read through this Lighten Up!
Build a light
sensor attachment, following building instruction on pages 34 an 35 of the
light sensor attachment to one of the Roverbots, placing the connector wire on
input port #1.
Roverbot so that the light sensor is directly above the black line on the Track
Sheet provided in each Mindstorms™ kit. Use the View button on the RCX to get a
light reading, and write it down. Then move Roverbot so that the light sensor is
directly above the light (white) area. Write down the light reading you get
Linetracker program. Look at the light ranges set for “if light” on each event
watcher. Check the reading with the light sensor above the black line to see if
it falls within the 25..38 range set in the program. (For example, if your
reading of the black line was 34 and the range set in the program is 25 to 38,
you do not have to adjust the range. However, if your reading was 23, you must
change the program to include the number 23 in the range set for this event
watcher.) Do the same for your light reading with the light sensor pointing at
the white background.
Linetracker program into slot #5.
Roverbot near or on the dark track and run it on program 5. It should track the
edge of the black line if the ranges are correct.
Ambient light conditions may change from one day to another or at different
hours of the day. If your Linetracker does not behave as expected, check the
light readings and see if they fall within your dark and light ranges. Change
the ranges as needed.
Also, turning on/off
overhead lights may help, because it will change the light readings, and they
may then fall within your set ranges.
Programming for Light Sensor Input