|
| 1 | +{ |
| 2 | + "deviceMapping": { |
| 3 | + "id": [ |
| 4 | + "yeelink.light.lamp15" |
| 5 | + ], |
| 6 | + "propertyMethod": "get_prop", |
| 7 | + "maxProperties": 2, |
| 8 | + "channels": [ |
| 9 | + { |
| 10 | + "property": "power", |
| 11 | + "friendlyName": "Power", |
| 12 | + "channel": "power", |
| 13 | + "type": "Switch", |
| 14 | + "refresh": true, |
| 15 | + "actions": [ |
| 16 | + { |
| 17 | + "command": "set_power", |
| 18 | + "parameterType": "ONOFF" |
| 19 | + } |
| 20 | + ], |
| 21 | + "category": "switch", |
| 22 | + "tags": [ |
| 23 | + "Switch" |
| 24 | + ] |
| 25 | + }, |
| 26 | + { |
| 27 | + "property": "bright", |
| 28 | + "friendlyName": "Brightness", |
| 29 | + "channel": "brightness", |
| 30 | + "type": "Dimmer", |
| 31 | + "refresh": true, |
| 32 | + "actions": [ |
| 33 | + { |
| 34 | + "command": "set_bright", |
| 35 | + "parameterType": "NUMBER", |
| 36 | + "condition": { |
| 37 | + "name": "BrightnessExisting" |
| 38 | + } |
| 39 | + }, |
| 40 | + { |
| 41 | + "command": "set_power", |
| 42 | + "parameterType": "ONOFF", |
| 43 | + "condition": { |
| 44 | + "name": "BrightnessOnOff" |
| 45 | + } |
| 46 | + } |
| 47 | + ], |
| 48 | + "category": "light", |
| 49 | + "tags": [ |
| 50 | + "Setpoint", |
| 51 | + "Light" |
| 52 | + ] |
| 53 | + }, |
| 54 | + { |
| 55 | + "property": "delayoff", |
| 56 | + "friendlyName": "Shutdown Timer", |
| 57 | + "channel": "delayoff", |
| 58 | + "type": "Number:Time", |
| 59 | + "unit": "seconds", |
| 60 | + "refresh": true, |
| 61 | + "actions": [ |
| 62 | + { |
| 63 | + "command": "cron_add", |
| 64 | + "parameterType": "NUMBER", |
| 65 | + "parameters": [ |
| 66 | + 0, |
| 67 | + "$value$" |
| 68 | + ] |
| 69 | + } |
| 70 | + ], |
| 71 | + "category": "time", |
| 72 | + "tags": [ |
| 73 | + "Setpoint", |
| 74 | + "Duration" |
| 75 | + ] |
| 76 | + }, |
| 77 | + { |
| 78 | + "property": "ct", |
| 79 | + "friendlyName": "Color Temperature", |
| 80 | + "channel": "colorTemperature", |
| 81 | + "type": "Number:Temperature", |
| 82 | + "unit": "kelvin", |
| 83 | + "stateDescription": { |
| 84 | + "minimum": 1700, |
| 85 | + "maximum": 6500, |
| 86 | + "step": 1, |
| 87 | + "pattern": "%.0f %unit%" |
| 88 | + }, |
| 89 | + "refresh": true, |
| 90 | + "actions": [ |
| 91 | + { |
| 92 | + "command": "set_ct_abx", |
| 93 | + "parameterType": "NUMBER", |
| 94 | + "parameters": [ |
| 95 | + "$value$", |
| 96 | + "smooth", |
| 97 | + 500 |
| 98 | + ] |
| 99 | + } |
| 100 | + ], |
| 101 | + "category": "colorlight", |
| 102 | + "tags": [ |
| 103 | + "Setpoint", |
| 104 | + "Temperature" |
| 105 | + ] |
| 106 | + }, |
| 107 | + { |
| 108 | + "property": "color_mode", |
| 109 | + "friendlyName": "Color Mode", |
| 110 | + "channel": "colorMode", |
| 111 | + "type": "Number", |
| 112 | + "stateDescription": { |
| 113 | + "minimum": 0, |
| 114 | + "maximum": 5, |
| 115 | + "step": 1, |
| 116 | + "options": [ |
| 117 | + { |
| 118 | + "value": "0", |
| 119 | + "label": "Default" |
| 120 | + }, |
| 121 | + { |
| 122 | + "value": "1", |
| 123 | + "label": "CT mode" |
| 124 | + }, |
| 125 | + { |
| 126 | + "value": "2", |
| 127 | + "label": "RGB mode" |
| 128 | + }, |
| 129 | + { |
| 130 | + "value": "3", |
| 131 | + "label": "HSV mode" |
| 132 | + }, |
| 133 | + { |
| 134 | + "value": "4", |
| 135 | + "label": "Color Flow mode" |
| 136 | + }, |
| 137 | + { |
| 138 | + "value": "5", |
| 139 | + "label": "Night Light mode" |
| 140 | + } |
| 141 | + ] |
| 142 | + }, |
| 143 | + "refresh": true, |
| 144 | + "actions": [ |
| 145 | + { |
| 146 | + "command": "set_power", |
| 147 | + "parameterType": "NUMBER", |
| 148 | + "parameters": [ |
| 149 | + "on", |
| 150 | + "smooth", |
| 151 | + 500, |
| 152 | + "$value$" |
| 153 | + ] |
| 154 | + } |
| 155 | + ], |
| 156 | + "category": "settings", |
| 157 | + "tags": [ |
| 158 | + "Control", |
| 159 | + "Light" |
| 160 | + ], |
| 161 | + "readmeComment": "Value mapping [\"0\"\u003d\"Default\",\"1\"\u003d\"CT mode\",\"2\"\u003d\"RGB mode\",\"3\"\u003d\"HSV mode\",\"4\"\u003d\"Color Flow mode\",\"5\"\u003d\"Night Light mode\"]" |
| 162 | + }, |
| 163 | + { |
| 164 | + "property": "rgb", |
| 165 | + "friendlyName": "RGB Color", |
| 166 | + "channel": "rgbColor", |
| 167 | + "type": "Color", |
| 168 | + "refresh": true, |
| 169 | + "ChannelGroup": "actions", |
| 170 | + "actions": [ |
| 171 | + { |
| 172 | + "command": "set_rgb", |
| 173 | + "parameterType": "COLOR", |
| 174 | + "parameters": [ |
| 175 | + "$value$", |
| 176 | + "smooth", |
| 177 | + 500 |
| 178 | + ], |
| 179 | + "condition": { |
| 180 | + "name": "HSBOnly" |
| 181 | + } |
| 182 | + }, |
| 183 | + { |
| 184 | + "command": "set_bright", |
| 185 | + "parameterType": "NUMBER", |
| 186 | + "condition": { |
| 187 | + "name": "BrightnessExisting" |
| 188 | + } |
| 189 | + }, |
| 190 | + { |
| 191 | + "command": "set_power", |
| 192 | + "parameterType": "ONOFF", |
| 193 | + "condition": { |
| 194 | + "name": "BrightnessOnOff" |
| 195 | + } |
| 196 | + } |
| 197 | + ], |
| 198 | + "category": "colorpicker", |
| 199 | + "tags": [ |
| 200 | + "Control", |
| 201 | + "Light" |
| 202 | + ] |
| 203 | + }, |
| 204 | + { |
| 205 | + "property": "bg_bright", |
| 206 | + "friendlyName": "Ambient Brightness", |
| 207 | + "channel": "ambientBrightness", |
| 208 | + "channelType": "ambientBrightness", |
| 209 | + "type": "Number", |
| 210 | + "refresh": true, |
| 211 | + "ChannelGroup": "actions", |
| 212 | + "actions": [ |
| 213 | + { |
| 214 | + "command": "bg_set_bright", |
| 215 | + "parameterType": "NUMBER" |
| 216 | + } |
| 217 | + ] |
| 218 | + }, |
| 219 | + { |
| 220 | + "property": "bg_power", |
| 221 | + "friendlyName": "Ambient Power", |
| 222 | + "channel": "ambientPower", |
| 223 | + "channelType": "ambientPower", |
| 224 | + "type": "Switch", |
| 225 | + "refresh": true, |
| 226 | + "ChannelGroup": "actions", |
| 227 | + "actions": [ |
| 228 | + { |
| 229 | + "command": "bg_set_power", |
| 230 | + "parameterType": "ONOFF" |
| 231 | + } |
| 232 | + ] |
| 233 | + }, |
| 234 | + { |
| 235 | + "property": "bg_rgb", |
| 236 | + "friendlyName": "Ambient Color", |
| 237 | + "channel": "ambientColor", |
| 238 | + "channelType": "ambientColor", |
| 239 | + "type": "Color", |
| 240 | + "refresh": true, |
| 241 | + "ChannelGroup": "actions", |
| 242 | + "actions": [ |
| 243 | + { |
| 244 | + "command": "bg_set_rgb", |
| 245 | + "parameterType": "COLOR" |
| 246 | + } |
| 247 | + ] |
| 248 | + }, |
| 249 | + { |
| 250 | + "property": "bg_ct", |
| 251 | + "friendlyName": "Ambient Color Temperature", |
| 252 | + "channel": "ambientColorTemperature", |
| 253 | + "channelType": "ambientColorTemperature", |
| 254 | + "type": "Number", |
| 255 | + "refresh": true, |
| 256 | + "ChannelGroup": "actions", |
| 257 | + "actions": [ |
| 258 | + { |
| 259 | + "command": "bg_set_ct_abx", |
| 260 | + "parameterType": "NUMBER", |
| 261 | + "parameters": [ |
| 262 | + "$value$", |
| 263 | + "smooth", |
| 264 | + 500 |
| 265 | + ] |
| 266 | + } |
| 267 | + ] |
| 268 | + }, |
| 269 | + { |
| 270 | + "property": "bg_lmode", |
| 271 | + "friendlyName": "Ambient Color Mode", |
| 272 | + "channel": "ambientColorMode", |
| 273 | + "channelType": "ambientColorMode", |
| 274 | + "type": "Number", |
| 275 | + "refresh": true, |
| 276 | + "actions": [] |
| 277 | + } |
| 278 | + ] |
| 279 | + } |
| 280 | +} |
0 commit comments