Removing extraneous MIDI messages

    Sep 05 2013 | 2:17 pm
    I'm trying to create a patch that will use midi note-on / note-off signals to send a simple OSC command. [ex. /light1/on, light1/off]. However I am getting multiple note and velocity messages when I hit a key. Here are some examples of an OSC data monitors reaction to notes being played. The patched used for this was a simple notein connected directly to a udpsend.
    This is a note pressed once and held for a few seconds then released:
    This is a note quickly tapped twice:
    Could someone please explain this behavior and what I could do to resolve it? I've seen in the tutorials information about setting note off on a timer but I don't think I should need to do that. I would think I could hold a note for hours if needed. Thank you for your help!

    • Sep 05 2013 | 2:21 pm
      Ok I guess it didn't like my imgur links. I guess I'll try attachments. The basic idea is a note held for a long period of time sends a single note with a velocity on press and then the note with a velocity of 0 on release. Tapping a note creates more than one instance of those messages. The example here is a note being tapped twice and THREE sets of note / velocity messages being sent.
    • Sep 05 2013 | 3:16 pm
      Assuming you are using a Midi keyboard, this *could* be a symptom of 'contact bounce' - in other words, a small time period in which the key contact is considered made, broken and made again etc- thus sending multiple note on/off messages - in which case you would need to apply some kind of 'debouncing' algorithm to your input. Perhaps you could try sending your note/velocity pair -> [thresh 50] -> [zl change] and see if that makes any difference...