From 54a4620c9bc1ff0318a0c398a9c35e346e9a6b40 Mon Sep 17 00:00:00 2001 From: Donald Kirker Date: Thu, 2 Feb 2017 22:00:49 -0800 Subject: [PATCH 1/4] DEVC-488 Add fingerprint for DL15S In-wall Switch --- devicetypes/smartthings/zigbee-switch.src/zigbee-switch.groovy | 1 + 1 file changed, 1 insertion(+) diff --git a/devicetypes/smartthings/zigbee-switch.src/zigbee-switch.groovy b/devicetypes/smartthings/zigbee-switch.src/zigbee-switch.groovy index 5b66e83..34192de 100644 --- a/devicetypes/smartthings/zigbee-switch.src/zigbee-switch.groovy +++ b/devicetypes/smartthings/zigbee-switch.src/zigbee-switch.groovy @@ -23,6 +23,7 @@ metadata { fingerprint profileId: "0104", inClusters: "0000, 0003, 0006", outClusters: "0003, 0006, 0019, 0406", manufacturer: "Leviton", model: "ZSS-10", deviceJoinName: "Leviton Switch" fingerprint profileId: "0104", inClusters: "0000, 0003, 0006", outClusters: "000A", manufacturer: "HAI", model: "65A21-1", deviceJoinName: "Leviton Wireless Load Control Module-30amp" fingerprint profileId: "0104", inClusters: "0000, 0003, 0004, 0005, 0006", outClusters: "0003, 0006, 0008, 0019, 0406", manufacturer: "Leviton", model: "DL15A", deviceJoinName: "Leviton Lumina RF Plug-In Appliance Module" + fingerprint profileId: "0104", inClusters: "0000, 0003, 0004, 0005, 0006", outClusters: "0003, 0006, 0008, 0019, 0406", manufacturer: "Leviton", model: "DL15S", deviceJoinName: "Leviton Lumina RF Switch" } // simulator metadata From 1800ea2bad1eae686290f51255ed58b7b89fc1fb Mon Sep 17 00:00:00 2001 From: Zach Varberg Date: Fri, 3 Feb 2017 11:55:45 -0600 Subject: [PATCH 2/4] Manually call on with setLevel This is to work around misbehaving devices that don't properly honor the move to level with on off command. This resolves: https://smartthings.atlassian.net/browse/DPROT-238 --- .../zigbee-dimmer-power.src/zigbee-dimmer-power.groovy | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/devicetypes/smartthings/zigbee-dimmer-power.src/zigbee-dimmer-power.groovy b/devicetypes/smartthings/zigbee-dimmer-power.src/zigbee-dimmer-power.groovy index 4bef6a9..2b34df5 100644 --- a/devicetypes/smartthings/zigbee-dimmer-power.src/zigbee-dimmer-power.groovy +++ b/devicetypes/smartthings/zigbee-dimmer-power.src/zigbee-dimmer-power.groovy @@ -97,7 +97,7 @@ def on() { } def setLevel(value) { - zigbee.setLevel(value) + zigbee.setLevel(value) + (value?.ToInteger() > 0 ? zigbee.on() : []) } /** From e019d22affda69ea36659278f0097e1814460f15 Mon Sep 17 00:00:00 2001 From: Zach Varberg Date: Fri, 3 Feb 2017 16:22:20 -0600 Subject: [PATCH 3/4] Fix typo on toInteger zigbee dimmer power This relates to: https://smartthings.atlassian.net/browse/DPROT-238 --- .../zigbee-dimmer-power.src/zigbee-dimmer-power.groovy | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/devicetypes/smartthings/zigbee-dimmer-power.src/zigbee-dimmer-power.groovy b/devicetypes/smartthings/zigbee-dimmer-power.src/zigbee-dimmer-power.groovy index 2b34df5..a781e77 100644 --- a/devicetypes/smartthings/zigbee-dimmer-power.src/zigbee-dimmer-power.groovy +++ b/devicetypes/smartthings/zigbee-dimmer-power.src/zigbee-dimmer-power.groovy @@ -97,7 +97,7 @@ def on() { } def setLevel(value) { - zigbee.setLevel(value) + (value?.ToInteger() > 0 ? zigbee.on() : []) + zigbee.setLevel(value) + (value?.toInteger() > 0 ? zigbee.on() : []) } /** From 3905d482350d46da1bfbecd806e849b0032c9ba2 Mon Sep 17 00:00:00 2001 From: Lars Finander Date: Mon, 6 Feb 2017 12:31:23 -0700 Subject: [PATCH 4/4] DVCSMP-2395 Update OpenT2T with bugfixes --- .../opent2t-smartapp-test.groovy | 28 +++++++++++-------- 1 file changed, 16 insertions(+), 12 deletions(-) diff --git a/smartapps/opent2t/opent2t-smartapp-test.src/opent2t-smartapp-test.groovy b/smartapps/opent2t/opent2t-smartapp-test.src/opent2t-smartapp-test.groovy index d9e731a..9951cfa 100644 --- a/smartapps/opent2t/opent2t-smartapp-test.src/opent2t-smartapp-test.groovy +++ b/smartapps/opent2t/opent2t-smartapp-test.src/opent2t-smartapp-test.groovy @@ -51,7 +51,7 @@ definition( //Device Inputs preferences { - section("Allow to control these things...") { + section("Allow OpenT2T to control these things...") { input "contactSensors", "capability.contactSensor", title: "Which Contact Sensors", multiple: true, required: false input "garageDoors", "capability.garageDoorControl", title: "Which Garage Doors?", multiple: true, required: false input "locks", "capability.lock", title: "Which Locks?", multiple: true, required: false @@ -329,34 +329,38 @@ private getDeviceType(device) { switch (it.name.toLowerCase()) { case "switch": deviceType = "switch" - break - case "switch level": - deviceType = "light" + if (caps.any { it.name.toLowerCase() == "power meter" }) { + return deviceType + } + if (caps.any { it.name.toLowerCase() == "switch level" }) { + deviceType = "light" + return deviceType + } break case "contact sensor": deviceType = "contactSensor" - break + return deviceType case "garageDoorControl": deviceType = "garageDoor" - break + return deviceType case "lock": deviceType = "lock" - break + return deviceType case "video camera": deviceType = "camera" - break + return deviceType case "motion sensor": deviceType = "motionSensor" - break + return deviceType case "presence sensor": deviceType = "presenceSensor" - break + return deviceType case "thermostat": deviceType = "thermostat" - break + return deviceType case "water sensor": deviceType = "waterSensor" - break + return deviceType default: break }