Page 1 of 1

Midi target as variable

Posted: 13 Apr 2012 07:31
by kabletx
NOTE: I've figured out that this is, in fact, how to do this. I figure it might be worth leaving this up for anyone else who ends up searching with the same question. However, If I happen to be wrong with my assessment below please let me know.

Howdy,

I've started the long process of creating a template for the Oberheim Matrix 1000, but before I get too far off into the wilderness I want to sort out a feature I've seen in a few other templates.

How is it that one can set the Project MIDI Target as a variable so that you're not locked into always using, say, Output 0?

I'll be doing sysex, and I know that it's best at this point to use the MIDIOut script for those commands. However, I'd like to be able to change the target so that I'm not locked in should I need to change it across the template. Is it simply a matter of declaring a global variable and slotting it in? Is there a way of monitoring what target the Lemur is currently sending to?

Thanks for your time,
Kevin

Re: Midi target as variable

Posted: 13 Apr 2012 17:49
by bxsj
Basically you already answered your question. A global variable can be used to control to which target to send midi data using the midiout function. I've attached a template which I use to send/receive sysex data with a Roland v-synth xt. On the settings interface there is a drop down menu to choose the target port used for example in the sysexout script. Beside that, don't take my template too serious, I'm not a pro in doing this :)
Cheers,
B.