Solved - Convert incoming sysex msg to cc

hello everybody

first of all i have to that this an amazing piece of software. but my javascript skills == 0.

i use open stage control with cubase and one of my goals is to switch articulations dynamically. i know how it would work without using any generic remote, without any plugin , without midi send and it would work just with any track (midi, audio and instrument). you just have to set an identifier on every cubase track. i use 0001, 0002, 0003 and so on. i use a mackie control in cubase to send sysex data to osc. what i've managed so far is, in the console i can see every sys for every track i have so far. now if i just could convert these sys msg into cc's.

i need a custom module for this to happen but as i said i've no clue how to do this. if it's possible at all.

i know i could do it with midi translator pro. but i wanna have all in osc if possible.

i hope somebody can help and put me in the right direction.

kind regards
mario

1 Like

Watching with interest…

(I’ve got it to work using cc data on instrument and midi tracks)

thats why i wanna convert the sys msg to cc's. :joy:

did you do the mihkel zilmer thing as posted on the vi-control forum?
i just don't want a plugin sitting there on every track.
the thing is how can i convert the sysex data to cc's and send them back to oscin?

If this is even possible.

let's see if somebody has something.

looking forward to replys.

Yes I use an adaption of the mihkel zilmer method. Transformer plugin doesn’t really cause any problems or performance hit. I also use a midi plugin on the instrument tracks insert to solve the lack of midi send issue.

I’ve been thinking about the idea of using mackie control and sysex but discounted it as I often create additional tracks during my workflow/composing and these would skew the track numbering unless the custom module is somehow dynamic and can respond to that. I don’t really know enough about mackie control to inderstand fully if that could be solved.

track numbering is a good point. actually it doesn't matter where the tracks are in the project as they have a unique identifier but overall i think i have to overthink the track naming. instead of only numbers one could use something like ww0001 for woodwinds, br0001 for brass, etc so each group of instruments has its own identifier. or we could go one step further to have hi's and lo's. wwh001 for woodwind hi, etc. you get the idea. the identifier shouldn't be longer than six characters because mackie control doesn't support more than that.
this way we could add and delete additional tracks and they would stay inline with the other tracks.

thanks for your input.

regards

i got it :crazy_face:

//track1 CubaseId ww0001
			if (args[0].value.includes('77 77 30 30 30 31')) {
			receive ('/track1/visible', 1);
			receive ('midi', 'DAWtoOSC', '/control', 127,0,0)
			
			} 
			else {
			receive ('/track1/visible', 0);
			}

Hello,
@gcat I'm really interested by this... but now i'm missing a few things to understand how it works and have it working...

Could you please give more details about the whole process ?...

I do use a mackie control in cubase (code found somewhere here), to have the "lcd screen", and i modified it a bit, just to show track's name. So, in my case, i'm almost ok with sysex, and i have a midi "mackie" port :
midi

Reading your code, i guess you have a button with '/track1' in osc propertie ? or '/control' in propertie and 'track1' as an id ?... Is this code a script that goes in the props, or is it a part of a custom module ?

Here i'm stuck... so... more infos would be usefull to me :slight_smile:

Thank you

hello @Sylvain
for every cubase track i use a panel in osc to show the things i need for every instrument. on the 'visible' property of every panel i set an OSC listener:
OSC{visible, false}
if a panel is showed depends on the sysex that arrives in osc. i'm using a custom module for this. this is what i have so far:

