Even though the Propeller chip can play WAV files and synthesize speech, sometimes a simple beep is all the noise you need to get the job done.
The first breadboard circuit we'll build for the ActivityBot is a simple piezo speaker.
It is very easy to make this speaker beep with a single line of code:
freqout(4, 1000, 3000); // pin, duration, frequency
You can optionally add this line code at the beginning of your ActivityBot example programs. Then, If your robot's batteries run low, the Propeller microcontroller will reset and restart the program—the beep will let you know if this has happened. We include it because it can be very helpful when experimenting with navigation programs, and trying to figure out why your robot is behaving in an unexpected manner.
Welcome back!
Well done! Now you are ready to go on to robot navigation.
Links
[1] https://learn.parallax.com/propeller-c-simple-circuits/piezo-beep