Button - Send "no value" when switched Off

I need to switch between eight Snapshots in the Helix Native plugin. Helix Native uses CC 69 with a value of 0-7 to select a snapshot.

I have eight buttons on the panel, one for each snapshot. Ideally, a button would send the value when ON and nothing when OFF.

Is it possible to set a button to send nothing when OFF?

Let me think :wink:

Try this
CC_Send.gig (107.0 KB)

This is the script:

Var
   MIN : MidiInBlock
   BT0 : Widget
   BT1 : Widget
   BT2 : Widget
   BT3 : Widget
   BT4 : Widget
   BT5 : Widget
   BT6 : Widget
   BT7 : Widget

   cc0 : ControlChangeMessage
   cc1 : ControlChangeMessage
   cc2 : ControlChangeMessage
   cc3 : ControlChangeMessage
   cc4 : ControlChangeMessage
   cc5 : ControlChangeMessage
   cc6 : ControlChangeMessage
   cc7 : ControlChangeMessage



initialization
 cc0 = MakeControlChangeMessage(69, 0)
 cc1 = MakeControlChangeMessage(69, 1)
 cc2 = MakeControlChangeMessage(69, 2)
 cc3 = MakeControlChangeMessage(69, 3)
 cc4 = MakeControlChangeMessage(69, 4)
 cc5 = MakeControlChangeMessage(69, 5)
 cc6 = MakeControlChangeMessage(69, 6)
 cc7 = MakeControlChangeMessage(69, 7)
end

// Called when any of several widgets changed
// The widget and index parameters are optional
On WidgetValueChanged(w : Widget, index: integer, newValue : double) from BT0, BT1, BT2, BT3, BT4, BT5, BT6, BT7
 if newValue == 1.0 then
  if index == 0 then
    SendNow(MIN,cc0)
  elsif index == 1 then
    SendNow(MIN,cc1)
  elsif index == 2 then
    SendNow(MIN,cc2)
  elsif index == 3 then
    SendNow(MIN,cc3)
  elsif index == 4 then
    SendNow(MIN,cc4)
  elsif index == 5 then
    SendNow(MIN,cc5)
  elsif index == 6 then
    SendNow(MIN,cc6)
  elsif index == 7 then
    SendNow(MIN,cc7)
  end  
    
 end 
End

Native has a single parameter for the snapshot changes. I would personally use that rather than send it Midi.

Have you seen how this template was set up? It uses separate buttons.

I don’t want to be a PITA but it seems to me that the entire script you wrote can be more simply written like this:

Var
   MIN : MidiInBlock
   BT0 : Widget
   BT1 : Widget
   BT2 : Widget
   BT3 : Widget
   BT4 : Widget
   BT5 : Widget
   BT6 : Widget
   BT7 : Widget


// Called when any of several widgets changed
// The widget and index parameters are optional
On WidgetValueChanged(w : Widget, index: integer, newValue : double) from BT0, BT1, BT2, BT3, BT4, BT5, BT6, BT7

 if newValue == 1.0 then
    
    SendNow(MIN, MakeControlChangeMessage(69,index))
 End
End
3 Likes

It was late…. and Germany lost :frowning:

What’s the point of some people asking for multi-parameter callbacks and developers making the effort to implement it? :stuck_out_tongue_winking_eye:

Well, the German team lost in Munich against the current world champions, that is not shameful. :innocent::soccer:

I remember last championship where Germany was the current world champion.
That says nothing :wink:

Yes, and that’s no indication of the outcome of the competition, but this defeat is not dishonorable.:wink:

And what is most important?
“Das Runde muss in das Eckige”
“Ein Spiel dauert mindestens 90 Minuten”
“Nach dem Spiel ist vor dem Spiel”

“Und wir dürfen jetzt nicht den Sand in den Kopf stecken”

Hi Paul - Thank you for responding, especially in the middle of a soccer game!

Thank you “rank13”! The Helix gig file is exactly what I needed.

1 Like

Follow up question… If there is a button for each device in the Helix Native chain, is it possible for the buttons to update the state of each device state when changing snapshots via the buttons in GP4?

It’s possible (right click the device in Native and use Automation Bypass), but I’ve found it gets messy trying to do both. For example, the manual button changes would end up being stored in the snapshot.

My preference is to do one or the other. Either (1) use the Native snapshots, or (2) map individual effects to widgets and then use GP variations instead. My 2 cents.