This article assumes you successfully downloaded a test program to your NXT as shown in the previous video. This means you can make your robot 'beep' once or twice. Next let's build some confidence while covering a fundamental concept in programming: Loops. We will also use the touch sensor.
So far we have created a program which output a single tone, or single sequence of tones. What if we want to repeat sounds, such as a police siren?
If you want to repeat a behaviors you will need to put them inside a loop block which looks like this:
The following video demonstrates the loop block in action. It explains how to nest loops as well as how to control a loop using your touch sensor:
Next let's build on loops to create a night vision device.