loop ? effect 'LoopRoll' active ? on & loop 0 & effect 'LoopRool' active
IF BOTH a loop is active and the effect 'LoopRoll' is active. The LED will turn on. When the button is pressed it will stop looping, and the effect will turn off.
loop ? on & loop 0
If ONLY a loop is active the LED will be on. When the button is pressed it will stop looping.
effect 'LoopRoll' active ? on & effect 'LoopRoll' active
IF ONLY effect 'Loop Roll' is active the LED will be on. When the button is pressed the effect will turn off.
and when I join them together.
loop ? effect 'LoopRoll' active ? on & loop 0 & effect 'LoopRool' active : loop ? on & loop 0 : effect 'LoopRoll' active ? on & effect 'LoopRoll' active
It doesn't work as intended, no LED for when 'LoopRoll' is active, and I have to press the button twice to cancel the effect when I am looping and have the 'LoopRoll' effect activated.
By the way my intention with this script is to have 2 types of loop modes toggled by a simple shift button.
Loop mode 1: Normal Loop. Playback starts again where the loop was activated.
Loop mode 2: LoopRoll. Playback continues from where the loop was activated.
Can anyone tell me what I am doing wrong?
Thanks!
Inviato Sun 07 Aug 11 @ 8:35 pm
First, you need to map the led to the led, so if you look in the mapper you should see the led note called the same as the button, eg "PLAY_LED" or something like that, then use this script
effect 'LoopRoll' active ? on : off
that will turn the light on when the effect is active
for the loop reset
down ? effect "looproll" active on & effect "looproll" button 4 1 & effect "looproll" slider 2 #% : effect "looproll" active off & effect "looproll" button 4 0
for the normal one
effect "looproll" active & effect "looproll" slider 2 #%
for both
var 'shift_name' ? down ? effect "looproll" active on & effect "looproll" button 4 1 & effect "looproll" slider 2 #% : effect "looproll" active off & effect "looproll" button 1 0 : effect "looproll" active & effect "looproll" slider 2 #%
you need to put in a value for how big you want the loop by replacing the # for the slider position (has to be a percentage), and change the "shift_name" to whatever yours is called
EDIT
---------------------------------------------------------------
actually it doesn't look like you can map button 4 for jump back so you would need to activate it manually or copy the dll and have looproll 1 and looproll 2 with the different settings, or contact tex and ask for an update
effect 'LoopRoll' active ? on : off
that will turn the light on when the effect is active
for the loop reset
down ? effect "looproll" active on & effect "looproll" button 4 1 & effect "looproll" slider 2 #% : effect "looproll" active off & effect "looproll" button 4 0
for the normal one
effect "looproll" active & effect "looproll" slider 2 #%
for both
var 'shift_name' ? down ? effect "looproll" active on & effect "looproll" button 4 1 & effect "looproll" slider 2 #% : effect "looproll" active off & effect "looproll" button 1 0 : effect "looproll" active & effect "looproll" slider 2 #%
you need to put in a value for how big you want the loop by replacing the # for the slider position (has to be a percentage), and change the "shift_name" to whatever yours is called
EDIT
---------------------------------------------------------------
actually it doesn't look like you can map button 4 for jump back so you would need to activate it manually or copy the dll and have looproll 1 and looproll 2 with the different settings, or contact tex and ask for an update
Inviato Sun 07 Aug 11 @ 10:31 pm
My apologies for not explaining myself in enough detail with my first post
My intention is to have 2 modes for my 4 buttons (loop 1, 2, 4, 8) on my ns6.
Loop mode 1: Normal Loop. Playback starts again where the loop was activated.
Loop mode 2: LoopRoll. Playback continues from where the loop was activated.
I have been able to map the 4 different functions on each button, I was working on the loop ON/OFF button when I ran into the problems.
This button I mapped was capable of cancelling a current loop or loop roll, but most importantly I can't get it to deactive when a loop & loop roll is activated at the same time.
Obviously a loop & loop roll activated at the same time is pointless, but I need this button to function as an end all no matter how many buttons I have pressed or how many things I have activated.
Also the LED_ON/OFF must be mapped to the same HID definition I believe? There is no button named LED_ON/OFF (or ON/OFF_LED)
loop ? on : off activates the LED on the button named ON/OFF.
Thankyou for your time it is much appreciated!
My intention is to have 2 modes for my 4 buttons (loop 1, 2, 4, 8) on my ns6.
Loop mode 1: Normal Loop. Playback starts again where the loop was activated.
Loop mode 2: LoopRoll. Playback continues from where the loop was activated.
I have been able to map the 4 different functions on each button, I was working on the loop ON/OFF button when I ran into the problems.
This button I mapped was capable of cancelling a current loop or loop roll, but most importantly I can't get it to deactive when a loop & loop roll is activated at the same time.
Obviously a loop & loop roll activated at the same time is pointless, but I need this button to function as an end all no matter how many buttons I have pressed or how many things I have activated.
Also the LED_ON/OFF must be mapped to the same HID definition I believe? There is no button named LED_ON/OFF (or ON/OFF_LED)
loop ? on : off activates the LED on the button named ON/OFF.
Thankyou for your time it is much appreciated!
Inviato Mon 08 Aug 11 @ 12:24 am
Loop mode 1: Normal Loop. Playback starts again where the loop was activated.
Loop mode 2: LoopRoll. Playback continues from where the loop was activated.
Not sure why you want to do that, they pretty much do the same thing, did you mean you want the loop roll to continue from where it would have been in the track?
Loop mode 2: LoopRoll. Playback continues from where the loop was activated.
Not sure why you want to do that, they pretty much do the same thing, did you mean you want the loop roll to continue from where it would have been in the track?
Inviato Mon 08 Aug 11 @ 1:59 am
for the off switch you can use this, it first asks if both are on, then if it is looping then if loop roll is on individually
loop ? effect "looproll" active on ? loop_exit & effect "looproll" active off : loop ? loop_exit : effect "looproll" active on ? effect "looproll" active off : Anything you want the button to do when neither of these are active
query 1 ? query 2 ? action if query 1 & 2 are true : query 1 ? action if query 1 is true : query 2 ? action if query 2 is true : action if all are false
loop ? effect "looproll" active on ? loop_exit & effect "looproll" active off : loop ? loop_exit : effect "looproll" active on ? effect "looproll" active off : Anything you want the button to do when neither of these are active
query 1 ? query 2 ? action if query 1 & 2 are true : query 1 ? action if query 1 is true : query 2 ? action if query 2 is true : action if all are false
Inviato Mon 08 Aug 11 @ 5:15 am
This script works! Thanks!
Although the LED doesn't turn on when a looroll is active, only when a normal loop is active.
As I said before there is no HID definition for this LED although it can turn on/off but I can work around it by setting each 4 buttons in both banks to toggle a variable and tell the LED to activate when the variable is true.
Also, when setting on/off fuction for an effect to an encoder how do you get the encoder activate it when you first move it and off when your not using it. It outputs an on message for every cc (0-127) of its scale when in use, which I don't want it to do!
Although the LED doesn't turn on when a looroll is active, only when a normal loop is active.
As I said before there is no HID definition for this LED although it can turn on/off but I can work around it by setting each 4 buttons in both banks to toggle a variable and tell the LED to activate when the variable is true.
Also, when setting on/off fuction for an effect to an encoder how do you get the encoder activate it when you first move it and off when your not using it. It outputs an on message for every cc (0-127) of its scale when in use, which I don't want it to do!
Inviato Mon 08 Aug 11 @ 9:47 pm
If you are using an absolute rotary encoder use
param_greater 0% ? effect "effect_name" active on & (whatever settings you want) : effect "effect_name" active off
eg
param_greater 0% ? effect "gates" active on & effect "gates" slider 2 : effect "gates" active off
(don't know if that will be good, it's just an example, I have never used gates)
I have no idea how to map the leds for that, maybe check with cstoll or jakovski
param_greater 0% ? effect "effect_name" active on & (whatever settings you want) : effect "effect_name" active off
eg
param_greater 0% ? effect "gates" active on & effect "gates" slider 2 : effect "gates" active off
(don't know if that will be good, it's just an example, I have never used gates)
I have no idea how to map the leds for that, maybe check with cstoll or jakovski
Inviato Mon 08 Aug 11 @ 10:48 pm
I managed to get the LED's for the loops working, what i didn't realise is that additional LED/buttons have to be added to the default map by using the + button and selecting them! In the default map the LED had been merged with the button to make it easier for you if you are not creating such a complicated mapping.
In some occasions of scripting I just can't find out what I am doing wrong (after trying every variation of syntax)
I have another question concerning mapping hotcues which involve 2 banks of 5 hotcue buttons. 1-5 + 6-10. It involves a toggled shift button while pressed to delete them.
var 'hotcue_delete' ? var '$shift' ? delete_cue 6 : var '$shift' ? delete_cue 1 : var 'delete_hotcue' ? hot_cue 6 : hot_cue 1
this means IF variable 'hotcue_delete' is TRUE and variable '$shift' is TRUE together then delete hotcue 6.
IF both variables 'hotcue_delete' and '$shift' are NOT TRUE together but variable '$shift' is TRUE then delete hotcue 1.
IF only variable 'delete_hotcue' is TRUE then trigger hotcue 6.
IF none of the variables are true then trigger hotcue 1.
this is how I understand the syntax, everything is working except I can't trigger hotcue 1. What is the problem?
Thanks!
In some occasions of scripting I just can't find out what I am doing wrong (after trying every variation of syntax)
I have another question concerning mapping hotcues which involve 2 banks of 5 hotcue buttons. 1-5 + 6-10. It involves a toggled shift button while pressed to delete them.
var 'hotcue_delete' ? var '$shift' ? delete_cue 6 : var '$shift' ? delete_cue 1 : var 'delete_hotcue' ? hot_cue 6 : hot_cue 1
this means IF variable 'hotcue_delete' is TRUE and variable '$shift' is TRUE together then delete hotcue 6.
IF both variables 'hotcue_delete' and '$shift' are NOT TRUE together but variable '$shift' is TRUE then delete hotcue 1.
IF only variable 'delete_hotcue' is TRUE then trigger hotcue 6.
IF none of the variables are true then trigger hotcue 1.
this is how I understand the syntax, everything is working except I can't trigger hotcue 1. What is the problem?
Thanks!
Inviato Sat 13 Aug 11 @ 2:29 pm
that script looks totaly insane, can you please tell me exactly what you want to do and ill see what i can do for you.
to me it looks wrongly set out. it has a conflict somewhere between the middle and end
var 'hotcue_delete' ? var '$shift' ? delete_cue 6 : var '$shift' ? delete_cue 1 : var 'delete_hotcue' ? hot_cue 6 : hot_cue 1
is hot_del set ? is glob shift set? if they are do del_cue 6 (otherwise do) is glob shift set? if it is then do del_cue 1 (otherwise do) is delete hotcue set ? if so do hot cue 6 (otherwise do) hotcue 1.
there is several conflicting variable requests there from how i understnd it.
i would use it like this
var 'hotcue_delete' ? var '$shift' ? delete_cue 6 : nothing : var '$shift' ? delete_cue 1 : nothing : var 'delete_hotcue' ? hot_cue 6 : hot_cue 1
that way it breaks the syntax into 3 sets of commands
if hot_del and $shift are set, then do delete cue 6 or do nothing.
if $shift only is set then do delete cue 1
if delete hot cue only is set, then do hot cue 6 otherwise do hot cue 1
the way you have it it seems to me like your trying to run 3 sets of comands but they are crossing over. i could be wrong, but i also could be right.
var '$shift' ? delete_cue 1 : var 'delete_hotcue' ? hot_cue 6 : hot_cue 1
this seems to be the conflicting section if $shift is on then delete cue 1 otherwse is del_hotcue on if it is do hot cue 6 : otherwise do hot cue 1
to me having 2 active requests without a seperation seems to be wrong.
to me it looks wrongly set out. it has a conflict somewhere between the middle and end
var 'hotcue_delete' ? var '$shift' ? delete_cue 6 : var '$shift' ? delete_cue 1 : var 'delete_hotcue' ? hot_cue 6 : hot_cue 1
is hot_del set ? is glob shift set? if they are do del_cue 6 (otherwise do) is glob shift set? if it is then do del_cue 1 (otherwise do) is delete hotcue set ? if so do hot cue 6 (otherwise do) hotcue 1.
there is several conflicting variable requests there from how i understnd it.
i would use it like this
var 'hotcue_delete' ? var '$shift' ? delete_cue 6 : nothing : var '$shift' ? delete_cue 1 : nothing : var 'delete_hotcue' ? hot_cue 6 : hot_cue 1
that way it breaks the syntax into 3 sets of commands
if hot_del and $shift are set, then do delete cue 6 or do nothing.
if $shift only is set then do delete cue 1
if delete hot cue only is set, then do hot cue 6 otherwise do hot cue 1
the way you have it it seems to me like your trying to run 3 sets of comands but they are crossing over. i could be wrong, but i also could be right.
var '$shift' ? delete_cue 1 : var 'delete_hotcue' ? hot_cue 6 : hot_cue 1
this seems to be the conflicting section if $shift is on then delete cue 1 otherwse is del_hotcue on if it is do hot cue 6 : otherwise do hot cue 1
to me having 2 active requests without a seperation seems to be wrong.
Inviato Sat 13 Aug 11 @ 4:34 pm
here you go mate, you had the right idea, but made it a little more complicated than it is, but it's good to see some other people trying to figure out how to map
var '$shift' ? var 'hotcue_delete' ? delete_cue 6 : hot_cue 6 : var 'hotcue_delete' ? delete_cue 1 : hot_cue 1
It works like this
var 1 ? var 2 ? if var 1 and var 2 is true : if var 1 is true but var 2 is false : var 2 ? if var 1 is false but var 2 is true : if var 1 and var 2 are false : if all are false
hope that's not too confusing
var '$shift' ? var 'hotcue_delete' ? delete_cue 6 : hot_cue 6 : var 'hotcue_delete' ? delete_cue 1 : hot_cue 1
It works like this
var 1 ? var 2 ? if var 1 and var 2 is true : if var 1 is true but var 2 is false : var 2 ? if var 1 is false but var 2 is true : if var 1 and var 2 are false : if all are false
hope that's not too confusing
Inviato Mon 15 Aug 11 @ 7:29 am
ah i see where your coming from with that synth, as opposed to 3 seperate command sets, the one string, gives you several outcomes. i cant think how to exlaine it simply really but it makes sence to ask, 1&2? : 1? or 2? : do this..
Inviato Tue 16 Aug 11 @ 6:40 pm
Actually I made a mistake in the explanation the last bit wont work
var 1 ? var 2 ? if var 1 and var 2 is true : if var 1 is true but var 2 is false : var 2 ? if var 1 is false but var 2 is true : if var 1 and var 2 are false
maybe a simpler way to explain it is you are asking a question
var 'shift' ? action if shifted : action if not shifted
but in the answer you are asking another question
var 'hotcue_delete' ? action if 'hotcue_delete' : action if not 'hotcue_delete'
all together it looks like this
var 'shift' ? action if shifted & var 'hotcue_delete' ? action if 'hotcue_delete' : action if not 'hotcue_delete' : action if not shifted & var 'hotcue_delete' ? action if 'hotcue_delete' : action if not 'hotcue_delete'
var 1 ? var 2 ? if var 1 and var 2 is true : if var 1 is true but var 2 is false : var 2 ? if var 1 is false but var 2 is true : if var 1 and var 2 are false
maybe a simpler way to explain it is you are asking a question
var 'shift' ? action if shifted : action if not shifted
but in the answer you are asking another question
var 'hotcue_delete' ? action if 'hotcue_delete' : action if not 'hotcue_delete'
all together it looks like this
var 'shift' ? action if shifted & var 'hotcue_delete' ? action if 'hotcue_delete' : action if not 'hotcue_delete' : action if not shifted & var 'hotcue_delete' ? action if 'hotcue_delete' : action if not 'hotcue_delete'
Inviato Wed 17 Aug 11 @ 4:09 am
ah ok, so theres not three seperated variables? i was under the impression that it worked like this,
if 1&2 is true then do action A : do action B : if 1 is tru only then do action c : do action d : only 2 is true, then do action e : do f
if 1&2 is true then do action A : do action B : if 1 is tru only then do action c : do action d : only 2 is true, then do action e : do f
Inviato Wed 17 Aug 11 @ 6:32 am
Hi, I need some SYNTAX help in mapping the "ENDLESS ROTARY ENCODER BUTTONS" to do 2-Functions in the pitch slider to do BPM matching.
1.) To have fine adjustments of the pitch slider when rotating the buttons forward / backward to match the BMP easily in smaller and finer steps.
2.) To have coarse adjustments of the pitch slider when rotating the buttons forward / backward while the buttons is pushed down in order to have big and coarse steps.
DEFINITION FILES:
<button note="0x11" channel="12" name="PITCH_RESET" deck="1" /> (This is the value when the button is PUSH DOWN) (down 127 up-0)
<encoder cc="0x24" channel="12" name="PITCH_SLIDER" deck="1" /> (This is the value when the button is rotated forward /backward) (0-127)
MAPPERS FILES:
<map value="PITCH_RESET" action="pitch_reset 0%" /> (this line is working great)
<map value="PITCH_SLIDER" action="param_greater 0 ? pitch +0.01% : pitch -0.01%" /> (this line is working great with smooth & fine adjustments)
<>>>>>>>>>>>>>>>>>>>> ????????? The 3rd line where i should create a function that when you rotate forward / backward while the button is push down will have coarse and big adjustments of the pitch slider and fine adjustment when you rotate the button forward / backward when it is not pushed down.
This makes me crazy as i have already tried a lot of syntax variation but it does not work. Hope somebody could help me some few syntax to try it out. Thank you so much.
1.) To have fine adjustments of the pitch slider when rotating the buttons forward / backward to match the BMP easily in smaller and finer steps.
2.) To have coarse adjustments of the pitch slider when rotating the buttons forward / backward while the buttons is pushed down in order to have big and coarse steps.
DEFINITION FILES:
<button note="0x11" channel="12" name="PITCH_RESET" deck="1" /> (This is the value when the button is PUSH DOWN) (down 127 up-0)
<encoder cc="0x24" channel="12" name="PITCH_SLIDER" deck="1" /> (This is the value when the button is rotated forward /backward) (0-127)
MAPPERS FILES:
<map value="PITCH_RESET" action="pitch_reset 0%" /> (this line is working great)
<map value="PITCH_SLIDER" action="param_greater 0 ? pitch +0.01% : pitch -0.01%" /> (this line is working great with smooth & fine adjustments)
<>>>>>>>>>>>>>>>>>>>> ????????? The 3rd line where i should create a function that when you rotate forward / backward while the button is push down will have coarse and big adjustments of the pitch slider and fine adjustment when you rotate the button forward / backward when it is not pushed down.
This makes me crazy as i have already tried a lot of syntax variation but it does not work. Hope somebody could help me some few syntax to try it out. Thank you so much.
Inviato Fri 11 Nov 11 @ 2:27 am
Please don't ask your question on several threads... You have already started a new topic regarding your issue and you're getting answers there.
Thank you!
Thank you!
Inviato Fri 11 Nov 11 @ 3:36 am
I'm sorry, by the way thank you for your help it works fine. It solve the problems.
Inviato Fri 11 Nov 11 @ 4:38 am
"DEFINITION FILES:
<button note="0x11" channel="12" name="PITCH_RESET" deck="1" /> (This is the value when the button is PUSH DOWN) (down 127 up-0)
<encoder cc="0x24" channel="12" name="PITCH_SLIDER" deck="1" /> (This is the value when the button is rotated forward /backward) (0-127)
MAPPERS FILES:
<map value="PITCH_RESET" action="pitch_reset 0%" /> (this line is working great)
<map value="PITCH_SLIDER" action="param_greater 0 ? pitch +0.01% : pitch -0.01%" /> (this line is working great with smooth & fine adjustments)"
where is files in virtual dj and listing command ?
<button note="0x11" channel="12" name="PITCH_RESET" deck="1" /> (This is the value when the button is PUSH DOWN) (down 127 up-0)
<encoder cc="0x24" channel="12" name="PITCH_SLIDER" deck="1" /> (This is the value when the button is rotated forward /backward) (0-127)
MAPPERS FILES:
<map value="PITCH_RESET" action="pitch_reset 0%" /> (this line is working great)
<map value="PITCH_SLIDER" action="param_greater 0 ? pitch +0.01% : pitch -0.01%" /> (this line is working great with smooth & fine adjustments)"
where is files in virtual dj and listing command ?
Inviato Sat 12 Nov 11 @ 2:29 pm