Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
midi [2023-06-14 00:17] – added note chart asdf | midi [2024-02-17 21:25] (current) – asdf | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== MIDI ====== | ====== MIDI ====== | ||
+ | ===== Physical spec ===== | ||
+ | {{ :: | ||
+ | |||
+ | MIDI signals are typically carried through DIN5 connectors (see image for socket pinout). Pin 4 is the current source/Vcc, pin 5 is the current sink/TX, and pin 2 is ground. | ||
+ | |||
+ | More compact devices may make use of a TRS connector instead. These come in a number of flavors: | ||
+ | |||
+ | ^ Type ^ Tip ^ Ring ^ | ||
+ | | Type A | Sink | Source | | ||
+ | | Type B | Source | Sink | | ||
+ | | Ring active | NC | Sink | | ||
+ | | Tip active | Sink | NC | | ||
+ | |||
===== Messages ===== | ===== Messages ===== | ||
+ | MIDI messages (other than SysEx) range from 1 to 3 bytes in length, transmitted as 8N1 serial [[:UART]] at 31250 bps. | ||
+ | |||
+ | Messages in the first group (0x8n--0xEn) are channel messages; the lower nybble indicates the channel number (where 0 = channel 1, etc.). Though their parameters are full bytes, their values only range from 0x00--0x7F. | ||
+ | |||
+ | ^ Command ^ Param 1 ^ Param 2 ^ Meaning ^ | ||
+ | | 0x8n | note | velocity | Note off | | ||
+ | | 0x9n | note | velocity | Note on | | ||
+ | | 0xAn | note | velocity | Polyphonic aftertouch | | ||
+ | | 0xBn | controller | value | Continuous controller | | ||
+ | | 0xCn | program | n/a | Program change | | ||
+ | | 0xDn | value | n/a | Channel aftertouch | | ||
+ | | 0xEn | LSB | MSB | Pitch bend | | ||
+ | ||| | ||
+ | | 0xF0 | ID | variable-size payload | SysEx start | | ||
+ | | 0xF1 | data | n/a | MIDI time code message | | ||
+ | | 0xF2 | LSB | MSB | Song position pointer | | ||
+ | | 0xF3 | song number | n/a | Song select | | ||
+ | | 0xF4 | n/a | n/a | undefined | | ||
+ | | 0xF5 | n/a | n/a | undefined | | ||
+ | | 0xF6 | n/a | n/a | Tune request | | ||
+ | | 0xF7 | n/a | n/a | SysEx end | | ||
+ | | 0xF8 | n/a | n/a | Clock (24 PPQ) | | ||
+ | | 0xF9 | n/a | n/a | undefined | | ||
+ | | 0xFA | n/a | n/a | Start | | ||
+ | | 0xFB | ? | n/a | Continue | | ||
+ | | 0xFC | n/a | n/a | Stop | | ||
+ | | 0xFD | n/a | n/a | undefined | | ||
+ | | 0xFE | n/a | n/a | Active sensing (keepalive) | | ||
+ | | 0xFF | n/a | n/a | System reset | | ||
+ | |||
===== Notes ===== | ===== Notes ===== | ||
Line 93: | Line 136: | ||
| 108 | | 108 | ||
+ | ===== Resources ===== | ||
+ | * https:// | ||
+ | * https:// | ||
+ | * https:// | ||
+ | * https:// | ||
+ | * https:// | ||
+ | * https:// | ||
{{tag> | {{tag> |