{ "title": "lamp.rgbw", "description": "Lamp with RGB and white", "lang": "en", "documentation": "http://recherche.imt-atlantique.fr/xaal/documentation/", "ref": "http://recherche.imt-atlantique.fr/xaal/documentation/lamp.rgbw", "license": "Copyright Christophe Lohr IMT Atlantique 2017 - 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.basic", "attributes": { "dimmer": { "description": "Level of the dimmer", "unit": "%", "type": { "$schema": "http://json-schema.org/draft-04/schema#", "type": "number", "minimum": 0, "maximum": 100 } }, "rgb": { "description": "RGB color of the lamp", "unit": "", "type": { "$schema": "http://json-schema.org/draft-04/schema#", "type": "array" } }, "white_temperature": { "description": "White temperature of the lamp", "unit": "", "type": { "$schema": "http://json-schema.org/draft-04/schema#", "type": "number" } }, "scene": { "description": "current animation scene", "unit": "", "type": { "$schema": "http://json-schema.org/draft-04/schema#", "type": "string" } }, "mode": { "description": "Current mode of the lamp", "unit": "", "type": { "$schema": "http://json-schema.org/draft-04/schema#", "enum": [ "white", "rgb", "scene" ] } } }, "methods": { "getAttributes": { "description": "Return attributes of the device", "parameters": { "attributes": { "description": "List of wanted attributes", "unit": "", "direction": "in", "type": { "$schema": "http://json-schema.org/draft-04/schema#", "type": "array", "items": { "enum": [ "light", "dimmer" ] }, "additionalItems": false } }, "light": { "description": "State of the lamp", "unit": "true=on false=off", "direction": "out", "type": { "$schema": "http://json-schema.org/draft-04/schema#", "type": "boolean" } }, "dimmer": { "description": "Level of the dimmer", "unit": "%", "direction": "out", "type": { "$schema": "http://json-schema.org/draft-04/schema#", "type": "number", "minimum": 0, "maximum": 100 } }, "rgb": { "description": "RGB color of the lamp", "unit": "", "direction": "out", "type": { "$schema": "http://json-schema.org/draft-04/schema#", "type": "array" } }, "white_temperature": { "description": "White temperature of the lamp", "unit": "", "direction": "out", "type": { "$schema": "http://json-schema.org/draft-04/schema#", "type": "number" } }, "scene": { "description": "Animation scene", "unit": "", "direction": "out", "type": { "$schema": "http://json-schema.org/draft-04/schema#", "type": "string" } }, "mode": { "description": "Current mode of the lamp white/rgb/scene", "unit": "", "direction": "out", "type": { "$schema": "http://json-schema.org/draft-04/schema#", "enum": [ "white", "rgb", "scene" ] } } }, "relatedAttributes": [ ] }, "dim": { "description": "Change the dimmer of the lamp", "parameters": { "target": { "description": "Target of the dimmer", "unit": "%", "direction": "in", "type": { "$schema": "http://json-schema.org/draft-04/schema#", "type": "number", "minimum": 0, "maximum": 100 } } }, "relatedAttributes": [ "dimmer" ] }, "setRGB": { "description": "Change the color of the lamp", "parameters": { "target": { "description": "Target color", "unit": "%", "direction": "in", "type": { "$schema": "http://json-schema.org/draft-04/schema#", "type": "array" } } }, "relatedAttributes": [ "rgb" ] }, "setWhite": { "description": "Change the white temperature", "parameters": { "target": { "description": "Target temperature", "unit": "%", "direction": "in", "type": { "$schema": "http://json-schema.org/draft-04/schema#", "type": "number" } } }, "relatedAttributes": [ "white_temperature" ] }, "setScene": { "description": "Change the animation scene", "parameters": { "target": { "description": "Target scene", "unit": "%", "direction": "in", "type": { "$schema": "http://json-schema.org/draft-04/schema#", "type": "string" } } }, "relatedAttributes": [ "scene" ] }, "getScenes": { "description": "Return scenes", "parameters": {}, "relatedAttributes": [] } }, "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/draft-04/schema#", "type": "boolean" } }, "dimmer": { "description": "Level of the dimmer", "unit": "%", "type": { "$schema": "http://json-schema.org/draft-04/schema#", "type": "number", "minimum": 0, "maximum": 100 } }, "rgb": { "description": "RGB color of the lamp", "unit": "", "type": { "$schema": "http://json-schema.org/draft-04/schema#", "type": "array" } }, "white_temperature": { "description": "White temperature of the lamp", "unit": "", "type": { "$schema": "http://json-schema.org/draft-04/schema#", "type": "number" } }, "scene": { "description": "Animation scene", "unit": "", "type": { "$schema": "http://json-schema.org/draft-04/schema#", "type": "string" } }, "mode": { "description": "Current mode of the lamp white/rgb/scene", "unit": "", "type": { "$schema": "http://json-schema.org/draft-04/schema#", "enum": [ "white", "rgb", "scene" ] } } } } } }