[CHF-482]

Health Check implementation for Z-Wave Metering Dimmer
This commit is contained in:
piyush.c
2016-12-16 17:21:02 +05:30
parent 0a82077b24
commit ef8611d2ea

View File

@@ -25,10 +25,12 @@ metadata {
capability "Switch Level"
capability "Sensor"
capability "Actuator"
capability "Health Check"
command "reset"
fingerprint inClusters: "0x26,0x32"
fingerprint mfr:"0086", prod:"0003", model:"001B", deviceJoinName: "Aeon Labs Micro Smart Dimmer 2E"
}
simulator {
@@ -98,6 +100,9 @@ def parse(String description) {
}
def updated() {
// 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])
response(refresh())
}
@@ -162,6 +167,14 @@ def poll() {
], 1000)
}
/**
* PING is used by Device-Watch in attempt to reach the Device
* */
def ping() {
log.debug "ping() called"
refresh()
}
def refresh() {
delayBetween([
zwave.switchMultilevelV1.switchMultilevelGet().format(),