Midi Channel +1 script?


Looking into the Scripting forum I see a lot of good musicians also being good programmers 
Unfortunately I am an average musician but in programming I am a total noob….
I read all the forum posts and the scripting manual and trying to write a script but I cannot get it working
So I am seeking your assistance, please forgive me 

I want to do the following

When a certain note (Bb4) is played I want to do a Midi Channel +1

Off course I also want no sound for this specific note.

I hope you can help me with this.


Hi Ronald, I will send you a piece of code you can test with.


I should also ask for a channel -1 key at the same time, or alternatively a reset to 1 option in case you go over 16 :stuck_out_tongue_winking_eye: :+1:


The modulo operator is your friend :slight_smile:


Quick & Dirty script:

var MIDI : MidiInBlock
v_channel : Double

on NoteOnEvent (m : NoteMessage) matching C3 from MIDI

v_channel = GetParameter (MIDI, 0)

v_channel = v_channel + 1.0/16.0

if v_channel > 1.0 then
v_channel = 1.0/16.0

SetParameter(MIDI, 0, v_channel)