I am using a capacitive touch control strip (sending out CC33) whose behavior is what you would expect for mod wheel or other fader control -- you move along the strip, lift your finger, and CC33's velocity value remains where your finger last had contact until you place your finger back on the strip.
Is it possible to map CC33's behavior to something that would instead be momentary, such as we might expect from a capacitive touch control strip made instead for pitch bending? So we lift our finger off the strip, and after xx milliseconds it would reset to velocity = 0.
Let me get back to you on this over the next couple of days. Setting the velocity back to 0 after n milliseconds is easy. The tricky bit is working out which is the final event before lift-off; I think I have a way but want to make sure.
nic, that would be amazing -- thanks! The touch strip is sensitive enough that if a finger is on the strip, it will be receiving some info. So the only time the velocity stays constant for any extended time is if the finger is lifted. I figured if what I am after is possible, then the script would probably rely on CC33's velocity remaining at a constant for XX milliseconds.
OK, I have something for you to try out. Below is a .SBR file that you can import into StreamByter or copy/paste the code below.
There are 4 controls on the GUI
CC Number - the number of the CC to return to zero (any channel) Detect - the time between when the CC stops and the return to zero RTZ Time - the speed at which it returns to zero Block Events - set this to 'yes' if only the RTZ CC events should be passed
# AutoRTZ - by audeonic if load set name AutoRTZ alias Q0 cc_number alias Q1 sensitivity alias Q2 rtz_time alias Q3 block_events define preserve +P
set cc_number CC_Number +M set sensitivity Detect_(ms) $50 $2000 +S set rtz_time RTZ_Time_(ms) 0 $5000 +S set block_events Block_Events +Y set Q4 +H set Q5 +H set Q6 +H set Q7 +H set sli 1
alias L0 serial define syx_preamble F0 7D 11
assign Q0 = $33 $500 $500 0 preserve assign serial = 0 end
# handle CC if MT == B0 if M1 == cc_number # increment serial mat serial = serial + 1 if serial > 1FFF ass serial = 1 end
# pack channel, value and serial into sysex mat I0 = serial / 80 mat I1 = serial & 7F send syx_preamble M0 M2 I0 I1 F7 +I +Dsensitivity end end
# handle trigger if M0 == syx_preamble # unpack sysex mat I0 = M5 * 80 mat I0 = I0 + M6 if I0 == serial # return to zero (M4 contains start value) mat P0 = M4 - 1 mat I0 = rtz_time / P0 ass I1 = 0 while P0 >= 0 send M3 cc_number P0 +dI1 mat P0 = P0 - 1 mat I1 = I1 + I0 end end block end
# handle block flag if block_events == 1 block end
Okay, I’m impressed!! It works. The GUI controls are a really nice touch (no pun intended) since others’ hardware may respond differently. I was getting pretty good success using appx 125 for Detect and appx 250 for RTZ time. Will continue playing with it.
Man... how do you do it? StreamByter is seriously some sorcery.