From 772fcfbcd2e23acd6a689c947ae7b8f50eb73c73 Mon Sep 17 00:00:00 2001 From: greens Date: Tue, 17 Sep 2019 13:12:33 -0700 Subject: [PATCH] ICP-10896 Axis Gear pause support The Axis Gear already had a command to stop the blinds, but this should hook it up to the Window Shade capability so that it can be used in OneApp. --- devicetypes/axis/axis-gear-st.src/axis-gear-st.groovy | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/devicetypes/axis/axis-gear-st.src/axis-gear-st.groovy b/devicetypes/axis/axis-gear-st.src/axis-gear-st.groovy index d258ed3b1af..3dce3ec841e 100644 --- a/devicetypes/axis/axis-gear-st.src/axis-gear-st.groovy +++ b/devicetypes/axis/axis-gear-st.src/axis-gear-st.groovy @@ -1,3 +1,5 @@ +import groovy.json.JsonOutput + metadata { definition (name: "AXIS Gear ST", namespace: "axis", author: "AXIS Labs", ocfDeviceType: "oic.d.blind", vid: "generic-shade-2") { capability "Window Shade" @@ -166,6 +168,10 @@ def stop() { } } +def pause() { + stop() +} + //Send Command through setLevel() def on() { log.info "on()" @@ -302,6 +308,7 @@ def configure() { sendEvent(name: "windowShade", value: "unknown") log.debug "Configuring Reporting and Bindings." sendEvent(name: "checkInterval", value: (2 * 60 * 60 + 10 * 60), displayed: true, data: [protocol: "zigbee", hubHardwareId: device.hub.hardwareID]) + sendEvent(name: "supportedWindowShadeCommands", value: JsonOutput.toJson(["open", "close", "pause"])) def attrs_refresh = zigbee.readAttribute(CLUSTER_BASIC, BASIC_ATTR_SWBUILDID) + zigbee.readAttribute(CLUSTER_WINDOWCOVERING, WINDOWCOVERING_ATTR_LIFTPERCENTAGE) +