Problems setting up midi with Allen and Heath SQ5


I'm trying to configure Open Stage Control to adjust aux mixes on an Allen and Heath SQ5, and I'm really struggling to understand how to do it. I'm using version 1.22, running on PopOS (an Ubuntu derivative).

In the launcher, if I put "list" in the midi field, I get:

(INFO, MIDI) Inputs
-1: Void (bypass)
0: Midi Through:Midi Through Port-0 14:0
1: SQ:SQ SQ - MIDI In 24:0
(INFO, MIDI) Outputs
-1: Void (bypass)
0: Midi Through:Midi Through Port-0 14:0
1: SQ:SQ SQ - MIDI In 24:0

But I don't understand what to put in the "send" field. I've tried midi:SQ, midi:SQ SQ, midi:SQ:SQ SQ, etc. Every permutation I have tried gets the same error -

(ERROR, MIDI) unknown device "SQ"

What am I missing?

Thanks in advance for your help.

First you need to configure open stage control's midi backend, the recommended way on linux is to use virtual ports. Writing this in the server's midi option


will create a virtual midi device with 1 input port and 1 output port which you can connect using a patchbay such as qjackctl.

If you don't want to use a patchbay and let open stage control handle the connection, you would write:


As in : « create a virtual midi device named "my_device" connected to input number 1 and output number 1 » (port numbers come from the list you posted).

Alternatively (and preferably), you could write:


As in : « create a virtual midi device named "my_device" connected to the first input whose name contains "SQ" and to the first output whose name matches "SQ" »

"my_device" is just a arbitrary name of your choice, that can then be used as a target for your widgets, either per widget by setting the widget's target property to midi:my_device, or for every widget by setting the server's send option to midi:my_device. I don't recommend the latter because every widget that's not properly configured to send midi message will generate errors.

The documentation describes the available configuration options for the server and how to configure a widget for sending midi.

Thank you for the quick response. I've implemented that change and read through the documentation - the last piece of the puzzle for me is to figure out how to send a message like this: /ch/01/mix/01/level 1. According to the Allen & Heath docs, the midi command should be (in hex):

B0 63 40 B0 62 44 B0 06 76 B0 26 5C

Do all of these arguments get converted to decimal and added to the preArgs field? I read the documentation but having difficulty applying it.

Thanks again.

Disclaimer: this turned out into quite a mess and I must say it's probably one of the worst possible ways to get started with open stage control. MIDI is such a pain...

From the little I've read you can only send midi to control the SQ5 so I'll try to start from that. If you can get you hands on a documentation that lists the expected messages as actual midi command names and not as hexadecimal codes you'll find it much easier to work with.

For example, if you wanted to send a control change with a fader you'd set its properties as follow:

  • address: /control
  • preArgs: [1, 40] (for channel 1, control change number 40)
  • range: {min:0, max:127} (so that the fader's value can be used as the control change's value which must be between 0 and 127
  • target: midi:my_device

Now lets play detective with your midi command...

B0 63 40 B0 62 44 B0 06 76 B0 26 5C

splits into four messages:

hexadecimal decimal meaning
B0 63 40 176, 99, 64 Control change on channel 1, CC 99, value 64
B0 62 44 176, 98, 68 Control change on channel 1, CC 98, value 68
B0 06 76 176, 6, 118 Control change on channel 1, CC 6, value 118
B0 26 5C 176, 38, 92 Control change on channel 1, CC 38, value 92

and now things get messy because that's how midi manages to get more precision than the usual 0-127 range provides (up to a 0-16383 range, 128*128 possible values instead of 128), that is by combining two control changes to control a single parameter:

  • CC 99 and 98 are combined to determine the NRPN parameter number
  • CC 6 and 38 are combined to determine that parameter's value

Open stage control does not pack nor unpack these kind of message sequence out of the box, you have to build them yourself : to send such a command you'll need a single widget to send 4 midi messages every time its value changes, that can be done using scripting :

// fader's onValue property
// assuming range is set to {min: 0, max: 16383}
// assuming target is set to midi:my_device
// assuming bypass is set to true (because the widget's default message is irrelevant here)
send('/control', 1, 99, 64)
send('/control', 1, 98, 68)
// "unpack" 0-16383 range in two 0-127 ranges 
send('/control', 1, 6, value >> 7)
send('/control', 1, 38, value & 0x7F)

If the SQ5 uses this kind of message to control most of its parameters (which is fairly possible), building a exhaustive and efficient control surface for it with open stage control will be painfully complicated if you're not familiar with Javscript and with how MIDI works in general. Partly because MIDI is admittedly - on purpose - a second class citizen in open stage control I'm afraid.

I started implementing an option for sending and receiving NPRN / RPN messages without going through all these troubles: in next release, it will be possible to configure a fader as follows:

  • address: /nrpn
  • preArgs: [1, 300] (channel 1 and parameter number between 0 and 16383 for example)
  • range: {min:0, 16383} (parameter value between 16383)
  • target: midi:my_device

The conversion between (N)RPN and control changes (99, 98, 6 and 38) will be handled automatically, this should also simplify bidirectional communication.

1 Like

This might be of some interest: GitHub - bitfocus/companion-module-allenheath-sq

That's good to hear, Jean-Emmanuel!

I had troubles using NRPN's directly so I had to rely on Bome's MIDI Translator Pro to convert arbitrary MIDI signals to NRPN's in Cubase.

By the way, despite the fact I haven't been active on this community forum for a while, I started actively using OSC recently again.

It has become an important part of my workflow in the studio. I recon there are many people enjoying your efforts even when they are not leaving any messages.


Est-ce que cela est opérationnel ou pas ?
car j'ai un retour
(ERROR, MIDI) invalid address (/nrpn)

Je tente d'envoyer des messages NRPN vers un mininova...

Oui, mais il faut bien ajouter "nrpn" dans les options midi.

ah bah oui je viens de regarder la doc en fait c'est "rpn" l'option Ă  ajouter :slight_smile:


J'avais trouvé en codant en "dur" avec les 4 messages MIDI

car la doc de mininova indique

Msb : 0
Lsb : 122

mais du coup avec ta syntaxe /nrpn, dans les preArgs, comment calculer le nombre du paramètre ?

"nrpn" fonctionne Ă©galement pour Ă©viter qu'on se trompe.

VALEUR (0-16383) = MSB * 128 + LSB
1 Like