I teach music in elementary school. We play a lot of recorder music. i.e. the kids play little flutes...... I have several special needs kids who can are using these black poster boards with circles that have the name of the note on them. These students push on the circles with notes names at the same time the rest of the students are playing a song..... Most of the special needs kids can do this fairly well and in time with the music.
What I am looking to to is build a very simple sound generator so that these kids could play the same pitch as those being played by the students on their recorders. I would only be a few pitches. I thought I could attach some kind of small button to the bottom of their round circles so that when they push on them the sound would come out of a small speaker, loud enough so they could hear.
Having a mother who is a teacher and having liked school, how could I resist? Truth be told I couldn't. This is pretty much a chronicle of the project and instructions on how to build your own.
Step 1: The beginning or why I couldn't stick to analog
The veritable timer:
After giving the project some thought I immediately thought of the piezo tone generator from my op-amps Forest Mims III book. Seemed like a good way to go, it's just a piezo, an 741 IC and a couple passive components. No big deal right? Well it has 2 problems, 1) when you depress the switch, it's possible to change the pitch 2) it's damn near impossible to tune. The first could likely be overcome with with some debounce technology, though i didn't know how to do that without adding another counter. It could also be an issue with using a piezo. The second issue just got unwieldy when you started trying to hit a certain pitch. What about the 555? The datasheet shows a time dlay function based on resistors and capacitors. Which is great until you start typing in actual values of real world parts, that's when you'll find hitting a 440Hz pitch starts to get a little difficult. You can use trim pots to get it tuned in, but over time they tend to move. Constantly tuning the instrument, compiled on top of rapid increase on cost and quantity of parts, and my wife making the pitch change when she pushed the button killed the 555 for this project.
No problem, people have been making synths with op-amps since before I was born. How hard could it be to make a really simple one, with few parts and specific notes? Harder than I thought. Most of the designs out there are very over complicated for this project. Synth designers are out for the perfect waveform/tone. This directly conflicts with a project that is supposed to be cheap enough for school or teachers budgets. Building a keyboard is easy enough, it's just a bunch of resistors and power or a bunch of diodes and power. It's the rest of the circuit design, and the cost of custom pcbs that starts to get out of hand for someone at a beginning electronics level.
So the project got redefined before i even really got going. I needed something that could toggle a speaker pin, in time, with the press of a button. I didn't want to have to design and buy a PCB. This had to use as few components an possible, and be assembled as a beginners kit. It was staring me in the face the whole time. Duh!! Microcontroller!
So after purchasing both an Modern Devices Bare Bones Arduino kit and an Evil Mad Scientist Simple Target Board and letting them sit on my desk for months not being used, I had the perfect introductory project. I started looking at the time it takes to put both together, the learning curve for the code, cost, the additional parts needed and make it do what I want and settled on the target board.
Cost was pretty even, $15 plus a $20 FTDI cable for the Arduino, $12 plus a $22 USBtinyISP programmer. I already knew C++ from the little college I could stand and figured C for microcontrollers wouldn't be that bad, while other than blinking a light to make sure I put my kit together properly, I had no Arduino experience. Both could be mounted. It was pretty much a toss up, so I decided on the fewer parts of the two, the target board.