9 years, 4 months ago.

MIDI Master/Slave - connecting to a MIDI keyboard.

These examples shows how to attach a Mbed-based device (slave) to a computer.

Is it possible with this library to connect the Mbed device as master; i.e. connect to e.g. a MIDI keyboard as the AKAI MPKmini and how is this done?

I wish to connect a keyboard directly to the Mbed and process the MIDI-information on the Mbed.

Question relating to:

1 Answer

9 years, 4 months ago.

Assuming your MIDI device has an actual MIDI port, you can usually communicate with it using a regular UART port and some additional components. (Here is a guide that seems to be fairly complete: http://www.instructables.com/id/Send-and-Receive-MIDI-with-Arduino/#step0)

If your MIDI device only has a USB port, you might still be able to make it work. It's not documented in the handbook, but a user has added functionality for USB Host MIDI. You can see the programming interface here: https://github.com/mbedmicro/mbed/blob/master/libraries/USBHost/USBHostMIDI/USBHostMIDI.h.

Here's an example program I found: https://developer.mbed.org/users/kshoji/code/USBHostMIDI_example/

Accepted Answer

Thank you, Brian. It looks exactly like the code I need. There is no Midi port on my device, so USB is only way, and it seems to be the norm of hobby priced deviced. I look forward to trying it.

posted by Rasmus Andersen 14 Aug 2015