MIDI In block and Note On callbacks

When I have a MIDI In block called Oxygen61 with all MIDI channels blocked:

And the following script:

var Oxygen61 : MidiInBlock

On NoteOnEvent(m : NoteMessage) from Oxygen61
   Print(m)
End

I see print statements when I press key, even though all MIDI channels are blocked.

Note on B4 (83) Velocity 64 Channel 1
Note on B4 (83) Velocity 56 Channel 1
Note on A4 (81) Velocity 52 Channel 1
Note on G4 (79) Velocity 50 Channel 1

Is this meant to be?

Yes, you block the output and the callback is listening on the input.

Ok clear :slight_smile: Luckily it’s easy to add a condition to filter out the keys and/or channels in the script.

Or you use a scriptlet after the midi in plugin

In my case that is not possible; I need to call a function from the global rackspace script.

More precisely, the system checks first to see if there is a callback for a particular message. If there is, that callback is invoked instead of being processed according to the MIDI in block settings.
That is why, for example, you need to call SendNow if you want the message sent out.