Accesso rapido:  

Forum: General Discussion

Topic: Script School - Page: 36.2
Hello friends how are you? I hope I don't bother you, I want to check if you can help me with a script, what I want is to reproduce the event scheduler automatically, I already managed to do it with the keyboard omnit, automatically when opening the program the event scheduler opens but what I want the program to know what day of the week it is and the event of the day opens in the event scheduler, that is, if today is Monday, the program knows that it is Monday and the Monday event opens in the scheduler, I don't know if I know can
 

Inviato Sat 20 May 23 @ 11:55 pm
locoDogPRO InfinityModeratorMember since 2013
This will give you a number between 0 & 6, zero = sunday

set $day `countdown '2023/01/01 00:00' '%DD' & param_cast 'int_trunc' & param_mod 7`


so imagining you have events named as the day of the week, then oninint could look something like this
set $day `countdown '2023/01/01 00:00' '%DD' & param_cast 'int_trunc' & param_mod 7` & var $day 0 ? eventscheduler_start 'sunday' : var $day 1 ? eventscheduler_start 'monday' : var $day 2 ? eventscheduler_start 'tuesday' : ... 


I'll leave you to fill the rest of the days.
There are other ways this could work but it depends on how eventscheduler is configured.
 

Inviato Sun 21 May 23 @ 12:47 am
is it possible to fully disable split pages (without ´select split page none´)

my pads keep enabling the split mode over and over again

https://youtu.be/F8UAE8op7cg

something like

press button1 page1
hold button1 page1


sorry im a total newb to this
 

Inviato Fri 26 May 23 @ 2:21 pm
Has anyone had any luck with scripting a broadcast to a shoutcast server? I want to connect/broadcast to a shoutcast server at a specific time, play a playlist, and end the session and disconnect from the broadcast at a specific time? I cant seem to find anything via search on here. I would really appreciate the help.
 

Inviato Thu 01 Jun 23 @ 9:00 am
locoDogPRO InfinityModeratorMember since 2013
everything is accessible via setting script
setting broadcastServer "PRESET" for the preset
& broadcast radio to start.
 

Inviato Thu 01 Jun 23 @ 8:21 pm
Thanks for your reply, I realised where I was going wrong. I was preparing the script in me word on my Mac. Word uses different ‘ and “ quotes to vdj script so it was ignoring my commands. It’s now doing what I want and I’m adding more to the process. Thx again
 

Inviato Fri 02 Jun 23 @ 9:53 am
SveninoPRO InfinityMember since 2009
If the key of a song is changed, I want to slowly return to the original key with a script.
The process should take about 15-20 seconds per semitone.
I tried the following script wich unfortunately doesn't work:

repeat_start 'KRwait' 500ms & deck left key_smooth +0.02 & 
deck left key_smooth 0 ?
repeat_stop 'KRwait'


I don't know how to check if the original key has already been reached.
In addition, KEY_SMOOTH must be +0.00x if the key has been set lower beforehand.
Otherwise, KEY_SMOOTH would have to be -0.00x...

Unfortunately, I program too rarely to find the solution on my own.
Can anyone help?
Thanks in advance
 

Inviato Sat 22 Jul 23 @ 4:23 pm
locoDogPRO InfinityModeratorMember since 2013
key_smooth is between 13 whole semitones -6 to +6, across a dial 0.0 to 1.0, 0.5 being the natural key

deck left key_smooth 0 ?

this won't work as a comparison, key_smooth is a little weird how it works compared this way, it only compares key_move [whole semi tones from neutral]

This would be the correct comparison for accurate natural key
deck left param_equal `key_smooth` 0.5 ?

So lets work out some numbers

1 is our key_smooth dial range, 13 keys, 20 seconds, 2 steps every a second

1 / 13 / 20 / 2
~0.001923 per step

we're dealing with small floats [that have been rounded] we get rounding errors, we might not get back to exactly 0.5, so we'll deal with that
NEUTRAL KEY + 1 STEP
0.5 + 0.001923
0.501923

NEUTRAL KEY - 1 STEP
0.5 - 0.001923
0.498077

param_smaller `key_smooth` 0.501923 ? WE ARE MORE THAN 1 STEP ABOVE NATURAL, GO DOWN :
WE ARE BELOW NATURAL param_bigger `key_smooth` 0.498077 ? WE ARE MORE THAN 1 STEP BELOW NATURAL, GO UP :
WE ARE LESS THAN 1 STEP AWAY FROM NATURAL key_smooth 0.5 & repeat_stop 'KRwait'

repeat_start 'KRwait' 500ms & param_smaller `key_smooth` 0.501923 ? key_smooth -0.001923 : param_bigger `key_smooth` 0.498077 ? key_smooth +0.001923 : key_smooth 0.5 & repeat_stop 'KRwait'

I'll invoice you later XD
 

Inviato Sat 22 Jul 23 @ 8:06 pm
SveninoPRO InfinityMember since 2009
Thank You very much Locodoc, changed the parameters a bit so that the reseting is a bit slower, and the other deck is changing together (If 2 songs are playing in sync):

deck right repeat_start 'KRwait' 250ms & 
deck right param_smaller `key_smooth` 0.50041667 ? deck right key_smooth -0.00041667 &
deck left key_smooth -0.00041667 :
deck right param_bigger `key_smooth` 0.49958333 ? deck right key_smooth +0.00041667 &
deck left key_smooth +0.00041667 :
deck right key_smooth 0.5 & deck right repeat_stop 'KRwait'


