Arduino library created for convenient playing of melodies through a small piezo buzzer or speaker.
Instructions:
-
Create a folder in your Arduino libraries folder called Melody and clone this repo into that folder. The root of your Melody folder should contain Melody.h and the other files from this repo.
-
Restart your Arduino IDE for it to be able to recognize the library
-
Create a new Arduino project. In it, paste the contents of /examples/example1.ino
-
Wire up a piezo buzzer or speaker just like in this example: http://arduino.cc/en/Tutorial/Tone. (Make sure MELODY_PIN matches yoru wiring.)
-
Run it. You should hear some tunes play.