BrightenWithRate: Variable Dimmer Ramp Rates (DISCONTINUED)

Posted on
Tue Apr 17, 2012 12:31 pm
nsheldon offline
Posts: 2469
Joined: Aug 09, 2010
Location: CA

BrightenWithRate: Variable Dimmer Ramp Rates (DISCONTINUED)

BrightenWithRate 1.02

NOTE: This AppleScript Attachment is obsolete. While this will work in Indigo 5 and 6, I've created the Dimmer Extender plugin which does everything this AppleScript does and much more.

I've created an Indigo Pro 4 and 5 compatible Attachment AppleScript which allows you to set the on-level (brightness) of an INSTEON dimmable device, specifying a ramping time that is different from the device's programmed default ramp rate.

This has been tested and found to work on Smarthome SwitchLinc Dimmers, LampLinc Dimmers and KeypadLinc Dimmers. It should also work on In-Line Linc Dimmers and the dual-band versions of these devices. It may or may not work on other INSTEON dimmable devices (like ICON dimmers).

Changes:

1.02: Slightly changed the way log messages show up in Indigo to make it more clear that the messages are coming from the script and not from Indigo. It also now allows any communication (no acknowledgement) errors to appear.
1.0: Initial release.

Installation:

Download the zip file and (if it isn't done automatically) decompress it. A folder containing a Read Me file and the BrightenWithRate.scpt file will be created.

Put the BrightenWithRate.scpt file in the Attachments folder for the version of Indigo Pro you are using. The path to the folder is listed below for the specific Indigo Pro version being used.

Indigo Pro 4:
/Library/Application Support/Perceptive Automation/Indigo 4/Scripts/Attachments

Indigo Pro 5:
/Library/Application Support/Perceptive Automation/Indigo 5/Scripts/Attachments

Indigo Pro 6:
/Library/Application Support/Perceptive Automation/Indigo 6/Scripts/Attachments


Once the file has been moved into one of the above folders, reload attachments from within the Indigo Pro client (in Indigo 5, that means going to the "Plugins" menu and selecting "Reload Libraries and Attachments").

Usage:

Within an Indigo "Execute Script" AppleScript action, simply enter the text

BrightenWithRate(<bright percent>,<ramp time seconds>,"<device name>")

where <bright percent> is the brightness on-level percentage, from 0 to 100, you'd like the device change to, <ramp time seconds> is the number of seconds (including fractional seconds) desired, and <device name> is the name of the device in Indigo. Some important things to remember: specifying a brightness of 0, perhaps obviously, actually turns off the device in the ramp time. Note that INSTEON dimmers that support per-request ramp rates only provide 16 different ramp rates, so this function simply chooses the available ramp rate closest to the number of seconds specified when calling this function. Also note that ramp times are based on going from fully off (0 percent) to fully on (100 percent).
Last edited by nsheldon on Sat Apr 28, 2012 12:43 pm, edited 1 time in total.

Posted on
Tue Apr 17, 2012 1:15 pm
matt (support) offline
Site Admin
User avatar
Posts: 21411
Joined: Jan 27, 2003
Location: Texas

Re: Attachment to get Different Dimmer Ramp Rate for Each Ac

Cool -- thanks for putting this together for everyone!

Image

Posted on
Tue Apr 17, 2012 2:54 pm
nsheldon offline
Posts: 2469
Joined: Aug 09, 2010
Location: CA

Re: Attachment to get Different Dimmer Ramp Rate for Each Ac

Glad I could contribute!

UPDATE: The download is also now available in the Indigo User Contribution Library here.

Posted on
Tue Apr 17, 2012 8:16 pm
nsheldon offline
Posts: 2469
Joined: Aug 09, 2010
Location: CA

Re: Attachment to get Different Dimmer Ramp Rate for Each Ac

Additional Test Results

I just tested the script on the SwitchLinc Dimmer (dual-band) (model 2477D, firmware 40) that I have in my hallway. That model responds to the brightness+rate commands as expected, but treats the ramp rate as the new default rate (i.e. it doesn't revert to the saved default). Interestingly (or perhaps as one might hope), it doesn't affect ramp rates associated with other device links (like a 3-way switch setup). However, it does mean that you'll probably want to use the BrightenWithRate function every time you control the 2477D through Indigo.

EDIT: It appears that, regardless of dimmer module used, if another normal brighten/dim command is sent while the module is in the middle of ramping up or down using the previous non-default rate, the module will begin brightening/dimming to the new level, but continuing to use the non-default rate until the entire brighten/dim cycle is complete. Once complete, it reverts to the default (except for the 2477D that is).

Posted on
Sat Apr 28, 2012 12:43 pm
nsheldon offline
Posts: 2469
Joined: Aug 09, 2010
Location: CA

Re: Attachment to get Different Dimmer Ramp Rate for Each Ac

Updated original post to reflect the latest version and link.

Page 1 of 1

Who is online

Users browsing this forum: No registered users and 3 guests

cron