Quick Sign In:  

Forum: Old versions

Topic: Script for mapping LED's

This topic is old and might contain outdated or incorrect information.

I'm looking to map some of my LED buttons on an Xone K2 controller. At present these buttons are mapped to send commands to Freestyler DMX software using the Freestyler8 plugin. There are 14 buttons mapped as follows which toggle a lighting cue on/off:

BUTTON_A_AMBER - set $fsvalue 255 & set $fscommand 46
BUTTON_B_AMBER - set $fsvalue 255 & set $fscommand 47
BUTTON_C_AMBER - set $fsvalue 255 & set $fscommand 48
........ETC

The problem I have is that I don't think Freestyler returns a message to VDJ to activated the LED to get the on/off function when the command is active. I have posted on the Freestyler8 feed about this but I think the above commands is not intended to be mapped to a button, it was designed as a POI.

The commands on these buttons work perfectly for me, but can I map the LED's of these buttons to perform independently of the command "set $fsvalue 255 & set $fscommand 46"? Below is what I would like to do.

Press BUTTON_A_AMBER, action - LED_BUTTON_A_AMBER on - LED_BUTTON_B_AMBER off & LED_BUTTON_C_AMBER off & LED_BUTTON_D_AMBER off...........& LED_BUTTON_N_AMBER off, then if BUTTON_A_AMBER is pressed again LED_BUTTON_A_AMBER off.

Then the same action for each LED button up to button N

Press BUTTON_B_AMBER, action - LED_BUTTON_B_AMBER on - LED_BUTTON_A_AMBER off & LED_BUTTON_C_AMBER off & LED_BUTTON_D_AMBER off...........& LED_BUTTON_N_AMBER off, then if BUTTON_B_AMBER is pressed again LED_BUTTON_B_AMBER off.

Press BUTTON_C_AMBER, action - LED_BUTTON_C_AMBER on - LED_BUTTON_A_AMBER off & LED_BUTTON_B_AMBER off & LED_BUTTON_D_AMBER off...........& LED_BUTTON_N_AMBER off, then if BUTTON_C_AMBER is pressed again LED_BUTTON_C_AMBER off.

.......etc through to BUTTON_N

Can anyone help?
 

Posted Wed 29 Oct 14 @ 4:06 am
On the buttons:
BUTTON_A_AMBER - set '$fsvalue' 255 & set '$fscommand' 46 & var_equal '$myled' 1 ? set '$myled' 0 : set '$myled' 1
BUTTON_B_AMBER - set '$fsvalue' 255 & set '$fscommand' 47 & var_equal '$myled' 2 ? set '$myled' 0 : set '$myled' 2
BUTTON_C_AMBER - set '$fsvalue' 255 & set '$fscommand' 48 & var_equal '$myled' 3 ? set '$myled' 0 : set '$myled' 3
...

On the leds:
LED_BUTTON_A_AMBER - var_equal '$myled' 1
LED_BUTTON_B_AMBER - var_equal '$myled' 2
LED_BUTTON_C_AMBER - var_equal '$myled' 3
...
 

Posted Wed 29 Oct 14 @ 12:22 pm
Many thanks, worked a charm!
 

Posted Wed 29 Oct 14 @ 3:09 pm


(Old topics and forums are automatically closed)