http://lamkins-guitar.com/music/article/midi-sysex-on-linux
David Lamkins picked up his first guitar a long time ago. As best he can recall the year was 1967: the year of the Summer of Love. Four decades later David has conjured up an amalgam of folk, rock and jazz solo guitar music for the occasional intimate Portland audience.
LCW on Bandcamp
location: Portland, OR USA

Facets: MIDI, computers, @musings info
Loading...

MIDI sysex on Linux

I sometimes need to transfer a MIDI sysex file to or from a MIDI-capable device. This is how one loads new firmware onto some devices, and how one saves and restores backups of patches and other settings.

As installed, Ubuntu Linux doesn't include a tool to support sending and receiving sysex files via a MIDI interface. You can try your luck with Google, only to find a bewildering array of possibilities. The Ubuntu Software Center, as of Ubuntu 11.10, offers no options.

This article describes how to install and use software that you can use to send and receive MIDI sysex files on your Ubuntu Linux system.

SimpleSysexxer is the most accessible, in that it has a graphical UI that's pretty much self-explanatory. You can find a pre-built binary of SimpleSysexxer, but there's no version available in a Debian-style package. That means that you need to either manually move the various components of the software into the appropriate system directories (something that I wasn't willing to research and document) or navigate to the folder containing the program and start it there. Or, if you're not using Unity, you can create a launcher. All in all, too much to keep track of for my tastes.

SimpleSysexxer is also available as source code, and is not difficult to build and install. Here's how:

  1. Download the source code from http://sourceforge.net/projects/sysexxer/.
  2. Install these packages that are necessary for the build (assuming you already have the GNU tool chain installed):
    • qt4-make
    • libqt4-dev
    • libasound2-dev
  3. Read the BUILDING file in the source directory; follow those instructions.

Once you've built and installed SimpleSysexxer, you'll be able to launch it from Unity. But you're not quite done...

MIDI applications on Linux communicate with devices via a common protocol. My Ubuntu installation uses ALSA for this protocol. ALSA depends upon another tool to connect MIDI devices to MIDI-capable programs.

I use QjackCtl to connect my MIDI interface to SimpleSysexxer. You can install QjackCtl on your system via the Ubuntu Software Center.

QjackCtl is simple to use. Plug in your MIDI interface, start up SimpleSysexxer, and start up QJackCtl. The order doesn't matter. Once everything's ready to go, click the Connect button in QJackCtl to open a window. Click the ALSA tabin that window to show all of the available MIDI ports: outputs on the left; inputs on the right.

What you need to do is to use the QJackCtl Connections window to connect outputs (on the left) to inputs (on the right) in such a way that data will flow from the appropriate source to the desired sink.

Let's say that I want to save a MIDI dump from an external MIDI-capable device. Here's what I do:

  1. Connect my MIDI interface's input plug to the MIDI output jack on the device.
  2. Click on my MIDI interface in the QjackCtl Connect window's list of output ports.
  3. Click on SimpleSysexxer in QjackCtl's list of input ports.
  4. Click the Connect button. Now you'll see a line connecting the two ports you just connected.
  5. Click the receive button (a downward-pointing arrow) in SimpleSysexxer.
  6. Tell your MIDI-capable device to begin sending data. If all is right, you'll see activity in the SimpleSysexxer window.
  7. When your device finishes sending data, click the cancel button and then the save button in SimpleSysexxer. Give the file a name ending in .syx, and you're done!

To restore a dump from computer to device, the steps are:

  1. Connect the MIDI interface's output plug to the MIDI input jack on the device.
  2. Click on SimpleSysexxer in the QjackCtl Connect window's list of output ports.
  3. Click on your MIDI interface in QjackCtl's list of input ports.
  4. Click the Connect button. Now you'll see a line connecting the two ports you just connected.
  5. Tell your MIDI-capable device to prepare to receive data.
  6. Click the send button (an upward-pointing arrow) in SimpleSysexxer. If all is right, you'll see activity in the SimpleSysexxer window and on your MIDI device.
  7. When SimpleSysexxer finishes sending data, you're done!

SimpleSysexxer paces sent data in order to avoid overrunning the input buffer on your MIDI device. The default pacing should be fine for most devices. If you experience problems sending sysex to a device, you can adjust the pacing to see whether that helps. Here's how:

  1. Using your plain-text editor of choice, open ~/.config/Simple\ Sysexxer/Simple\ Sysexxer.conf.
  2. Change the value of the SendingDelay parameter, save the file, and restart SimpleSysexxer.

If you'd rather send and receive sysex via the command line, you can use amidi. Use the Ubuntu Software Center to install the alsa-utils package, then read the man page for amidi.

February 08 2012 03:31:53 GMT