DVCSMP-2024 OSRAM: Hue is incorrectly set to be 0-360

-Hue changed to handle 0-100 according to SmartThings API
This commit is contained in:
Lars Finander
2016-09-09 16:52:52 -06:00
parent 60c2006bfc
commit bc817f8530
3 changed files with 10 additions and 10 deletions

View File

@@ -105,7 +105,7 @@ def parse(String description) {
if (zigbeeMap?.clusterInt == COLOR_CONTROL_CLUSTER) {
if(zigbeeMap.attrInt == ATTRIBUTE_HUE){ //Hue Attribute
def hueValue = Math.round(zigbee.convertHexToInt(zigbeeMap.value) / 255 * 360)
def hueValue = Math.round(zigbee.convertHexToInt(zigbeeMap.value) / 255 * 100)
sendEvent(name: "hue", value: hueValue, descriptionText: "Color has changed")
}
else if(zigbeeMap.attrInt == ATTRIBUTE_SATURATION){ //Saturation Attribute