Facility for Sending MIDI Song Select?

Hi.

Is there a facility in GP for sending MIDI Song Select messages?

What is the use case?

Commanding software that requires Song Select to change configuration.

So you want GP to be the controlling center?

Yes, that’s what I was thinking.

OK, little scripting could help

//$<AutoDeclare>
// DO NOT EDIT THIS SECTION MANUALLY
Var
   MOUT : MidiOutBlock
   BUTTON : Widget
   m : MidiMessage
//$</AutoDeclare>



// Called when a single widget value has changed
On WidgetValueChanged(newValue : double) from BUTTON
 m = MakeMidiMessage2(243, 0)
 SendNowExternal(MOUT, m)
End

In this example by pressing a widget the MIDI message for selecting the 1st song is created and then sent out via a MIDI Out plugin which has the handle MOUT.

So you could use the IAC driver (when you are on MAC) or similar virtual MIDI on Windows the send out such a message and in your receiving software you listen to this device.

1 Like

Very interesting. Thanks!

So I guess if I wanted to choose between 64 songs I would use a knob, construct the value of the knob into a correct Song Select message and then send as shown?

For example, yes.

I think it would be better to do this with a scriptlet that has a parameter that represents song select and then attach a widget to that.

1 Like

Actually, this is a case where using an unlocked label tied to a SongSelect parameter of a scriptlet would work better
screenshot_8241

Here’s an example gig file demonstrating this approach
ScriptletSongSelect.gig.zip (12.0 KB)

1 Like

That works very well… You can see the number, operate it, link it to a physical knob if you want - and it is very straightforward to understand and use.

I love it. Thank you very much!