As a technology MIDI has been amazingly successful, it was developed in 1982 by a group of synthesiser manufacturers and the first devices with MIDI capabilities went on sale in 1983. Since then, as a standard it has remained virtually unchanged.
MIDI is one of those things you know you are probably going to encounter when recording electronic music. Even if you only use VSTi's or Reason, understanding MIDI can help explain a lot.
So what is MIDI?
The name stands for "Musical Instrument Digital Interface" and it is used to connect together two or more electronic musical instruments. Or as is more often the case, connect one or more instruments to a computer in order to record the musical performance.
The key thing to remember about MIDI is that:
MIDI transmits information about the notes being played and not audio data about the sound being played.
So basically, when you press middle C on your keyboard, the keyboard sends out a MIDI message that says "Middle C on channel 1 is on, they played it with a velocity of 98 (or however hard you hit it)".
So then anything that receives that message will do just that, play a middle C on whatever instrument is assigned to channel 1 with a velocity of 98.
Remember, no sound or audio data is being sent down that MIDI cable.
It is also important to remember that MIDI uses a system of channels to organise the data being sent. There are 16 channels, and each message carries information about which channel it is on. Each message will therefore only affect the channel that it is assigned to.
Types of MIDI Message
The most important MIDI message is of course the MIDI 'note on' message. But each 'note on' message needs a corresponding 'note off' message. Otherwise the note will play forever.
This can be a source for problems if the MIDI connection is lost at some point while notes are being played or recorded. If someome trips over the cable and pulls the plug, you can end up with hung notes.
Most MIDI equipment and software has the ability to send a very handy MIDI message called the 'MIDI panic'. Which tells each device connected to cease playing all notes and stop transmitting data.
In addition to the actual note information that is carried by the 'note on' and 'note off' messages, the most regularly used MIDI message is the controller message.
The controller messages are identified by a number, and there are 128 of them. Some of them are pre-assigned, which means that most hardware and software will respond to them in a standard way.
For example MIDI controller #7 is pre-assigned to volume, and #10 is pre-assigned to pan. This doesn't mean you can't set up your equipment to respond to these messages in another way, but there are plenty of unassigned controller numbers that you can use instead.
System Exclusive Messages
SysEx messages are used by synthesisers and samplers to send and receive detailed information about their settings. Each manufacturer implements SysEx in a slightly different way, and the messages are not assigned to a particular MIDI channel like other messages, but rather by manufacturer and model.
So you can have several different Roland synths attached to the same MIDI connection, but each synth will only repond to SysEx messages that identify themselves as being for that particular synth.
SysEx messages can be sent as a continuous stream of data, so that parameters can be altered in real time as a sequence is recorded or played back, or they can be sent as a 'SysEx Dump' which can be used to store information about all the settings made on a synth for a particular song or project.