Go Down

Topic: Arduino MIDI to play Garage Band on the iPhone/iPAD (Read 1 time) previous topic - next topic

marcelloblue

Hi,
I'm building a drum kit and I'm now able to play the sounds on my Windows PC through the Serial to MIDI converter running on the PC.
I would like now to do the same using my iPhone 4 with Garage Band instead of a PC.

Garage Band accepts MIDI-in, and devices like the iRIG Keys mini keyboard is provided with a simple cable to connect the keyboard to the iPhone to play the sounds of any MIDI compatible iPhone app.

I'm wondering why I shouldn't be able to do the same.
I can probably use something like Sparkfun iPOD 30 pins male connector (which pin??), but I don't know what to do on the Arduino side.

Do I need a MIDI Shield?
Is my Arduino UNO USB connector enough?

Grumpy_Mike

Quote
I'm wondering why I shouldn't be able to do the same.

You can.  :)
Quote
Do I need a MIDI Shield?

No.
Quote
s my Arduino UNO USB connector enough?

No the Arduino's USB port is a USB client, that is it will only look like a serial port to any device connected to it.

However the Arduino Leonardo can be made to look like a MIDI port, I would use that along with a Camera interface connector to the iPhone. 

marcelloblue

Thanks. I'll take a look at Leonardo.
Also, is there a way to avoid even the camera connector and plug directly into the iphone with the 30 pins connector?
I would prefer to build my own interface to the iphone even if that means additional components for Arduino.

Grumpy_Mike

Quote
I'll take a look at Leonardo

Be sure to check how to make it into a MIDI device, it is possible but I think it might be a bit new at the moment.

Quote
is there a way to avoid even the camera connector and plug directly into the iphone with the 30 pins connector?

I would have thought so, yes.
You will need to make up a special lead from the arduino's USB to the right pins on the connector. I don't know off hand what these are numbered.

Nantonos


However the Arduino Leonardo can be made to look like a MIDI port, I would use that along with a Camera interface connector to the iPhone. 


Is that in 1.0.2, or some newer testing version?

Looking in USBCore.h from Arduino 1.0.2 I see

Code: [Select]
#define USB_DEVICE_CLASS_COMMUNICATIONS        0x02
#define USB_DEVICE_CLASS_HUMAN_INTERFACE       0x03
#define USB_DEVICE_CLASS_STORAGE               0x08
#define USB_DEVICE_CLASS_VENDOR_SPECIFIC       0xFF


Notice that the Audio class (0x01) is missing. USB MIDI is subclass 0x03 of the Audio class.

Grumpy_Mike

Quote
Is that in 1.0.2,

No.
It is in code that you write or at least that other people write.

marcelloblue

Quote

You will need to make up a special lead from the arduino's USB to the right pins on the connector. I don't know off hand what these are numbered.


I found the  30 pins connector map here http://www.allpinouts.org/index.php/Apple_iPod,_iPad_and_iPhone_dock
I'll give a try.

Go Up