Unify Manual

Your complete reference to PlugInGuru's creative playground!

User Tools

Site Tools


Changing patches with MIDI

As of v1.1.10, Unify can respond to standard MIDI bank-select and program-change messages. Right now, this is not part of the Unify graphical user interface (GUI), but is instead handled using a very simple system of text files.

MIDI message values

Most MIDI messages carry a 7-bit value, which is a binary number in the range 0 to 127. When such numbers are interpreted as patch or patch-bank numbers, some MIDI devices may display them as 0-127, others as 1-128 (i.e., adding one to the actual binary value), and a few use more exotic numbering systems. Consult the user's manual for your specific MIDI devices to understand which numbering conventions they use.

MIDI “continuous controller” messages (typically used for knob movements) use such 7-bit values. When more than 7 bits are required, it has become conventional to use two consecutive CC messages together, the first providing a “coarse” value and the second a “fine” adjustment. The two values are sometimes referred to as MSB (most significant bits) and LSB (least significant bits), reflecting how the receiving MIDI device combines the two 7-bit numbers (0-127) into a single 14-bit number (0-16,383).

The current MIDI Standard specifies that CC#0 through CC#31 carry coarse/MSB values, and CC#32 through CC#63 (if used) carry the corresponding fine/LSB values. (If the “coarse” CC number is N, the corresponding “fine” CC number is N+32.)

How MIDI messages select patches

The MIDI standard uses as many as three consecutive messages for program (aka patch) selection. The full three-message sequence is as follows:

  • A CC#0 message provides the 7 most-significant bits (MSB) of the bank number
  • A CC#32 message provides the 7 least-significant bits (LSB) of the bank number
  • A PC (“Program Change”) message selects one of up to 128 patches (“programs”) within the selected bank.

MIDI “devices” (which includes software programs like Unify) are expected to remember the current (most recently received) bank-MSB and bank-LSB numbers, both of which default to 0. This allows shorter message sequences:

  • A CC#0 message followed by a PC message selects one of 128 banks, and within it, one of 128 patches.
  • A PC message alone selects one of 128 patches in the “current” bank.

How Unify interprets MIDI bank and program numbers

When Unify receives a MIDI patch-selection message sequence, it responds as follows:

  1. It adds one to the bank MSB and LSB, and also the program number, yielding three numbers in the range 1-128:
    • a number MMM = 1 + bank MSB
    • a number LLL = 1 + bank LSB
    • a number PPP = 1 + program number
  2. It looks in the main Unify data folder, for a sub-folder called MIDI Bank Files.
    • If the folder does not exist, it ignores (see below) the entire MIDI message sequence
  3. It looks in the MIDI Bank Files folder, for a file whose name matches MMM_LLL.txt
    • For example, if the bank MSB and LSB are both zero, it will look for a file called 1_1.txt
    • If no matching file is found, it ignores (see below) the entire MIDI message sequence
  4. Within the file, it looks for a line which begins with the number PPP.
    • If a matching line is found, it selects the patch identified by the remainder of the line (see below)
    • If not, the entire MIDI message sequence is ignored (see below)

There is a checkbox on the Settings view to display error messages instead of silently ignoring problem MIDI sequences.

Finding the MMM/LLL numbers to use for your MIDI controller

Different MIDI controller produce different patch-select MIDI message sequences. The owner's manual for the product usually gives the details, but the best way to figure out what messages your particular controller produces is to use Unify's built-in MIDI Monitor plug-in (swap it in to any Instrument slot).

Remember that the bank MSB and LSB values default to zero (corresponding to MMM and LLL values of ONE), if your controller sends a two- or one-message sequence and does not provide them.

Structure of MIDI Bank files

MIDI Bank files are plain-text files. Files created by e.g. a word processor can NOT be used.

  • On Windows, use the built-in Notepad app (or a compatible app such as Notepad++) to create or edit these files. DO NOT use the built-in WordPad app, Microsoft Word, etc.
  • On Macintosh, use the built-in Textedit app, but make sure to set it to plain-text mode by selecting Make Plain Text from the Format menu.

The format of MIDI bank files is best illustrated by an example:

# This is a comment. Any text, on any line, after a # sign is ignored.
# For comments at the end of a non-blank line, TWO spaces are required before the # character.
# Blank lines (like the one above) are also ignored.
# Non-comment lines in bank files have the form:
#   patch-number   patch-name
# Where patch-number is a number between 1 and 128, and patch-name is
# the exact name of a Unify patch. The number must be followed by at
# least one space.
# In rare cases where you might have two or more patches with the same
# name in different libraries, you can put the library name before the
# patch name like this:
#   patch-number   library-name / patch-name
1   ARP - Andromeda
2   1 SHOT - TinkerBell
3   UniChill / KEYS - Air Hammer

The main content consist of a series of lines which start with a “program number” in the range 1-128 (called PPP above) followed by a “patch identifier”, which can be any of the following:

  • The exact name of a patch (as displayed in Unify's patch browser)
  • The exact file name of the patch file (.unify or .upf file)
  • Either of the above, preceded by the exact name of the Unify library containing the desired patch

Note that you can use blank spaces freely, e.g.

  • before and after program numbers
  • at the end of the lines (after the patch identifier)
  • before and after the slash (“/”) character separating library name (if used) from patch/file name

Downloadable collection of bank files

Use the following link to download a collection of MIDI Bank files covering all 505 patches in the Unify Standard Library. You can copy and paste individual lines from these files (changing the program numbers as desired) to create your own MIDI Bank files. Make sure to name your own files according to the MMM_LLL.txt convention defined above.


Enabling bank/patch select and tracking down errors

In Unify's Settings view, near the bottom there is a row of checkboxes like this:

Make sure “Bank/Program Change” is checked (as it is by default), or Unify will ignore incoming MIDI bank/patch select messages and pass them on to all hosted plug-ins.

If you're having any trouble setting up your MIDI Bank files, check the “Bank/Prog error messages” box. Each time a MIDI bank/patch select message sequence is received, if Unify can't identify the target patch (according to the rules given above), it will pop up an error message explaining why not.

midi-patch-select.txt · Last modified: 2023/05/08 18:59 by