Making a lighting slider

Plugin for the HAI family of security panels
ha_kiwi
New Member
New Member
Posts: 43
Joined: Mon May 28, 2007 7:19 am
Location: New Zealand
Contact:

Making a lighting slider

Postby ha_kiwi » Mon Sep 26, 2011 9:32 pm

I have the HAI lighting units working and I can dim and brighten to a set level but I would like to be able to have a slider that goes form 0 - 100 % for this can anyone show me how to do it ?

ha_kiwi
New Member
New Member
Posts: 43
Joined: Mon May 28, 2007 7:19 am
Location: New Zealand
Contact:

Re: Making a lighting slider

Postby ha_kiwi » Tue Sep 27, 2011 11:52 pm

OK with Davids help I got this far but it still doesn't work. Any help please ?
Capture.JPG
You do not have the required permissions to view the files attached to this post.

User avatar
CinemarDave
Site Admin
Site Admin
Posts: 10535
Joined: Fri Feb 07, 2003 8:56 am
Location: Planet Earth
Contact:

Re: Making a lighting slider

Postby CinemarDave » Wed Sep 28, 2011 11:12 am

The command needs to be MLHAI|001~Dim~5~{{value}} and do not use the continuous version of the slider use the release version.

ha_kiwi
New Member
New Member
Posts: 43
Joined: Mon May 28, 2007 7:19 am
Location: New Zealand
Contact:

Re: Making a lighting slider

Postby ha_kiwi » Thu Sep 29, 2011 5:07 am

OK Clearly I'm missing something with these sliders. I now have the command exactly as above. If I turn the light on by another button then the slider will allow me to Dim the light but not brighten it. It also jumps back to the start position each time i.e. does not stay at the dim level I have set. So my question is how do I get it to brighten and DIm and how do a I make the slider stay where i put it.
Any help once again would be much appreciated
Thanks
David

User avatar
mcascio
Founder
Founder
Posts: 8270
Joined: Tue Jan 28, 2003 4:03 pm
Location: Kenosha, Wi
Contact:

Re: Making a lighting slider

Postby mcascio » Thu Sep 29, 2011 9:20 am

Did you enter a variable in the label field of the slider?
Mario Cascio
Cinemar, Inc.
http://www.cinemaronline.com

ha_kiwi
New Member
New Member
Posts: 43
Joined: Mon May 28, 2007 7:19 am
Location: New Zealand
Contact:

Re: Making a lighting slider

Postby ha_kiwi » Thu Sep 29, 2011 2:53 pm

No I didn't - what should be in there ?

User avatar
ronsatter
Is there life beyond Cinemar?
Is there life beyond Cinemar?
Posts: 1304
Joined: Mon Dec 04, 2006 1:40 am
Location: San Leandro, CA
Contact:

Re: Making a lighting slider

Postby ronsatter » Thu Sep 29, 2011 10:40 pm

ha_kiwi wrote:No I didn't - what should be in there ?


I think if you are using this command:

MLHAI|001~Dim~5~{{value}}

then the variable in the label field of the slider would be:

{{value}}

Ron

PS - If you don't want to display the actual value on your slider (some percentage number like 46), then check the "Hide Value" box next to the label field.
If it ain't broke ... don't fix it!

User avatar
mcascio
Founder
Founder
Posts: 8270
Joined: Tue Jan 28, 2003 4:03 pm
Location: Kenosha, Wi
Contact:

Re: Making a lighting slider

Postby mcascio » Fri Sep 30, 2011 6:20 pm

ha_kiwi wrote:No I didn't - what should be in there ?


Actually, you wouldn't put {{value}} in the label field. You'll have to look in the list of Variables in MLServer, but one of them should represent the lighting value and will probably look something like: MLHAI_001_Lighting_xxx
Mario Cascio

Cinemar, Inc.

http://www.cinemaronline.com

ha_kiwi
New Member
New Member
Posts: 43
Joined: Mon May 28, 2007 7:19 am
Location: New Zealand
Contact:

Re: Making a lighting slider

Postby ha_kiwi » Sun Oct 02, 2011 8:33 pm

How on earth do I find the variable ? does the variable change for each lighting unit ?

User avatar
CinemarDave
Site Admin
Site Admin
Posts: 10535
Joined: Fri Feb 07, 2003 8:56 am
Location: Planet Earth
Contact:

Re: Making a lighting slider

Postby CinemarDave » Mon Oct 03, 2011 9:45 am

Each light would have a different server variable. In your case it is probably {{HAI_001_UNIT005_Value}}

ha_kiwi
New Member
New Member
Posts: 43
Joined: Mon May 28, 2007 7:19 am
Location: New Zealand
Contact:

Re: Making a lighting slider

Postby ha_kiwi » Thu Oct 06, 2011 4:54 am

OK I'm so close now it's drivin' me mad.

In the attached image you can see I have buttons to set the light to 50% or 75% etc if I use those buttons then the slider adjusts to display the value set however if I try to drag the slider it immediately returns to zero and turns the light off if it's on. Surely I can't be far away ?
Capture.JPG
You do not have the required permissions to view the files attached to this post.

User avatar
CinemarDave
Site Admin
Site Admin
Posts: 10535
Joined: Fri Feb 07, 2003 8:56 am
Location: Planet Earth
Contact:

Re: Making a lighting slider

Postby CinemarDave » Thu Oct 06, 2011 10:37 am

What does the MLServer event log look like when you drag and release the slider? Verbose logging,


Return to “MLHAI”

Who is online

Users browsing this forum: No registered users and 1 guest