module.exports = {

    oscInFilter:function(data)
	{
        var {address, args, host, port} = data

		if (host === 'midi' && port === 'HUI' && address === '/sysex') {

			if (args[0].value.includes('f0 00 00 66 05 00 10')) return //filter out unwanted sysex
			if (args[0].value.includes('f0 00 00 66 05 00 11')) return //filter out unwanted sysex
			
			

			// WOODWINDS Panel
			if (args[0].value.includes('77 77')) {
			receive ('/woodwinds/visible', 1);
			} 
			else {
			receive ('/woodwinds/visible', 0);
			}

			//track1 CubaseId ww0001
			if (args[0].value.includes('77 77 30 30 30 31')) {
			receive ('/ww_track_1/visible', 1);
			} 
			else {
			receive ('/ww_track_1/visible', 0);
			}

			//track2 CubaseId ww0002
			if (args[0].value.includes('77 77 30 30 30 32')) {
			receive ('/ww_track_2/visible', 1);
			} 
			else {
			receive ('/ww_track_2/visible', 0);
			}

			//track3 CubaseId ww0003
			if (args[0].value.includes('77 77 30 30 30 33')) {
			receive ('/ww_track_3/visible', 1);
			} 
			else {
			receive ('/ww_track_3/visible', 0);
			}

			//track4 CubaseId ww0004
			if (args[0].value.includes('77 77 30 30 30 34')) {
			receive ('/ww_track_4/visible', 1);
			} 
			else {
			receive ('/ww_track_4/visible', 0);
			}

			//track5 CubaseId ww0005
			if (args[0].value.includes('77 77 30 30 30 35')) {
			receive ('/ww_track_5/visible', 1);
			} 
			else {
			receive ('/ww_track_5/visible', 0);
			}

			//track6 CubaseId ww0006
			if (args[0].value.includes('77 77 30 30 30 36')) {
			receive ('/ww_track_6/visible', 1);
			} 
			else {
			receive ('/ww_track_6/visible', 0);
			}

			//track7 CubaseId ww0007
			if (args[0].value.includes('77 77 30 30 30 37')) {
			receive ('/ww_track_7/visible', 1);
			} 
			else {
			receive ('/ww_track_7/visible', 0);
			}

			//track8 CubaseId ww0008
			if (args[0].value.includes('77 77 30 30 30 38')) {
			receive ('/ww_track_8/visible', 1);
			} 
			else {
			receive ('/ww_track_8/visible', 0);
			}

			//track9 CubaseId ww0009
			if (args[0].value.includes('77 77 30 30 30 39')) {
			receive ('/ww_track_9/visible', 1);
			} 
			else {
			receive ('/ww_track_9/visible', 0);
			}

			//track10 CubaseId ww0010
			if (args[0].value.includes('77 77 30 30 31 30')) {
			receive ('/ww_track_10/visible', 1);
			} 
			else {
			receive ('/ww_track_10/visible', 0);
			}

			//track11 CubaseId ww0011
			if (args[0].value.includes('77 77 30 30 31 31')) {
			receive ('/ww_track_11/visible', 1);
			} 
			else {
			receive ('/ww_track_11/visible', 0);
			}

			//track12 CubaseId ww0012
			if (args[0].value.includes('77 77 30 30 31 32')) {
			receive ('/ww_track_12/visible', 1);
			} 
			else {
			receive ('/ww_track_12/visible', 0);
			}

			//track13 CubaseId ww0013
			if (args[0].value.includes('77 77 30 30 31 33')) {
			receive ('/ww_track_13/visible', 1);
			} 
			else {
			receive ('/ww_track_13/visible', 0);
			}

			//track14 CubaseId ww0014
			if (args[0].value.includes('77 77 30 30 31 34')) {
			receive ('/ww_track_14/visible', 1);
			} 
			else {
			receive ('/ww_track_14/visible', 0);
			}

			//track15 CubaseId ww0015
			if (args[0].value.includes('77 77 30 30 31 35')) {
			receive ('/ww_track_15/visible', 1);
			} 
			else {
			receive ('/ww_track_15/visible', 0);
			}

			//track16 CubaseId ww0016
			if (args[0].value.includes('77 77 30 30 31 36')) {
			receive ('/ww_track_16/visible', 1);
			} 
			else {
			receive ('/ww_track_16/visible', 0);
			}

			//track17 CubaseId ww0017
			if (args[0].value.includes('77 77 30 30 31 37')) {
			receive ('/ww_track_17/visible', 1);
			} 
			else {
			receive ('/ww_track_17/visible', 0);
			}

			//track18 CubaseId ww0018
			if (args[0].value.includes('77 77 30 30 31 38')) {
			receive ('/ww_track_18/visible', 1);
			} 
			else {
			receive ('/ww_track_18/visible', 0);
			}

			//track19 CubaseId ww0019
			if (args[0].value.includes('77 77 30 30 31 39')) {
			receive ('/ww_track_19/visible', 1);
			} 
			else {
			receive ('/ww_track_19/visible', 0);
			}

			//track20 CubaseId ww0020
			if (args[0].value.includes('77 77 30 30 32 30')) {
			receive ('/ww_track_20/visible', 1);
			} 
			else {
			receive ('/ww_track_20/visible', 0);
			}

			//track21 CubaseId ww0021
			if (args[0].value.includes('77 77 30 30 32 31')) {
			receive ('/ww_track_21/visible', 1);
			} 
			else {
			receive ('/ww_track_21/visible', 0);
			}


			//BRASS Panel
			if (args[0].value.includes('62 72')) {
			receive ('/brass/visible', 1);
			} 
			else {
			receive ('/brass/visible', 0);
			}

			//track1 CubaseId br0001			
			if (args[0].value.includes('62 72 30 30 30 31')) {
			receive ('/br_track_1/visible', 1);
			} 
			else {
			receive ('/br_track_1/visible', 0);
			}

			//track2 CubaseId br0002			
			if (args[0].value.includes('62 72 30 30 30 32')) {
			receive ('/br_track_2/visible', 1);
			} 
			else {
			receive ('/br_track_2/visible', 0);
			}

			//track3 CubaseId br0003			
			if (args[0].value.includes('62 72 30 30 30 33')) {
			receive ('/br_track_3/visible', 1);
			} 
			else {
			receive ('/br_track_3/visible', 0);
			}

			//track4 CubaseId br0004			
			if (args[0].value.includes('62 72 30 30 30 34')) {
			receive ('/br_track_4/visible', 1);
			} 
			else {
			receive ('/br_track_4/visible', 0);
			}

			//track5 CubaseId br0005			
			if (args[0].value.includes('62 72 30 30 30 35')) {
			receive ('/br_track_5/visible', 1);
			} 
			else {
			receive ('/br_track_5/visible', 0);
			}

			//track6 CubaseId br0006			
			if (args[0].value.includes('62 72 30 30 30 36')) {
			receive ('/br_track_6/visible', 1);
			} 
			else {
			receive ('/br_track_6/visible', 0);
			}

			//track7 CubaseId br0007			
			if (args[0].value.includes('62 72 30 30 30 37')) {
			receive ('/br_track_7/visible', 1);
			} 
			else {
			receive ('/br_track_7/visible', 0);
			}

			//track8 CubaseId br0008			
			if (args[0].value.includes('62 72 30 30 30 38')) {
			receive ('/br_track_8/visible', 1);
			} 
			else {
			receive ('/br_track_8/visible', 0);
			}

			//track9 CubaseId br0009			
			if (args[0].value.includes('62 72 30 30 30 39')) {
			receive ('/br_track_9/visible', 1);
			} 
			else {
			receive ('/br_track_9/visible', 0);
			}

			//track10 CubaseId br0010			
			if (args[0].value.includes('62 72 30 30 31 30')) {
			receive ('/br_track_10/visible', 1);
			} 
			else {
			receive ('/br_track_10/visible', 0);
			}

			//track11 CubaseId br0011			
			if (args[0].value.includes('62 72 30 30 31 31')) {
			receive ('/br_track_11/visible', 1);
			} 
			else {
			receive ('/br_track_11/visible', 0);
			}

			//track12 CubaseId br0012			
			if (args[0].value.includes('62 72 30 30 31 32')) {
			receive ('/br_track_12/visible', 1);
			} 
			else {
			receive ('/br_track_12/visible', 0);
			}

			//track13 CubaseId br0013			
			if (args[0].value.includes('62 72 30 30 31 33')) {
			receive ('/br_track_13/visible', 1);
			} 
			else {
			receive ('/br_track_13/visible', 0);
			}

			//track14 CubaseId br0014			
			if (args[0].value.includes('62 72 30 30 31 34')) {
			receive ('/br_track_14/visible', 1);
			} 
			else {
			receive ('/br_track_14/visible', 0);
			}

			//track15 CubaseId br0015			
			if (args[0].value.includes('62 72 30 30 31 35')) {
			receive ('/br_track_15/visible', 1);
			} 
			else {
			receive ('/br_track_15/visible', 0);
			}


			//PERCUSSION Panel
			if (args[0].value.includes('74 70')) {
			receive ('/percussion/visible', 1);
			}
			else if (args[0].value.includes('75 70')) {
			receive ('/percussion/visible', 1);
			}
			else if (args[0].value.includes('70 6b')) {
			receive ('/percussion/visible', 1);
			}
			else {
			receive ('/percussion/visible', 0);
			}

			//Tuned Percussion

			//track1 CubaseId tp0001			
			if (args[0].value.includes('74 70 30 30 30 31')) {
			receive ('/tp_track_1/visible', 1);
			} 
			else {
			receive ('/tp_track_1/visible', 0);
			}

			//track2 CubaseId tp0002			
			if (args[0].value.includes('74 70 30 30 30 32')) {
			receive ('/tp_track_2/visible', 1);
			} 
			else {
			receive ('/tp_track_2/visible', 0);
			}

			//track3 CubaseId tp0003			
			if (args[0].value.includes('74 70 30 30 30 33')) {
			receive ('/tp_track_3/visible', 1);
			} 
			else {
			receive ('/tp_track_3/visible', 0);
			}

			//track4 CubaseId tp0004			
			if (args[0].value.includes('74 70 30 30 30 34')) {
			receive ('/tp_track_4/visible', 1);
			} 
			else {
			receive ('/tp_track_4/visible', 0);
			}

			//track5 CubaseId tp0005			
			if (args[0].value.includes('74 70 30 30 30 35')) {
			receive ('/tp_track_5/visible', 1);
			} 
			else {
			receive ('/tp_track_5/visible', 0);
			}

			//track6 CubaseId tp0001			
			if (args[0].value.includes('74 70 30 30 30 36')) {
			receive ('/tp_track_6/visible', 1);
			} 
			else {
			receive ('/tp_track_6/visible', 0);
			}

			//track7 CubaseId tp0006			
			if (args[0].value.includes('74 70 30 30 30 37')) {
			receive ('/tp_track_7/visible', 1);
			} 
			else {
			receive ('/tp_track_7/visible', 0);
			}

			//track8 CubaseId tp0007			
			if (args[0].value.includes('74 70 30 30 30 38')) {
			receive ('/tp_track_8/visible', 1);
			} 
			else {
			receive ('/tp_track_8/visible', 0);
			}

			//track9 CubaseId tp0008			
			if (args[0].value.includes('74 70 30 30 30 39')) {
			receive ('/tp_track_9/visible', 1);
			} 
			else {
			receive ('/tp_track_9/visible', 0);
			}

			//track10 CubaseId tp0009			
			if (args[0].value.includes('74 70 30 30 31 30')) {
			receive ('/tp_track_10/visible', 1);
			} 
			else {
			receive ('/tp_track_10/visible', 0);
			}

			//track11 CubaseId tp0011			
			if (args[0].value.includes('74 70 30 30 31 31')) {
			receive ('/tp_track_11/visible', 1);
			} 
			else {
			receive ('/tp_track_11/visible', 0);
			}

			//track12 CubaseId tp0012			
			if (args[0].value.includes('74 70 30 30 31 32')) {
			receive ('/tp_track_12/visible', 1);
			} 
			else {
			receive ('/tp_track_12/visible', 0);
			}

			//track13 CubaseId tp0013			
			if (args[0].value.includes('74 70 30 30 31 33')) {
			receive ('/tp_track_13/visible', 1);
			} 
			else {
			receive ('/tp_track_13/visible', 0);
			}

			//track14 CubaseId tp0014			
			if (args[0].value.includes('74 70 30 30 31 34')) {
			receive ('/tp_track_14/visible', 1);
			} 
			else {
			receive ('/tp_track_14/visible', 0);
			}

			//track15 CubaseId tp0015			
			if (args[0].value.includes('74 70 30 30 31 35')) {
			receive ('/tp_track_15/visible', 1);
			} 
			else {
			receive ('/tp_track_15/visible', 0);
			}

			//track16 CubaseId tp0016			
			if (args[0].value.includes('74 70 30 30 31 36')) {
			receive ('/tp_track_16/visible', 1);
			} 
			else {
			receive ('/tp_track_16/visible', 0);
			}

			//Untuned Percussion

			//track1 CubaseId up0001			
			if (args[0].value.includes('75 70 30 30 30 31')) {
			receive ('/up_track_1/visible', 1);
			} 
			else {
			receive ('/up_track_1/visible', 0);
			}

			//track2 CubaseId up0002			
			if (args[0].value.includes('75 70 30 30 30 32')) {
			receive ('/up_track_2/visible', 1);
			} 
			else {
			receive ('/up_track_2/visible', 0);
			}

			//track3 CubaseId up0003			
			if (args[0].value.includes('75 70 30 30 30 33')) {
			receive ('/up_track_3/visible', 1);
			} 
			else {
			receive ('/up_track_3/visible', 0);
			}

			//track4 CubaseId up0004			
			if (args[0].value.includes('75 70 30 30 30 34')) {
			receive ('/up_track_4/visible', 1);
			} 
			else {
			receive ('/up_track_4/visible', 0);
			}

			//track5 CubaseId up0005			
			if (args[0].value.includes('75 70 30 30 30 35')) {
			receive ('/up_track_5/visible', 1);
			} 
			else {
			receive ('/up_track_5/visible', 0);
			}

			//track6 CubaseId up0006			
			if (args[0].value.includes('75 70 30 30 30 36')) {
			receive ('/up_track_6/visible', 1);
			} 
			else {
			receive ('/up_track_6/visible', 0);
			}

			//track7 CubaseId up0007			
			if (args[0].value.includes('75 70 30 30 30 37')) {
			receive ('/up_track_7/visible', 1);
			} 
			else {
			receive ('/up_track_7/visible', 0);
			}

			//track8 CubaseId up0008			
			if (args[0].value.includes('75 70 30 30 30 38')) {
			receive ('/up_track_8/visible', 1);
			} 
			else {
			receive ('/up_track_8/visible', 0);
			}

			//track9 CubaseId up0009			
			if (args[0].value.includes('75 70 30 30 30 39')) {
			receive ('/up_track_9/visible', 1);
			} 
			else {
			receive ('/up_track_9/visible', 0);
			}

			//track10 CubaseId up0010			
			if (args[0].value.includes('75 70 30 30 31 30')) {
			receive ('/up_track_10/visible', 1);
			} 
			else {
			receive ('/up_track_10/visible', 0);
			}

			//track11 CubaseId up0011			
			if (args[0].value.includes('75 70 30 30 31 31')) {
			receive ('/up_track_11/visible', 1);
			} 
			else {
			receive ('/up_track_11/visible', 0);
			}

			//track12 CubaseId up0012			
			if (args[0].value.includes('75 70 30 30 31 32')) {
			receive ('/up_track_12/visible', 1);
			} 
			else {
			receive ('/up_track_12/visible', 0);
			}

			//track13 CubaseId up0013			
			if (args[0].value.includes('75 70 30 30 31 33')) {
			receive ('/up_track_13/visible', 1);
			} 
			else {
			receive ('/up_track_13/visible', 0);
			}

			//track14 CubaseId up0014			
			if (args[0].value.includes('75 70 30 30 31 34')) {
			receive ('/up_track_14/visible', 1);
			} 
			else {
			receive ('/up_track_14/visible', 0);
			}

			//track15 CubaseId up0015			
			if (args[0].value.includes('75 70 30 30 31 35')) {
			receive ('/up_track_15/visible', 1);
			} 
			else {
			receive ('/up_track_15/visible', 0);
			}

			//track16 CubaseId up0016			
			if (args[0].value.includes('75 70 30 30 31 36')) {
			receive ('/up_track_16/visible', 1);
			} 
			else {
			receive ('/up_track_16/visible', 0);
			}

			//track17 CubaseId up0017			
			if (args[0].value.includes('75 70 30 30 31 37')) {
			receive ('/up_track_17/visible', 1);
			} 
			else {
			receive ('/up_track_17/visible', 0);
			}

			//track18 CubaseId up0018			
			if (args[0].value.includes('75 70 30 30 31 38')) {
			receive ('/up_track_18/visible', 1);
			} 
			else {
			receive ('/up_track_18/visible', 0);
			}

			//track19 CubaseId up0019			
			if (args[0].value.includes('75 70 30 30 31 39')) {
			receive ('/up_track_19/visible', 1);
			} 
			else {
			receive ('/up_track_19/visible', 0);
			}

			//track20 CubaseId up0020			
			if (args[0].value.includes('75 70 30 30 32 30')) {
			receive ('/up_track_20/visible', 1);
			} 
			else {
			receive ('/up_track_20/visible', 0);
			}

			//track21 CubaseId up0021			
			if (args[0].value.includes('75 70 30 30 32 31')) {
			receive ('/up_track_21/visible', 1);
			} 
			else {
			receive ('/up_track_21/visible', 0);
			}

			//track22 CubaseId up0022			
			if (args[0].value.includes('75 70 30 30 32 32')) {
			receive ('/up_track_22/visible', 1);
			} 
			else {
			receive ('/up_track_22/visible', 0);
			}

			//track23 CubaseId up0023			
			if (args[0].value.includes('75 70 30 30 32 33')) {
			receive ('/up_track_23/visible', 1);
			} 
			else {
			receive ('/up_track_23/visible', 0);
			}

			//track24 CubaseId up0024			
			if (args[0].value.includes('75 70 30 30 32 34')) {
			receive ('/up_track_24/visible', 1);
			} 
			else {
			receive ('/up_track_24/visible', 0);
			}

			//track25 CubaseId up0025			
			if (args[0].value.includes('75 70 30 30 32 35')) {
			receive ('/up_track_25/visible', 1);
			} 
			else {
			receive ('/up_track_25/visible', 0);
			}

			//track26 CubaseId up0026			
			if (args[0].value.includes('75 70 30 30 32 36')) {
			receive ('/up_track_26/visible', 1);
			} 
			else {
			receive ('/up_track_26/visible', 0);
			}

			//track27 CubaseId up0027			
			if (args[0].value.includes('75 70 30 30 32 37')) {
			receive ('/up_track_27/visible', 1);
			} 
			else {
			receive ('/up_track_27/visible', 0);
			}

			//track28 CubaseId up0028			
			if (args[0].value.includes('75 70 30 30 32 38')) {
			receive ('/up_track_28/visible', 1);
			} 
			else {
			receive ('/up_track_28/visible', 0);
			}

			//track29 CubaseId up0029			
			if (args[0].value.includes('75 70 30 30 32 39')) {
			receive ('/up_track_29/visible', 1);
			} 
			else {
			receive ('/up_track_29/visible', 0);
			}

			//track30 CubaseId up0030			
			if (args[0].value.includes('75 70 30 30 33 30')) {
			receive ('/up_track_30/visible', 1);
			} 
			else {
			receive ('/up_track_30/visible', 0);
			}

			//track31 CubaseId up0031			
			if (args[0].value.includes('75 70 30 30 33 31')) {
			receive ('/up_track_31/visible', 1);
			} 
			else {
			receive ('/up_track_31/visible', 0);
			}

			//track32 CubaseId up0032			
			if (args[0].value.includes('75 70 30 30 33 32')) {
			receive ('/up_track_32/visible', 1);
			} 
			else {
			receive ('/up_track_32/visible', 0);
			}

			//track33 CubaseId up0033			
			if (args[0].value.includes('75 70 30 30 33 33')) {
			receive ('/up_track_33/visible', 1);
			} 
			else {
			receive ('/up_track_33/visible', 0);
			}

			//track34 CubaseId up0034			
			if (args[0].value.includes('75 70 30 30 33 34')) {
			receive ('/up_track_34/visible', 1);
			} 
			else {
			receive ('/up_track_34/visible', 0);
			}

			//track35 CubaseId up0035			
			if (args[0].value.includes('75 70 30 30 33 35')) {
			receive ('/up_track_35/visible', 1);
			} 
			else {
			receive ('/up_track_35/visible', 0);
			}

			//track36 CubaseId up0036			
			if (args[0].value.includes('75 70 30 30 33 36')) {
			receive ('/up_track_36/visible', 1);
			} 
			else {
			receive ('/up_track_36/visible', 0);
			}

			//track37 CubaseId up0037			
			if (args[0].value.includes('75 70 30 30 33 37')) {
			receive ('/up_track_37/visible', 1);
			} 
			else {
			receive ('/up_track_37/visible', 0);
			}

			//track38 CubaseId up0038			
			if (args[0].value.includes('75 70 30 30 33 38')) {
			receive ('/up_track_38/visible', 1);
			} 
			else {
			receive ('/up_track_38/visible', 0);
			}

			//track39 CubaseId up0039			
			if (args[0].value.includes('75 70 30 30 33 39')) {
			receive ('/up_track_39/visible', 1);
			} 
			else {
			receive ('/up_track_39/visible', 0);
			}

			//track40 CubaseId up0040			
			if (args[0].value.includes('75 70 30 30 34 30')) {
			receive ('/up_track_40/visible', 1);
			} 
			else {
			receive ('/up_track_40/visible', 0);
			}

			//track41 CubaseId up0041			
			if (args[0].value.includes('75 70 30 30 34 31')) {
			receive ('/up_track_41/visible', 1);
			} 
			else {
			receive ('/up_track_41/visible', 0);
			}

			//track42 CubaseId up0042			
			if (args[0].value.includes('75 70 30 30 34 32')) {
			receive ('/up_track_42/visible', 1);
			} 
			else {
			receive ('/up_track_42/visible', 0);
			}

			//track43 CubaseId up0043			
			if (args[0].value.includes('75 70 30 30 34 33')) {
			receive ('/up_track_43/visible', 1);
			} 
			else {
			receive ('/up_track_43/visible', 0);
			}

			//track44 CubaseId up0044			
			if (args[0].value.includes('75 70 30 30 34 34')) {
			receive ('/up_track_44/visible', 1);
			} 
			else {
			receive ('/up_track_44/visible', 0);
			}

			//track45 CubaseId up0045			
			if (args[0].value.includes('75 70 30 30 34 35')) {
			receive ('/up_track_45/visible', 1);
			} 
			else {
			receive ('/up_track_45/visible', 0);
			}

			//track46 CubaseId up0046			
			if (args[0].value.includes('75 70 30 30 34 36')) {
			receive ('/up_track_46/visible', 1);
			} 
			else {
			receive ('/up_track_46/visible', 0);
			}

			//track47 CubaseId up0047			
			if (args[0].value.includes('75 70 30 30 34 37')) {
			receive ('/up_track_47/visible', 1);
			} 
			else {
			receive ('/up_track_47/visible', 0);
			}

			//track48 CubaseId up0048			
			if (args[0].value.includes('75 70 30 30 34 38')) {
			receive ('/up_track_48/visible', 1);
			} 
			else {
			receive ('/up_track_48/visible', 0);
			}

			//track49 CubaseId up0049			
			if (args[0].value.includes('75 70 30 30 34 39')) {
			receive ('/up_track_49/visible', 1);
			} 
			else {
			receive ('/up_track_49/visible', 0);
			}

			//track50 CubaseId up0050			
			if (args[0].value.includes('75 70 30 30 35 30')) {
			receive ('/up_track_50/visible', 1);
			} 
			else {
			receive ('/up_track_50/visible', 0);
			}

			//track51 CubaseId up0051			
			if (args[0].value.includes('75 70 30 30 35 31')) {
			receive ('/up_track_51/visible', 1);
			} 
			else {
			receive ('/up_track_51/visible', 0);
			}

			//track52 CubaseId up0052			
			if (args[0].value.includes('75 70 30 30 35 32')) {
			receive ('/up_track_52/visible', 1);
			} 
			else {
			receive ('/up_track_52/visible', 0);
			}

			//track53 CubaseId up0053			
			if (args[0].value.includes('75 70 30 30 35 33')) {
			receive ('/up_track_53/visible', 1);
			} 
			else {
			receive ('/up_track_53/visible', 0);
			}

			//track54 CubaseId up0054			
			if (args[0].value.includes('75 70 30 30 35 34')) {
			receive ('/up_track_54/visible', 1);
			} 
			else {
			receive ('/up_track_54/visible', 0);
			}

			//track55 CubaseId up0055			
			if (args[0].value.includes('75 70 30 30 35 35')) {
			receive ('/up_track_55/visible', 1);
			} 
			else {
			receive ('/up_track_55/visible', 0);
			}

			//track56 CubaseId up0056			
			if (args[0].value.includes('75 70 30 30 35 36')) {
			receive ('/up_track_56/visible', 1);
			} 
			else {
			receive ('/up_track_56/visible', 0);
			}

			//track57 CubaseId up0057			
			if (args[0].value.includes('75 70 30 30 35 37')) {
			receive ('/up_track_57/visible', 1);
			} 
			else {
			receive ('/up_track_57/visible', 0);
			}


			//Pianos & Keys

			//track1 CubaseId pk0001			
			if (args[0].value.includes('70 6b 30 30 30 31')) {
			receive ('/pk_track_1/visible', 1);
			} 
			else {
			receive ('/pk_track_1/visible', 0);
			}

			//track2 CubaseId pk0002			
			if (args[0].value.includes('70 6b 30 30 30 32')) {
			receive ('/pk_track_2/visible', 1);
			} 
			else {
			receive ('/pk_track_2/visible', 0);
			}

			//track3 CubaseId pk0003			
			if (args[0].value.includes('70 6b 30 30 30 33')) {
			receive ('/pk_track_3/visible', 1);
			} 
			else {
			receive ('/pk_track_3/visible', 0);
			}

			//track4 CubaseId pk0004			
			if (args[0].value.includes('70 6b 30 30 30 34')) {
			receive ('/pk_track_4/visible', 1);
			} 
			else {
			receive ('/pk_track_4/visible', 0);
			}

			//track5 CubaseId pk0005			
			if (args[0].value.includes('70 6b 30 30 30 35')) {
			receive ('/pk_track_5/visible', 1);
			} 
			else {
			receive ('/pk_track_5/visible', 0);
			}

			//track6 CubaseId pk0006			
			if (args[0].value.includes('70 6b 30 30 30 36')) {
			receive ('/pk_track_6/visible', 1);
			} 
			else {
			receive ('/pk_track_6/visible', 0);
			}

			//track7 CubaseId pk0007			
			if (args[0].value.includes('70 6b 30 30 30 37')) {
			receive ('/pk_track_7/visible', 1);
			} 
			else {
			receive ('/pk_track_7/visible', 0);
			}

			//track8 CubaseId pk0008			
			if (args[0].value.includes('70 6b 30 30 30 38')) {
			receive ('/pk_track_8/visible', 1);
			} 
			else {
			receive ('/pk_track_8/visible', 0);
			}

			//track9 CubaseId pk0009			
			if (args[0].value.includes('70 6b 30 30 30 39')) {
			receive ('/pk_track_9/visible', 1);
			} 
			else {
			receive ('/pk_track_9/visible', 0);
			}

			//track10 CubaseId pk0010			
			if (args[0].value.includes('70 6b 30 30 31 30')) {
			receive ('/pk_track_10/visible', 1);
			} 
			else {
			receive ('/pk_track_10/visible', 0);
			}


			//VOCALS & CHOIRS Panel
			if (args[0].value.includes('76 6f 63')) {
			receive ('/vocals/visible', 1);
			} 
			else {
			receive ('/vocals/visible', 0);
			}

			//track1 CubaseId voc001			
			if (args[0].value.includes('76 6f 63 30 30 31')) {
			receive ('/voc_track_1/visible', 1);
			} 
			else {
			receive ('/voc_track_1/visible', 0);
			}

			//track2 CubaseId voc002			
			if (args[0].value.includes('76 6f 63 30 30 32')) {
			receive ('/voc_track_2/visible', 1);
			} 
			else {
			receive ('/voc_track_2/visible', 0);
			}

			//track3 CubaseId voc003			
			if (args[0].value.includes('76 6f 63 30 30 33')) {
			receive ('/voc_track_3/visible', 1);
			} 
			else {
			receive ('/voc_track_3/visible', 0);
			}

			//track4 CubaseId voc004			
			if (args[0].value.includes('76 6f 63 30 30 34')) {
			receive ('/voc_track_4/visible', 1);
			} 
			else {
			receive ('/voc_track_4/visible', 0);
			}

			//track5 CubaseId voc005			
			if (args[0].value.includes('76 6f 63 30 30 35')) {
			receive ('/voc_track_5/visible', 1);
			} 
			else {
			receive ('/voc_track_5/visible', 0);
			}

			//track6 CubaseId voc006			
			if (args[0].value.includes('76 6f 63 30 30 36')) {
			receive ('/voc_track_6/visible', 1);
			} 
			else {
			receive ('/voc_track_6/visible', 0);
			}

			//track7 CubaseId voc007			
			if (args[0].value.includes('76 6f 63 30 30 37')) {
			receive ('/voc_track_7/visible', 1);
			} 
			else {
			receive ('/voc_track_7/visible', 0);
			}

			//track8 CubaseId voc008			
			if (args[0].value.includes('76 6f 63 30 30 38')) {
			receive ('/voc_track_8/visible', 1);
			} 
			else {
			receive ('/voc_track_8/visible', 0);
			}

			//track9 CubaseId voc009			
			if (args[0].value.includes('76 6f 63 30 30 39')) {
			receive ('/voc_track_9/visible', 1);
			} 
			else {
			receive ('/voc_track_9/visible', 0);
			}

			//track10 CubaseId voc001			
			if (args[0].value.includes('76 6f 63 30 31 30')) {
			receive ('/voc_track_10/visible', 1);
			} 
			else {
			receive ('/voc_track_10/visible', 0);
			}

			//track11 CubaseId voc011			
			if (args[0].value.includes('76 6f 63 30 31 31')) {
			receive ('/voc_track_11/visible', 1);
			} 
			else {
			receive ('/voc_track_11/visible', 0);
			}

			//track12 CubaseId voc012		
			if (args[0].value.includes('76 6f 63 30 31 32')) {
			receive ('/voc_track_12/visible', 1);
			} 
			else {
			receive ('/voc_track_12/visible', 0);
			}

			//track13 CubaseId voc013			
			if (args[0].value.includes('76 6f 63 30 31 33')) {
			receive ('/voc_track_13/visible', 1);
			} 
			else {
			receive ('/voc_track_13/visible', 0);
			}

			//track14 CubaseId voc014			
			if (args[0].value.includes('76 6f 63 30 30 31')) {
			receive ('/voc_track_14/visible', 1);
			} 
			else {
			receive ('/voc_track_14/visible', 0);
			}


			//STRINGS Panel
			if (args[0].value.includes('73 74 72')) {
			receive ('/strings/visible', 1);
			} 
			else {
			receive ('/strings/visible', 0);
			}

			//track1 CubaseId str001			
			if (args[0].value.includes('73 74 72 30 30 31')) {
			receive ('/str_track_1/visible', 1);
			} 
			else {
			receive ('/str_track_1/visible', 0);
			}

			//track2 CubaseId str002			
			if (args[0].value.includes('73 74 72 30 30 32')) {
			receive ('/str_track_2/visible', 1);
			} 
			else {
			receive ('/str_track_2/visible', 0);
			}

			//track3 CubaseId str003			
			if (args[0].value.includes('73 74 72 30 30 33')) {
			receive ('/str_track_3/visible', 1);
			} 
			else {
			receive ('/str_track_3/visible', 0);
			}

			//track4 CubaseId str004			
			if (args[0].value.includes('73 74 72 30 30 34')) {
			receive ('/str_track_4/visible', 1);
			} 
			else {
			receive ('/str_track_4/visible', 0);
			}

			//track5 CubaseId str005			
			if (args[0].value.includes('73 74 72 30 30 35')) {
			receive ('/str_track_5/visible', 1);
			} 
			else {
			receive ('/str_track_5/visible', 0);
			}

			//track6 CubaseId str006			
			if (args[0].value.includes('73 74 72 30 30 36')) {
			receive ('/str_track_6/visible', 1);
			} 
			else {
			receive ('/str_track_6/visible', 0);
			}

			//track7 CubaseId str007			
			if (args[0].value.includes('73 74 72 30 30 37')) {
			receive ('/str_track_7/visible', 1);
			} 
			else {
			receive ('/str_track_7/visible', 0);
			}

			//track8 CubaseId str008			
			if (args[0].value.includes('73 74 72 30 30 38')) {
			receive ('/str_track_8/visible', 1);
			} 
			else {
			receive ('/str_track_8/visible', 0);
			}

			//track9 CubaseId str009		
			if (args[0].value.includes('73 74 72 30 30 39')) {
			receive ('/str_track_9/visible', 1);
			} 
			else {
			receive ('/str_track_9/visible', 0);
			}

			//track10 CubaseId str010			
			if (args[0].value.includes('73 74 72 30 31 30')) {
			receive ('/str_track_10/visible', 1);
			} 
			else {
			receive ('/str_track_10/visible', 0);
			}

			//track11 CubaseId str011			
			if (args[0].value.includes('73 74 72 30 31 31')) {
			receive ('/str_track_11/visible', 1);
			} 
			else {
			receive ('/str_track_11/visible', 0);
			}


			//SFX Panel
			if (args[0].value.includes('73 66 78')) {
			receive ('/sfx/visible', 1);
			} 
			else {
			receive ('/sfx/visible', 0);
			}

			//track1 CubaseId sfx001			
			if (args[0].value.includes('73 66 78 30 30 31')) {
			receive ('/sfx_track_1/visible', 1);
			} 
			else {
			receive ('/sfx_track_1/visible', 0);
			}

			//track2 CubaseId sfx002			
			if (args[0].value.includes('73 66 78 30 30 32')) {
			receive ('/sfx_track_2/visible', 1);
			} 
			else {
			receive ('/sfx_track_2/visible', 0);
			}

			//track3 CubaseId sfx003			
			if (args[0].value.includes('73 66 78 30 30 33')) {
			receive ('/sfx_track_3/visible', 1);
			} 
			else {
			receive ('/sfx_track_3/visible', 0);
			}

			//track4 CubaseId sfx00			
			if (args[0].value.includes('73 66 78 30 30 34')) {
			receive ('/sfx_track_4/visible', 1);
			} 
			else {
			receive ('/sfx_track_4/visible', 0);
			}

			


		








		}

		// Cubase Beats & Bars
		else if (data.host === 'midi' && data.port === 'MCUtoOSC') {
            
            var [channel, control, value] = data.args.map(x=>x.value)
            
            if (control > 63 && control < 74) {
                
                var digit = 73 - control,
                    msb = value >> 4,
                    val = value & 0xF
                
                if (msb >> 2) val += '.'
                if (!(msb & (1 << 1))) val = ''

                // digit -> digit
                // val -> digit's value 
                
                // assuming 10 text widgets with incrementing preArgs 
                receive('/timecode', digit, val)

                return
                
            }
        }
	return {address, args, host, port}
	},
}

