# Patchmap Files

MultitrackStudio uses patchmap (*.pmp) files to define the names of patches and drum instruments of hardware synths, so they can be displayed instead of plain bank:program numbers where appropriate.

The Options menu of an External MIDI Instrument window has a Patchmap option, which has an Import option to import your patchmap. Alternatively, you can drop the file on an External MIDI Instrument window. If you've edited the file, you can simply import it again.

Tip: You can search the web for a .ins (instrument definition) file for your synth. It will be converted to .pmp when it's imported.

Under the hoodUser patchmap files are stored in the user's "Library/Application Support/MultitrackStudio/PatchMaps" folder.

Patchmap files can be edited using TextEdit. The following examples demonstrate how to create patchmap files for your own hardware synthesizer. The italic text represents comments and should not be included in actual patchmap files.

### Example 1: Banks and Patch Names

This example shows a plain simple patchmap having just two banks.

[patchmap] |  | mandatory identifier
[bank 0] |  | This section holds the first bank. Note it's 0, not 1. Also note the space.
bank=1280 |  | The MIDI bank it applies to. This number equals 128 * MSB + LSB.
|  | MSB and LSB correspond to MIDI controllers #0 and #32 respectively.
|  | In this example MSB=10 and LSB=0.
0=Piano |  | MIDI program 0 is a piano
1=Bass |  | MIDI program 1 is a Bass
|  | These values can go up to and including 127
[bank 1] |  | This section holds the second bank. Banks must be numbered sequentially
bank=1281 |  | MSB=10 and LSB=1
32=Guitar |  | MIDI program 32 is a guitar
33=Violin |  | MIDI program 33 is a violin

### Example 2: Drum Instrument Names

Assume our synth has one drum patch. Let's add both the patch and the drum instrument names to the patchmap:

[patchmap] |  |
[bank 0] |
bank=1280 |
0=Piano |
[bank 1] |
bank=1281 |
32=Guitar |
33=Violin |
64=Acoustic Drum Kit |  | The drum patch is on program number 64
[drum 0] |
bank=0 |  | The drums are in bank 0. This equals 128 * MSB + LSB,
|  | see explanation in [bank 0] section of example 1.
patch=8 |  | The drums are on MIDI program 8
36=Bass Drum |  | Note 36 is a bass drum
40=Snare |  | Note 40 is a snare

Additional drum kit sections must be numbered sequentially ([drum 1], [drum2] etc.)

### Example 3: Percussion Channel

Assume it's a GM synth, which has one bank only, and drums on channel 10:

[patchmap] |  |
[bank 0] |
bank=-1 |  | -1 means "all banks", we do this because GM doesn't support banks
|  | If you omit the "bank=" statement then it will default to 0 because it's
|  | the [bank 0] section. [bank 1] defaults to 1 etc.
channel=1,2,3,4,5,6,7,8,9,11,12,13,14,15,16 |  | [bank 0] is not valid for channel 10
0=Piano |
1=Bright Piano |
12=Marimba |
25=Acoustic Guitar |
26=Electric Guitar |
[bank 1] |
bank=-1 |  | -1 means "all banks", we do this because GM doesn't support banks
channel=10 |  | [bank 1] is valid for channel 10 only
0=Drum Kit |
[drum 0] |
channel=10 |  | These instrument names are valid for channel 10
36=Bass Drum |
40=Snare |

### Example 4: Patch Categories

Let's add some categories. They will appear in the External MIDI Instrument's patch selector.

[patchmap] |  |
[category] |  | This is the section which defines the categories
#0=Piano |  | The first section must be #0. In this case it holds the pianos
#1=Guitar |  | The second section holds the guitars
|  | Categories must be numbered sequentially
[bank 0] |
bank=-1 |
0=Piano#0 |  | Add #0 to the name, so MultitrackStudio knows it's in category #0
1=Bright Piano#0 |
12=Marimba |  | No category specified here, it will end up in the "Other" category
25=Acoustic Guitar#1 |  | Add #1 to the name, so MultitrackStudio knows it's in category #1
26=Electric Guitar#1 |

### Example 5: Drum Instrument Categories

Drum Instrument Categories can be defined locally within a drum section:

