Howdie,
So I've been using Arduino stuff for music for some time, and I always use it as serial, and send it into Max/MSP where I parse the stuff. This works ok, but I often have pretty serious kernel panics (greyscreen on a mac) related to serial/buffer stuff.
So what I want to do is setup an Arduino to be a generic input device. So all digital inputs would be sent as 0/127 (binary) and analog inputs would end 0-127.
But the idea being that all inputs are being read and sent as midi.
There's a sacrifice in resolution for analog inputs this way, but in exchange for bulletproof stability (class-compliant MIDI).
I know there's the Maxuino library that lets you control everything on the Arduino from Max, but it, too, uses serial, and I want to avoid that.
I've never reprogrammed the input chip on an Arduino, like you can with the newer ones, so that part is new to me.
So the two questions are:
- Anyone know of a 'read all inputs and send all MIDI' sketch?
- Is there a decent guide for programming the input chip on an Arduino to act as class-compliant MIDI?
Ok, so I found this which looks pretty good. I've not messed with Teensy's at all, so don't know how different it is to 'regular' Arduino stuff.
http://www.pjrc.com/teensy/td_midi.html
Hi,
Yes that is the only simple way to do it at the moment, you should be able to do it with the other Arduinos but the software drivers are not developed yet.
The teensy seems to be well built for this kind of thing, and is cheap too.
Yes I have one and is is just as easy to use as the arduino.
The form factor is so much smaller, which makes it easy to build into things but harder for casual playing about with.
The only snag is that you need a patch to apply to the Arduino IDE which is version specific. So if you upgrade the IDE you have to wait until the upgraded patch is available.
kriista:
Ok, so I found this which looks pretty good. I've not messed with Teensy's at all, so don't know how different it is to 'regular' Arduino stuff.
Teensyduino: Using USB MIDI with Teensy on the Arduino IDE
Yes, each of the Teensy models has a good USB stack which includes USB MIDI (class compliant) as well as USB Keyboard, mouse, etc. The USB mode is chosen with a menu option.
In terms of compatibility the Teensy 2 and Teensy ++2 are both AVR-based so code that works on an Arduino Uno will likely work there; a major difference is that Serial (over USB to the serial monitor) and Serial1 (using Tx and Rx) are independent 9so you can use both at once, unlike Arduino).
Teensy 3.0 uses a fast, 96MHz ARM chip so it is more like the Arduino Due. Except you can use the Arduino 1.0.5 with it, its not restricteed to 1.5.x.
There are a lot of libraries available, which either work as-is or have been ported to add Teensy support or have been specially written for Teensy.
Its a good choice for a USB Midi device.