Hello folks,
I’m building a sketch that uses a MIDI controller to change variables live. I’m using a MIDI In CHOP for that. The specific MIDI controller I’m using (Novation Launch Control XL 3) supports setting encoder values from MIDI in. I would like to create a “Reset” button which sets all my encoders to a specific value (64). I’ve been able to do that using an Execute DAT and a MIDI Out CHOP and I can see that my controller has picked up the correct value on the encoders.
My problem is that the MIDI In CHOP will still report the old values of the encoders. This means that even if I set my controller encoders to 64, MIDI In will still show the old value and will immediately jump to 63 or 65 as soon as I move my encoders. As a consequence, resetting encoder values on my controller will not reset variables to their middle value.
Does anyone have any ideas how to get my desired behavior?
One way I’ve come up with is:
- Pipe the MIDI In CHOP into a Math CHOP, Multiply by 0 and add 64
- Combine the MIDI In CHOP and the Math CHOP into an Override CHOP ← the most recent value will win
- When I press the “Reset” button:
- Send “64” to all encoders ← Encoders move to 64
- Jiggle the Math CHOP values by 0.001, enough to replace MIDI values in Override ← the values in Math are now the most recent and will make it through Override
- When I move any encoder, MIDI In will immediately jump to 63 or 65 ← this value is now the most recent and will make it through Override
While it works, it feels a bit clunky. Anyone have a better idea?
Thank you!