Tuesday, December 1, 2009

Calculator MIDI USB Controller

Borderline useless, more trouble than its worth, but cool nonetheless.

Make cool things look as nerdy and boring as possible!
One of the first things I thought of doing with an arduino was turning an old calculator into a MIDI controller. The buttons are simple momentary switches.. no velocity sensitivity, but its nice for a pretty compact set of buttons.. and it looks neat. stfu.



Eight of the buttons are connected to the arduino digital inputs through a 4021 shift register as explained here. The rest make their way directly to the remaining digital ins.

The shift reg as well as the actual connections to the keypad are hidden on the underside of that slightly burnt perf board
Button matrixeses are generally pretty similar. Each button can be checked by a unique pair of contacts on the terminal or ribbon cable or whatever is connecting to the board. The trick is finding out which ones go where. All it takes is a little patience and a volt meter with a continuity tester.

Here's a tutorial I just found showing how to interface with a keypad. You're welcome.

The arduino patch checks the state of the buttons and generates the MIDI signals which are sent to a butchered $6 MIDI to USB converter cable/board/thing.

The midi-usb converter is the green board at the far right. 
Midi from the arduino's serial out goes into the bottom, usb comes out of the top. 
It also powers the arduino.

I mainly use it to trigger cue points in Torq Serato, but it works just as well for triggering clips or controlling a drum rack (minus velocity sensitivity, of course) in Live.

This is actually the second calculator I've tried. The first one is a mess and lacked the tricky USB support. I'll find some time to redo it and document it from the start, in case someone else would like to do something similar.

11 comments:

  1. Great job on the controller! It would be cool if you posted a video of you "playing" it :)
    I found your blog via a post you made in another blog (create digital music) about using the Arduino as a MIDI drum controller. I have a question about the Arduino I wanted to see if you could answer. I recently received a "Rock revolution" drum pad as a gift. (Game for xbox 360). I have hooked it up to the PC and can use it to trigger drum samples at full volume. However, as a game controller, it has no velocity sensitive information. I am considering getting an Arduino to interface it to MIDI. But I needed to know if a stock Arduino will work, or if I would also need to get this kit: http://www.spikenzielabs.com/SpikenzieLabs/DrumKitKit.html

    I know next to nothing about the Arduino so I wasn't sure how necessary it would be to have the expansion drumkitkit. All I would be doing is soldering the piezos from the drumpad into the arduino. In the video on create digital music, it just looks like he has some kind of breadboard on the Arduino and not necessarily the drumkitkit, and his is taking velocity sensitive information. So I assume it would work, but again I know nothing about this thing and am also "severely amateur" at electronics.

    I also really like your idea of using the $6 midi-usb interface! I find it incredible that it works with such minimal soldering and I'll definitely do the same for mine. :)

    Upon looking closer at the drumkitkit, it appears that it just gives you some piezo's, which I already have.... But I just wanted to run it by somebody else to make sure that I would be OK to solder the piezos straight onto the plain Arduino and still get velocity sensitive MIDI information?

    Thanks for any help!

    Peace

    ReplyDelete
  2. Thanks for the feedback!

    You can definitely hook those piezos directly to an arduino.. It looks like all he's doing with that shield is cleaning up some of the mess that you would have if you did it yourself..

    you'll still need to include everything he has on that board (the resistors for sure, not sure what the diodes are for..), but the board itself is just to make your life easier when its all hooked up... which is pretty much the point of any arduino shield and might very well be worth the price.

    The piezo's will send some voltage (0-5v or whatever depending on the force used to hit the piezo) to the arduino's analog in. Its then up to the code you write for the arduino to take that information and generate the appropriate midi data. Make sense?

    I'll be posting a more in-depth look at that cheapo usb-midi hack in the next week or so if you are interested..

    Good luck!

    ReplyDelete
  3. Hey. Thanks for your response. I read through more info on todbot's blog and found some people who encountered problems while trying to use the arduino as a drum brain. Specifically, this:

    http://www.somesoundswelike.com/2008/02/diy-drum-triggers-reading-the-sensor-scientifically/

    However, I may have found several alternate solutions, that I am looking into at the moment. One involving software, several involving other hardware (not a regular arduino)

    If I go the hardware route, I may still use your usb midi cable idea to make things simpler, so I am definitely very interested in hearing more about this! I'll keep checking back

    Thanks again

    ReplyDelete
  4. Mr. Shiftmore,

    I was wondering if you may be able to post what the names of the terminals are on either side of your midi to usb converter. I have bought two so far and the terminals have had the same names but they have not been in the same order in each case. So my fear is that connecting mine in the fashion you have is that the terminals will be different. The one that I currently have has the names : S, G, V , D+, and D- on the usb side and in-, in+, G(two terminals), 0+, and 0-.

    Thanks

    ReplyDelete
  5. This is just great, I really love how simple it is. I'm going to use this to build a footcontroller to operate Sooperlooper.

    ReplyDelete
  6. You're the operator with the pocket calculator! Awesome!

    ReplyDelete
  7. You're the operator with the pocket calculator! Awesome!

    ReplyDelete
  8. Hi! A regular reader here in Lubbock, Texas!
    I finally trusted to leave a comment
    I have enjoyed reading your page.
    Just wanted to tell you to keep up the great work you are doing!
    driverpack solution crack
    morphvox pro crack
    reason crack
    mirillis action crack
    poweriso crack

    ReplyDelete
  9. It was very easy to find my way around and very user friendly Good job to your designer and dev of your site. I hope your rate was doing well. 먹튀검증

    ReplyDelete
  10. People should know these tips because you have great content! Thanks anyway! 온라인경마

    ReplyDelete
  11. I am very grateful that I have crossed your site. Your content was very great that I cant stop reading each post that you have. I hope for the best outcome of your site. Thanks 토토

    ReplyDelete