[patchmap] |  |
[bank 0] |
bank=0 |
0=Piano |
1=Bright Piano |
[drum 0] |
#0=Bass |  | The first section must be #0. In this case it holds the bass drums
#1=Snare |  | The second section holds the snare drums
35=Acoustic Bass#0 |  | Add #0 to the name, so MultitrackStudio knows it's in category #0
36=Bass Drum 1#0 |
38=Acoustic Snare#1 |  | Add #1 to the name, so MultitrackStudio knows it's in category #1
39=Hand Clap |  | No category specified here, it will end up in the "Other" category
40=Electric Snare#1 |

### Example 6: Controller Names

Let's override some default controller names with custom ones:

[patchmap] |  |
[bank 0] |
bank=0 |
0=Piano |
1=Bright Piano |
[controllers] |
2=Joystick -Y |  | New name for controller 2
83=Dynamic Modulation |

NRPNs can be named too:

[patchmap] |  |
[bank 0] |
bank=0 |
0=Piano |
1=Bright Piano |
[nrpn] |
160=Cutoff |  | New name for nrpn 160 (=128 * MSB + LSB)
161=Resonance |

### Example 7: GM compatibility

GM2, GS and XG use bank messages while GM doesn't. You can specify a compatibility mode to ensure the patchmap works regardless of the bank being specified or not. It also affects the handling of GM percussion channel.

[patchmap] |  |
compatibility=XG |  | Can be GM2, GS or XG
[bank 0] |
bank=0 |
0=Piano |
1=Bright Piano |

### Example 8: Supported Controls

The controllers, NRPNs etc. which are supported can be listed. They appear in the controller editor's VIEW menu. Channel controllers appear as rotary knobs in an External MIDI Instrument window's Controls section.

[controllers] |  |
supported=pitchbend,7,10,nrpn100,rpn4130,aftertouch,polyaftertouch,sysex |  | RPN/NRPN numbers are explained in example 6
2=Joystick -Y |  | Controller name as per example 6

### Example 9: Channel Names

Channel names appear in the channel selector dropdown menu:

[channels] |  |
10=Percussion |

### Example 10: Profiles

Some (older) devices may conform to a MIDI-CI profile, even if it can't do the MIDI-CI negotiation. Some profiles can be force enabled. The supported controls (see example 8) and drum instrument names (example 2) are used to compile suitable profile details.

The Piano profile can be enabled for a program like this:

[patchmap] |  |
[bank 0] |  |
bank=13824 |  |
0=Piano |  | Name of program 0
profiles0=piano |  | Program 0 conforms to the Piano profile
6=Harpsichord |  |

The Default Drum Note Map profile can be enabled for a program like this:

[patchmap] |  |
[bank 0] |  |
bank=-1 |  |
profiles=defaultdrumnotemap |  | Alternative way: this means all 128 programs are compatible with the Default Drum Note Map profile
0=Drum Kit |  |
1=Drum Kit 2 |  |
profiles1=defaultdrumnotemap |  | Program 1 conforms to the Default Drum Note Map profile

### Example 11: Patch Switch Time

Some synths need quite some time to load a patch. Let's make sure MultitrackStudio sends the patch change messages in time. Note that it's usually not necessary to add this.

[patchmap] |  |
patchswitchtime=750 |  | Schedule patch changes 750 milliseconds earlier
[bank 0] |
bank=0 |
0=Piano |
1=Bright Piano |

### Example 12: Initialization Sysex

A sysex message can be sent before recording or playback starts. This can be used to switch a synth to multi-mode for example.

[patchmap] |  |
initsysex=f0123456f7 |  | Hex numbers representing sysex MIDI message
[bank 0] |
bank=0 |
0=Piano |
1=Bright Piano |

If a sysex needs to be send to each MIDI channel used you can replace a hex digit with "<channel>":

[patchmap] |  |
initsysex=f0123<channel>56f7 |  | Hex numbers representing sysex MIDI message
|  | "<channel>" will be replaced with the actual MIDI channel.
[bank 0] |
bank=0 |
0=Piano |
1=Bright Piano |

### Example 13: Don't send Program Change

Some synths lose your custom settings if a Program Change is received. You can prevent MultitrackStudio from sending Program Change messages to certain channels. Bank messages won't be sent either.

[patchmap] |  |
no_programchange=15,16 |  | Don't send Program Change to channel 15 and 16