Home AMX User Forum NetLinx Studio

Turning ON all Outputs of Channels in a DEVCHAN

Greetings,

I have a DEVCHAN which contains a keypad button on each of multiple keypads. Is there a way to light up ALL of the keypad feedback LEDs in the DEVCHAN with one line of code?

ON [dcMY_DEVCHAN] or things similar do not work.

Thank you.

Comments

  • Use a For loop? (2 lines of code)
  • Greetings,

    I have a DEVCHAN which contains a keypad button on each of multiple keypads. Is there a way to light up ALL of the keypad feedback LEDs in the DEVCHAN with one line of code?

    ON [dcMY_DEVCHAN] or things similar do not work.

    Thank you.

    Hm, should work......
    Are these channels some kind of mutually exclusive?
    Could you post the affected code?
  • TurnipTruckTurnipTruck Posts: 1,485
    I do not have affected code at this point. It is just something that I have tried in the past without success. I will be working on code soon that will require this function. If I have trouble I'll post code.

    Thank you!
  • This works fine
    DEFINE_DEVICE
    dvRelais = 5001:4:0
    dvPanel = 10001:1:0
    
    DEFINE_VARIABLE
    DEVCHAN dcMyRelais[] = 
    {
    	{ dvRelais,1 },
    	{ dvRelais,2 },
    	{ dvRelais,3 },
    	{ dvRelais,4 }
    }
    
    DEFINE_EVENT
    BUTTON_EVENT[dvPanel,101]
    {
    	PUSH:
    	{
    		ON[dcMyRelais]
    	}
    	RELEASE:
    	{
    		OFF[dcMyRelais]
    	}
    }
    
Sign In or Register to comment.