Bildschirmfoto 2022-01-12 um 12.42.32
Bildschirmfoto 2022-01-12 um 12.42.56

i have to mention, for the track display i use 'HUI' and the mackie i only use for bars &beats.
as for the /control, this was just a test if i can "send" back midi cc into osc.
i hope i could help you.

i have to say i'm in no way a programmer. i'm more the copy paste guy
if you have further questions feel free to ask. if i can i'll answer them happily

cheers

Thank you very much, it really really helps :slight_smile: ... and saves ten days of me-in-a-pulling-my-hair-out-mode :smiley:

I will now have a closer look at how sysex work.

Just two things :

  • What are those two "unwanted sysex" that are excluded at the beginning of this code ?
  • i understand the last values progressions,but do the two first numbers (77 77 ; 62 72...) correspond, in a way, to folder tracks ?

Thanks a lot

lots of hair laying around my studio :joy: :joy: :joy:

if (args[0].value.includes('f0 00 00 66 05 00 10')) return //filter out unwanted sysex
if (args[0].value.includes('f0 00 00 66 05 00 11')) return //filter out unwanted sysex

this sysex i filter out. they screw up the visibilty of my tracks as soon as i hit play. i just don't want them to arrive at osc.

the first two numbers declaire on which group of instruments i am.

for the the first track in woodwinds in cubase i use

