Page 1 of 1

Light On/Off button highlight?

Posted: Mon Apr 09, 2018 1:06 am
by anderdea
What is the best way to do this. I’m assuming with flags but not clear on the process.
I have X10 IR controlled lights in my project. I want to add a direct ON button and a Direct OFF button. The ON light button is Yellow and the OFF light button is grayish. I want to stack them and have the yellow button appear when the light and that button is pressed for ON and then the grayish button to show when the next press turns the light off. No feedback here, just two buttons showing visually the two stages. Can this be done?

Re: Light On/Off button highlight?

Posted: Mon Apr 09, 2018 9:48 am
by DemoPad
You can do it with a single button / flag.

use the highlight image menu, and choose an alternate image for the button, which is set when the flag is on using the highlight image flag option.

Each time you press the button, toggle the flag, which will alter the button image back and forth, and have your actions dependent on the flag status:

Button actions:
Toggle Flag (which will change the image)
Send lights ON command dependent on flag being ON
Send lights OFF command dependent on flag being OFF

Re: Light On/Off button highlight?

Posted: Mon Apr 09, 2018 10:23 pm
by anderdea
Got it to work, thanks.