Go Down

Topic: Mac OS X Arduino-virtual MIDI device software (Read 7421 times) previous topic - next topic


I wrote an open source Mac OS X application that creates a virtual MIDI drum instrument from Arduino serial output. This eliminates the need for additional MIDI hardware.  Just plug in your Arduino USB, start the Ardrumo application, then your favorite MIDI sequencer (e.g. GarageBand).  See this site for details and downloads: http://code.google.com/p/ardrumo/ for details.



The Graphical User Interface is so nice to.
I like the way you exhibit your project (including price details)


I love the java knob to (and I hope Mellis 'll put many of them in the next arduino release :-)))



hi there,
I've been waiting for something like your software for a long time, it looks amazing.
However, when I tried running it (PowerPC Mac OS X 10.4.1) It didnt work. I got the error message

"Cannot launch Java application
Uncaught exception in main method:
java.lang.UnsatisfiedLinkError: /Ardrumo.app/Contents/Resources/Java/librxtxSerial.jnlib:"

And the only option is to press the quit button.
Any help would be greatly appreciated


replaced the librxtxSerial.jnlib file with the one that comes in the arduino package and it works brilliantly now. Might be a PowerPC issue?
anyway, thanks again for the wonderful software!


Thanks for the heads up!  A new version is now available with PowerPC-compatible libraries.


Great job,

For me I only got it working when I create the /var/lock dir by hand and chmod 777 it and also chmod 777 the /var/spool/uucp dir.



Hey, Great project!  Kinda new to this side of things (computer guy) so i have a few questions for you if you don't mind!  been experimenting with this.              

First,  i couldn't find any of the peizo's you used in Canada (radioshack closed here) so I got some pizeo film tabs from http://search.digikey.com/scripts/DkSearch/dksus.dll?Detail?name=MSP1006-ND

Now,  they do seem to be partially working but I'm having a lot of problems with sensitivity.    I hit it once and it goes twice, or I don't hit it at all and it still registers as a hit.  

The threshold doesn't really have much effect for me (inside arduino or ardumo.        

Do you think this could be because I need to use a higher value resistor on the piezo? I'm using the 1m like yours and todbot.

I've tried a few differen't smooth functions with no luck.  I have managed to get it to stop hitting on its own at points (by setting threshold/smoothing functions), but I can't get a consistant single hit from it when I give it a good wack, it likes doubling up on me.  

Also, Its really hard to tell from your video because your child is playing, but how fast does it respond?  not meanig the delay between the computer, but can it pick up doubles and midium speed rolls?  Mine does not seem to be able to pick up anything above maybe 80 bpm,  am I expecting too much from this?  (I figured  57600 should be quick enough to send pretty fast signals but maybe I'm crazy?)

And when I look at the serial monitor (with your ardumo ardunio code) I'm seeing a constant sending between 0 - 400 (give or take, there are spikes)  and when I hit it, it usally only registers in the 420-500 area,  with some going up into the thousands for what appears to be no reason (doesn't match the strength I hit it at).

What kind of numbers do you get in your serial monitor,  a) when nothing is happening and b) when you hit it,  and when you do hit it do you get just one number or does your java program smooth it out? ( I get multiple readings per hit)   I'm thinking my numbers must be varying a lot more then yours.

Last thing I can think of,  does the piezo senor you use sense vibration as well?  because I've been noticing feedback from me moving and such close to it.

I'm not really sure where to go next,  my best guess would be something like http://www.musicfromouterspace.com/analogsynth/SOUNDLABMINISYNTH/drum_trigger.html

but your numbers from the serial output would deffently put me in the right direction.

Anyways, that sure was mouth full.    Any help you can give would be awsome, love to get this going right!  



hey, this is way cool!  I'm working on more of the physical side of the interface... (http://somesoundswelike.com)   To my reluctant resignation, I've been pursuing the physical MIDI route.  I much prefer your serial to virtual midi approach, but I ran into some system freeze problem.  If I can reliably reproduce it, I will send the details along, otherwise, chalk it up to user-error.  

Hey, so any thoughts on the double triggering issue?  It seems like it could be the piezo's "ringing" if I read the todbot graph correctly...  



hey, this is way cool!  I'm working on more of the physical side of the interface... (http://somesoundswelike.com)  [...]

these pedals look great. i love MDF :-)


Jan 08, 2008, 12:57 pm Last Edit: Jan 08, 2008, 12:59 pm by orphans Reason: 1
I've had a bit of a play with this, and I reckon it's possibly trying to do a bit too much with a bit too little.      Some of this might be wrong, but it's what I've interpreted from a bit of reading around...
The double triggering is because the piezo is essentially giving out an AC signal, giving current in one direction when it flexes, then the other direction when it returns.  Because it vibrates you are likely to get multiple triggers.  This also explains the higher/lower velocity triggering, because sometimes you are reading a secondary peak.  See http://www.edrum.info/theory.html for a few nice graphs and a better explanation that I could give :)

I think there's probably some mileage out of building a bit of a more complex input circuit to rectify the signal off the piezo.  Then something like an envelope follower in the code (or hardware) to give you a nice smoothed peak.  Again have a look at http://www.edrum.info/files/analog8_v06.gif for another example of an input circuit (with sensitivity control - fancy.)  I've not had the time to try this out, but it looks interesting to give a shot at.

Anyway, not sure if any of this is really any use, but I thought I'd put it out there to see what anyone reckoned.


Ah yeah, that's interesting. I was thinking something similar, but not as plausible as your explanation. :) Yours makes a lot more sense.    It sure seems like a lot of extra junk to make sure the signal doesn't flow backwards.  I'm no expert, but I think I'll try hooking another zener diode inline between the piezo's red wire and the arduino's analog in pin...  it's probably way too simple to actually work, but we learn by failing... :)


This also explains the higher/lower velocity triggering, because sometimes you are reading a secondary peak.  See http://www.edrum.info/theory.html for a few nice graphs and a better explanation that I could give :)

I just checked out the link, and yep, that's very good information.


Hey mschaff.

Amazing project, it has been a great inspiration for me to get started on doing my own projects.

As you are most probably aware there has been quite some discussion about the need for a generic Arduino Serial to MIDI converter for Mac OS (see here). Your program seems to fill out that hole, but I am wondering how much of the MIDI protocol it supports. I assume Note On/Off messages, but does it also support Controller messages (0x80-0x8F) and Clock/Start/Continue/Stop messages (0xF8, 0xFA, 0xFB and 0xFC)?

I hooked up an old Super Nintendo Joypad to my Arduino board and succeeded in sending Controller messages to Ableton Live, but only on a Windows XP system using the serial to MIDI drivers suggested in the above mentioned thread. As I am migrating to Mac at the moment I'm very interested in finding a solution for this platform, but unfortunately my own programming skills are limited to Arduino code :D

I am also leaning towards running the Arduino interface as a MIDI sync master device for Ableton (I shall post my project once I get the documentation down) hence my interest in the MIDI Clock/Start/Continue/Stop messages.

Thanks for the inspiration


Keep Under Water Music Alive!


Could anyone please explain this schematic a little clearer for me.  I am fairly new to this and catch myself making things a lot harder then they really are.  Thanks in advance!


Just place a 1 mega-ohm resistor between the Piezo's negative lead and ground (there should be a ground point near the analog in Pins). Next plug the piezo's  positive into pin 0 (or the other 5 analog in pins).

Go Up