Old 07-10-2020, 07:22 AM   #1
Florian.S
Human being with feelings
 
Join Date: Jul 2020
Posts: 2
Default Reaper OSC to Companion

Hi,

trying to get reaper marker names into companion.
Reaper sends out names like "s/marker/@/name" but labeling a button direkt in companion expects "/style/text/page/button string"

Is there a way to do this.
I'm not getting how OSCII Bot scripts working right now.
My first thought would be something like:

@input DAW_Reaper OSC „localhost:9001“ //9001 osc out port reaper
@output Companion OSC „localhost:12321“ //12321 osc in port companion

@init

@oscmsg
page = 2
mystring = s/marker/@/name
/style/text/page/@/ mystring

Would be nice if somebody could guide me. Thanks.
Florian.S is offline   Reply With Quote
Old 07-11-2020, 01:03 AM   #2
kram0
Human being with feelings
 
Join Date: Mar 2015
Posts: 35
Default

Hi Florian
You just need to catch the OSC command and translate it to what you require.

This example will trigger when the OSC command begins with 's/marker/' and ends with '/name':

oscmatch("s/marker/*/name") ? (
(do something here...);
);



So see if this works as a test. I'm not sure what the exact syntax your device is expecting but have a play with it. When the script is launched it should immediately send "Test String" to "page 1". I hope it makes sense!



@input DAW_Reaper OSC „localhost:9001“ //9001 osc out port reaper
@output Companion OSC „localhost:12321“ //12321 osc in port companion

@init
sendcommand = "/style/text/page/1/";
sendvalue = "Test String";

//The following line sends the OSC command to your device
oscsend(Companion, sendcommand, sendvalue);

@oscmsg
kram0 is offline   Reply With Quote
Old 07-16-2020, 01:14 PM   #3
Florian.S
Human being with feelings
 
Join Date: Jul 2020
Posts: 2
Default

Hi kram0,

i only get the following in OSCII-bot

Error listening for '„localhost:9001“'
0 inputs, 0 outputs, 1 bidirectional

Total: 1 scripts, 0 inputs 0 outputs 1 bidirectional

I managed to get the osc massage out when script is loaded.

Only thing i need is to resolve the Error mentioned above and i need to store the string wich contains the name of the marker and the number if this marker so i can push it out to different buttons.

sendstring = ( name of the marker)
sendnumber = ( number of the marker )
sendcommand = " s/style/text/1/sendnumber"

So i could come up with something like

oscmatch("s/marker/*/name") ?
(oscsend(Companion, sendcommand, sendstring));

Sry, but i don't get the syntax of this language. I searched a lot but i don't get the initial spark.
Florian.S is offline   Reply With Quote
Old 07-21-2020, 06:56 AM   #4
goldenarpharazon
Human being with feelings
 
Join Date: Feb 2016
Posts: 144
Default Getting code going

Florian. There are good code examples to follow in [user] Banned's Peavey Studio Mix (thread and script code) and the Akai MidiMix control surface script and in kram0's control signal routing.

There are also simple but terse code examples included with OSCII-bot that work and can be incrementally extended for a chosen use.

The OSCII-bot code reference web page gives information on string handling but it is not a tutorial.

To make help easier for a specific syntax or functionality questions then please post sufficiently complete & readable OSCII-bot script code using the [code] BB code formatting.
goldenarpharazon is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 09:28 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2020, vBulletin Solutions Inc.