ww0001

and this arrives as

'77 77 30 30 30 31' in osc.

in osc i have a panel for every instrument group, and to identify it i just use the first to letters of my cubase instrument groups.

Bildschirmfoto 2022-01-12 um 14.00.28

ww = woodwinds
br = brass
.
.
.
so '77' stands for ww, '62 72' for br, etc

i use this site to convert ascii to hex and vica versa:

i hope things are getting cleare now.

now i have to clean up this mess of hair here... :joy: :joy: :joy:

regards

:smiley:

Ok, so before i went back here, i managed to get this working :crazy_face:

A bit hard to find out which sysex was transmitted in my case (i finally used MidiOx, switch fastly 2/3 tracks in Cubase, and quickly stop MidiOx... because of control messages constantly received...).

But now it's ok, as a bald Harry Potter, i managed to have two buttons visible / invisible, depending on the selected track in Cubase :partying_face:

So again, thank you very much, a whole new Era has just opened to me !

And Peace to our hairs... :innocent:

that's great!!!

exactly what i feel. :crazy_face:
i just figured this thing out yesterday i think. next thing would be how to dynamically switch articulations with labels automaticly generated from an expression map in cubase.
i have absolutely no, i mean no plan where to start and how and anyway.
if i'm gonna make this beast you can call me gandalf :joy:

