Lesson Four: Sound Alarm
This program makes your alarm clock seem even more familiar with a loud beep at alarm time. To make the speaker work, you need a way to create and stop tones without interrupting the counting of the clock, so you'll use more variable and millis() to constantly check the time and control the speaker.
Topics Covered:
Triggering a beep when it is alarmTime is similar to creating a message on the screen: It's an action that takes place when a condition is met. In this program, you saw how you had to modify the way that action works because it has two parts: on and off.