Controller transformation for program change

I found the following script an placed it in the global rackspace. The plugin editor shows four horizontal faders with the names “Conversion”, “CC Start”, “CC End” and “Converted PC starts at 0”.


// This scriptlet will convert incoming Control Change (CC) messages to Program Change (PC) messages.
Var

  • CONVERSION (“Conversion”) : Parameter “Off”,“On” = “On”*
  • CC_START (“CC Start”) : Parameter 0…127 = 51*
  • CC_END (“CC End”) : Parameter 0…127 = 58*
  • START_AT_0 (“Converted PC Starts at 0”) : Parameter “No”,“Yes” = “Yes”*

//Called when a CC message is received
//The CC numbers must be within the specified range
On ControlChangeEvent(m : ControlChangeMessage)

  • Var offset : Integer = 0*
  • if CONVERSION == “On” then*
  •    if GetCCNumber(m) >= CC_START and GetCCNumber(m) <= CC_END then*
    
  •        if GetCCValue(m) == 127 then*
    
  •            if START_AT_0 == "Yes" then offset = 0 - CC_START end*
    
  •            InjectMidiEvent("Local GP Port", MakeProgramChangeMessage(GetCCNumber(m) + offset))*
    
  •        end*
    
  •    end*
    
  • end*
    End

// Called automatically after script is loaded
Initialization

  • SetDisplayMessage(“Convert CC to PC”)*
  • SetInfoMessage(“This scriptlet will convert incoming Control Change (CC) messages to Program Change (PC) messages. They will be inserted to the Local GP Port so they will be picked up by GP at the system level.”)*
    End

I can set a connection of the scriptlet with my midi input device.

I can place some knobs on the panel of the global rackspace. I can control these knobs with the encoders of my hardware controller. Acitvating “Sync” synchronizes the encoders LED’s with the panel knobs.

The faders are moving on the screen but none of the four encoders can change rackspaces. Do I need to place additional connections between items? What might be missing?