| MIDI
in a Nutshell
by Jon F. Eiche; excerpted from What's MIDI? (Hal
Leonard Publications)
|
Exactly
what is MIDI? If you ask just about anyone who owns an electronic
musical instrument that was made since 1984 or so, the answer you'll
get is likely to be, "It's those plugs on the back." And that answer
is right, as far as it goes.
But
the important thing about MIDI is not the physical connectors or
the electronics behind it; the important thing is what it allows
you to do. For example, with MIDI you can:
* play
two instruments from the keyboard of one; or
* record
your music for playback later; or
* synchronize
the performance of such a recording with that of an automatic drummer.
Still,
before you can appreciate all that MIDI does, you really should
spend a little time becoming familiar with what it is.
What
MIDI Is
The
name "MIDI" stands for "Musical Instrument Digital Interface" --
quite a mouthful. But by breaking this name down into its component
parts, you'll find that it's really pretty easy to understand:
* "Musical
Instrument." You already know what that is. MIDI was designed for
use in playing music. Over the years it has found other uses, and
has been incorporated into pieces of equipment that are not strictly
instruments; but "musical instrument" still describes where it is
used most often. (Judging by the first paragraph of this chapter,
you might think that a more accurate name might be "Electronic
Musical Instrument" But as you'll see later in this book, MIDI can
work for all instruments, and voices, too.)
* "Digital."
This isn't so difficult. It simply means that computers are involved.
Since computers work with numbers, and another word for "numbers"
is "digits," the adjective "digital" means that somewhere in that
MIDI stuff is a computer of some kind. Now, you don't have to know
a thing about computers to enjoy the wonders of MIDI. It's like
automobiles: You don't have to be a mechanic to drive a car. So
don't let this word scare you.
* "Interface."
Uh-oh -- this one looks imposing. But the meaning is simple: communication.
That's all.
Now
that you understand the parts, let's put them back together: Musical
instruments communicating with the help of computers. I told you
it was easy.
By
the way, "MIDI" rhymes more or less with "city." Please don't say
"my-dye" unless you want to be branded a "MIDIot."
Time
for a history lesson: MIDI is a specification that was developed
in the early 1980s to allow musical instruments of different brands
to "talk" to one another. It was developed jointly by the major
manufacturers of electronic musical instruments, and as such, represents
a cooperative effort of impressive proportions. Moreover, that cooperation
continues, for MIDI is not a formal standard that must be adhered
to; rather, it is a specification that is followed voluntarily by
the individual manufacturers.
The
MIDI specification consists of two parts:
* The
hardware by which MIDI devices are connected.
* The
"language" that is "spoken" when the devices "talk" to one another.
Let's
look at these parts one at a time.
MIDI
Hardware
Remember
the "plugs" on the back of the instrument? In MIDI jargon these
are known as ports. There are three possible kinds: In, Out,
and Thru.
* IN
receives MIDI information from other equipment.
* OUT
sends MIDI information to other equipment.
* THRU
provides a duplicate of the information received by IN, to be passed
along to other equipment.
Not
all MIDI equipment has all three ports, and some devices may have
more than one of a given type. The MIDI ports of different pieces
of equipment are connected by special MIDI cables, which have five
pins in each end and plug into the ports themselves.
Next,
we’ll explain a little about what travels through a MIDI cable from
one device to another.
The
MIDI Language
A
MIDI cable is something like a telephone line, in that it allows
communication between two points. That communication takes the form
of MIDI messages.
MIDI
Rule #1:
What
travels through the MIDI cable is NOT sound; it's information (data).
A
typical MIDI instrument will have some kind of audio output, whether
it consists of built-in speakers or jacks for connection to external
amplification; this audio output is necessary for you to hear the
sound that the instrument produces. The MIDI connections are totally
separate and different from the audio output.
The
information in a MIDI message consists of numbers (remember: digital
interface). In computer jargon, these numbers are known as bytes,
but you can think of them as words.
A
typical MIDI message consists of one or more words, the meaning
of which is specified in the MIDI language.
It
should be mentioned here that not all MIDI devices understand all
MIDI messages. While this might seem like a bad thing, it's really
not. It's just that MIDI devices tend to be "specialists," and not
all areas of the language apply to all devices. For example, there
are some messages that pertain to the synchronization of MIDI recording
and playback equipment that do not apply to instruments without
those functions. It's like a plumber speaking to a chemist; they
both speak the same language, but there are some words that are
limited to their respective specialties.
The
difference is that MIDI devices are "dumb" and totally lacking in
curiosity. So when a message comes along that a MIDI device doesn't
understand, rather than asking, "What do you mean?" the device will
just ignore it and keep going about its own business. This keeps
things simple and prevents all kinds of traffic jams in the MIDI
cable.
MIDI
Rule #2:
MIDI
can't make an instrument do something it wasn't designed to do.
So
many "problems" with MIDI stem from ignorance of this simple fact.
For example, don't expect that connecting a keyboard to a drum machine
and holding the keys down will make the drum sounds sustain.
A
typical MIDI message consists of two or three words (bytes):
* First
is a status byte, which tells what kind of message it is.
A typical example is the Note On message, which is transmitted when
a note is played. The status byte says, "This is a Note On message."
* Next
come one or two data bytes, which provide further information
to complete the message. The Note On message has two data bytes:
one to tell which note has been played and one to tell how hard
it was struck.
The
three words of a typical Note On message could be translated as:
"This is a Note On message." "It's for G above middle C." "Play
it medium loud." As you can see, MIDI is a lot more succinct than
English, requiring only three words to say what took three sentences
to describe here. And it is also fast. A complete MIDI message such
as the one just described is transmitted in less than a thousandth
of a second. This means not only that receiving instruments will
get messages quickly, but also that many messages can be transmitted
in a short time. This is especially useful because MIDI can transmit
only one message at a time. For example, if you play a three-note
chord on a MIDI keyboard, the three Note On messages are actually
sent one after another, in rapid succession.
Two
Categories of Messages
MIDI
messages are divided into two broad categories: channel messages
and system messages.
* Channel
messages are transmitted and received on a specific MIDI channel,
which can be compared to a TV channel: An instrument has to be "tuned"
to the correct one or it won't receive what is being transmitted.
There are 16 channels available, and each one can carry different
messages than the others, over the same MIDI cable. This makes it
possible, for example, to play different musical parts at the same
time.
There
are generally two channel settings that apply to a MIDI instrument:
the transmit channel is the channel over which an instrument
transmits MIDI messages, and the receive channel is the channel
over which an instrument will respond to MIDI messages that it receives.
* System
messages are not restricted to a specific MIDI channel, but rather
are transmitted to all equipment that is connected in a MIDI system.
This is an efficient way to transmit pertinent information to many
instruments at once.
|