RESULT
The LED on board will periodically switch on and off, with each state lasting for 1 second.
TIPS
The 2 main APIs we are using are digitalWrite(pin, state) & delay(milliseconds). Note that we
need to also use the pinMode(pin, direction) function to set the appropriate pin as an OUTPUT
port before we can use the digitalWrite function for toggling it ON & OFF. Try changing the blink
speed or controlling another LED!
Example - 02 : Playing Music (Buzzer)
WHAT ARE WE DOING HERE?
This example shows how to use the Grove buzzer module to play melodies. It sends a square
wave of the appropriate frequency to the buzzer, generating the corresponding tone.
THE CIRCUIT