you are very welcome
glad i could help you

:innocent:

1 Like

This is very excited as a development. As I’ve said on another thread I’ve got articulation switching working now on all types of tracks but it has its limitations. Using sysex might unlock a few of them. But the big issue for me is how to link the expression map to a track dynamically in OSC - at some point you will have to tell OSC what expression map is being used on what track and I can’t think of any way to do that other than really getting under the hood in the code of cubase which of course isn’t going to happen.

The closest I can get is when I’ve told OSC which track uses which map by objects in my custom module, I think I can get the custom module to read the xml of the map directly so if the map is updated, I don’t need to update the custom module objects. That is the current challenge.

Hey, i have a strange issue... Do you have it too ?

hui

Panels, buttons... sometimes don't appear... sometimes appear and then disappear instantly...

:thinking:

for the track visibility i use a HUI device. i think it's essential to use a separate midi port for this task. because there is sysex data we don't want.
did you filter out the unwanted sysex in the custom module?

if (host === 'midi' && port === 'HUI' && address === '/sysex') {

			if (args[0].value.includes('f0 00 00 66 05 00 10')) return //filter out unwanted sysex
			if (args[0].value.includes('f0 00 00 66 05 00 11')) return //filter out unwanted sysex

Yep, i do use a HUI device, and have included both "unwanted sysex" (altough i don't receive the 11's one).

Well, i see this "issue" happens when i switch from one kind of track to another... audio to midi, vst to audio... when i navigate in the same kind of tracks, it's ok...
Here i went from vst track to audio track, and i first received that :
sysex

then i selected the second audio track and once again the first, which gave me that :
sysex2

Strange...

till now i only worked with instrument tracks. but i can confirm it happens here also. when we switch to an instrument track or audio track we get this:

adding this two lines in the custome module where you filter unwanted sysex did the trick:

if (args[0].value.includes('f0 00 00 66 05 00 12 04 20 45 51 20 31 20 47 61 69 6e 05 20 45 51 20 31 20 46 72 65 71 06 20 20 45 51 20 31 20 51 20 20 07 20 20 45 51 20 31 20 4f 6e 20 f7')) return //filter out unwanted sysex
if (args[0].value.includes('f0 00 00 66 05 00 12 04 20 20 20 20 20 20 20 20 20 20 05 20 20 20 20 20 20 20 20 20 20 06 20 20 20 20 20 20 20 20 20 20 07 20 20 20 20 20 20 20 20 20 20 f7')) return //filter out unwanted sysex

something else that's interesting i found is, i think we don't need any identifiers for the tracks 'cause the sysex output includes 19 characters for each track.
i think this is massiv. so you can add any track anywhere in your template without screwing up anything.

hopes this helps others

cheers and regards
mario

1 Like

Yes it did, cool :wink:

Would you be able to post a blank template with 1 instrument track and the OSC file? I’m having a hard time recreating the dynamic buttons