From dd308f6d8fee1a5e1a52b8148ad7afbac4bb4a91 Mon Sep 17 00:00:00 2001 From: juano2310 Date: Tue, 2 Aug 2016 18:53:28 -0400 Subject: [PATCH 1/3] SSVD-1823 - Name change --- .../zwave-dimmer-switch-generic.groovy} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename devicetypes/smartthings/{zwave-dimmer-switch.src/zwave-dimmer-switch.groovy => zwave-dimmer-switch-generic.src/zwave-dimmer-switch-generic.groovy} (100%) diff --git a/devicetypes/smartthings/zwave-dimmer-switch.src/zwave-dimmer-switch.groovy b/devicetypes/smartthings/zwave-dimmer-switch-generic.src/zwave-dimmer-switch-generic.groovy similarity index 100% rename from devicetypes/smartthings/zwave-dimmer-switch.src/zwave-dimmer-switch.groovy rename to devicetypes/smartthings/zwave-dimmer-switch-generic.src/zwave-dimmer-switch-generic.groovy From 534118a47a8bac49d17b58647b32cc200eb5da85 Mon Sep 17 00:00:00 2001 From: marstorp Date: Thu, 4 Aug 2016 16:47:13 -0700 Subject: [PATCH 2/3] Fix for SSVD-1605 and SSVD-1897, update of switch tile when speaker is turned on/off --- .../bose-soundtouch.groovy | 25 +++++++++++++------ 1 file changed, 18 insertions(+), 7 deletions(-) diff --git a/devicetypes/smartthings/bose-soundtouch.src/bose-soundtouch.groovy b/devicetypes/smartthings/bose-soundtouch.src/bose-soundtouch.groovy index 496797c..2d60bf8 100644 --- a/devicetypes/smartthings/bose-soundtouch.src/bose-soundtouch.groovy +++ b/devicetypes/smartthings/bose-soundtouch.src/bose-soundtouch.groovy @@ -64,8 +64,10 @@ metadata { } standardTile("switch", "device.switch", width: 1, height: 1, canChangeIcon: true) { - state "off", label: '${name}', action: "switch.on", icon: "st.Electronics.electronics16", backgroundColor: "#ffffff" - state "on", label: '${name}', action: "switch.off", icon: "st.Electronics.electronics16", backgroundColor: "#79b821" + state "on", label: '${name}', action: "switch.off", icon: "st.Electronics.electronics16", backgroundColor: "#79b821", nextState:"turningOff" + state "turningOff", label:'TURNING OFF', icon:"st.Electronics.electronics16", backgroundColor:"#ffffff" + state "off", label: '${name}', action: "switch.on", icon: "st.Electronics.electronics16", backgroundColor: "#ffffff", nextState:"turningOn" + state "turningOn", label:'TURNING ON', icon:"st.Electronics.electronics16", backgroundColor:"#79b821" } valueTile("1", "device.station1", decoration: "flat", canChangeIcon: false) { state "station1", label:'${currentValue}', action:"preset1" @@ -747,8 +749,16 @@ def cb_boseSetInput(xml, input) { */ def boseSetPowerState(boolean enable) { log.info "boseSetPowerState(${enable})" - queueCallback('nowPlaying', "cb_boseSetPowerState", enable ? "POWERON" : "POWEROFF") - return boseRefreshNowPlaying() + // Fix to get faster update of power status back from speaker after sending on/off + // Instead of queuing the command to be sent after the refresh send it directly via sendHubCommand + // Note: This is a temporary hack that should be replaced by a re-design of the + // DTH to use sendHubCommand for all commands + sendHubCommand(bosePOST("/key", "POWER")) + sendHubCommand(bosePOST("/key", "POWER")) + sendHubCommand(boseGET("/now_playing")) + if (enable) { + queueCallback('nowPlaying', "cb_boseConfirmPowerOn", 5) + } } /** @@ -787,10 +797,11 @@ def cb_boseSetPowerState(xml, state) { */ def cb_boseConfirmPowerOn(xml, tries) { def result = [] - log.warn "boseConfirmPowerOn() attempt #" + tries - if (xml.attributes()['source'] == "STANDBY" && tries > 0) { + def attempt = tries as Integer + log.warn "boseConfirmPowerOn() attempt #$attempt" + if (xml.attributes()['source'] == "STANDBY" && attempt > 0) { result << boseRefreshNowPlaying() - queueCallback('nowPlaying', "cb_boseConfirmPowerOn", tries-1) + queueCallback('nowPlaying', "cb_boseConfirmPowerOn", attempt-1) } return result } From 236c37290ebbf0f337d4d0e0ad49a1d2ac0f8de9 Mon Sep 17 00:00:00 2001 From: Vinay Rao Date: Mon, 8 Aug 2016 12:36:22 -0700 Subject: [PATCH 3/3] adding leviton switch to zigbee switch post certification --- 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 4440054..7e243f4 100644 --- a/devicetypes/smartthings/zigbee-switch.src/zigbee-switch.groovy +++ b/devicetypes/smartthings/zigbee-switch.src/zigbee-switch.groovy @@ -20,6 +20,7 @@ metadata { capability "Switch" fingerprint profileId: "0104", inClusters: "0000, 0003, 0004, 0005, 0006" + fingerprint profileId: "0104", inClusters: "0000, 0003, 0006", outClusters: "0003, 0006, 0019, 0406", manufacturer: "Leviton", model: "ZSS-10", deviceJoinName: "Leviton Switch" } // simulator metadata