Apparently, the previous article was our 30th post. Hoorah!
Anyway, here’s some more of our summer shenanigans.
This was a project that I really wanted to finish, but was unfortunately postponed due to some… complications. (I’ll get into that later!) The idea was to create a tiny, MIDI compatible keyboard, using keys scrapped from a kid’s toy.
..Not pictured is of course the Arduino chip. The keyboard works in an odd way, due to me wanting to conserve the amount of pins on the chip. Since the Arduino only has 14 digital pins, (meaning working with values of just 0 and 1) it wouldn’t be smart to assign each pin to a single key, as that would leave me very little room to work with. So I decided that I would rather use the analogue pins, which can process data anywhere between 1 and 0. Doing this was possible through a voltage divider set up through resistors:
This would mean that pressing the first key would divide the given 5 volts by 1, pressing the second key would divide it by two, etc. The resulting voltage would be sent to the Arduino as a value from 0 to 1023, and there it would be used to calculate a desired frequency. Each key is actually just a standard switch, which you can see here.
Now I mentioned earlier that I encountered some ‘complications’ in trying to build this on a permanent board. I’m not sure exactly what caused it– I assume it had to do with some bad connection, or perhaps the quality of the components– but every once in a blue moon the keyboard would become completely sporadic and unstable. This means that it would start producing some bizarre sounds, without any way to stop it. Here is a lovely sound clip! (Prepare your eardrums)
Maybe I’ll pick this up again someday, especially since now I’ve found some cheaper places to get parts…