General

handling MIDI Note On/Off from a sequencer

Started by Dark Arps on .

Sign in or create an account to join the conversation.

9 posts

Topic starter
I am trying to send note on/off messages from Ableton to trigger a pad, or group of pads. The Note on would create a Pads.x=1, note off creates a Pads.x=0.

I can't do this easily because Lemur wants to hear Note On with a velocity of 0 in order to send a 0 value to the object's variable. Ableton Live sends Note Off messages, rather than Note On (velocity 0) when MIDI notes stop in the sequencer. How do I get around this?
Yup good idea! This worked:

1) Create a script local to the Pads object, called HandleNoteOff

2) Execution set to On MIDI - Note Off - 0-127 (all notes) - 1-16 (all channels)

3) Pads.x=0;

What I'd like to know is how would I make that script global to the project and make it so that any Note Off message received creates a 0 variable in any object which uses the corresponding Note On to trigger its x variable to be 1. Anyone?
OK actually there are still shortcomings. I'll explain my scenario. I am using Lemur to control a wearable lighting system. Lemur acts as an intermediary app between live or pre-sequenced inputs (specifically Leap Motion>GecoMIDI and Ableton Live) ultimately parsing MID CCs and Note On/Off info and routing OSC data out to an Arduino with a WiFi shield.

I want to use MIDI note sequencing/arpeggiating from Ableton to trigger Pads, which send OSC variable data out to the Arduino. But I also want to be able to use the physics and envelope capabilities of the Lemur environment in this setup. If I have a series of note on and note off data being sent to a Pads object, I want to be able to increase the release time or otherwise modify the envelope to vary the attack and decay time from 0 to 1 to 0 again, which ultimately results in a gentle fading up and down of the lights instead of harsh blinking. Engaging the envelope's release has no effect because the script is forcing the value of the Pads.x variable to drop to 0 when the note off is received, instead of treating it as if I'd released my finger from the iPad screen.
This is fantastic! I haven't had the time to check this out yet but it sounds very promising, thanks a lot!

So here's adding an extra layer to the challenge: it would be even better if I could use the AHDSR envelope functionality on the pads like normal, but triggered from the incoming note on/note off information instead of touch. I tried it but it appears the physics engine only responds to touch and not MIDI information.
OK so I've finally got round to checking this out properly. Pads turn on and off with incoming MIDI notes, as expected. There are two issues however:

1) I want each note on/off to have a corresponding, discrete OSC output, but the Pads object only allows one single OSC address. How would I get around that?

2) It seems that even though the pads light up when it receives the MIDI note on information, this does not result in the corresponding OSC message to be sent out to the address. The OSC message only gets sent if I touch the pads with my finger. How do I directly route incoming MIDI to the OSC output without actually touching the pads?