I developed this library for my own use in a fake "cricketuino" project.
Now thousands of people have tried it, broke it, forked it, and it even caught the eye of Atmel themselves after being posted on the main HaD blog. (Go follow / like Atmel on here by the way, we owe this awesome hardware platform to them!)
In return for all the love the lib has gotten this week, I've picked development back up, and expanded much-needed compatibility to the ATmega168 / 328 / 1280 / 2560 / 16u2 / 32u4! Because each of these boards ties Timer0 to different pins, the most recent release of the Volume lib no longer allows direct assignment of speaker pins.
Volume vol(speakerPin);is now just:
With this change, a DEFAULT_PIN for each board is automatically defined, and you have the option to change it to the ALTERNATE_PIN Timer0 is also tied to for that board using:
*I recently killed my only ATmega32u4 board while stripping it for low-power usage and don't have one to test current releases of the library. If anyone who has a working one wants to report compatibility back to me, please do so as I've only tested the initial release!
Thank you all so much for the awesome support, let's work together to bring beautiful tones to more Arduinos! I'm currently working on the highly-demanded ATtiny support, more on that soon!
- Connor Nishijima