{ "title": "lamp.cie1931", "description": "Lamp color in cie1931 color space", "lang": "en", "documentation": "http://recherche.telecom-bretagne.eu/xaal/documentation/", "ref": "http://recherche.telecom-bretagne.eu/xaal/documentation/lamp.dimmer", "license": "Copyright Tanguy Philippe Telecom Bretagne 2014 - Copying and distribution of this file, with or without modification, are permitted in any medium without royalty provided the copyright notice and this notice are preserved. This file is offered as-is, without any warranty.", "extends": "lamp.dimmer", "attributes": { "xy": { "description": "xy coordinates in the cie1931 chromacity diagram", "unit": "", "type": { "$schema": "http://json-schema.org/schema#", "type": "array", "items": { "type": "number", "minimum": 0, "maximum": 1 } } }, "saturation": { "description": "saturation", "unit": "", "type": { "$schema": "http://json-schema.org/schema#", "type": "number", "minimum": 0, "maximum": 255 } } }, "methods": { "getAttributes": { "description": "Return attributes of the device", "parameters": { "attributes": { "description": "List of wanted attributes", "unit": "", "direction": "in", "type": { "$schema": "http://json-schema.org/schema#", "type": "array", "items": { "enum": ["light", "dimmer", "xy", "saturation" ] }, "additionalItems": false } }, "light": { "description": "State of the lamp", "unit": "true=on false=off", "direction": "out", "type": { "$schema": "http://json-schema.org/schema#", "type": "boolean" } }, "dimmer": { "description": "Level of the dimmer", "unit": "%", "direction": "out", "type": { "$schema": "http://json-schema.org/schema#", "type": "number", "minimum": 0, "maximum": 100 } }, "xy": { "description": "Set color coordinates in cie1931 chromacity diagram", "unit": "xy coordinates in the chromicity diagram", "direction": "out", "type": { "$schema": "http://json-schema.org/schema#", "type": "array", "items": { "type": "number", "minimum": 0, "maximum": 1 } } }, "saturation": { "description": "Saturation level", "unit": "", "direction": "out", "type": { "$schema": "http://json-schema.org/schema#", "type": "number", "minimum": 0, "maximum": 255 } } }, "relatedAttributes": ["light","dimmer","xy","saturation"] }, "xy": { "description": "Set color coordinates in cie1931 chromacity diagram", "parameters": { "target": { "description": "Target of xy", "unit": "xy coordinates in the chromicity diagram", "direction": "in", "type": { "$schema": "http://json-schema.org/schema#", "type": "array", "items": { "type": "number", "minimum": 0, "maximum": 1 } } } }, "relatedAttributes": [ "xy" ] }, "saturation": { "description": "Set saturation level", "parameters": { "target": { "description": "Target of saturation", "unit": "", "direction": "in", "type": { "$schema": "http://json-schema.org/schema#", "type": "number", "minimum": 0, "maximum":255 } } }, "relatedAttributes": [ "saturation" ] } }, "notifications": { "attributesChange": { "description": "Report attributes that have changed", "parameters": { "light": { "description": "State of the lamp", "unit": "true=on false=off", "type": { "$schema": "http://json-schema.org/schema#", "type": "boolean" } }, "dimmer": { "description": "Level of the dimmer", "unit": "%", "type": { "$schema": "http://json-schema.org/schema#", "type": "number", "minimum": 0, "maximum": 100 } }, "xy": { "description": "xy coordinates", "unit": "", "type": { "$schema": "http://json-schema.org/schema#", "type": "array", "items": { "type": "number", "minimum": 0, "maximum": 1 } } }, "saturation": { "description": "Level of the saturation", "unit": "", "type": { "$schema": "http://json-schema.org/schema#", "type": "number", "minimum": 0, "maximum": 255 } } } } } }