mirror of
https://github.com/mtan93/SmartThingsPublic.git
synced 2026-04-02 06:13:07 +01:00
Merge pull request #1429 from surfous/DVCSMP-2155_CHF-453-fix
Fix CHF-453 on ZigBee switch power DH
This commit is contained in:
@@ -84,18 +84,20 @@ def refresh() {
|
|||||||
|
|
||||||
def configure() {
|
def configure() {
|
||||||
log.debug "in configure()"
|
log.debug "in configure()"
|
||||||
configureHealthCheck()
|
return configureHealthCheck()
|
||||||
}
|
}
|
||||||
|
|
||||||
def configureHealthCheck() {
|
def configureHealthCheck() {
|
||||||
Integer hcIntervalMinutes = 12
|
Integer hcIntervalMinutes = 12
|
||||||
refresh()
|
|
||||||
sendEvent(name: "checkInterval", value: hcIntervalMinutes * 60, displayed: false, data: [protocol: "zigbee", hubHardwareId: device.hub.hardwareID])
|
sendEvent(name: "checkInterval", value: hcIntervalMinutes * 60, displayed: false, data: [protocol: "zigbee", hubHardwareId: device.hub.hardwareID])
|
||||||
|
return refresh()
|
||||||
}
|
}
|
||||||
|
|
||||||
def updated() {
|
def updated() {
|
||||||
log.debug "in updated()"
|
log.debug "in updated()"
|
||||||
configureHealthCheck()
|
// updated() doesn't have it's return value processed as hub commands, so we have to send them explicitly
|
||||||
|
def cmds = configureHealthCheck()
|
||||||
|
cmds.each{ sendHubCommand(new physicalgraph.device.HubAction(it)) }
|
||||||
}
|
}
|
||||||
|
|
||||||
def ping() {
|
def ping() {
|
||||||
|
|||||||
Reference in New Issue
Block a user