Difference between revisions of "MIDI"

Phi2x (Talk | contribs)
(General MIDI)
Phi2x (Talk | contribs)
(General MIDI)
 
(12 intermediate revisions by the same user not shown)
Line 1: Line 1:
[[Category:Music and sound]][[Category:Electronic Component]]
 
 
 
''Musical Instrument Digital Interface (MIDI)''
 
''Musical Instrument Digital Interface (MIDI)''
  
Line 7: Line 5:
 
== Software Protocol ==
 
== Software Protocol ==
  
Basically transmits commands like key on, key off, plus pitch/volume parameters.
+
Unlike audio protocols that transmit sound waves, MIDI carries event messages—instructions about what to play, how to play it, and when. These messages include:
  
Write more...
+
*Note On/Off: Triggers a note (e.g., "play middle C") and stops it.
 +
*Velocity: Indicates how hard a note is struck (volume or intensity, typically 0-127).
 +
*Pitch Bend: Adjusts a note’s pitch in real-time.
 +
*Control Change (CC): Modifies parameters like volume, pan, or modulation (e.g., CC#7 for volume).
 +
*Program Change: Switches instrument sounds (e.g., from piano to violin).
 +
 
 +
MIDI doesn’t contain audio data; it’s a set of commands that a synthesizer, sampler, or software interprets to generate sound. This makes MIDI files tiny compared to audio files—think kilobytes versus megabytes.
 +
 
 +
A MIDI message is typically 1-3 bytes long:
 +
 
 +
*Status Byte: Defines the message type (e.g., Note On) and channel (1-16).
 +
*Data Bytes: Provide specifics (e.g., note number, velocity).
 +
 
 +
The 16-channel system lets one controller  command multiple devices or voices independently. For example, Channel 1 could trigger a drum kit while Channel 2 plays a bassline.
  
 
== Hardware Protocol ==
 
== Hardware Protocol ==
Line 19: Line 30:
 
* MIDI is one-directional (MIDI OUT implements only TX, no RX, and MIDI IN implements only RX, no TX)
 
* MIDI is one-directional (MIDI OUT implements only TX, no RX, and MIDI IN implements only RX, no TX)
 
* There are no control signals like CTS/RTS/DSR/DTR used
 
* There are no control signals like CTS/RTS/DSR/DTR used
 +
 +
The standard in MIDI interface was the MPU-401, first introduced as a standalone hardware by Roland in 1984, and then integrated into PC soundcards.
 +
 +
The MPU-401 had 2 modes:
 +
* In UART mode, it acted as any other MIDI interface, passing MIDI data between the computer and external MIDI devices
 +
* In intelligent mode, the PC offloaded the MIDI playback task to the interface, freeing the PC to do other tasks while the music was playing
  
 
== Schematic ==
 
== Schematic ==
Line 34: Line 51:
 
* [[DIY MIDI Interface from CPCAI magazine]]
 
* [[DIY MIDI Interface from CPCAI magazine]]
 
* [[DIY MIDI Interface from CPCinfos magazine]] by Thierry MANGION, port &FAF0 [http://cpcrulez.fr/hardware_montage_8x-interface_MIDI-part_2__CNFO.htm]
 
* [[DIY MIDI Interface from CPCinfos magazine]] by Thierry MANGION, port &FAF0 [http://cpcrulez.fr/hardware_montage_8x-interface_MIDI-part_2__CNFO.htm]
 +
* [[Willy|Willy MIDI]] General MIDI Wavetable Synth
 +
* [[RSF3]] Multi-purpose expansion card including MIDI synth. It is EMR MIDI compatible [https://youtu.be/YOjV9AaIVKM Source]
  
 
== MIDI software for the CPC ==
 
== MIDI software for the CPC ==
Line 40: Line 59:
 
* [[EMR Miditrack Performer]] (ElectroMusic Research)
 
* [[EMR Miditrack Performer]] (ElectroMusic Research)
  
== Presentation in ACU magazine ==
+
== Presentation in magazines ==
  
 
<gallery>
 
<gallery>
Line 46: Line 65:
 
image:MIDI test ACU Feb1989 p2.jpg|[[Amstrad Computer User]] reviews MIDI on CPC (page 2/3)
 
image:MIDI test ACU Feb1989 p2.jpg|[[Amstrad Computer User]] reviews MIDI on CPC (page 2/3)
 
image:MIDI test ACU Feb1989 p3.jpg|[[Amstrad Computer User]] reviews MIDI on CPC (page 3/3)
 
image:MIDI test ACU Feb1989 p3.jpg|[[Amstrad Computer User]] reviews MIDI on CPC (page 3/3)
</gallery>
 
 
== Presentation in CPCAI magazine ==
 
 
<gallery>
 
 
image:MIDI CPCAI.jpg|[[CPC Amstrad International]] 2/1987 reviews MIDI on CPC (pages 16-22)
 
image:MIDI CPCAI.jpg|[[CPC Amstrad International]] 2/1987 reviews MIDI on CPC (pages 16-22)
</gallery>
 
 
== DIY MIDI Interface from CPCAI ==
 
 
<gallery>
 
 
image:MIDI Interface CPCAI.jpg|[[CPC Amstrad International]] 2/1987 published a DIY MIDI interface & software for CPC (pages 24-31)
 
image:MIDI Interface CPCAI.jpg|[[CPC Amstrad International]] 2/1987 published a DIY MIDI interface & software for CPC (pages 24-31)
 
</gallery>
 
</gallery>
Line 64: Line 73:
 
General MIDI (GM) is a standardized specification for electronic musical instruments and synthesizers, introduced in 1991 by the MIDI Manufacturers Association and the Japan MIDI Standards Committee.
 
General MIDI (GM) is a standardized specification for electronic musical instruments and synthesizers, introduced in 1991 by the MIDI Manufacturers Association and the Japan MIDI Standards Committee.
  
General MIDI aimed to ensure consistency across devices by defining a uniform set of 128 instrument sounds (called "patches"), such as piano, violin, and drums, organized in a specific program change order, along with standardized channel assignments (e.g., channel 10 for percussion).
+
General MIDI aimed to ensure consistency across devices by defining a uniform set of 128 instrument sounds (called "patches"), organized in a specific program change order:
 +
 
 +
{| class="wikitable"
 +
! Piano !! Chromatic Percussion !! Organ !! Guitar !! Bass !! Strings !! Ensemble !! Brass
 +
|-
 +
| 1. Acoustic Grand Piano || 9. Celesta || 17. Drawbar Organ || 25. Acoustic Guitar (nylon) || 33. Acoustic Bass || 41. Violin || 49. String Ensemble 1 || 57. Trumpet
 +
|-
 +
| 2. Bright Acoustic Piano || 10. Glockenspiel || 18. Percussive Organ || 26. Acoustic Guitar (steel) || 34. Electric Bass (finger) || 42. Viola || 50. String Ensemble 2 || 58. Trombone
 +
|-
 +
| 3. Electric Grand Piano || 11. Music Box || 19. Rock Organ || 27. Electric Guitar (jazz) || 35. Electric Bass (pick) || 43. Cello || 51. Synth Strings 1 || 59. Tuba
 +
|-
 +
| 4. Honky-tonk Piano || 12. Vibraphone || 20. Church Organ || 28. Electric Guitar (clean) || 36. Fretless Bass || 44. Contrabass || 52. Synth Strings 2 || 60. Muted Trumpet
 +
|-
 +
| 5. Electric Piano 1 || 13. Marimba || 21. Reed Organ || 29. Electric Guitar (muted) || 37. Slap Bass 1 || 45. Tremolo Strings || 53. Choir Aahs || 61. French Horn
 +
|-
 +
| 6. Electric Piano 2 || 14. Xylophone || 22. Accordion || 30. Overdriven Guitar || 38. Slap Bass 2 || 46. Pizzicato Strings || 54. Voice Oohs || 62. Brass Section
 +
|-
 +
| 7. Harpsichord || 15. Tubular Bells || 23. Harmonica || 31. Distortion Guitar || 39. Synth Bass 1 || 47. Orchestral Harp || 55. Synth Voice || 63. Synth Brass 1
 +
|-
 +
| 8. Clavi || 16. Dulcimer || 24. Tango Accordion || 32. Guitar Harmonics || 40. Synth Bass 2 || 48. Timpani || 56. Orchestra Hit || 64. Synth Brass 2
 +
|-
 +
! Reed !! Pipe !! Synth Lead !! Synth !! Synth Effects !! Ethnic !! Percussive !! Sound Effects
 +
|-
 +
| 65. Soprano Sax || 73. Piccolo || 81. Lead 1 (square) || 89. Pad 1 (new age) || 97. FX 1 (rain) || 105. Sitar || 113. Tinkle Bell || 121. Guitar Fret Noise
 +
|-
 +
| 66. Alto Sax || 74. Flute || 82. Lead 2 (sawtooth) || 90. Pad 2 (warm) || 98. FX 2 (soundtrack) || 106. Banjo || 114. Agogo || 122. Breath Noise
 +
|-
 +
| 67. Tenor Sax || 75. Recorder || 83. Lead 3 (calliope) || 91. Pad 3 (polysynth) || 99. FX 3 (crystal) || 107. Shamisen || 115. Steel Drums || 123. Seashore
 +
|-
 +
| 68. Baritone Sax || 76. Pan Flute || 84. Lead 4 (chiff) || 92. Pad 4 (choir) || 100. FX 4 (atmosphere) || 108. Koto || 116. Woodblock || 124. Bird Tweet
 +
|-
 +
| 69. Oboe || 77. Blown Bottle || 85. Lead 5 (charang) || 93. Pad 5 (bowed) || 101. FX 5 (brightness) || 109. Kalimba || 117. Taiko Drum || 125. Telephone Ring
 +
|-
 +
| 70. English Horn || 78. Shakuhachi || 86. Lead 6 (voice) || 94. Pad 6 (metallic) || 102. FX 6 (goblins) || 110. Bagpipe || 118. Melodic Tom || 126. Helicopter
 +
|-
 +
| 71. Bassoon || 79. Whistle || 87. Lead 7 (fifths) || 95. Pad 7 (halo) || 103. FX 7 (echoes) || 111. Fiddle || 119. Synth Drum || 127. Applause
 +
|-
 +
| 72. Clarinet || 80. Ocarina || 88. Lead 8 (bass+lead) || 96. Pad 8 (sweep) || 104. FX 8 (sci-fi) || 112. Shanai || 120. Reverse Cymbal || 128. Gunshot
 +
|}
 +
 
 +
Note: In the actual MIDI data bytes, the instrument numbers are 0-127 (zero-indexed). But in user interfaces and documentation, these are typically displayed as 1-128 (one-indexed) to be more intuitive for musicians.
  
This allowed musicians and composers to create music that would sound reasonably similar on any GM-compliant device, solving the patchwork compatibility issues of early MIDI systems.
+
General MIDI allowed musicians and composers to create music that would sound reasonably similar on any GM-compliant device, solving the patchwork compatibility issues of early MIDI systems.
  
 
General MIDI largely superseded the previous Roland MT-32 de-facto standard and quickly became foundational in music production, video game soundtracks, and consumer electronics.
 
General MIDI largely superseded the previous Roland MT-32 de-facto standard and quickly became foundational in music production, video game soundtracks, and consumer electronics.
Line 76: Line 125:
 
* http://en.wikipedia.org/wiki/Musical_Instrument_Digital_Interface - wikipedia on MIDI in general
 
* http://en.wikipedia.org/wiki/Musical_Instrument_Digital_Interface - wikipedia on MIDI in general
  
[[Category:Peripherals]] [[Category:Music_and_sound]]
+
[[Category:Peripherals]]
[[Category:DIY| ]] [[Category:Hardware| ]]
+
[[Category:Music and sound]]
 +
[[Category:DIY]] [[Category:Hardware]]

Latest revision as of 14:39, 2 April 2025

Musical Instrument Digital Interface (MIDI)

The original MIDI (Musical Instrument Digital Interface) protocol was developed in 1983 by Dave Smith and Ikutaro Kakehashi to enable communication between electronic instruments.

Software Protocol

Unlike audio protocols that transmit sound waves, MIDI carries event messages—instructions about what to play, how to play it, and when. These messages include:

  • Note On/Off: Triggers a note (e.g., "play middle C") and stops it.
  • Velocity: Indicates how hard a note is struck (volume or intensity, typically 0-127).
  • Pitch Bend: Adjusts a note’s pitch in real-time.
  • Control Change (CC): Modifies parameters like volume, pan, or modulation (e.g., CC#7 for volume).
  • Program Change: Switches instrument sounds (e.g., from piano to violin).

MIDI doesn’t contain audio data; it’s a set of commands that a synthesizer, sampler, or software interprets to generate sound. This makes MIDI files tiny compared to audio files—think kilobytes versus megabytes.

A MIDI message is typically 1-3 bytes long:

  • Status Byte: Defines the message type (e.g., Note On) and channel (1-16).
  • Data Bytes: Provide specifics (e.g., note number, velocity).

The 16-channel system lets one controller command multiple devices or voices independently. For example, Channel 1 could trigger a drum kit while Channel 2 plays a bassline.

Hardware Protocol

The data is transferred at 31250 bits per second, using 8-N-1 format (one start bit, eight data bits, no parity bit, and one stop bit). So far, the MIDI protocol is much similar to RS232, and many MIDI interfaces do actually use standard "RS232" UART chips. Differences to RS232 are:

  • The signals are transmitted as TTL levels (0V and 5V) (unlike +/-12V on RS232) with 5V reference voltage (unlike 0V on RS232)
  • The receiver should pass the TTL signal through an Opto-Isolator
  • The 31250 Hz baudrate isn't a standard RS232 rate
  • MIDI is one-directional (MIDI OUT implements only TX, no RX, and MIDI IN implements only RX, no TX)
  • There are no control signals like CTS/RTS/DSR/DTR used

The standard in MIDI interface was the MPU-401, first introduced as a standalone hardware by Roland in 1984, and then integrated into PC soundcards.

The MPU-401 had 2 modes:

  • In UART mode, it acted as any other MIDI interface, passing MIDI data between the computer and external MIDI devices
  • In intelligent mode, the PC offloaded the MIDI playback task to the interface, freeing the PC to do other tasks while the music was playing

Schematic

MidiElectricalSpecificationDiagram.gif

MIDI Interfaces for the CPC

MIDI software for the CPC

Presentation in magazines

General MIDI

General MIDI (GM) is a standardized specification for electronic musical instruments and synthesizers, introduced in 1991 by the MIDI Manufacturers Association and the Japan MIDI Standards Committee.

General MIDI aimed to ensure consistency across devices by defining a uniform set of 128 instrument sounds (called "patches"), organized in a specific program change order:

Piano Chromatic Percussion Organ Guitar Bass Strings Ensemble Brass
1. Acoustic Grand Piano 9. Celesta 17. Drawbar Organ 25. Acoustic Guitar (nylon) 33. Acoustic Bass 41. Violin 49. String Ensemble 1 57. Trumpet
2. Bright Acoustic Piano 10. Glockenspiel 18. Percussive Organ 26. Acoustic Guitar (steel) 34. Electric Bass (finger) 42. Viola 50. String Ensemble 2 58. Trombone
3. Electric Grand Piano 11. Music Box 19. Rock Organ 27. Electric Guitar (jazz) 35. Electric Bass (pick) 43. Cello 51. Synth Strings 1 59. Tuba
4. Honky-tonk Piano 12. Vibraphone 20. Church Organ 28. Electric Guitar (clean) 36. Fretless Bass 44. Contrabass 52. Synth Strings 2 60. Muted Trumpet
5. Electric Piano 1 13. Marimba 21. Reed Organ 29. Electric Guitar (muted) 37. Slap Bass 1 45. Tremolo Strings 53. Choir Aahs 61. French Horn
6. Electric Piano 2 14. Xylophone 22. Accordion 30. Overdriven Guitar 38. Slap Bass 2 46. Pizzicato Strings 54. Voice Oohs 62. Brass Section
7. Harpsichord 15. Tubular Bells 23. Harmonica 31. Distortion Guitar 39. Synth Bass 1 47. Orchestral Harp 55. Synth Voice 63. Synth Brass 1
8. Clavi 16. Dulcimer 24. Tango Accordion 32. Guitar Harmonics 40. Synth Bass 2 48. Timpani 56. Orchestra Hit 64. Synth Brass 2
Reed Pipe Synth Lead Synth Synth Effects Ethnic Percussive Sound Effects
65. Soprano Sax 73. Piccolo 81. Lead 1 (square) 89. Pad 1 (new age) 97. FX 1 (rain) 105. Sitar 113. Tinkle Bell 121. Guitar Fret Noise
66. Alto Sax 74. Flute 82. Lead 2 (sawtooth) 90. Pad 2 (warm) 98. FX 2 (soundtrack) 106. Banjo 114. Agogo 122. Breath Noise
67. Tenor Sax 75. Recorder 83. Lead 3 (calliope) 91. Pad 3 (polysynth) 99. FX 3 (crystal) 107. Shamisen 115. Steel Drums 123. Seashore
68. Baritone Sax 76. Pan Flute 84. Lead 4 (chiff) 92. Pad 4 (choir) 100. FX 4 (atmosphere) 108. Koto 116. Woodblock 124. Bird Tweet
69. Oboe 77. Blown Bottle 85. Lead 5 (charang) 93. Pad 5 (bowed) 101. FX 5 (brightness) 109. Kalimba 117. Taiko Drum 125. Telephone Ring
70. English Horn 78. Shakuhachi 86. Lead 6 (voice) 94. Pad 6 (metallic) 102. FX 6 (goblins) 110. Bagpipe 118. Melodic Tom 126. Helicopter
71. Bassoon 79. Whistle 87. Lead 7 (fifths) 95. Pad 7 (halo) 103. FX 7 (echoes) 111. Fiddle 119. Synth Drum 127. Applause
72. Clarinet 80. Ocarina 88. Lead 8 (bass+lead) 96. Pad 8 (sweep) 104. FX 8 (sci-fi) 112. Shanai 120. Reverse Cymbal 128. Gunshot

Note: In the actual MIDI data bytes, the instrument numbers are 0-127 (zero-indexed). But in user interfaces and documentation, these are typically displayed as 1-128 (one-indexed) to be more intuitive for musicians.

General MIDI allowed musicians and composers to create music that would sound reasonably similar on any GM-compliant device, solving the patchwork compatibility issues of early MIDI systems.

General MIDI largely superseded the previous Roland MT-32 de-facto standard and quickly became foundational in music production, video game soundtracks, and consumer electronics.

Weblinks