This works fine but now a new problem arises:

Even with
repeat_stop 'KRwait'

on another button, 'KRwait' cannot be stopped. It goes on and on. Sometimes, however, I also want to change a key WITHOUT it slowly receding on its own. This is no more possible at the moment. I change the Key of deck right (and want to keep this for a longer time) and after 30 secs the key is back at the original.
What is the problem now?
 

Inviato Sat 22 Jul 23 @ 9:42 pm
locoDogPRO InfinityModeratorMember since 2013
Don't know, I can't see what you're doing.
I'd guess that repeat_stop needs the deck specifying.
 

Inviato Sat 22 Jul 23 @ 11:14 pm
adjnuPRO InfinityMember since 2005
I have 2 NVII W/4chs, i would like to assign controller 1 to decks 1 and 2 only and assign controller 2 to decks 3 and 4 only.
 

Inviato Sun 23 Jul 23 @ 9:38 pm
locoDogPRO InfinityModeratorMember since 2013


see the "deck" drop down, do it there.
 

Inviato Sun 23 Jul 23 @ 9:43 pm
Can a professional help me create a script for (2 Items);
+ When a new TRACK is LOADED, disengage BEALOCK if engaged.
+ When enabling PTCH LOCK, check if BEAT LOCK is active, if YES, Disengage BEATLOCK and Keep PITCH LOCK ACTIVE.

 

Inviato Mon 21 Aug 23 @ 2:27 pm
locoDogPRO InfinityModeratorMember since 2013
keyboard mapping has onsongload event, so your beatlock is easy, no query needed you're just switching off

2
pitch_lock & pitch_lock ? deck all beatlock off :
 

Inviato Mon 21 Aug 23 @ 5:02 pm
Hi,

short question. Is there a possibility to just return some information from
broadcast_message
?
I only want to display the connected clients.

Thx in advanced
 

Inviato Thu 24 Aug 23 @ 6:23 am
locoDogPRO InfinityModeratorMember since 2013
For 2 deck Line 5932, for 4 deck line 5844
change action to
action="broadcast_message & param_cast 'text' 27"


A bit of a rough way to do it, but I don't know what params this action accepts other than "full" but this cast is good upto 999 clients.

A bit of a strange ask, is it just for clarities sake?
 

Inviato Thu 24 Aug 23 @ 6:04 pm
Hey Locodog,

thank you for your answer. The usecase is to have a broadcast button on a controller skin that, when broadcasting, shows the number of connected clients.
The standard text is a bit long for the space of a button.

 

Inviato Fri 25 Aug 23 @ 8:19 am
locoDogPRO InfinityModeratorMember since 2013
Ah then the above will still be too long.

you'll want something like this

broadcast_message & param_cast 'text' 27 &
param_contains " 1 " ? get_text "1" :
param_contains " 2 " ? get_text "2" :
param_contains " 3 " ? get_text "3" :
param_contains " 4 " ? get_text "4" :
param_contains " 5 " ? get_text "5" :
keep going till
param_contains "10" ? get_text "10" :
then keep going as far as you think needed
 

Inviato Fri 25 Aug 23 @ 9:15 am
Baldy68PRO InfinityMember since 2019
Hi, I am in preparation to make a custom controller (dubstation) for VDJ software. First I was thinking if there was possible to route the five stem outputs to five audio outputs in audio settings to route all stems live to another software, but until that will be doable (if ever) I was thinking maybe it is better to use VDJ as the only software since it is so powerful with scripting.

For testing purpose, I am now using a midimix (amongst other midi controllers) to try out if my idea is even possible to do.

Without being too technical the first problem I need to get solved is how to map a fader to behave like a crossfader for stems. In other words, I need to crossfade between the stems from two decks, where I am using one crossfader for every "pair" of stems meaning there will be five crossfaders for stems only. (for example, one crossfader for smooth transitions between Bass from deck one and Bass from deck two, and four more crossfaders for the other 4 stems). This will result in full volume on deck one when all five faders are down, and full volume on deck two when all faders are in top position, and a mix of both decks when the faders are in the middle position.
I have read about verbs and parameters and have no problems mapping any buttons, faders or knobs, but to make this crossfading function I can't find the working parameters. I tried adding 0%-100% and 100%-0% and 0.0-1.0 and 1.0-0.0 but either the fader doesn't work at all or as default, meaning 0-100%

When I get this working, I need to have three effects (echo, reverb and flanger resulting in three knobs for each crossfader) affecting only that "pair" of stems, but this shouldn't be any problems since I have seen there already are effects that affects a specific stem only?

If I could be pointed in the right way to learn how to script these things I will be forever grateful! :-D
 

Inviato Sun 27 Aug 23 @ 3:35 pm
locoDogPRO InfinityModeratorMember since 2013
nothing & nothing & param_invert & param_multiply 0.5 & deck 1 eq_low & param_multiply 2 & param_invert & param_multiply 0.5 & deck 2 eq_low

See this example on a custom_button [dial version]
ignore the nothing & nothing, that's just a quirk of custom_buttons with param manipulation

invert the value so the dial is mapped backwards, and half it, then it's good for deck 1, then multiply by 2 and invert it, [so it once again is the value from the dial], then half it and it's good the send to deck 2
 

Inviato Sun 27 Aug 23 @ 4:01 pm
78%