Archive

Posts Tagged ‘processing’

Serial to Midi converter!

January 18th, 2009

So I’ve just finished writing an application in Processing which converts midi data coming in over USB to “real” midi data which can then be routed to wherever you want.

But, why should you care? Well, because now you can make and use an ArduinoBoy with no soldering at all! In the picture to the right, you can see the wires coming from the Gameboy link cable into my breadboard, with jumper wires linking this to my Arduino. You could just as easily put the wires straight into your Arduino, though. Then, a couple of quick changes to the ArduinoBoy code to force it into “LSDJ Master Sync” mode (all at the top of the main file, and with very friendly names) and you’re set. Plug everything in, launch my serial2midi app, and bingo!

Heres a vid of it in action:

Here are the downloads (including source) for the serial2midi app…

serial2midi-win

serial2midi-osx

serial2midi-linux

(Only tested under OSX)

And finally, some more images:

UPDATE:

There are some things which I forgot to mention when I originally posted this. Midi over USB is not as fast as using real Midi. If you’re using LSDJ master sync mode on an ArduinoBoy for example, on my computer I start to get some noticeable latency around the 130bpm mark. Having said that, if this were being used only to route note data, there should be no problem at all.

Another thing I forgot to mention is that this version of the app is running at a fixed baud rate of 38400. Soon I’ll make it selectable, as faster baud rates should give lower latencies. Still, the latencies you get with this thing are not as low as you would get over real Midi – but I think for ease of use (ie no need to build any Midi circuitry) this is still a pretty handy app.

Arduino, processing , ,

Schematic and code for my midi keyboard

December 31st, 2008

I’ve put up the schematic and code for the little midi keyboard I made

Awesome schematic

I’m pretty sure most resistor values would work alright in place of the 10Ks, but if I’m wrong, then… tough. They’re just acting as pulldown resistors anyway. The value for the resistors marked with a question mark depends on the current required by your LEDs.

Code

Here is the code which needs to go on your Arduino board, and also the code for the Processing app which converts the serial data to midi. The Processing app requires the rwmidi library, which you can get here.

Arduino code

Processing code

Enjoy!

Arduino, Music , , ,

Arduino/Processing drum machine

December 29th, 2008

So, I made this before my little keyboard, but I’m posting it after. Four dimensional blogging, hooray! Heres the video:

Read more…

Arduino, Music ,