So i have been looking into using midi translator to enable me to control the headamp gains on a XR18. It seems to be possible by using OSC vis midi sysex. Im using the Sysex OSC Generator and taking the hex string and using it as a output in midi translator.
To be honest im not an expert when it comes to sysex and im not quite sure how to get this working.
Is it a case of setting up a seperate hex string output for every step of the -12 - +20 range being controled by a different midi CC input? Also how do i differentiate between the mixer channels in the hex string?
So the X32/XAir OSC protocol is expalined here. The OSC message for the headamp gain adjustment for mixer channel 1 is: /headamp/01/gain [-12 - +20] , which apparently translates to hex string F0 00 20 32 32 2F 68 65 61 64 61 6D 70 2F 31 32 2F 67 61 69 6E 20 2D 31 32 F7.
I generated this via the sysex tool in my first post.
Hi
Im a bit confused…and missing something
I use a panel in gig performer 4 to to control my iem mix. They have osc supported so it was super simple although they havent solved any easy feedback path but its bot a showstopper
So how can sysex possibly control osc? Ie without a masthead or address/support?
This util sounds pretty interesting
EDIT: ok i see its a middle man doing the work. Nice tool…thanks for the inf. A lot of work though compared to an osc extension for mtp
Where oo=Ascii + or -, pp is the tens digit 0x30-0x39 (for 0-9) and qq is the ones digit 0x30-0x39.
What we do is extract each digit into an absolute number and then create it in rr. Then we look at oo and if it is 0x2d (minus) we reverse the sign.
Finally, we offset it by 12 (-12 to +12) to make it 0-24 and we scale it to represent a CC value of 0-127.
Then we output it as a CC message.
The rules are all shown below.
// oo is the + or minus 0x2b for + and 0x2d for minus
// pp is the tens digit and qq is the ones digit
// get 10's digit
rr=pp-0x30
rr=rr*10
// add 1's digit
ss=qq-0x30
rr=rr+ss
// determine if negaative
if oo==0x2d then rr=rr*-1
// Now rr contains the decimal value in DB +12 to -12
// Lets scale it so that it is 0-24 all positive
rr=rr+12
// lets convert to 0-127
rr=rr*127
rr=rr/24
if rr>127 then rr=127
if rr<0 then rr=0
// Now it will be 0-127
See the attached project file. Input as OSC converted to SysEX. SysEX value digits extracted and converted to MIDI CC.
Also, my example IS OSC to MIDI so if it needs to be MIDI to OSC instead and then convert OSC SysEX to OSC string, then the process would be pretty much reversed. Take the relevant bytes and convert to ASCII characters and embed into the SysEX OSC and then use the other tool to convert to a true OSC message.
Steve Caldwell
Bome Customer Care
Also available for paid consulting services: bome@sniz.biz
So ive been trying to reverse your process and i cant seem to get it to output the correct bytes, any help would be super useful. Here are my rules:
// oo is the + or minus 0x2b for + and 0x2d for minus
// pp is the tens digit and qq is the ones digit
// lets convert to 0-24
rr=rr*24
rr=rr/127
if rr<0 then rr=0
if rr>24 then rr=24
// Lets scale it so that it is -12 - +12
rr=rr-12
// Now rr contains the decimal value in DB +12 to -12
// determine if negative
if rr<=0 then oo=0x2d
if rr>=0 then oo=0x2b
if oo==0x2d then rr=rr*-1
// get 1's digit
qq=rr+30
if qq>=40 then qq=qq-10
//Get 10's Digit
pp=rr/10
pp=pp+30
if pp=30 then pp=[doesnt exist?]
I’ve also realised that when the DB digits are only in the 1’s there needs to be no pp variable at all, is it possible to have it not show up in this case (hence the last rule).
Also, despite the documentation, the gain seems to be able to be controled from -12 - +60 DB via the SysEX OSC. Im not sure now to go about writing this in a rule.
Hi, I will need to see examples of the SysEx message for this. If the SysEX message had more or less bytes than the translator I created (for example, because of no 10’s digit) then the length of the SysEx will not match the incoming pattern and the translator will not fire. In this case another similar translator will need to be created to handle this case. Every time the SysEX length changes, you would need a new translator.
For reversing the process, if you don’t need the 10s digit then do not put pp in your outgoing SysEX raw MIDI message. Also the offset formula will certainly be different to get the correct outgoing db value. Since the CC value will be 0-127 and the db value you want is -12 to +12.
Steve Caldwell
Bome Customer Care
Also available for paid consulting services: bome@sniz.biz
Thanks again for all your help. I will start on setting up 2 translators to deal with the issue.
Ive made progress and im able to get the tens byte in the hex string but im struggling with the unit byte.
Ive now scaled the variable to 0-60 (the mixer seems to accept up to 60db as apposed to 12db) which is being translateted into the two sets of relevent bytes: 3(ten) and 3(unit).
Am i able to use a mod function at all to get the unit byte from the 0-60 variable? Not sure how to go about this without using complicated maths.
Hi, if you can give me an example of the OSC string your are struggling with, perhaps I can help. Maybe post your project where it is so far?
Whatever you do it will involve some math to figure out the digits that you want and a separate SysEX translator will be required for each String length you want. So if there is no leading 0 digit then the length of the SysEX string will be one less character.
Steve Caldwell
Bome Customer Care
Also available for paid consulting services: bome@sniz.biz
So with a little help from a maths savvy friend of mine i have managed to sort this, just needed to have a different equation to work out the units digit.
Turns out the mixer is ok with the hex string being too long so no need for the extra translator. Ive attached the project for reference.
Im trying to run this on my bomebox but im getting this error:
This project file is not compatible with this program.
(must be signed by the vendor)
Please contact the vendor of this tool, or Bome Software, for more information.
Loading project from ‘/projects/XAir.bmtp’: Error loading project file:
/projects/XAir.bmtp
Hi,
My guess is you are running the trial version of Bome MIDI Translator Pro which doesn’t generate a signature in the project file. You will need to purchase the paid version to generate the signature to run it on BomeBox.
If you want to test the project, you can send it to me and I can update it with my signature (one time deal) to test it.
Steve Caldwell
Bome Customer Care
Also available for paid consulting services: bome@sniz.biz
Hi, before I update it, you have one translator but you have 2 input ports and 3 output ports opened in the project. Since the translator or the preset does not indicate the source port or destination port, the translator will read from any of the input ports and send to all of the output ports. Is this really what you want?
Maybe you should look at this tutorial, and make the necessary corrections before I sign the project file and return it to you for testing on BomeBox.
Steve Caldwell
Bome Customer Care
Also available for paid consulting services: bome@sniz.biz