Creative Commons images are CC BY-NC-SA 3.0

Description: The SparkFun MIDI Shield board gives your Arduino-based device access to the antiquated, but still widely used and well supported MIDI communication protocol, so you can control synthesizers, sequencers, and other musical devices. The MIDI protocol shares many similarities with standard asynchronous serial interfaces, so you can use the UART pins of your Arduino to send and receive MIDI’s event messages.

The SparkFun MIDI Shield provides an opto-isolated MIDI-IN port as well as a MIDI-OUT port. The MIDI Shield can be mounted directly on top of an Arduino, connecting the MIDI-IN to the Arduino’s hardware RX pin and the MIDI-OUT to TX. Potentiometers are connected to analog pins 1 and 2, and can be used to control volume, pitch, tone or anything else you’d like. The shield also comes with three momentary push buttons, a reset button, and green and red stat LEDs. The RUN/PROG switch allows you to program the Arduino over serial without having to remove the shield.

This revision of the SparkFun MIDI Shield also adds several configurable features, such as converting the MIDI output to a MIDI thru, and the option to use a software serial port for MIDI, leaving the hardware serial for programming and debugging. It also buffers the output, making it compatible with the Arduino Pro without needing to circumvent the protection resistors on the serial TX and RX lines.

Note: The MIDI Shield does not come with all parts soldered on. Two MIDI connectors, two trimpots, and three pushbuttons are included with the product and will need to be attached by the end user.

Includes:

  • SparkFun MIDI Shield PCB
  • 2x 5-pin DIN conectors
  • 2x 10K rotary potentiometer
  • 3x 12mm tactile pushbutton switches

Documents:

Recommended Products

Customer Comments

  • Curious if this shield will work with an Arduino Mega? Thanks

  • I flashed my Arduino UNO with the MocoLUFA USB-MIDI firmware, making it a class-compliant USB-MIDI interface that can be used with my iPad. I am using the Arduino Midi Library in my sketch.

    When I set the Midi Shield’s RUN/PROG switch to the “RUN” position, midi-in from the shield’s DIN port transfers to the USB-MIDI port, and I can record midi to my iPad, but midi-out from my iPad through the USB port does not get transferred to the midi-out DIN.

    When I set the RUN/PROG switch to “PROG”, the opposite is true. I can send midi-out from iPad USB and it will transfer to the shield’s midi-out DIN port, but midi-in from the shield’s DIN port does not work.

    Is there way to have both? I would like midi-in from the DIN to go to the USB-MIDI out, and midi-in from USB-MIDI to go to the shield’s midi-out DIN port, at the same time, without having to flip a switch and choose between exclusive in or out.

  • I am trying to download the midi library suggested in the hook up guide. When I try to add it I get an arduino error message “specified folder/zip file does not contain a valid library”. Checked some user groups and some say arduino can’t handle the special characters (underscore) and some say it can. Any ideas on what else to try.

    • I don’t know if the 47 Effects library is up to date with the latest automatic Arduino library manager format. You might have to install it manually. I installed it by copying the contents of the /src/ directory into my Arduino library directory: C:\Users\byron.j\Documents\Arduino\libraries\MIDI

      After that, when I start Arduino, MIDI simply shows up in the ‘sketch->include library’ menu. You don’t need to ‘add…’ or ‘manage…’ the library.

      It’s building in Arduino 1.6.5, running under Windows 7.

      Perusing my libraries directory, I see a number of other libraries with underscores in the directory and file names, so I’m not sure that’s the problem.

    • Toni_K / last year / 1

      Make sure you’re nesting the library properly. If you manually add it to Arduino but nest in too many directories, it won’t read properly. Your structure should look like the following: arduino>libraries>Midi_Library>src/examples

Customer Reviews

4.6 out of 5

Based on 7 ratings:

5 star
5
4 star
1
3 star
1
2 star
0
1 star
0

You are the Best

It worked pretty well. Am so happy with the product. I hope to do more business with sparkfun in Future


Perfect for my MIDI Project

I use it on an Arduino Uno to connect a Roland PC-100 keyboard to a Roland CM-32L sound module. I would advise against changing the default hardware serial configuration. I tried software serial for MIDI but noticed dropped data, plus I almost destroyed the shield trying to desolder and change the jumpers back to hardware serial communications.


Great gift for my son's birthday

I got this for my son’s 15th birthday, he is really into MIDI stuff and python programming for MIDI, and arduino. I was amazed how fast he had this kit soldered up, we barely had finished the cake and ice cream and he had it attached to his m-audio keyboard and making sounds. Thanks for a great product.


Great shield!

I used this for my Halloween project - a sidewalk keyboard. The MIDI shield made the music-making part easy. I didn’t think I’d use the pots and buttons but they came in handy, too, for controlling LED blink rates and MIDI program changes.


Easy arpeggiator

I bought this to create a little standalone MIDI arpeggiator using Brendan Clarke’s code found here: http://brendanclarke.com/2014/04/23/arduino-based-midi-sequencer/. It works great (I used the default jumper settings), and the shield was a very simple build. I have another Arduino that I use as a USB host for USB MIDI controllers (the controller’s USB output is converted to DIN MIDI via a non-Sparkfun MIDI shield). The controls on the Sparkfun could be really useful in that application, too.


Suffers from some deficiencies: good for a simple hobby, but not for anything more advanced

I have purchased a number of Sparkfun MIDI Shields for a project I developed (https://cs.gmu.edu/~sean/projects/gizmo/). The Shield is unique in providing both an interface (two knobs, three buttons) and a MIDI In/Out, so it’s the best option for me. It does just what it says on the tin, and it’s easy to assemble and code for. But it has a number of deficiencies, which force me to give it less than a stellar review.

First off: the parts are low quality. The provided buttons are really spectacularly bad: from the start they are wobbly and easily mis-trigger, and in my experience they usually start going south after a mere 5000 presses each! Do not install these buttons: buy some better ones. The pots are pretty noisy: this is a problem because for MIDI applications you want at least 7 bits of reliable accuracy, and ideally 10 bits. With a combination of tricks I can squeeze maybe 8 bits out of them. Last, the MIDI ports themselves are a cheap, bendy plastic. Mine haven’t died on me yet, but I’m just counting the days. Sparkfun would do well to provide better quality parts for this kit.

Second: there are some unfortunate design flaws on the board. The board supports software serial, but that is basically worthless. MIDI applications are very timing sensitive (google for “MIDI lag”), and run at about 31K bps. Software serial cannot reliably support this, not if you’re planning on doing anything else on the board at the same time! An alternative would be to upgrade to an Arduino Mega, which has four UARTs, but so far as I can tell the shield cannot be moved to a different UART: you can disable MIDI via the PROG switch but you don’t have the option to shift it to some other RX/TX lines that could then be wired to some other UART on the Mega. You’re stuck sharing the UART with the USB chip or going software serial. Thus if you were planning on doing USB MIDI as well, you’re out of luck. Also I have no idea why the buttons are between the pots and the MIDI ports, making them hard to reach. Why in the world are the buttons not out in front?

If you need a MIDI shield with buttons and pots, this is your one and only option, besides going a more costly route such as that offered by e-licktronics. But it could have been a much better offering.


Related Tutorials

MIDI Shield Hookup Guide

October 8, 2015

How to assemble the SparkFun MIDI Shield, plus several example projects.

MIDI Tutorial

October 8, 2015

Understanding the Musical Instrument Digital Interface.