Hey, folks!
I haven't updated my OSC controller in a while but I wanted to add a new XY module to it.
I am looking to have the buttons (MOD,BREATH,EXP) set numbers (mod=1, breath=2 ,exp = 11) to variables varPadX, and varPadY when toggled, and then the X or Y part of the pad, would send CC data for the corresponding controllers.
I can't seem to get things functioning though, and I have very little coding knowledge sadly. I would greatly appreciate some assistance. Thank you! <3
My variable widgets are called varPadX and varPadY
My X buttons have the following code. (the second two lines just toggle off the other buttons like a switch)
var xValue = get('varPadX')
if (value == 1) {
set('BREATH', 0),
set('EXP', 0),
set('varPadX', xValue = 1)
}
and my XY pad has the following code.
var padx = get('varPadX'),
pady = get('varPadY')
var x = value[0]
var y = value[1]
send('midi:osc', '/control', 1, padx, 1, x)
send('midi:osc', '/control', 1, pady, 1, y)