Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
PAGE 30<br />
1<br />
2<br />
3<br />
4<br />
5<br />
6<br />
7<br />
8<br />
9<br />
10<br />
ACTIVITY<br />
2<br />
SECTION 4<br />
Copymaster for use with 9795<br />
INTERMEDIATE AND<br />
ADVANCED IDEAS USING<br />
PROGRAMMER INVENTOR<br />
The Burglar Alarm 2<br />
You are going to create a burglar alarm that uses sound, light and a<br />
motorized “scarecrow” to scare away a burglar.<br />
Add the light sensor to the house as shown on page 11 of the Building Booklet.<br />
Make sure the lamp is connected to port A and the light sensor is connected<br />
to port 1.<br />
Load the ROBOLAB software and choose Inventor 3.<br />
Create a program that turns on the light and makes some sounds when the<br />
light sensor is activated.Also add the movement of the motorized scarecrow<br />
you created in the first Burglar Alarm activity.You can use the Jump and Land<br />
icons to make the program run continuously.<br />
Download the program and run it.<br />
Try to sneak the LEGO figure through the door past the light sensor. Does<br />
your burglar alarm work? If not, check the light sensor reading as the LEGO<br />
figure is in front of the light sensor and compare it to the light sensor setting<br />
in your program.<br />
For a more dramatic burglar alarm, use the Loop icons<br />
to make the sound and lamp turn on more than once. Create a loop that<br />
runs inside the Jump and Land structure.<br />
Download the program with the loop and try it.<br />
What do you think? Is it a better burglar alarm? The Loop runs twice as a<br />
default but you can modify the command to run many more times.<br />
Finally, use the Piano Player to create a more elaborate sound for your<br />
burglar alarm. (See a description in the Doorbell activity). Change to<br />
Inventor 4.Then choose Piano Player from the Project menu so you can<br />
record a scroll of your own!<br />
Use micromotor pieces<br />
for your scarecrow.