Levels & Multi-State Buttons
hodeyp
Posts: 104
Hi, I am not sure if what I want to do is possible but seems that it should be...
I have created a lutron module (the amx module is way too complex for the basic functionality i need) instead of setting up 16 channels for each unit I have written the module so each unit has a level attached to it to define what scene to use.
This is working well and by combining levels between the tp and the device makes it quite simple to set the current scene using a button & a level control value.
Now for the problem - How can I get the button to change state if it is the current scene? I would prefer to do this without using channels as I was looking to get away from this with the levels concept. I have tried this using the multistate buttons but the lose the ability to set the level control value...
I have created a lutron module (the amx module is way too complex for the basic functionality i need) instead of setting up 16 channels for each unit I have written the module so each unit has a level attached to it to define what scene to use.
This is working well and by combining levels between the tp and the device makes it quite simple to set the current scene using a button & a level control value.
Now for the problem - How can I get the button to change state if it is the current scene? I would prefer to do this without using channels as I was looking to get away from this with the levels concept. I have tried this using the multistate buttons but the lose the ability to set the level control value...
0
Comments
A couple of assumptions: this is for Homeworks Interactive and you have 15 button KPs, and have associated a level to each button on each KP.
There are other threads which show a few different ways to easily work with HWI, tracking all LED states (and all lighting levels if desired) is easily handled in NetLinx. I found some of the ideas useful as future alternatives.
Get button to change state if it is the current scene -- I think you are looking for a multi-state bargraph, not just multi-state.
Do a SEND_LEVEL to a multi-state bargraph button, you can use different colors/text/font if you are using multiple on-states from the HWI side. This level can be the button state directly from Lutron.
I set up an integer array, so I get an ON for anything other than 0 (ie. if Lutron says "2" and is blinking fast, mine is just ON) - a better way is to use a structure. Again, check other threads. Do a send_level on any change from Lutron and maybe in a periodic timeline to catch up.
You still want a channel event to be able to send Lutron command to press that button. Then let Lutron tell you what really happened.
If this is not quite the level of detail you wanted, just say so, lots of talented and experienced people who post have lots of experience with HWI.
I'm not quite getting how you will be doing this with a lighting button - seems to me they are on, off, or blinking, but in case I'm just missing something, bargraph is what you want. Note, it doesn't have to resemble a bargraph in any way, shape or form. You can make your states as unique as you like. The only thing to be careful about is setting the range on the level port to match your control levels (if your control level has 16 states, make sure the bargraph button has 16 states AND has a level range of 1 to 16).
I have 3 units covering different rooms and each room has between 4 and 8 scene settings.
For each unit the touchpanel has the same number of buttons as there are scenes (e.g. lounge has 6 buttons, one for each scene)
My thoughts was instead of having to program 16 butons for each unit to use COMBINE_LEVELS and buttons with the 'Level Control Value' set to the scene I wanted to select.
Drawback is that I can't get the button to change to reflect status! Issue with using the bargraph is that I would effectively have to create 16 states, 15 of them identical and the scene the button represents being the highlight format. I was hoping to do something neat by using levels but the feedback issue seems to be making this a bit of a fudge...
Not having used levels heavily before this was quite experimental, looks like my experiment may have failed
Here are my assumptions:
You have a level that goes from 1 to 16. Depending what the level value is it dictates which scene is selected.
If that is true then you should be able to:
Each state of the bargraph (16 total states) says what scene is selected.
First
-change that "button type" to a "multistate bargraph" and the "level function" to display only.
Second
-Create 16 other "general" buttons, these will be the "level Control" buttons so you can discretely select a specific scene.
-on the programming tab of the properties for these buttons you will need to do the following:
--Change the "level control type" to "absolute"
---Set the level code and level port to match the multistate bargraph
---The "Level Control Value" will be the value the button sets the level to when it is pressed
What should happen when loaded is when pressing one of these "Direct Level Control" buttons is it will set the level to a specified value which will cause the multistate bargraph to display the appropriate state. The changing of the levels value will generate a LEVEL_EVENT so it can be programatically dealt with.
This means if you are already controlling the Lutron unit via a level this should just work.
FYI there is a way to do all this with a single button/bargraph, but lets leave that for later. . .