Skip to content

Commit

Permalink
[ICP-4628] Reduce ramp time for the device to work correctly using lo…
Browse files Browse the repository at this point in the history
…cal execution. (SmartThingsCommunity#3009)

* [ICP-4628] Reduce ramp time for the device to work correctly using local execution.

* [ICP-4628] Fixed prod and model IDs.

* [ICP-4628] Make this change work for all 4 Honeywell dimmers.

* [ICP-4628] Configuration size and value fix.
  • Loading branch information
ALamchaS authored and greens committed Apr 17, 2018
1 parent 0473cdc commit 941418d
Showing 1 changed file with 22 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -93,10 +93,22 @@ def installed() {
// Device-Watch simply pings if no device events received for 32min(checkInterval)
sendEvent(name: "checkInterval", value: 2 * 15 * 60 + 2 * 60, displayed: false, data: [protocol: "zwave", hubHardwareId: device.hub.hardwareID, offlinePingable: "1"])
def commands = refresh()
if (zwaveInfo.mfr.equals("001A")) {
if (zwaveInfo?.mfr?.equals("001A")) {
commands << "delay 100"
//for Eaton dimmers parameter 7 is ramp time. We set it to 1s for devices to work correctly with local execution
commands << zwave.configurationV1.configurationSet(configurationValue: [1], parameterNumber: 7, size: 1).format()
} else if (isHoneywellDimmer()) {
//Set ramp time to 1s for this device to turn off dimmer correctly when current level is over 66.
commands << "delay 100"
//Parameter 7 - z-wave ramp up/down step size, Parameter 8 - z-wave step interval equals configurationValue times 10 ms
commands << zwave.configurationV1.configurationSet(configurationValue: [1], parameterNumber: 7, size: 1).format()
commands << "delay 200"
commands << zwave.configurationV1.configurationSet(configurationValue: [0, 1], parameterNumber: 8, size: 2).format()
commands << "delay 200"
//Parameter 7 - manual operation ramp up/down step size, Parameter 8 - z-wave manual operation interval equals configurationValue times 10 ms
commands << zwave.configurationV1.configurationSet(configurationValue: [1], parameterNumber: 9, size: 1).format()
commands << "delay 200"
commands << zwave.configurationV1.configurationSet(configurationValue: [0, 1], parameterNumber: 10, size: 2).format()
}
response(commands)
}
Expand Down Expand Up @@ -248,3 +260,12 @@ def refresh() {
}
delayBetween(commands, 100)
}

def isHoneywellDimmer() {
zwaveInfo?.mfr?.equals("0039") && (
(zwaveInfo?.prod?.equals("5044") && zwaveInfo?.model?.equals("3033")) ||
(zwaveInfo?.prod?.equals("5044") && zwaveInfo?.model?.equals("3038")) ||
(zwaveInfo?.prod?.equals("4944") && zwaveInfo?.model?.equals("3038")) ||
(zwaveInfo?.prod?.equals("4944") && zwaveInfo?.model?.equals("3130"))
)
}

0 comments on commit 941418d

Please sign in to comment.