Midi device background scripts

Discussion in 'PangoScript, Universe and Midi Templates' started by m4rv, Jun 17, 2014.

  1. m4rv

    m4rv New Member

    I'm trying to send some midi notes out to two separate devices from the "Background Scripts" on each device.

    The background script is being triggered from the "Initialisation" script.

    Both scripts will execute but the notes are all sent to midi device 1.

    I know that I can use "SelectMidi" to change the output but it would be better to not have to change the output device each time I load the midi settings, if I have to load the script onto different devices for different setups for example.

    My test scripts are very simple:

    Device 1:
    "Initialisation script"
    StartCode "TestOut1"
    "Background scripts"
    CodeName "TestOut1"
    MidiOut 0x91, 0x40, 0x7F
    Device 2 is the same except the code name is "TestOut2" and it outputs a different midi note.

    When the scripts execute, In the midi monitor I get:
     Dev1 92 20 7F Note On  Script(TestOut2) MidiOut
    Dev1 91 40 7F Note On  Script(TestOut1) MidiOut
    Is there a way to fix this?

    Last edited: Jun 17, 2014
  2. ENOT

    ENOT Software Developer Staff Member

    Thanks for poining on this, good point. Code adjusted. Let me know if you willing to test internal version.

    Best Regards,

  3. m4rv

    m4rv New Member

    Hi Alexey,

    Thanks for the reply.

    I'd be happy to do some testing. Ive sent you a PM.