From d88b64c33cc06ae2521346c5b0d6f16e55b24e27 Mon Sep 17 00:00:00 2001 From: "Marta Wierzbinska/Home IoT Development (IoT) /SRPOL/Professional/Samsung Electronics" Date: Fri, 28 Aug 2020 13:40:02 +0200 Subject: [PATCH] Added fingerprint for Inovelli Dimmer LZW31 --- .../inovelli-dimmer.src/inovelli-dimmer.groovy | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/devicetypes/smartthings/inovelli-dimmer.src/inovelli-dimmer.groovy b/devicetypes/smartthings/inovelli-dimmer.src/inovelli-dimmer.groovy index f0ca4278d04..c883a81c017 100644 --- a/devicetypes/smartthings/inovelli-dimmer.src/inovelli-dimmer.groovy +++ b/devicetypes/smartthings/inovelli-dimmer.src/inovelli-dimmer.groovy @@ -27,6 +27,7 @@ metadata { capability "Power Meter" fingerprint mfr: "031E", prod: "0001", model: "0001", deviceJoinName: "Inovelli Dimmer Switch", mnmn: "SmartThings", vid: "SmartThings-smartthings-Inovelli_Dimmer" //Inovelli Dimmer LZW31-SN + fingerprint mfr: "031E", prod: "0003", model: "0001", deviceJoinName: "Inovelli Dimmer Switch", mnmn: "SmartThings", vid: "SmartThings-smartthings-Inovelli_Dimmer_LZW31" //Inovelli Dimmer LZW31 } tiles(scale: 2) { @@ -119,10 +120,12 @@ def installed() { } } // Preferences template end - createChildButtonDevices() - def value = ['pushed', 'pushed_2x', 'pushed_3x', 'pushed_4x', 'pushed_5x'].encodeAsJson() - sendEvent(name: "supportedButtonValues", value: value) - sendEvent(name: "numberOfButtons", value: 3, displayed: true) + if(isInovelliDimmerLZW31SN()) { + createChildButtonDevices() + def value = ['pushed', 'pushed_2x', 'pushed_3x', 'pushed_4x', 'pushed_5x'].encodeAsJson() + sendEvent(name: "supportedButtonValues", value: value) + sendEvent(name: "numberOfButtons", value: 3, displayed: true) + } createChildDevice("smartthings", "Child Color Control", "${device.deviceNetworkId}:4", "LED Bar", "LEDColorConfiguration") } @@ -511,6 +514,10 @@ private encapSequence(cmds, Integer delay = 250) { delayBetween(cmds.collect { encap(it) }, delay) } +private isInovelliDimmerLZW31SN(){ + zwaveInfo.mfr.equals("031E") && zwaveInfo.prod.equals("0001") && zwaveInfo.model.equals("0001") +} + private getParameterMap() { [ [