├── .gitattributes ├── .project ├── CONTRIBUTING.md ├── D_Arduino1.json ├── D_Arduino1.xml ├── D_ArduinoNode1.json ├── D_ArduinoNode1.xml ├── D_ArduinoRelay1.json ├── D_ArduinoRelay1.xml ├── I_Arduino1.xml ├── IrRecordPlayback ├── D_ArduinoIr1.json ├── D_ArduinoIr1.xml └── S_ArduinoIr1.xml ├── L_Arduino.lua ├── LcdText ├── D_LcdText1.json ├── D_LcdText1.xml └── S_LcdText1.xml ├── Multimeter ├── D_Multimeter1.json ├── D_Multimeter1.xml └── S_Multimeter1.xml ├── S_Arduino.xml ├── S_ArduinoNode.xml ├── WindSensor ├── D_WindSensor1.json ├── D_WindSensor1.xml └── S_WindSensor1.xml ├── barometer ├── D_BarometerSensor1.json ├── D_BarometerSensor1.xml └── S_BarometerSensor1.xml ├── distance ├── D_DistanceSensor1.json ├── D_DistanceSensor1.xml └── S_DistanceSensor1.xml ├── raingauge ├── D_RainSensor1.json ├── D_RainSensor1.xml └── S_Rainsensor1.xml ├── scale ├── D_ScaleSensor1.json ├── D_ScaleSensor1.xml └── S_ScaleSensor.xml └── watermeter ├── D_WaterMeter1.json ├── D_WaterMeter1.xml └── S_WaterMeter1.xml /.gitattributes: -------------------------------------------------------------------------------- 1 | # Set default behaviour, in case users don't have core.autocrlf set. 2 | * text=auto 3 | 4 | # Explicitly declare text files we want to always be normalized and converted 5 | # to native line endings on checkout. 6 | *.c text 7 | *.cpp text 8 | *.h text 9 | *.ino text 10 | *.xml text 11 | *.lua text 12 | *.json text 13 | 14 | 15 | # Denote all files that are truly binary and should not be modified. 16 | *.png binary 17 | *.jpg binary 18 | *.gif binary 19 | -------------------------------------------------------------------------------- /.project: -------------------------------------------------------------------------------- 1 | 2 | 3 | MySensors-Vera 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | To get started, sign the Contributor License Agreement. -------------------------------------------------------------------------------- /D_Arduino1.json: -------------------------------------------------------------------------------- 1 | { 2 | "flashicon": "http://www.mysensors.org/icon/MySensors.png", 3 | "imgIconBody": "", 4 | "imgIconDimmable": "", 5 | "imgIconTurnable": "", 6 | "imgIconMin": "", 7 | "imgIconMax": "", 8 | "halloIconsDir": "pics/hallo", 9 | "inScene": "0", 10 | "DisplayStatus": { 11 | }, 12 | "doc_url": { 13 | "doc_language": 1, 14 | "doc_manual": 1, 15 | "doc_version": 1, 16 | "doc_platform": 0, 17 | "doc_page": "sensors" 18 | }, 19 | "Tabs": [ 20 | { 21 | "Label": { 22 | "lang_tag": "tabname_control", 23 | "text": "Settings" 24 | }, 25 | "Position": "0", 26 | "TabType": "flash", 27 | "ControlGroup": [ 28 | { 29 | "id": "1", 30 | "scenegroup": "1" 31 | }, 32 | { 33 | "id": "2", 34 | "scenegroup": "2", 35 | "isSingle": "1" 36 | 37 | } 38 | ], 39 | "SceneGroup": [ 40 | { 41 | "id": "1", 42 | "top": "0", 43 | "left": "0.1", 44 | "x": "1.5", 45 | "y": "2" 46 | }, 47 | { 48 | "id": "2", 49 | "top": "1", 50 | "left": "0", 51 | "x": "2", 52 | "y": "3" 53 | } 54 | ], 55 | "Control": [ 56 | 57 | { 58 | "ControlGroup": "1", 59 | "ControlType": "label", 60 | "text_align": "right", 61 | "Style": "numeric", 62 | "Label": { 63 | "lang_tag": "plugin_version", 64 | "text": "Plugin Version:" 65 | }, 66 | "top": "0.4", 67 | "left": "-0.9", 68 | "x": "1.45", 69 | "y": "1", 70 | "Display": { 71 | "Top": 25, 72 | "Left": 30, 73 | "Width": 300, 74 | "Height": 20 75 | } 76 | }, 77 | { 78 | "ControlGroup": "1", 79 | "ControlType": "variable", 80 | "text_align": "left", 81 | "top": "0.4", 82 | "left": "0.6", 83 | "x": "2", 84 | "y": "1", 85 | "Display": { 86 | "Service": "urn:upnp-arduino-cc:serviceId:arduino1", 87 | "Variable": "PluginVersion", 88 | "Top": 25, 89 | "Left": 120, 90 | "Width": 300, 91 | "Height": 20 92 | } 93 | }, 94 | 95 | { 96 | "ControlGroup": "1", 97 | "ControlType": "label", 98 | "text_align": "right", 99 | "Label": { 100 | "lang_tag": "gateway_version", 101 | "text": "Lib Version: " 102 | }, 103 | "top": "1.1", 104 | "left": "-0.9", 105 | "x": "1.45", 106 | "y": "1", 107 | "Display": { 108 | "Top": 45, 109 | "Left": 30, 110 | "Width": 300, 111 | "Height": 20 112 | } 113 | }, 114 | { 115 | "ControlGroup": "1", 116 | "ControlType": "variable", 117 | "text_align": "left", 118 | "top": "1.1", 119 | "left": "0.6", 120 | "x": "2", 121 | "y": "1", 122 | "Display": { 123 | "Service": "urn:upnp-arduino-cc:serviceId:arduino1", 124 | "Variable": "ArduinoLibVersion", 125 | "Top": 45, 126 | "Left": 120, 127 | "Width": 300, 128 | "Height": 20 129 | } 130 | }, 131 | { 132 | "ControlGroup": "1", 133 | "ControlType": "label", 134 | "text_align": "left", 135 | "Label": { 136 | "lang_tag": "found_count", 137 | "text": "Press start for inclusion" 138 | }, 139 | "top": "1.8", 140 | "left": "-0.2", 141 | "x": "2.5", 142 | "y": "1", 143 | "Display": { 144 | "Top": 65, 145 | "Left": 30, 146 | "Width": 300, 147 | "Height": 20 148 | } 149 | }, 150 | { 151 | "ControlGroup": "1", 152 | "ControlType": "variable", 153 | "text_align": "left", 154 | "top": "2.4", 155 | "left": "-0.2", 156 | "x": "3", 157 | "y": "1", 158 | "Display": { 159 | "Service": "urn:upnp-arduino-cc:serviceId:arduino1", 160 | "Variable": "InclusionFoundCountHR", 161 | "Top": 115, 162 | "Left": 30, 163 | "Width": 300, 164 | "Height": 20 165 | } 166 | }, 167 | { 168 | "ControlGroup": "2", 169 | "ControlType": "button", 170 | "top": "2", 171 | "left": "0", 172 | "Label": { 173 | "lang_tag": "include_start", 174 | "text": "Start" 175 | }, 176 | "Display": { 177 | "Service": "urn:upnp-arduino-cc:serviceId:arduino1", 178 | "Variable": "InclusionMode", 179 | "Value": "1", 180 | "Top": 85, 181 | "Left": 30, 182 | "Width": 50, 183 | "Height": 20 184 | }, 185 | "Command": { 186 | "Service": "urn:upnp-arduino-cc:serviceId:arduino1", 187 | "Action": "StartInclusion", 188 | "Parameters": [] 189 | } 190 | }, 191 | { 192 | "ControlGroup": "2", 193 | "ControlType": "button", 194 | "top": "2", 195 | "left": "1", 196 | "Label": { 197 | "lang_tag": "include_stop", 198 | "text": "Stop" 199 | }, 200 | "Display": { 201 | "Service": "urn:upnp-arduino-cc:serviceId:arduino1", 202 | "Variable": "InclusionMode", 203 | "Value": "0", 204 | "Top": 85, 205 | "Left": 90, 206 | "Width": 50, 207 | "Height": 20 208 | }, 209 | "Command": { 210 | "Service": "urn:upnp-arduino-cc:serviceId:arduino1", 211 | "Action": "StopInclusion", 212 | "Parameters": [] 213 | } 214 | }, 215 | 216 | 217 | 218 | 219 | { 220 | "ControlType": "label", 221 | "text_align": "left", 222 | "Label": { 223 | "lang_tag": "unit", 224 | "text": "Unit:" 225 | }, 226 | "top": "0.2", 227 | "left": "-0.2", 228 | "x": "2.5", 229 | "y": "1", 230 | "Display": { 231 | "Top": 25, 232 | "Left": 200, 233 | "Width": 50, 234 | "Height": 20 235 | } 236 | }, 237 | 238 | 239 | 240 | { 241 | "ControlType": "button", 242 | "top": "2", 243 | "left": "0", 244 | "Label": { 245 | "lang_tag": "metric", 246 | "text": "Metric" 247 | }, 248 | "Display": { 249 | "Service": "urn:upnp-arduino-cc:serviceId:arduino1", 250 | "Variable": "Unit", 251 | "Value": "M", 252 | "Top": 20, 253 | "Left": 240, 254 | "Width": 60, 255 | "Height": 20 256 | }, 257 | "Command": { 258 | "Service": "urn:upnp-arduino-cc:serviceId:arduino1", 259 | "Action": "SetUnit", 260 | "Parameters": [{ 261 | "Name": "unit", 262 | "Value": "M" 263 | }] 264 | } 265 | }, 266 | { 267 | "ControlType": "button", 268 | "top": "2", 269 | "left": "1", 270 | "Label": { 271 | "lang_tag": "imperial", 272 | "text": "Imperial" 273 | }, 274 | "Display": { 275 | "Service": "urn:upnp-arduino-cc:serviceId:arduino1", 276 | "Variable": "Unit", 277 | "Value": "I", 278 | "Top": 20, 279 | "Left": 310, 280 | "Width": 60, 281 | "Height": 20 282 | }, 283 | "Command": { 284 | "Service": "urn:upnp-arduino-cc:serviceId:arduino1", 285 | "Action": "SetUnit", 286 | "Parameters": [{ 287 | "Name": "unit", 288 | "Value": "I" 289 | }] 290 | } 291 | } 292 | 293 | 294 | 295 | 296 | 297 | 298 | 299 | 300 | 301 | 302 | 303 | 304 | 305 | 306 | ] 307 | }, 308 | { 309 | "Label": { 310 | "lang_tag": "advanced", 311 | "text": "Advanced" 312 | }, 313 | "Position": "1", 314 | "TabType": "javascript", 315 | "ScriptName": "shared.js", 316 | "Function": "advanced_device" 317 | } 318 | ], 319 | "DeviceType": "urn:schemas-arduino-cc:device:arduino:1" 320 | } 321 | -------------------------------------------------------------------------------- /D_Arduino1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | urn:schemas-arduino-cc:device:arduino:1 9 | D_Arduino1.json 10 | MySensors Plugin 11 | Arduino 12 | http://www.mysensors.org 13 | Arduino with radio 14 | 15 | 1.0 16 | 1 17 | crlf 18 | rs232 19 | 20 | I_Arduino1.xml 21 | 22 | 23 | 24 | urn:schemas-arduino-cc:service:arduino:1 25 | urn:upnp-arduino-cc:serviceId:arduino1 26 | S_Arduino.xml 27 | 28 | 29 | 30 | -------------------------------------------------------------------------------- /D_ArduinoNode1.json: -------------------------------------------------------------------------------- 1 | { 2 | "flashicon": "http://www.mysensors.org/icon/Node.png", 3 | "imgIconBody": "", 4 | "imgIconDimmable": "", 5 | "imgIconTurnable": "", 6 | "imgIconMin": "", 7 | "imgIconMax": "", 8 | "halloIconsDir": "pics/hallo", 9 | "inScene": "0", 10 | "DisplayStatus": { 11 | }, 12 | "doc_url": { 13 | "doc_language": 1, 14 | "doc_manual": 1, 15 | "doc_version": 1, 16 | "doc_platform": 0, 17 | "doc_page": "sensors" 18 | }, 19 | "Tabs": [ 20 | { 21 | "Label": { 22 | "lang_tag": "tabname_control", 23 | "text": "Settings" 24 | }, 25 | "Position": "0", 26 | "TabType": "flash", 27 | "ControlGroup": [ 28 | { 29 | "id": "1", 30 | "scenegroup": "1" 31 | }, 32 | { 33 | "id": "2", 34 | "scenegroup": "2", 35 | "isSingle": "1" 36 | 37 | } 38 | ], 39 | "SceneGroup": [ 40 | { 41 | "id": "1", 42 | "top": "0", 43 | "left": "0.1", 44 | "x": "1.5", 45 | "y": "2" 46 | }, 47 | { 48 | "id": "2", 49 | "top": "2", 50 | "left": "0", 51 | "x": "2", 52 | "y": "3" 53 | } 54 | ], 55 | "Control": [ 56 | { 57 | "ControlGroup": "1", 58 | "ControlType": "label", 59 | "text_align": "right", 60 | "Label": { 61 | "lang_tag": "sketch_name", 62 | "text": "Sketch Name:" 63 | }, 64 | "top": "0.4", 65 | "left": "-0.8", 66 | "x": "1.35", 67 | "y": "1", 68 | "Display": { 69 | "Top": 25, 70 | "Left": 30, 71 | "Width": 300, 72 | "Height": 20 73 | } 74 | }, 75 | { 76 | "ControlGroup": "1", 77 | "ControlType": "variable", 78 | "text_align": "left", 79 | "top": "0.4", 80 | "left": "0.6", 81 | "x": "2", 82 | "y": "1", 83 | "Display": { 84 | "Service": "urn:upnp-arduino-cc:serviceId:arduinonode1", 85 | "Variable": "SketchName", 86 | "Value": "1", 87 | "Top": 25, 88 | "Left": 120, 89 | "Width": 300, 90 | "Height": 20 91 | } 92 | }, 93 | { 94 | "ControlGroup": "1", 95 | "ControlType": "label", 96 | "text_align": "right", 97 | "Label": { 98 | "lang_tag": "sketch_version", 99 | "text": "Sketch Version:" 100 | }, 101 | "top": "1.1", 102 | "left": "-0.9", 103 | "x": "1.45", 104 | "y": "1", 105 | "Display": { 106 | "Top": 45, 107 | "Left": 30, 108 | "Width": 300, 109 | "Height": 20 110 | } 111 | }, 112 | { 113 | "ControlGroup": "1", 114 | "ControlType": "variable", 115 | "text_align": "left", 116 | "top": "1.1", 117 | "left": "0.6", 118 | "x": "2", 119 | "y": "1", 120 | "Display": { 121 | "Service": "urn:upnp-arduino-cc:serviceId:arduinonode1", 122 | "Variable": "SketchVersion", 123 | "Value": "1", 124 | "Top": 45, 125 | "Left": 120, 126 | "Width": 300, 127 | "Height": 20 128 | } 129 | }, 130 | { 131 | "ControlGroup": "1", 132 | "ControlType": "label", 133 | "text_align": "right", 134 | "top": "1.8", 135 | "left": "-0.8", 136 | "x": "1.35", 137 | "y": "1", 138 | "Label": { 139 | "lang_tag": "gateway_version", 140 | "text": "Lib Version:" 141 | }, 142 | "Display": { 143 | "Top": 65, 144 | "Left": 30, 145 | "Width": 300, 146 | "Height": 20 147 | } 148 | }, 149 | { 150 | "ControlGroup": "1", 151 | "ControlType": "variable", 152 | "text_align": "left", 153 | "top": "1.8", 154 | "left": "0.6", 155 | "x": "2", 156 | "y": "1", 157 | "Display": { 158 | "Service": "urn:upnp-arduino-cc:serviceId:arduinonode1", 159 | "Variable": "ArduinoLibVersion", 160 | "Value": "1", 161 | "Top": 65, 162 | "Left": 120, 163 | "Width": 300, 164 | "Height": 20 165 | } 166 | }, 167 | { 168 | "ControlGroup": "1", 169 | "ControlType": "label", 170 | "text_align": "right", 171 | "top": "2.5", 172 | "left": "-0.8", 173 | "x": "1.35", 174 | "y": "1", 175 | "Label": { 176 | "lang_tag": "relay_label", 177 | "text": "Parent node:" 178 | }, 179 | "Display": { 180 | "Top": 85, 181 | "Left": 30, 182 | "Width": 300, 183 | "Height": 20 184 | } 185 | }, 186 | { 187 | "ControlGroup": "1", 188 | "ControlType": "variable", 189 | "text_align": "left", 190 | "top": "2.5", 191 | "left": "0.6", 192 | "x": "2", 193 | "y": "1", 194 | "Display": { 195 | "Service": "urn:upnp-arduino-cc:serviceId:arduinonode1", 196 | "Variable": "RelayNodeHR", 197 | "Value": "1", 198 | "Top": 85, 199 | "Left": 120, 200 | "Width": 300, 201 | "Height": 20 202 | } 203 | }, 204 | { 205 | "ControlGroup": "1", 206 | "ControlType": "label", 207 | "text_align": "right", 208 | "top": "3.2", 209 | "left": "-0.8", 210 | "x": "1.35", 211 | "y": "1", 212 | "Label": { 213 | "lang_tag": "last_update_label", 214 | "text": "Last Update:" 215 | }, 216 | "Display": { 217 | "Top": 105, 218 | "Left": 30, 219 | "Width": 300, 220 | "Height": 20 221 | } 222 | }, 223 | { 224 | "ControlGroup": "1", 225 | "ControlType": "variable", 226 | "text_align": "left", 227 | "top": "3.2", 228 | "left": "0.6", 229 | "x": "2", 230 | "y": "1", 231 | "Display": { 232 | "Service": "urn:micasaverde-com:serviceId:HaDevice1", 233 | "Variable": "LastUpdateHR", 234 | "Value": "1", 235 | "Top": 105, 236 | "Left": 120, 237 | "Width": 300, 238 | "Height": 20 239 | } 240 | } 241 | ] 242 | }, 243 | { 244 | "Label": { 245 | "lang_tag": "advanced", 246 | "text": "Advanced" 247 | }, 248 | "Position": "1", 249 | "TabType": "javascript", 250 | "ScriptName": "shared.js", 251 | "Function": "advanced_device" 252 | } 253 | ], 254 | "DeviceType": "urn:schemas-arduino-cc:device:arduinonode:1" 255 | } 256 | -------------------------------------------------------------------------------- /D_ArduinoNode1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | urn:schemas-arduino-cc:device:arduinonode:1 9 | D_ArduinoNode1.json 10 | Arduino Node 11 | Arduino 12 | http://www.arduino.cc 13 | Arduino with nRF24L01 transceiver 14 | 15 | 1.0 16 | 17 | 18 | urn:schemas-arduino-cc:service:arduinonode:1 19 | urn:upnp-arduino-cc:serviceId:arduinonode1 20 | S_ArduinoNode.xml 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /D_ArduinoRelay1.json: -------------------------------------------------------------------------------- 1 | { 2 | "flashicon": "http://www.mysensors.org/icon/Relay.png", 3 | "imgIconBody": "", 4 | "imgIconDimmable": "", 5 | "imgIconTurnable": "", 6 | "imgIconMin": "", 7 | "imgIconMax": "", 8 | "halloIconsDir": "pics/hallo", 9 | "inScene": "0", 10 | "DisplayStatus": { 11 | }, 12 | "doc_url": { 13 | "doc_language": 1, 14 | "doc_manual": 1, 15 | "doc_version": 1, 16 | "doc_platform": 0, 17 | "doc_page": "sensors" 18 | }, 19 | "Tabs": [ 20 | { 21 | "Label": { 22 | "lang_tag": "tabname_control", 23 | "text": "Settings" 24 | }, 25 | "Position": "0", 26 | "TabType": "flash", 27 | "ControlGroup": [ 28 | { 29 | "id": "1", 30 | "scenegroup": "1" 31 | }, 32 | { 33 | "id": "2", 34 | "scenegroup": "2", 35 | "isSingle": "1" 36 | 37 | } 38 | ], 39 | "SceneGroup": [ 40 | { 41 | "id": "1", 42 | "top": "0", 43 | "left": "0.1", 44 | "x": "1.5", 45 | "y": "2" 46 | }, 47 | { 48 | "id": "2", 49 | "top": "2", 50 | "left": "0.15", 51 | "x": "3", 52 | "y": "3" 53 | } 54 | ], 55 | "Control": [ 56 | { 57 | "ControlGroup": "1", 58 | "ControlType": "label", 59 | "text_align": "right", 60 | "Label": { 61 | "lang_tag": "sketch_name", 62 | "text": "Sketch Name:" 63 | }, 64 | "top": "0.4", 65 | "left": "-0.8", 66 | "x": "1.35", 67 | "y": "1", 68 | "Display": { 69 | "Top": 75, 70 | "Left": 25, 71 | "Width": 150, 72 | "Height": 20 73 | } 74 | }, 75 | { 76 | "ControlGroup": "1", 77 | "ControlType": "variable", 78 | "text_align": "left", 79 | "top": "0.4", 80 | "left": "0.6", 81 | "x": "2", 82 | "y": "1", 83 | "Display": { 84 | "Service": "urn:upnp-arduino-cc:serviceId:arduinonode1", 85 | "Variable": "SketchName", 86 | "Value": "1", 87 | "Top": 75, 88 | "Left": 110, 89 | "Width": 100, 90 | "Height": 20 91 | } 92 | }, 93 | { 94 | "ControlGroup": "1", 95 | "ControlType": "label", 96 | "text_align": "right", 97 | "Label": { 98 | "lang_tag": "sketch_version", 99 | "text": "Sketch Version:" 100 | }, 101 | "top": "1.1", 102 | "left": "-0.9", 103 | "x": "1.45", 104 | "y": "1", 105 | "Display": { 106 | "Top": 95, 107 | "Left": 25, 108 | "Width": 150, 109 | "Height": 20 110 | } 111 | }, 112 | { 113 | "ControlGroup": "1", 114 | "ControlType": "variable", 115 | "text_align": "left", 116 | "top": "1.1", 117 | "left": "0.6", 118 | "x": "2", 119 | "y": "1", 120 | "Display": { 121 | "Service": "urn:upnp-arduino-cc:serviceId:arduinonode1", 122 | "Variable": "SketchVersion", 123 | "Value": "1", 124 | "Top": 95, 125 | "Left": 110, 126 | "Width": 100, 127 | "Height": 20 128 | } 129 | }, 130 | { 131 | "ControlGroup": "1", 132 | "ControlType": "label", 133 | "text_align": "right", 134 | "top": "1.8", 135 | "left": "-0.8", 136 | "x": "1.35", 137 | "y": "1", 138 | "Label": { 139 | "lang_tag": "gateway_version", 140 | "text": "Lib Version:" 141 | }, 142 | "Display": { 143 | "Top": 115, 144 | "Left": 25, 145 | "Width": 150, 146 | "Height": 20 147 | } 148 | }, 149 | { 150 | "ControlGroup": "1", 151 | "ControlType": "variable", 152 | "text_align": "left", 153 | "top": "1.8", 154 | "left": "0.6", 155 | "x": "2", 156 | "y": "1", 157 | "Display": { 158 | "Service": "urn:upnp-arduino-cc:serviceId:arduinonode1", 159 | "Variable": "ArduinoLibVersion", 160 | "Value": "1", 161 | "Top": 115, 162 | "Left": 110, 163 | "Width": 100, 164 | "Height": 20 165 | } 166 | }, 167 | 168 | 169 | { 170 | "ControlGroup": "1", 171 | "ControlType": "label", 172 | "text_align": "right", 173 | "top": "2.5", 174 | "left": "-0.8", 175 | "x": "1.35", 176 | "y": "1", 177 | "Label": { 178 | "lang_tag": "relay_label", 179 | "text": "Parent node:" 180 | }, 181 | "Display": { 182 | "Top": 135, 183 | "Left": 25, 184 | "Width": 150, 185 | "Height": 20 186 | } 187 | }, 188 | { 189 | "ControlGroup": "1", 190 | "ControlType": "variable", 191 | "text_align": "left", 192 | "top": "2.5", 193 | "left": "0.6", 194 | "x": "2", 195 | "y": "1", 196 | "Display": { 197 | "Service": "urn:upnp-arduino-cc:serviceId:arduinonode1", 198 | "Variable": "RelayNodeHR", 199 | "Value": "1", 200 | "Top": 135, 201 | "Left": 110, 202 | "Width": 100, 203 | "Height": 20 204 | } 205 | }, 206 | 207 | { 208 | "ControlGroup": "1", 209 | "ControlType": "label", 210 | "text_align": "right", 211 | "top": "3.2", 212 | "left": "-0.8", 213 | "x": "1.35", 214 | "y": "1", 215 | "Label": { 216 | "lang_tag": "last_update_label", 217 | "text": "Last Update:" 218 | }, 219 | "Display": { 220 | "Top": 155, 221 | "Left": 25, 222 | "Width": 300, 223 | "Height": 20 224 | } 225 | }, 226 | { 227 | "ControlGroup": "1", 228 | "ControlType": "variable", 229 | "text_align": "left", 230 | "top": "3.2", 231 | "left": "0.6", 232 | "x": "2", 233 | "y": "1", 234 | "Display": { 235 | "Service": "urn:micasaverde-com:serviceId:HaDevice1", 236 | "Variable": "LastUpdateHR", 237 | "Value": "1", 238 | "Top": 155, 239 | "Left": 120, 240 | "Width": 300, 241 | "Height": 20 242 | } 243 | }, 244 | 245 | 246 | 247 | { 248 | "ControlType": "label", 249 | "text_align": "left", 250 | "top": "0.65", 251 | "left": "-0.3", 252 | "x": "2.25", 253 | "y": "1", 254 | "Label": { 255 | "lang_tag": "neighbors", 256 | "text": "Child nodes" 257 | }, 258 | "Display": { 259 | "Top": 23, 260 | "Left": 25, 261 | "Width": 150, 262 | "Height": 20 263 | } 264 | }, 265 | 266 | { 267 | "ControlType": "button", 268 | "top": "0.4", 269 | "left": "1", 270 | 271 | "Label": { 272 | "lang_tag": "clear_child_routes", 273 | "text": "Clear" 274 | }, 275 | "Display": { 276 | "Service": "urn:upnp-arduino-cc:serviceId:arduinonode1", 277 | "Variable": "Routing table", 278 | "Value": "Clearing...", 279 | "Top": 15, 280 | "Left": 200, 281 | "Width": 160, 282 | "Height": 20 283 | }, 284 | "Command": { 285 | "Service": "urn:upnp-arduino-cc:serviceId:arduinonode1", 286 | "Action": "ClearChildren", 287 | "Parameters": [] 288 | } 289 | }, 290 | 291 | 292 | { 293 | "ControlType": "variable", 294 | "text_align": "left", 295 | "top": "1.5", 296 | "left": "-0.3", 297 | "x": "2.25", 298 | "y": "1", 299 | "Display": { 300 | "Service": "urn:upnp-arduino-cc:serviceId:arduinonode1", 301 | "Variable": "Children", 302 | "Value": "", 303 | "Top": 45, 304 | "Left": 25, 305 | "Width": 300, 306 | "Height": 20 307 | } 308 | } 309 | 310 | ] 311 | }, 312 | { 313 | "Label": { 314 | "lang_tag": "advanced", 315 | "text": "Advanced" 316 | }, 317 | "Position": "1", 318 | "TabType": "javascript", 319 | "ScriptName": "shared.js", 320 | "Function": "advanced_device" 321 | } 322 | ], 323 | "DeviceType": "urn:schemas-arduino-cc:device:arduinonode:1" 324 | } 325 | -------------------------------------------------------------------------------- /D_ArduinoRelay1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | urn:schemas-arduino-cc:device:arduinorelay:1 9 | D_ArduinoRelay1.json 10 | Arduino Relay Node 11 | Arduino 12 | http://www.arduino.cc 13 | Arduino with nRF24L01 transceiver 14 | 15 | 1.0 16 | 17 | 18 | urn:schemas-arduino-cc:service:arduinonode:1 19 | urn:upnp-arduino-cc:serviceId:arduinonode1 20 | S_ArduinoNode.xml 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /I_Arduino1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | local p 5 | 6 | function startup(lul_device) 7 | luup.log("Arduino plugin: loading library L_Arduino ...") 8 | if (package.path:find ("/etc/cmh-ludl/?.lua;/etc/cmh-lu/?.lua", 1, true) == nil) then 9 | package.path = package.path .. ";/etc/cmh-ludl/?.lua;/etc/cmh-lu/?.lua" 10 | end 11 | 12 | package.loaded.L_Arduino = nil 13 | p = require("L_Arduino") 14 | if (package.loaded.L_Arduino == nil) 15 | then 16 | luup.log("Arduino plugin: plugin is not installed correctly. Library L_Arduino cannot be loaded.", 1) 17 | luup.task("Plugin not correctly installed", 2, "Arduino plugin", -1) 18 | return false 19 | end 20 | 21 | luup.log("Arduino plugin: library L_Arduino loaded") 22 | 23 | return p.startup(lul_device) 24 | end 25 | 26 | 27 | 28 | if (p ~= nil) then p.processIncoming(lul_data) end 29 | 30 | 31 | startup 32 | 33 | 34 | urn:upnp-org:serviceId:SwitchPower1 35 | SetTarget 36 | 37 | if (p ~= nil) then p.switchPower(lul_device, lul_settings.newTargetValue) end 38 | return 4,0 39 | 40 | 41 | 42 | urn:micasaverde-com:serviceId:HaDevice1 43 | ToggleState 44 | 45 | local status = luup.variable_get("urn:upnp-org:serviceId:SwitchPower1", "Status", lul_device) 46 | if(status=="0") then 47 | p.switchPower(lul_device, 1) 48 | return 4,0 49 | else 50 | p.switchPower(lul_device, 0) 51 | return 4,0 52 | end 53 | 54 | 55 | 56 | urn:upnp-org:serviceId:Dimming1 57 | SetLoadLevelTarget 58 | 59 | if (p ~= nil) then 60 | p.setDimmerLevel(lul_device, lul_settings.newLoadlevelTarget) 61 | if(lul_settings.newLoadlevelTarget ~= "0")then 62 | luup.variable_set("urn:upnp-org:serviceId:SwitchPower1","Status",1,lul_device) 63 | else 64 | luup.variable_set("urn:upnp-org:serviceId:SwitchPower1","Status",0,lul_device) 65 | end 66 | end 67 | return 4,0 68 | 69 | 70 | 71 | urn:micasaverde-com:serviceId:DoorLock1 72 | SetTarget 73 | 74 | if (p ~= nil) then p.setLockStatus(lul_device, lul_settings.newTargetValue) end 75 | return 4,0 76 | 77 | 78 | 79 | urn:upnp-org:serviceId:TemperatureSetpoint1 80 | SetCurrentSetpoint 81 | 82 | if (p ~= nil) then p.SetpointHeat(lul_device, lul_settings.NewCurrentSetpoint) end 83 | return 4,0 84 | 85 | 86 | 87 | urn:upnp-org:serviceId:TemperatureSetpoint1_Heat 88 | SetCurrentSetpoint 89 | 90 | if (p ~= nil) then p.SetpointHeat(lul_device, lul_settings.NewCurrentSetpoint) end 91 | return 4,0 92 | 93 | 94 | 95 | urn:upnp-org:serviceId:TemperatureSetpoint1_Cool 96 | SetCurrentSetpoint 97 | 98 | if (p ~= nil) then p.SetpointCool(lul_device, lul_settings.NewCurrentSetpoint) end 99 | return 4,0 100 | 101 | 102 | 103 | urn:upnp-org:serviceId:HVAC_UserOperatingMode1 104 | SetModeTarget 105 | 106 | if (p ~= nil) then p.SetOperatingMode(lul_device, lul_settings.NewModeTarget) end 107 | return 4,0 108 | 109 | 110 | 111 | urn:upnp-org:serviceId:HVAC_FanOperatingMode1 112 | SetMode 113 | 114 | if (p ~= nil) then p.SetFanMode(lul_device, lul_settings.NewMode) end 115 | return 4,0 116 | 117 | 118 | 119 | 120 | 121 | urn:upnp-org:serviceId:WindowCovering1 122 | Up 123 | 124 | if (p ~= nil) then p.windowCovering(lul_device, "UP") end 125 | return 4,0 126 | 127 | 128 | 129 | urn:upnp-org:serviceId:WindowCovering1 130 | Down 131 | 132 | if (p ~= nil) then p.windowCovering(lul_device, "DOWN") end 133 | return 4,0 134 | 135 | 136 | 137 | urn:upnp-org:serviceId:WindowCovering1 138 | Stop 139 | 140 | if (p ~= nil) then p.windowCovering(lul_device, "STOP") end 141 | return 4,0 142 | 143 | 144 | 145 | urn:micasaverde-com:serviceId:SecuritySensor1 146 | SetArmed 147 | 148 | if (p ~= nil) then p.setArmed(lul_device, lul_settings.newArmedValue) end 149 | return 4,0 150 | 151 | 152 | 153 | urn:upnp-arduino-cc:serviceId:arduino1 154 | SendCommand 155 | 156 | if (p ~= nil) then p.sendCommand(lul_settings.radioId, lul_settings.variableId, lul_settings.value) end 157 | return 4,0 158 | 159 | 160 | 161 | urn:upnp-arduino-cc:serviceId:arduinonode1 162 | SendNodeCommand 163 | 164 | if (p ~= nil) then p.sendNodeCommand(lul_device, lul_settings.variableId, lul_settings.value) end 165 | return 4,0 166 | 167 | 168 | 169 | urn:upnp-arduino-cc:serviceId:arduinonode1 170 | ClearChildren 171 | 172 | if (p ~= nil) then p.clearChildren(lul_device) end 173 | return 4,0 174 | 175 | 176 | 177 | urn:upnp-arduino-cc:serviceId:arduino1 178 | SetUnit 179 | 180 | if (p ~= nil) then p.setUnit(lul_settings.unit) end 181 | return 4,0 182 | 183 | 184 | 185 | urn:upnp-arduino-cc:serviceId:arduino1 186 | StartInclusion 187 | 188 | if (p ~= nil) then p.startInclusion(lul_device) end 189 | return 4,0 190 | 191 | 192 | 193 | urn:upnp-arduino-cc:serviceId:arduino1 194 | StopInclusion 195 | 196 | if (p ~= nil) then p.stopInclusion(lul_device) end 197 | return 4,0 198 | 199 | 200 | 201 | urn:schemas-arduino-cc:serviceId:ArduinoIr1 202 | SendIrCode 203 | 204 | if (p ~= nil) then p.sendIrCommand(lul_device, lul_settings.Index) end 205 | return 4,0 206 | 207 | 208 | 209 | urn:schemas-arduino-cc:serviceId:ArduinoIr1 210 | RecordIrCode 211 | 212 | luup.log("Record IR code #" .. lul_settings.Index .. " with name: " .. lul_settings.CodeName) 213 | if (p ~= nil) then p.recordIrCode(lul_device, lul_settings.Index, lul_settings.CodeName) end 214 | return 4,0 215 | 216 | 217 | 218 | urn:upnp-org:serviceId:LcdText1 219 | SetLcdText 220 | 221 | if (p ~= nil) then p.SetLcdText(lul_device, lul_settings.NewLcdText) end 222 | return 4,0 223 | 224 | 225 | 226 | 227 | -------------------------------------------------------------------------------- /IrRecordPlayback/D_ArduinoIr1.json: -------------------------------------------------------------------------------- 1 | { 2 | "flashicon": "http://www.mysensors.org/icon/RemoteControl.png", 3 | "imgIconBody": "", 4 | "imgIconDimmable": "", 5 | "imgIconTurnable": "", 6 | "imgIconMin": "", 7 | "imgIconMax": "", 8 | "halloIconsDir": "pics/hallo", 9 | "state_icons": [ 10 | "RemoteControl_0.png", 11 | "RemoteControl_100.png" 12 | ], 13 | "x": "2", 14 | "y": "4", 15 | "inScene": "1", 16 | "DisplayStatus": { 17 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 18 | "Variable": "Recording", 19 | "MinValue": "0", 20 | "MaxValue": "1" 21 | }, 22 | "doc_url": { 23 | "doc_language": 1, 24 | "doc_manual": 1, 25 | "doc_version": 1, 26 | "doc_platform": 0, 27 | "doc_page": "sensors" 28 | }, 29 | "Tabs": [ 30 | { 31 | "Label": { 32 | "lang_tag": "tabname_control", 33 | "text": "Information" 34 | }, 35 | "Position": "0", 36 | "TabType": "flash", 37 | "SceneGroup": [ 38 | { 39 | "id": "1", 40 | "top": "0", 41 | "left": "0", 42 | "x": "2", 43 | "y": "2" 44 | } 45 | ], 46 | "ControlGroup": [ 47 | { 48 | "id": "1", 49 | "scenegroup": "1" 50 | } 51 | ], 52 | "Control": [ 53 | { 54 | "ControlType": "label", 55 | "Label": { 56 | "lang_tag": "IrCode", 57 | "text": "Preset 1:" 58 | }, 59 | "Display": { 60 | "Top": 15, 61 | "Left": 45, 62 | "Width": 75, 63 | "Height": 20 64 | } 65 | }, 66 | { 67 | "ControlType": "variable", 68 | "ControlGroup": "1", 69 | "top": "0.4", 70 | "left": "0", 71 | "x": "1", 72 | "y": "1", 73 | "Display": { 74 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 75 | "Variable": "IrCodeName1", 76 | "Top": 15, 77 | "Left": 110, 78 | "Width": 120, 79 | "Height": 20 80 | } 81 | }, 82 | { 83 | "ControlType": "label", 84 | "Label": { 85 | "lang_tag": "NewName", 86 | "text": "New name:" 87 | }, 88 | "Display": { 89 | "Top": 15, 90 | "Left": 220, 91 | "Width": 50, 92 | "Height": 20 93 | } 94 | }, 95 | { 96 | "ControlType": "input", 97 | "ID": "NewIrText1", 98 | "Display": { 99 | "Top": 10, 100 | "Left": 300, 101 | "Width": 120, 102 | "Height": 20 103 | } 104 | }, 105 | { 106 | "ControlType": "button", 107 | "Label": { 108 | "lang_tag": "cmd_add", 109 | "text": "Record IR" 110 | }, 111 | "Display": { 112 | "Top": 10, 113 | "Left": 450, 114 | "Width": 90, 115 | "Height": 20 116 | }, 117 | "Command": { 118 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 119 | "Action": "RecordIrCode", 120 | "Parameters": [ 121 | { 122 | "Name": "Index", 123 | "Value": "1" 124 | }, 125 | { 126 | "Name": "CodeName", 127 | "ID": "NewIrText1" 128 | } 129 | ] 130 | } 131 | }, 132 | { 133 | "ControlGroup": "1", 134 | "ControlType": "button", 135 | "top": "0.0", 136 | "left": "0", 137 | "x": "1", 138 | "y": "1", 139 | "Label": { 140 | "lang_tag": "cmd_on", 141 | "text": "" 142 | }, 143 | "Display": { 144 | "Top": 10, 145 | "Left": 550, 146 | "Width": 40, 147 | "Height": 20 148 | }, 149 | "Command": { 150 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 151 | "Action": "SendIrCode", 152 | "Parameters": [ 153 | { 154 | "Name": "Index", 155 | "Value": "1" 156 | } 157 | ] 158 | } 159 | }, 160 | 161 | { 162 | "ControlType": "label", 163 | "Label": { 164 | "lang_tag": "IrCode", 165 | "text": "Preset 2:" 166 | }, 167 | "Display": { 168 | "Top": 45, 169 | "Left": 45, 170 | "Width": 75, 171 | "Height": 20 172 | } 173 | }, 174 | { 175 | "ControlGroup": "1", 176 | "top": "1.1", 177 | "left": "0", 178 | "x": "1", 179 | "y": "1", 180 | "ControlType": "variable", 181 | "Display": { 182 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 183 | "Variable": "IrCodeName2", 184 | "Top": 45, 185 | "Left": 110, 186 | "Width": 120, 187 | "Height": 20 188 | } 189 | }, 190 | { 191 | "ControlType": "label", 192 | "Label": { 193 | "lang_tag": "NewName", 194 | "text": "New name:" 195 | }, 196 | "Display": { 197 | "Top": 45, 198 | "Left": 220, 199 | "Width": 50, 200 | "Height": 20 201 | } 202 | }, 203 | { 204 | "ControlType": "input", 205 | "ID": "NewIrText2", 206 | "Display": { 207 | "Top": 40, 208 | "Left": 300, 209 | "Width": 120, 210 | "Height": 20 211 | } 212 | }, 213 | { 214 | "ControlType": "button", 215 | "Label": { 216 | "lang_tag": "cmd_add", 217 | "text": "Record IR" 218 | }, 219 | "Display": { 220 | "Top": 40, 221 | "Left": 450, 222 | "Width": 90, 223 | "Height": 20 224 | }, 225 | "Command": { 226 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 227 | "Action": "RecordIrCode", 228 | "Parameters": [ 229 | { 230 | "Name": "Index", 231 | "Value": "2" 232 | }, 233 | { 234 | "Name": "CodeName", 235 | "ID": "NewIrText2" 236 | } 237 | ] 238 | } 239 | }, 240 | { 241 | "ControlGroup": "1", 242 | "ControlType": "button", 243 | "top": "1.1", 244 | "left": "0", 245 | "x": "1", 246 | "y": "1", 247 | "Label": { 248 | "lang_tag": "cmd_on", 249 | "text": "" 250 | }, 251 | "Display": { 252 | "Top": 40, 253 | "Left": 550, 254 | "Width": 40, 255 | "Height": 20 256 | }, 257 | "Command": { 258 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 259 | "Action": "SendIrCode", 260 | "Parameters": [ 261 | { 262 | "Name": "Index", 263 | "Value": "2" 264 | } 265 | ] 266 | } 267 | }, 268 | 269 | 270 | { 271 | "ControlType": "label", 272 | "Label": { 273 | "lang_tag": "IrCode", 274 | "text": "Preset 3:" 275 | }, 276 | "Display": { 277 | "Top": 75, 278 | "Left": 45, 279 | "Width": 75, 280 | "Height": 20 281 | } 282 | }, 283 | { 284 | "ControlType": "variable", 285 | "ControlGroup": "1", 286 | "top": "1.8", 287 | "left": "0", 288 | "x": "1", 289 | "y": "1", 290 | "Display": { 291 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 292 | "Variable": "IrCodeName3", 293 | "Top": 75, 294 | "Left": 110, 295 | "Width": 120, 296 | "Height": 20 297 | } 298 | }, 299 | { 300 | "ControlType": "label", 301 | "Label": { 302 | "lang_tag": "NewName", 303 | "text": "New name:" 304 | }, 305 | "Display": { 306 | "Top": 75, 307 | "Left": 220, 308 | "Width": 50, 309 | "Height": 20 310 | } 311 | }, 312 | { 313 | "ControlType": "input", 314 | "ID": "NewIrText3", 315 | "Display": { 316 | "Top": 70, 317 | "Left": 300, 318 | "Width": 120, 319 | "Height": 20 320 | } 321 | }, 322 | { 323 | "ControlType": "button", 324 | "Label": { 325 | "lang_tag": "cmd_add", 326 | "text": "Record IR" 327 | }, 328 | "Display": { 329 | "Top": 70, 330 | "Left": 450, 331 | "Width": 90, 332 | "Height": 20 333 | }, 334 | "Command": { 335 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 336 | "Action": "RecordIrCode", 337 | "Parameters": [ 338 | { 339 | "Name": "Index", 340 | "Value": "3" 341 | }, 342 | { 343 | "Name": "CodeName", 344 | "ID": "NewIrText3" 345 | } 346 | ] 347 | } 348 | }, 349 | { 350 | "ControlGroup": "1", 351 | "ControlType": "button", 352 | "top": "1.8", 353 | "left": "0", 354 | "x": "1", 355 | "y": "1", 356 | "Label": { 357 | "lang_tag": "cmd_on", 358 | "text": "" 359 | }, 360 | "Display": { 361 | "Top": 70, 362 | "Left": 550, 363 | "Width": 40, 364 | "Height": 20 365 | }, 366 | "Command": { 367 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 368 | "Action": "SendIrCode", 369 | "Parameters": [ 370 | { 371 | "Name": "Index", 372 | "Value": "3" 373 | } 374 | ] 375 | } 376 | }, 377 | 378 | { 379 | "ControlType": "label", 380 | "Label": { 381 | "lang_tag": "IrCode", 382 | "text": "Preset 4:" 383 | }, 384 | "Display": { 385 | "Top": 105, 386 | "Left": 45, 387 | "Width": 75, 388 | "Height": 20 389 | } 390 | }, 391 | { 392 | "ControlType": "variable", 393 | "ControlGroup": "1", 394 | "top": "2.5", 395 | "left": "0", 396 | "x": "1", 397 | "y": "1", 398 | "Display": { 399 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 400 | "Variable": "IrCodeName4", 401 | "Top": 105, 402 | "Left": 110, 403 | "Width": 120, 404 | "Height": 20 405 | } 406 | }, 407 | { 408 | "ControlType": "label", 409 | "Label": { 410 | "lang_tag": "NewName", 411 | "text": "New name:" 412 | }, 413 | "Display": { 414 | "Top": 105, 415 | "Left": 220, 416 | "Width": 50, 417 | "Height": 20 418 | } 419 | }, 420 | { 421 | "ControlType": "input", 422 | "ID": "NewIrText4", 423 | "Display": { 424 | "Top": 100, 425 | "Left": 300, 426 | "Width": 120, 427 | "Height": 20 428 | } 429 | }, 430 | { 431 | "ControlType": "button", 432 | "Label": { 433 | "lang_tag": "cmd_add", 434 | "text": "Record IR" 435 | }, 436 | "Display": { 437 | "Top": 100, 438 | "Left": 450, 439 | "Width": 90, 440 | "Height": 20 441 | }, 442 | "Command": { 443 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 444 | "Action": "RecordIrCode", 445 | "Parameters": [ 446 | { 447 | "Name": "Index", 448 | "Value": "4" 449 | }, 450 | { 451 | "Name": "CodeName", 452 | "ID": "NewIrText4" 453 | } 454 | ] 455 | } 456 | }, 457 | { 458 | "ControlGroup": "1", 459 | "ControlType": "button", 460 | "top": "2.5", 461 | "left": "0", 462 | "x": "1", 463 | "y": "1", 464 | "Label": { 465 | "lang_tag": "cmd_on", 466 | "text": "" 467 | }, 468 | "Display": { 469 | "Top": 100, 470 | "Left": 550, 471 | "Width": 40, 472 | "Height": 20 473 | }, 474 | "Command": { 475 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 476 | "Action": "SendIrCode", 477 | "Parameters": [ 478 | { 479 | "Name": "Index", 480 | "Value": "4" 481 | } 482 | ] 483 | } 484 | }, 485 | 486 | { 487 | "ControlType": "label", 488 | "Label": { 489 | "lang_tag": "IrCode", 490 | "text": "Preset 5:" 491 | }, 492 | "Display": { 493 | "Top": 135, 494 | "Left": 45, 495 | "Width": 75, 496 | "Height": 20 497 | } 498 | }, 499 | { 500 | "ControlType": "variable", 501 | "ControlGroup": "1", 502 | "top": "3.2", 503 | "left": "0", 504 | "x": "1", 505 | "y": "1", 506 | "Display": { 507 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 508 | "Variable": "IrCodeName5", 509 | "Top": 135, 510 | "Left": 110, 511 | "Width": 120, 512 | "Height": 20 513 | } 514 | }, 515 | { 516 | "ControlType": "label", 517 | "Label": { 518 | "lang_tag": "NewName", 519 | "text": "New name:" 520 | }, 521 | "Display": { 522 | "Top": 135, 523 | "Left": 220, 524 | "Width": 50, 525 | "Height": 20 526 | } 527 | }, 528 | { 529 | "ControlType": "input", 530 | "ID": "NewIrText5", 531 | "Display": { 532 | "Top": 130, 533 | "Left": 300, 534 | "Width": 120, 535 | "Height": 20 536 | } 537 | }, 538 | { 539 | "ControlType": "button", 540 | "Label": { 541 | "lang_tag": "cmd_add", 542 | "text": "Record IR" 543 | }, 544 | "Display": { 545 | "Top": 130, 546 | "Left": 450, 547 | "Width": 90, 548 | "Height": 20 549 | }, 550 | "Command": { 551 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 552 | "Action": "RecordIrCode", 553 | "Parameters": [ 554 | { 555 | "Name": "Index", 556 | "Value": "5" 557 | }, 558 | { 559 | "Name": "CodeName", 560 | "ID": "NewIrText5" 561 | } 562 | ] 563 | } 564 | }, 565 | { 566 | "ControlGroup": "1", 567 | "ControlType": "button", 568 | "top": "3.2", 569 | "left": "0", 570 | "x": "1", 571 | "y": "1", 572 | "Label": { 573 | "lang_tag": "cmd_on", 574 | "text": "" 575 | }, 576 | "Display": { 577 | "Top": 130, 578 | "Left": 550, 579 | "Width": 40, 580 | "Height": 20 581 | }, 582 | "Command": { 583 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 584 | "Action": "SendIrCode", 585 | "Parameters": [ 586 | { 587 | "Name": "Index", 588 | "Value": "5" 589 | } 590 | ] 591 | } 592 | }, 593 | 594 | { 595 | "ControlType": "label", 596 | "Label": { 597 | "lang_tag": "IrCode", 598 | "text": "Preset 6:" 599 | }, 600 | "Display": { 601 | "Top": 165, 602 | "Left": 45, 603 | "Width": 75, 604 | "Height": 20 605 | } 606 | }, 607 | { 608 | "ControlType": "variable", 609 | "ControlGroup": "1", 610 | "top": "0.4", 611 | "left": "1", 612 | "x": "1", 613 | "y": "1", 614 | "Display": { 615 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 616 | "Variable": "IrCodeName6", 617 | "Top": 165, 618 | "Left": 110, 619 | "Width": 120, 620 | "Height": 20 621 | } 622 | }, 623 | { 624 | "ControlType": "label", 625 | "Label": { 626 | "lang_tag": "NewName", 627 | "text": "New name:" 628 | }, 629 | "Display": { 630 | "Top": 165, 631 | "Left": 220, 632 | "Width": 50, 633 | "Height": 20 634 | } 635 | }, 636 | { 637 | "ControlType": "input", 638 | "ID": "NewIrText6", 639 | "Display": { 640 | "Top": 160, 641 | "Left": 300, 642 | "Width": 120, 643 | "Height": 20 644 | } 645 | }, 646 | { 647 | "ControlType": "button", 648 | "Label": { 649 | "lang_tag": "cmd_add", 650 | "text": "Record IR" 651 | }, 652 | "Display": { 653 | "Top": 160, 654 | "Left": 450, 655 | "Width": 90, 656 | "Height": 20 657 | }, 658 | "Command": { 659 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 660 | "Action": "RecordIrCode", 661 | "Parameters": [ 662 | { 663 | "Name": "Index", 664 | "Value": "6" 665 | }, 666 | { 667 | "Name": "CodeName", 668 | "ID": "NewIrText6" 669 | } 670 | ] 671 | } 672 | }, 673 | { 674 | "ControlGroup": "1", 675 | "ControlType": "button", 676 | "top": "0.0", 677 | "left": "1", 678 | "x": "1", 679 | "y": "1", 680 | "Label": { 681 | "lang_tag": "cmd_on", 682 | "text": "" 683 | }, 684 | "Display": { 685 | "Top": 160, 686 | "Left": 550, 687 | "Width": 40, 688 | "Height": 20 689 | }, 690 | "Command": { 691 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 692 | "Action": "SendIrCode", 693 | "Parameters": [ 694 | { 695 | "Name": "Index", 696 | "Value": "6" 697 | } 698 | ] 699 | } 700 | }, 701 | 702 | { 703 | "ControlType": "label", 704 | "Label": { 705 | "lang_tag": "IrCode", 706 | "text": "Preset 7:" 707 | }, 708 | "Display": { 709 | "Top": 195, 710 | "Left": 45, 711 | "Width": 75, 712 | "Height": 20 713 | } 714 | }, 715 | { 716 | "ControlType": "variable", 717 | "ControlGroup": "1", 718 | "top": "1.1", 719 | "left": "1", 720 | "x": "1", 721 | "y": "1", 722 | "Display": { 723 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 724 | "Variable": "IrCodeName7", 725 | "Top": 195, 726 | "Left": 110, 727 | "Width": 120, 728 | "Height": 20 729 | } 730 | }, 731 | { 732 | "ControlType": "label", 733 | "Label": { 734 | "lang_tag": "NewName", 735 | "text": "New name:" 736 | }, 737 | "Display": { 738 | "Top": 195, 739 | "Left": 220, 740 | "Width": 50, 741 | "Height": 20 742 | } 743 | }, 744 | { 745 | "ControlType": "input", 746 | "ID": "NewIrText7", 747 | "Display": { 748 | "Top": 190, 749 | "Left": 300, 750 | "Width": 120, 751 | "Height": 20 752 | } 753 | }, 754 | { 755 | "ControlType": "button", 756 | "Label": { 757 | "lang_tag": "cmd_add", 758 | "text": "Record IR" 759 | }, 760 | "Display": { 761 | "Top": 190, 762 | "Left": 450, 763 | "Width": 90, 764 | "Height": 20 765 | }, 766 | "Command": { 767 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 768 | "Action": "RecordIrCode", 769 | "Parameters": [ 770 | { 771 | "Name": "Index", 772 | "Value": "7" 773 | }, 774 | { 775 | "Name": "CodeName", 776 | "ID": "NewIrText7" 777 | } 778 | ] 779 | } 780 | }, 781 | { 782 | "ControlGroup": "1", 783 | "ControlType": "button", 784 | "top": "1.1", 785 | "left": "1", 786 | "x": "1", 787 | "y": "1", 788 | "Label": { 789 | "lang_tag": "cmd_on", 790 | "text": "" 791 | }, 792 | "Display": { 793 | "Top": 190, 794 | "Left": 550, 795 | "Width": 40, 796 | "Height": 20 797 | }, 798 | "Command": { 799 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 800 | "Action": "SendIrCode", 801 | "Parameters": [ 802 | { 803 | "Name": "Index", 804 | "Value": "7" 805 | } 806 | ] 807 | } 808 | }, 809 | 810 | { 811 | "ControlType": "label", 812 | "Label": { 813 | "lang_tag": "IrCode", 814 | "text": "Preset 8:" 815 | }, 816 | "Display": { 817 | "Top": 225, 818 | "Left": 45, 819 | "Width": 75, 820 | "Height": 20 821 | } 822 | }, 823 | { 824 | "ControlType": "variable", 825 | "ControlGroup": "1", 826 | "top": "1.8", 827 | "left": "1", 828 | "x": "1", 829 | "y": "1", 830 | "Display": { 831 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 832 | "Variable": "IrCodeName8", 833 | "Top": 225, 834 | "Left": 110, 835 | "Width": 120, 836 | "Height": 20 837 | } 838 | }, 839 | { 840 | "ControlType": "label", 841 | "Label": { 842 | "lang_tag": "NewName", 843 | "text": "New name:" 844 | }, 845 | "Display": { 846 | "Top": 225, 847 | "Left": 220, 848 | "Width": 50, 849 | "Height": 20 850 | } 851 | }, 852 | { 853 | "ControlType": "input", 854 | "ID": "NewIrText8", 855 | "Display": { 856 | "Top": 220, 857 | "Left": 300, 858 | "Width": 120, 859 | "Height": 20 860 | } 861 | }, 862 | { 863 | "ControlType": "button", 864 | "Label": { 865 | "lang_tag": "cmd_add", 866 | "text": "Record IR" 867 | }, 868 | "Display": { 869 | "Top": 220, 870 | "Left": 450, 871 | "Width": 90, 872 | "Height": 20 873 | }, 874 | "Command": { 875 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 876 | "Action": "RecordIrCode", 877 | "Parameters": [ 878 | { 879 | "Name": "Index", 880 | "Value": "8" 881 | }, 882 | { 883 | "Name": "CodeName", 884 | "ID": "NewIrText8" 885 | } 886 | ] 887 | } 888 | }, 889 | { 890 | "ControlGroup": "1", 891 | "ControlType": "button", 892 | "top": "1.8", 893 | "left": "1", 894 | "x": "1", 895 | "y": "1", 896 | "Label": { 897 | "lang_tag": "cmd_on", 898 | "text": "" 899 | }, 900 | "Display": { 901 | "Top": 220, 902 | "Left": 550, 903 | "Width": 40, 904 | "Height": 20 905 | }, 906 | "Command": { 907 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 908 | "Action": "SendIrCode", 909 | "Parameters": [ 910 | { 911 | "Name": "Index", 912 | "Value": "8" 913 | } 914 | ] 915 | } 916 | }, 917 | 918 | 919 | { 920 | "ControlType": "label", 921 | "Label": { 922 | "lang_tag": "IrCode", 923 | "text": "Preset 9:" 924 | }, 925 | "Display": { 926 | "Top": 255, 927 | "Left": 45, 928 | "Width": 75, 929 | "Height": 20 930 | } 931 | }, 932 | { 933 | "ControlType": "variable", 934 | "ControlGroup": "1", 935 | "top": "2.5", 936 | "left": "1", 937 | "x": "1", 938 | "y": "1", 939 | "Display": { 940 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 941 | "Variable": "IrCodeName9", 942 | "Top": 255, 943 | "Left": 110, 944 | "Width": 120, 945 | "Height": 20 946 | } 947 | }, 948 | { 949 | "ControlType": "label", 950 | "Label": { 951 | "lang_tag": "NewName", 952 | "text": "New name:" 953 | }, 954 | "Display": { 955 | "Top": 255, 956 | "Left": 220, 957 | "Width": 50, 958 | "Height": 20 959 | } 960 | }, 961 | { 962 | "ControlType": "input", 963 | "ID": "NewIrText9", 964 | "Display": { 965 | "Top": 250, 966 | "Left": 300, 967 | "Width": 120, 968 | "Height": 20 969 | } 970 | }, 971 | { 972 | "ControlType": "button", 973 | "Label": { 974 | "lang_tag": "cmd_add", 975 | "text": "Record IR" 976 | }, 977 | "Display": { 978 | "Top": 250, 979 | "Left": 450, 980 | "Width": 90, 981 | "Height": 20 982 | }, 983 | "Command": { 984 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 985 | "Action": "RecordIrCode", 986 | "Parameters": [ 987 | { 988 | "Name": "Index", 989 | "Value": "9" 990 | }, 991 | { 992 | "Name": "CodeName", 993 | "ID": "NewIrText9" 994 | } 995 | ] 996 | } 997 | }, 998 | { 999 | "ControlGroup": "1", 1000 | "ControlType": "button", 1001 | "top": "2.5", 1002 | "left": "1", 1003 | "x": "1", 1004 | "y": "1", 1005 | "Label": { 1006 | "lang_tag": "cmd_on", 1007 | "text": "" 1008 | }, 1009 | "Display": { 1010 | "Top": 250, 1011 | "Left": 550, 1012 | "Width": 40, 1013 | "Height": 20 1014 | }, 1015 | "Command": { 1016 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 1017 | "Action": "SendIrCode", 1018 | "Parameters": [ 1019 | { 1020 | "Name": "Index", 1021 | "Value": "9" 1022 | } 1023 | ] 1024 | } 1025 | }, 1026 | 1027 | { 1028 | "ControlType": "label", 1029 | "Label": { 1030 | "lang_tag": "IrCode", 1031 | "text": "Preset 10:" 1032 | }, 1033 | "Display": { 1034 | "Top": 285, 1035 | "Left": 45, 1036 | "Width": 75, 1037 | "Height": 20 1038 | } 1039 | }, 1040 | { 1041 | "ControlType": "variable", 1042 | "ControlGroup": "1", 1043 | "top": "3.2", 1044 | "left": "1", 1045 | "x": "1", 1046 | "y": "1", 1047 | "Display": { 1048 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 1049 | "Variable": "IrCodeName10", 1050 | "Top": 285, 1051 | "Left": 110, 1052 | "Width": 120, 1053 | "Height": 20 1054 | } 1055 | }, 1056 | { 1057 | "ControlType": "label", 1058 | "Label": { 1059 | "lang_tag": "NewName", 1060 | "text": "New name:" 1061 | }, 1062 | "Display": { 1063 | "Top": 285, 1064 | "Left": 220, 1065 | "Width": 50, 1066 | "Height": 20 1067 | } 1068 | }, 1069 | { 1070 | "ControlType": "input", 1071 | "ID": "NewIrText10", 1072 | "Display": { 1073 | "Top": 280, 1074 | "Left": 300, 1075 | "Width": 120, 1076 | "Height": 20 1077 | } 1078 | }, 1079 | { 1080 | "ControlType": "button", 1081 | "Label": { 1082 | "lang_tag": "cmd_add", 1083 | "text": "Record IR" 1084 | }, 1085 | "Display": { 1086 | "Top": 280, 1087 | "Left": 450, 1088 | "Width": 90, 1089 | "Height": 20 1090 | }, 1091 | "Command": { 1092 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 1093 | "Action": "RecordIrCode", 1094 | "Parameters": [ 1095 | { 1096 | "Name": "Index", 1097 | "Value": "10" 1098 | }, 1099 | { 1100 | "Name": "CodeName", 1101 | "ID": "NewIrText10" 1102 | } 1103 | ] 1104 | } 1105 | }, 1106 | { 1107 | "ControlGroup": "1", 1108 | "ControlType": "button", 1109 | "top": "3.2", 1110 | "left": "1", 1111 | "x": "1", 1112 | "y": "1", 1113 | "Label": { 1114 | "lang_tag": "cmd_on", 1115 | "text": "" 1116 | }, 1117 | "Display": { 1118 | "Top": 280, 1119 | "Left": 550, 1120 | "Width": 40, 1121 | "Height": 20 1122 | }, 1123 | "Command": { 1124 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 1125 | "Action": "SendIrCode", 1126 | "Parameters": [ 1127 | { 1128 | "Name": "Index", 1129 | "Value": "10" 1130 | } 1131 | ] 1132 | } 1133 | }, 1134 | 1135 | { 1136 | "ControlType": "label", 1137 | "ControlGroup": "1", 1138 | "top": "3.2", 1139 | "left": "-1.4", 1140 | "x": "1", 1141 | "y": "1", 1142 | "Label": { 1143 | "lang_tag": "IrCode", 1144 | "text": "Last #" 1145 | }, 1146 | "Display": { 1147 | "Top": 315, 1148 | "Left": 45, 1149 | "Width": 75, 1150 | "Height": 20 1151 | } 1152 | }, 1153 | { 1154 | "ControlType": "variable", 1155 | "ControlGroup": "1", 1156 | "top": "3.2", 1157 | "left": "-0.9", 1158 | "x": "1", 1159 | "y": "1", 1160 | "Display": { 1161 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 1162 | "Variable": "IrCode", 1163 | "Top": 315, 1164 | "Left": 120, 1165 | "Width": 20, 1166 | "Height": 20 1167 | } 1168 | }, 1169 | { 1170 | "ControlType": "button", 1171 | "top": "3.2", 1172 | "left": "1", 1173 | "Label": { 1174 | "lang_tag": "cmd_on", 1175 | "text": "P11" 1176 | }, 1177 | "Display": { 1178 | "Top": 310, 1179 | "Left": 165, 1180 | "Width": 40, 1181 | "Height": 20 1182 | }, 1183 | "Command": { 1184 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 1185 | "Action": "SendIrCode", 1186 | "Parameters": [ 1187 | { 1188 | "Name": "Index", 1189 | "Value": "11" 1190 | } 1191 | ] 1192 | } 1193 | }, 1194 | { 1195 | "ControlType": "button", 1196 | "top": "3.2", 1197 | "left": "1", 1198 | "Label": { 1199 | "lang_tag": "cmd_on", 1200 | "text": "P12" 1201 | }, 1202 | "Display": { 1203 | "Top": 310, 1204 | "Left": 210, 1205 | "Width": 40, 1206 | "Height": 20 1207 | }, 1208 | "Command": { 1209 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 1210 | "Action": "SendIrCode", 1211 | "Parameters": [ 1212 | { 1213 | "Name": "Index", 1214 | "Value": "12" 1215 | } 1216 | ] 1217 | } 1218 | }, 1219 | { 1220 | "ControlType": "button", 1221 | "top": "3.2", 1222 | "left": "1", 1223 | "Label": { 1224 | "lang_tag": "cmd_on", 1225 | "text": "P13" 1226 | }, 1227 | "Display": { 1228 | "Top": 310, 1229 | "Left": 255, 1230 | "Width": 40, 1231 | "Height": 20 1232 | }, 1233 | "Command": { 1234 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 1235 | "Action": "SendIrCode", 1236 | "Parameters": [ 1237 | { 1238 | "Name": "Index", 1239 | "Value": "13" 1240 | } 1241 | ] 1242 | } 1243 | }, 1244 | { 1245 | "ControlType": "button", 1246 | "top": "3.2", 1247 | "left": "1", 1248 | "Label": { 1249 | "lang_tag": "cmd_on", 1250 | "text": "P14" 1251 | }, 1252 | "Display": { 1253 | "Top": 310, 1254 | "Left": 300, 1255 | "Width": 40, 1256 | "Height": 20 1257 | }, 1258 | "Command": { 1259 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 1260 | "Action": "SendIrCode", 1261 | "Parameters": [ 1262 | { 1263 | "Name": "Index", 1264 | "Value": "14" 1265 | } 1266 | ] 1267 | } 1268 | }, 1269 | { 1270 | "ControlType": "button", 1271 | "top": "3.2", 1272 | "left": "1", 1273 | "Label": { 1274 | "lang_tag": "cmd_on", 1275 | "text": "P15" 1276 | }, 1277 | "Display": { 1278 | "Top": 310, 1279 | "Left": 345, 1280 | "Width": 40, 1281 | "Height": 20 1282 | }, 1283 | "Command": { 1284 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 1285 | "Action": "SendIrCode", 1286 | "Parameters": [ 1287 | { 1288 | "Name": "Index", 1289 | "Value": "15" 1290 | } 1291 | ] 1292 | } 1293 | }, 1294 | { 1295 | "ControlType": "button", 1296 | "top": "3.2", 1297 | "left": "1", 1298 | "Label": { 1299 | "lang_tag": "cmd_on", 1300 | "text": "P16" 1301 | }, 1302 | "Display": { 1303 | "Top": 310, 1304 | "Left": 390, 1305 | "Width": 40, 1306 | "Height": 20 1307 | }, 1308 | "Command": { 1309 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 1310 | "Action": "SendIrCode", 1311 | "Parameters": [ 1312 | { 1313 | "Name": "Index", 1314 | "Value": "16" 1315 | } 1316 | ] 1317 | } 1318 | }, 1319 | { 1320 | "ControlType": "button", 1321 | "top": "3.2", 1322 | "left": "1", 1323 | "Label": { 1324 | "lang_tag": "cmd_on", 1325 | "text": "P17" 1326 | }, 1327 | "Display": { 1328 | "Top": 310, 1329 | "Left": 435, 1330 | "Width": 40, 1331 | "Height": 20 1332 | }, 1333 | "Command": { 1334 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 1335 | "Action": "SendIrCode", 1336 | "Parameters": [ 1337 | { 1338 | "Name": "Index", 1339 | "Value": "17" 1340 | } 1341 | ] 1342 | } 1343 | }, 1344 | { 1345 | "ControlType": "button", 1346 | "top": "3.2", 1347 | "left": "1", 1348 | "Label": { 1349 | "lang_tag": "cmd_on", 1350 | "text": "P18" 1351 | }, 1352 | "Display": { 1353 | "Top": 310, 1354 | "Left": 480, 1355 | "Width": 40, 1356 | "Height": 20 1357 | }, 1358 | "Command": { 1359 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 1360 | "Action": "SendIrCode", 1361 | "Parameters": [ 1362 | { 1363 | "Name": "Index", 1364 | "Value": "18" 1365 | } 1366 | ] 1367 | } 1368 | }, 1369 | { 1370 | "ControlType": "button", 1371 | "top": "3.2", 1372 | "left": "1", 1373 | "Label": { 1374 | "lang_tag": "cmd_on", 1375 | "text": "P19" 1376 | }, 1377 | "Display": { 1378 | "Top": 310, 1379 | "Left": 525, 1380 | "Width": 40, 1381 | "Height": 20 1382 | }, 1383 | "Command": { 1384 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 1385 | "Action": "SendIrCode", 1386 | "Parameters": [ 1387 | { 1388 | "Name": "Index", 1389 | "Value": "19" 1390 | } 1391 | ] 1392 | } 1393 | }, 1394 | { 1395 | "ControlType": "button", 1396 | "top": "3.2", 1397 | "left": "1", 1398 | "Label": { 1399 | "lang_tag": "cmd_on", 1400 | "text": "P20" 1401 | }, 1402 | "Display": { 1403 | "Top": 310, 1404 | "Left": 570, 1405 | "Width": 40, 1406 | "Height": 20 1407 | }, 1408 | "Command": { 1409 | "Service": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 1410 | "Action": "SendIrCode", 1411 | "Parameters": [ 1412 | { 1413 | "Name": "Index", 1414 | "Value": "20" 1415 | } 1416 | ] 1417 | } 1418 | } 1419 | 1420 | ] 1421 | }, 1422 | { 1423 | "Label": { 1424 | "lang_tag": "advanced", 1425 | "text": "Advanced" 1426 | }, 1427 | "Position": "1", 1428 | "TabType": "javascript", 1429 | "ScriptName": "shared.js", 1430 | "Function": "advanced_device" 1431 | }, 1432 | { 1433 | "Label": { 1434 | "lang_tag": "logs", 1435 | "text": "Logs" 1436 | }, 1437 | "Position": "2", 1438 | "TabType": "javascript", 1439 | "ScriptName": "shared.js", 1440 | "Function": "device_logs" 1441 | }, 1442 | { 1443 | "Label": { 1444 | "lang_tag": "notifications", 1445 | "text": "Notifications" 1446 | }, 1447 | "Position": "3", 1448 | "TabType": "javascript", 1449 | "ScriptName": "shared.js", 1450 | "Function": "device_notifications" 1451 | } 1452 | ], 1453 | 1454 | "sceneList": { 1455 | "group_1": { 1456 | "cmd_1": { 1457 | "label": "Send IR code of preset", 1458 | "serviceId": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 1459 | "action": "SendIrCode", 1460 | 1461 | "argumentList": { 1462 | "argument_1" : { 1463 | "dataType": "ui1", 1464 | "defaultValue": "1", 1465 | "allowedValueRange" : { 1466 | "minimum": "0", 1467 | "maximum": "10" 1468 | }, 1469 | "prefix": "#", 1470 | "name": "SendIrCode" 1471 | } 1472 | } 1473 | } 1474 | } 1475 | }, 1476 | "eventList2": [ 1477 | { 1478 | "id": 1, 1479 | "label": { 1480 | "lang_tag": "ircode_received", 1481 | "text": "An IR code has been received" 1482 | }, 1483 | "serviceId": "urn:schemas-arduino-cc:serviceId:ArduinoIr1", 1484 | "argumentList": [ 1485 | { 1486 | "id": 1, 1487 | "dataType": "ui1", 1488 | "defaultValue": "1", 1489 | "allowedValueRange" : { 1490 | "minimum": "0", 1491 | "maximum": "10" 1492 | }, 1493 | "name": "IrCode", 1494 | "comparisson": "=", 1495 | "prefix": { 1496 | "lang_tag": "number", 1497 | "text": "#" 1498 | }, 1499 | "suffix": {} 1500 | } 1501 | ] 1502 | } 1503 | ], 1504 | "DeviceType": "urn:schemas-arduino-cc:device:ArduinoIr:1" 1505 | } 1506 | -------------------------------------------------------------------------------- /IrRecordPlayback/D_ArduinoIr1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | urn:schemas-arduino-cc:device:ArduinoIr:1 9 | 10 10 | D_ArduinoIr1.json 11 | 12 | 13 | urn:schemas-arduino-cc:service:ArduinoIr:1 14 | urn:schemas-arduino-cc:serviceId:ArduinoIr1 15 | S_ArduinoIr1.xml 16 | 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /IrRecordPlayback/S_ArduinoIr1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | 9 | Recording 10 | yes 11 | boolean 12 | 0 13 | recording 14 | 15 | 16 | 17 | 18 | IrCode 19 | yes 20 | string 21 | - 22 | IrCode 23 | 24 | 25 | 26 | 27 | RecordIrCode 28 | 29 | 30 | Index 31 | in 32 | CodeName 33 | in 34 | 35 | 36 | 37 | 38 | SendIrCode 39 | 40 | Index 41 | in 42 | 43 | 44 | 45 | 46 | -------------------------------------------------------------------------------- /L_Arduino.lua: -------------------------------------------------------------------------------- 1 | module("L_Arduino", package.seeall) 2 | 3 | -- 4 | -- MySensors Gateway Plugin 5 | -- 6 | -- Created by Henrik Ekblad 7 | -- 8 | -- http://www.mysensors.org 9 | -- https://github.com/mysensors 10 | -- 11 | -- See github for contributors 12 | -- Ethernet contribution by A-lurker 13 | -- 14 | -- This program is free software; you can redistribute it and/or 15 | -- modify it under the terms of the GNU General Public License 16 | -- version 2 as published by the Free Software Foundation. 17 | -- 18 | 19 | local PLUGIN_NAME = "MySensors Gateway Plugin" 20 | local PLUGIN_VERSION = "1.5" 21 | local GATEWAY_VERSION = "" 22 | local IP_PORT = "5003" 23 | local BAUD_RATE = "115200" 24 | local ARDUINO_SID = "urn:upnp-arduino-cc:serviceId:arduino1" 25 | local VARIABLE_CONTAINER_SID = "urn:upnp-org:serviceId:VContainer1" 26 | local MAX_RADIO_ID=255 27 | local NODE_CHILD_ID="255" 28 | 29 | local ARDUINO_DEVICE 30 | local TASK_ERROR = 2 31 | local TASK_ERROR_PERM = -2 32 | local TASK_SUCCESS = 4 33 | local TASK_BUSY = 1 34 | local childIdLookupTable = {} 35 | local availableIds = {} 36 | local inclusionResult = {} 37 | local inclusionResultTitle = {} 38 | local includeCount = 0 39 | 40 | local msgType = { 41 | PRESENTATION = "0", 42 | SET = "1", 43 | REQUEST = "2", 44 | INTERNAL = "3", 45 | STREAM = "4" 46 | } 47 | 48 | local tDeviceLookupNumType = {} 49 | local tDeviceTypes = { 50 | DOOR = {0, "urn:schemas-micasaverde-com:device:DoorSensor:1", "D_DoorSensor1.xml", "Door "}, 51 | MOTION = {1, "urn:schemas-micasaverde-com:device:MotionSensor:1", "D_MotionSensor1.xml", "Motion "}, 52 | SMOKE = {2, "urn:schemas-micasaverde-com:device:SmokeSensor:1", "D_SmokeSensor1.xml", "Smoke "}, 53 | LIGHT = {3, "urn:schemas-upnp-org:device:BinaryLight:1", "D_BinaryLight1.xml", "Light "}, 54 | DIMMER = {4, "urn:schemas-upnp-org:device:DimmableLight:1", "D_DimmableLight1.xml", "Dim Light "}, 55 | COVER = {5, "urn:schemas-micasaverde-com:device:WindowCovering:1", "D_WindowCovering1.xml", "Win Covering " }, 56 | TEMP = {6, "urn:schemas-micasaverde-com:device:TemperatureSensor:1", "D_TemperatureSensor1.xml", "Temp "}, 57 | HUM = {7, "urn:schemas-micasaverde-com:device:HumiditySensor:1", "D_HumiditySensor1.xml", "Humidity "}, 58 | BARO = {8, "urn:schemas-micasaverde-com:device:BarometerSensor:1", "D_BarometerSensor1.xml", "Baro "}, 59 | WIND = {9, "urn:schemas-micasaverde-com:device:WindSensor:1", "D_WindSensor1.xml", "Wind "}, 60 | RAIN = {10, "urn:schemas-micasaverde-com:device:RainSensor:1", "D_RainSensor1.xml", "Rain "}, 61 | UV = {11, "urn:schemas-micasaverde-com:device:UvSensor:1", "D_UvSensor1.xml", "UV "}, 62 | WEIGHT = {12, "urn:schemas-micasaverde-com:device:ScaleSensor:1", "D_ScaleSensor1.xml", "Weight "}, 63 | POWER = {13, "urn:schemas-micasaverde-com:device:PowerMeter:1", "D_PowerMeter1.xml", "Power "}, 64 | HEATER = {14, "urn:schemas-upnp-org:device:Heater:1", "D_Heater1.xml", "Heater "}, 65 | DISTANCE = {15, "urn:schemas-upnp-org:device:Distance:1", "D_DistanceSensor1.xml", "Distance "}, 66 | LIGHT_LEVEL= {16, "urn:schemas-micasaverde-com:device:LightSensor:1", "D_LightSensor1.xml", "Light "}, 67 | ARDUINO_NODE= {17, "urn:schemas-arduino-cc:device:arduinonode:1", "D_ArduinoNode1.xml", "Node "}, 68 | ARDUINO_RELAY={18, "urn:schemas-arduino-cc:device:arduinorelay:1", "D_ArduinoRelay1.xml", "Repeater "}, 69 | LOCK = {19, "urn:micasaverde-com:serviceId:DoorLock1", "D_DoorLock1.xml", "Lock "}, 70 | IR = {20, "urn:schemas-arduino-cc:device:ArduinoIr:1", "D_ArduinoIr1.xml", "IR "}, 71 | WATER = {21, "urn:schemas-micasaverde-com:device:WaterMeter:1", "D_WaterMeter1.xml", "Water "}, 72 | AIR_QUALITY = {22, "urn:schemas-micasaverde-com:device:LightSensor:1", "D_LightSensor1.xml", "Air Quality "}, -- Not implemented. Using Light sensor for now 73 | CUSTOM = {23, "urn:schemas-micasaverde-com:device:GenericSensor:1", "D_GenericSensor1.xml", "Generic "}, 74 | DUST = {24, "urn:schemas-micasaverde-com:device:LightSensor:1", "D_LightSensor1.xml", "Dust "}, -- Not implemented, Using light sensor for now 75 | SCENE_CONTROLLER = {25, "urn:schemas-micasaverde-com:device:SceneController:1", "D_SceneController1.xml", "SceneCtrl "}, 76 | 77 | RGB_LIGHT = {26, "urn:schemas-upnp-org:device:RGBController:1", "D_RGBController1.xml", "RGB Light "}, -- Not implemented, New device files needed 78 | RGBW_LIGHT = {27, "urn:schemas-upnp-org:device:RGBController:1", "D_RGBController1.xml", "RGBW Light "}, -- Not implemented. New device files needed 79 | COLOR_SENSOR = {28, "urn:schemas-upnp-org:device:RGBController:1", "D_LightSensor1.xml", "Color "}, -- Not implemented. New device files needed 80 | 81 | HVAC = {29, "urn:schemas-upnp-org:device:HVAC_ZoneThermostat:1", "D_HVAC_ZoneThermostat1.xml", "HVAC "}, 82 | 83 | MULTIMETER = {30, "urn:schemas-arduino-cc:device:EnergyMetering:1", "D_Multimeter1.xml", "Multimeter "}, -- Handles V_VOLTAGE, V_CURRENT, V_IMPEDANCE 84 | SPRINKLER = {31, "urn:schemas-upnp-org:device:BinaryLight:1", "D_BinaryLight1.xml", "Sprinkler "}, -- Not implemented, using binary light for now 85 | WATER_LEAK = {32, "urn:schemas-micasaverde-com:device:DoorSensor:1", "D_DoorSensor1.xml", "Water leak "}, -- Not implemented, using door sensor for now 86 | SOUND = {33, "urn:schemas-micasaverde-com:device:LightSensor:1", "D_LightSensor1.xml", "Sound "}, -- V_LEVEL (dB) not implemented, using light sensor for now 87 | VIBRATION = {34, "urn:schemas-micasaverde-com:device:DoorSensor:1", "D_DoorSensor1.xml", "Vibration "}, -- V_LEVEL (Hz) not implemented, using light sensor for now 88 | MOISTURE = {35, "urn:schemas-micasaverde-com:device:LightSensor:1", "D_LightSensor1.xml", "Moisture "}, -- V_LEVEL (?) not implemented, using light sensor for now 89 | INFO = {36, "urn:schemas-micasaverde-com:device:LcdText:1", "D_LcdText1.xml", "LCD text "}, -- LCD text device / Simple information device on controller, V_TEXT 90 | GAS = {37, "urn:schemas-micasaverde-com:device:GasMeter:1", "D_GasMeter1.xml", "Gas "}, -- Not implemented, Should handle V_FLOW, V_VOLUME not implemented 91 | GPS = {38, "urn:schemas-arduino-cc:device:ArduinoGPS:1", "D_ArduinoGPS1.xml", "IR "} -- Not implemented, Should handle V_POSITION not implemented 92 | } 93 | 94 | local tVarLookupNumType = {} 95 | local tVarTypes = { 96 | TEMP = {0, "urn:upnp-org:serviceId:TemperatureSensor1", "CurrentTemperature", ""}, 97 | HUM = {1, "urn:micasaverde-com:serviceId:HumiditySensor1", "CurrentLevel", "" }, 98 | LIGHT = {2, "urn:upnp-org:serviceId:SwitchPower1", "Status", "0" }, 99 | DIMMER = {3, "urn:upnp-org:serviceId:Dimming1", "LoadLevelStatus", "" }, 100 | PRESSURE = {4, "urn:upnp-org:serviceId:BarometerSensor1", "CurrentPressure", "" }, 101 | FORECAST = {5, "urn:upnp-org:serviceId:BarometerSensor1", "Forecast", "" }, 102 | RAIN = {6, "urn:upnp-org:serviceId:RainSensor1", "CurrentTRain", "" }, 103 | RAINRATE = {7, "urn:upnp-org:serviceId:RainSensor1", "CurrentRain", "" }, 104 | WIND = {8, "urn:upnp-org:serviceId:WindSensor1", "AvgSpeed", "" }, 105 | GUST = {9, "urn:upnp-org:serviceId:WindSensor1", "GustSpeed", "" }, 106 | DIRECTION = {10, "urn:upnp-org:serviceId:WindSensor1", "Direction", "" }, 107 | UV = {11, "urn:upnp-org:serviceId:UvSensor1", "CurrentLevel", "" }, 108 | WEIGHT = {12, "urn:micasaverde-com:serviceId:ScaleSensor1", "Weight", "" }, 109 | DISTANCE = {13, "urn:micasaverde-com:serviceId:DistanceSensor1", "CurrentDistance", "" }, 110 | IMPEDANCE = {14, "urn:micasaverde-com:serviceId:ScaleSensor1", "Impedance", "" }, 111 | ARMED = {15, "urn:micasaverde-com:serviceId:SecuritySensor1", "Armed", "" }, 112 | TRIPPED = {16, "urn:micasaverde-com:serviceId:SecuritySensor1", "Tripped", "0" }, 113 | WATT = {17, "urn:micasaverde-com:serviceId:EnergyMetering1", "Watts", "" }, 114 | KWH = {18, "urn:micasaverde-com:serviceId:EnergyMetering1", "KWH", "0" }, 115 | SCENE_ON = {19, "urn:micasaverde-com:serviceId:SceneController1", "sl_SceneActivated", "" }, 116 | SCENE_OFF = {20, "urn:micasaverde-com:serviceId:SceneController1", "sl_SceneDeactivated", "" }, 117 | HVAC_FLOW_STATE = {21, "urn:upnp-org:serviceId:HVAC_UserOperatingMode1", "ModeStatus", "" }, 118 | HVAC_FLOW_SPEED = {22, "urn:upnp-org:serviceId:HVAC_Speed", "Speed", "" }, -- Unsupported on Vera 119 | LIGHT_LEVEL = {23, "urn:micasaverde-com:serviceId:LightSensor1", "CurrentLevel", "" }, 120 | VAR_1 = {24, "urn:upnp-org:serviceId:VContainer1", "Variable1", ""}, 121 | VAR_2 = {25, "urn:upnp-org:serviceId:VContainer1", "Variable2", ""}, 122 | VAR_3 = {26, "urn:upnp-org:serviceId:VContainer1", "Variable3", ""}, 123 | VAR_4 = {27, "urn:upnp-org:serviceId:VContainer1", "Variable4", ""}, 124 | VAR_5 = {28, "urn:upnp-org:serviceId:VContainer1", "Variable5", ""}, 125 | UP = {29, nil, nil, ""}, 126 | DOWN = {30, nil, nil, ""}, 127 | STOP = {31, nil, nil, ""}, 128 | IR_SEND = {32, "urn:schemas-arduino-cc:serviceId:ArduinoIr1", "IrCode", ""}, 129 | IR_RECEIVE = {33, "urn:schemas-arduino-cc:serviceId:ArduinoIr1", "IrCode", ""}, 130 | FLOW = {34, "urn:micasaverde-com:serviceId:WaterMetering1", "Flow", "" }, 131 | VOLUME = {35, "urn:micasaverde-com:serviceId:WaterMetering1", "Volume", "0" }, 132 | LOCK = {36, "urn:micasaverde-com:serviceId:DoorLock1", "Status", ""}, 133 | LEVEL = {37, "urn:micasaverde-com:serviceId:LightSensor1", "CurrentLevel", ""}, -- Temporary fix for MOISTURE, VIBRATION, SOUND, HVAC_SETPOINT we should probably create a new devicetype/variable for this 134 | VOLTAGE = {38, "urn:micasaverde-com:serviceId:EnergyMetering1", "Voltage", ""}, 135 | CURRENT = {39, "urn:micasaverde-com:serviceId:EnergyMetering1", "Current", ""}, 136 | 137 | RGB = {40, "urn:upnp-org:serviceId:RGBController1", "SensorId", "SetColorTarget"}, -- Not implemented 138 | RGBW = {41, "urn:upnp-org:serviceId:RGBController1", "SensorId", "SetColorTarget"}, -- Not implemented 139 | 140 | SENSOR_ID = {42, "urn:micasaverde-com:serviceId:MySensor1", "SensorId", ""}, 141 | UNIT_PREFIX = {43, "urn:micasaverde-com:serviceId:MySensor1", "UnitPrefix", ""}, -- Currently unused in GUI on vera 142 | HVAC_SETPOINT_COOL = {44, "urn:upnp-org:serviceId:TemperatureSetpoint1_Cool", "CurrentSetpoint", "" }, 143 | HVAC_SETPOINT_HEAT = {45, "urn:upnp-org:serviceId:TemperatureSetpoint1_Heat", "CurrentSetpoint", "" }, 144 | HVAC_FLOW_MODE = {46, "urn:upnp-org:serviceId:HVAC_FanOperatingMode1", "Mode", "" }, 145 | TEXT = {47, "urn:upnp-org:serviceId:LcdText1", "LcdText", "" }, -- S_INFO. Text message to display on LCD or controller device 146 | CUSTOM = {48, "urn:micasaverde-com:serviceId:MySensor1", "Custom", "" }, -- Not implemented S_CUSTOM device type. 147 | POSITION = {49, "urn:micasaverde-com:serviceId:MySensor1", "Position", "" }, -- Not implemented GPS position and altitude 148 | IR_RECORD = {50, "urn:schemas-arduino-cc:serviceId:ArduinoIr1", "Recording", ""} -- S_IR_RECORD message 149 | } 150 | 151 | local tVeraTypes = { 152 | BATTERY_DATE = {0, "urn:micasaverde-com:serviceId:HaDevice1", "BatteryDate", "" }, 153 | LAST_TRIP = {1, "urn:micasaverde-com:serviceId:SecuritySensor1", "LastTrip", "" }, 154 | LAST_UPDATE = {2, "urn:micasaverde-com:serviceId:HaDevice1", "LastUpdate", "" } 155 | } 156 | 157 | local tInternalLookupNumType = {} 158 | local tInternalTypes = { 159 | BATTERY_LEVEL = {0, "urn:micasaverde-com:serviceId:HaDevice1", "BatteryLevel", "" }, 160 | TIME = {1, nil, nil, nil}, 161 | VERSION = {2, "urn:upnp-arduino-cc:serviceId:arduinonode1", "ArduinoLibVersion", ""}, 162 | ID_REQUEST = {3, nil, nil, nil}, 163 | ID_RESPONSE = {4, nil, nil, nil}, 164 | INCLUSION_MODE ={5, "urn:upnp-arduino-cc:serviceId:arduino1", "InclusionMode", "0"}, 165 | CONFIG = {6, "urn:upnp-arduino-cc:serviceId:arduinonode1", "RelayNode", ""}, 166 | PING = {7, nil, nil, nil }, 167 | PING_ACK = {8, nil, nil, nil }, 168 | LOG_MESSAGE = {9, nil, nil, nil }, 169 | CHILDREN = {10, "urn:upnp-arduino-cc:serviceId:arduinonode1", "Children", "0"}, 170 | SKETCH_NAME = {11, "urn:upnp-arduino-cc:serviceId:arduinonode1", "SketchName", ""}, 171 | SKETCH_VERSION = {12, "urn:upnp-arduino-cc:serviceId:arduinonode1", "SketchVersion", ""}, 172 | REBOOT = {13, nil, nil, nil}, 173 | GATEWAY_READY = {14, nil, nil, nil} 174 | } 175 | 176 | 177 | local function printTable(list, i) 178 | local listString = '' 179 | if not i then 180 | listString = listString .. '{' 181 | end 182 | i = i or 1 183 | local element = list[i] 184 | if not element then 185 | return listString .. '}' 186 | end 187 | if(type(element) == 'table') then 188 | listString = listString .. printTable(element) 189 | else 190 | listString = listString .. element 191 | end 192 | return listString .. ', ' .. printTable(list, i + 1) 193 | end 194 | 195 | function string.starts(String,Start) 196 | return string.sub(String,1,string.len(Start))==Start 197 | end 198 | 199 | local function log(text, level) 200 | if(type(text) == 'table') then 201 | luup.log("Arduino: table:" .. printTable(text) , (level or 50)) 202 | elseif (text == nil) then 203 | luup.log("Arduino: nil-value" , (level or 50)) 204 | else 205 | luup.log("Arduino: " .. text, (level or 50)) 206 | end 207 | end 208 | 209 | -- 210 | -- Update variable if changed 211 | -- Return true if changed or false if no change 212 | -- 213 | function setVariableIfChanged(serviceId, name, value, deviceId) 214 | log(serviceId ..","..name..", "..value..", ".. deviceId) 215 | local curValue = luup.variable_get(serviceId, name, deviceId) 216 | 217 | if ((value ~= curValue) or (curValue == nil) or (serviceId == "urn:micasaverde-com:serviceId:SceneController1")) then 218 | luup.variable_set(serviceId, name, value, deviceId) 219 | if ((serviceId == "urn:upnp-org:serviceId:TemperatureSetpoint1_Heat") or (serviceId == "urn:upnp-org:serviceId:TemperatureSetpoint1_Cool")) then 220 | luup.variable_set("urn:upnp-org:serviceId:TemperatureSetpoint1", name, value, deviceId) 221 | end 222 | return true 223 | 224 | else 225 | return false 226 | 227 | end 228 | end 229 | 230 | 231 | local function setLastUpdate(nodeDevice) 232 | if (nodeDevice ~= nil) then 233 | local timestamp = os.time() 234 | local variable = tVeraTypes["LAST_UPDATE"] 235 | setVariableIfChanged(variable[2], variable[3], timestamp, nodeDevice) 236 | 237 | -- Set the last update in a human readable form for display on the console 238 | local unit = luup.variable_get(ARDUINO_SID, "Unit", ARDUINO_DEVICE) 239 | local timeFormat = (unit == 'M' and '%H:%M' or '%I:%M %p') 240 | setVariableIfChanged(variable[2], "LastUpdateHR", os.date(timeFormat, timestamp), nodeDevice) 241 | else 242 | 243 | log("Unable to update LAST_UPDATE due to missing parent node.", 2) 244 | end 245 | end 246 | 247 | local function setVariable(incomingData, childId, nodeId) 248 | if (childId ~= nil) then 249 | -- Set variable on child sensor. 250 | local index = tonumber(incomingData[5]); 251 | local varType = tVarLookupNumType[index] 252 | local var = tVarTypes[varType] 253 | local value = incomingData[6] 254 | local timestamp = os.time() 255 | if (var[2] ~= nil) then 256 | log("Setting variable '".. var[3] .. "' to value '".. value.. "'") 257 | setVariableIfChanged(var[2], var[3], value, childId) 258 | 259 | -- Handle special variables battery level and tripped which also 260 | -- should update other variables to os.time() 261 | if (varType == "TRIPPED" and value == "1") then 262 | local variable = tVeraTypes["LAST_TRIP"] 263 | setVariableIfChanged(variable[2], variable[3], timestamp, childId) 264 | else 265 | local variable = tVeraTypes["LAST_UPDATE"] 266 | setVariableIfChanged(variable[2], variable[3], timestamp, childId) 267 | end 268 | end 269 | 270 | -- Always update LAST_UPDATE for node 271 | if (nodeId ~= nil) then 272 | local nodeDevice = childIdLookupTable[nodeId .. ";" .. NODE_CHILD_ID] 273 | setLastUpdate(nodeDevice) 274 | end 275 | end 276 | end 277 | 278 | local function task(text, mode) 279 | if (mode == TASK_ERROR_PERM) then 280 | log(text, 1) 281 | elseif (mode ~= TASK_SUCCESS) then 282 | log(text, 2) 283 | else 284 | log(text) 285 | end 286 | if (mode == TASK_ERROR_PERM) then 287 | taskHandle = luup.task(text, TASK_ERROR, "MySensors plugin", taskHandle) 288 | else 289 | taskHandle = luup.task(text, mode, "MySensors plugin", taskHandle) 290 | 291 | -- Clear the previous error, since they're all transient 292 | if (mode ~= TASK_SUCCESS) then 293 | luup.call_delay("clearTask", 15, "", false) 294 | end 295 | end 296 | end 297 | 298 | local function clearTask() 299 | task("Clearing...", TASK_SUCCESS) 300 | end 301 | 302 | local function nextAvailiableRadioId() 303 | for i=1,255 do 304 | if (availableIds[i] == true) then 305 | availableIds[i] = false 306 | return i 307 | end 308 | end 309 | return 255 310 | end 311 | 312 | -- Function to send a message to sensor 313 | function sendCommand(altid, variableId, value) 314 | return sendCommandWithMessageType(altid, "SET", 1, tonumber(tVarTypes[variableId][1]), value) 315 | end 316 | 317 | function sendNodeCommand(device, variableId, value) 318 | return sendCommandWithMessageType(luup.devices[device].id, "SET", 1, tonumber(tVarTypes[variableId][1]), value) 319 | end 320 | 321 | function sendInternalCommand(altid, variableId, value) 322 | return sendCommandWithMessageType(altid, "INTERNAL",0, tonumber(tInternalTypes[variableId][1]), value) 323 | end 324 | 325 | function sendRequestResponse(altid, variableId, value) 326 | return sendCommandWithMessageType(altid, "SET", 0, tonumber(tVarTypes[variableId][1]), value) 327 | end 328 | 329 | 330 | 331 | local function presentation(incomingData, device, childId, altId) 332 | local type = incomingData[5] 333 | local data = incomingData[6] 334 | local mode = luup.variable_get(ARDUINO_SID, "InclusionMode", ARDUINO_DEVICE) 335 | 336 | if (mode == "1" and device ~= nil and childId ~= NODE_CHILD_ID and string.len(data)>0 and (not string.starts(data,"1."))) then 337 | -- Update sensor description (device title) during inclusion mode (for already known sensors) 338 | -- We ignore names starting with "1." because old sensors sent version number in payload 339 | local splitted = altId:split(";") 340 | local nodeId = splitted[1] 341 | luup.attr_set("name", data .. " (" .. nodeId .. ")", device) 342 | end 343 | 344 | if (mode == "1" and device == nil) then 345 | -- A new sensor (not created before) was presented during inclusion mode 346 | if (inclusionResult[altId] == nil) then 347 | log("Found new device "..altId); 348 | includeCount = includeCount+1; 349 | setVariableIfChanged(ARDUINO_SID, "InclusionFoundCountHR", includeCount .." devices found", ARDUINO_DEVICE) 350 | inclusionResult[altId] = type 351 | if (childId ~= NODE_CHILD_ID and string.len(data)>0) then 352 | -- save mode decription for later 353 | inclusionResultTitle[altId] = data 354 | end 355 | end 356 | elseif (mode == "0" and device ~= nil and childId == NODE_CHILD_ID) then 357 | -- Store version information if this is radio node 358 | local var = tInternalTypes["VERSION"] 359 | setVariableIfChanged(var[2], var[3], data, device) 360 | if (data ~= GATEWAY_VERSION) then 361 | -- The library version of sensor differs from plugin version. Warn about it. 362 | log("Warning: Sensor has different library version than GW. Id: "..altId) 363 | end 364 | end 365 | end 366 | 367 | local function processInternalMessage(incomingData, iChildId, iAltId, incomingNodeId) 368 | local data = incomingData[6] 369 | local index = tonumber(incomingData[5]); 370 | local varType = tInternalLookupNumType[index] 371 | local var = tInternalTypes[varType] 372 | 373 | if (varType == "VERSION" and iAltId == "0;255") then 374 | -- Store version of Arduino Gateway 375 | GATEWAY_VERSION = data 376 | setVariableIfChanged(ARDUINO_SID, "ArduinoLibVersion", GATEWAY_VERSION, ARDUINO_DEVICE) 377 | elseif ((varType == "SKETCH_NAME" or varType == "SKETCH_VERSION") and iChildId ~= nil) then 378 | -- Store the Sketch name and Version 379 | setVariableIfChanged(var[2], var[3], data, iChildId) 380 | elseif (varType == "TIME") then 381 | -- Request time was sent from one of the sensors 382 | sendInternalCommand(iAltId,"TIME",os.time() + 3600 * luup.timezone) 383 | elseif (varType == "ID_REQUEST") then 384 | -- Determine next available radioid and sent it to the sensor 385 | sendInternalCommand(iAltId,"ID_RESPONSE",nextAvailiableRadioId()) 386 | elseif (varType == "CONFIG" and iChildId ~= nil) then 387 | -- Update last update value for this node 388 | setLastUpdate(iChildId) 389 | -- Update parent node information 390 | setVariableIfChanged(var[2], var[3], data, iChildId) 391 | -- Create a human readable form for parent 392 | setVariableIfChanged(var[2], "RelayNodeHR", data == "0" and "GW" or data, iChildId) 393 | -- Send back configuration to node 394 | local unit = luup.variable_get(ARDUINO_SID, "Unit", ARDUINO_DEVICE) 395 | sendInternalCommand(iAltId,"CONFIG",unit) 396 | elseif (varType == "BATTERY_LEVEL") then 397 | setVariableIfChanged(var[2], var[3], data, iChildId) 398 | local variable = tVeraTypes["BATTERY_DATE"] 399 | setVariableIfChanged(variable[2], variable[3], os.time(), iChildId) 400 | elseif (varType == "INCLUSION_MODE") then 401 | setVariableIfChanged(var[2], var[3], data, ARDUINO_DEVICE) 402 | if (data == "0") then 403 | setVariableIfChanged(ARDUINO_SID, "InclusionFoundCountHR", "", ARDUINO_DEVICE) 404 | inclusionCount = 0 405 | -- Here comes the presentation data from sensors 406 | local newDevices = 0 407 | local child_devices 408 | log("Inclusion mode ended.") 409 | for altId,deviceType in pairs(inclusionResult) do 410 | local childId = childIdLookupTable[altId] 411 | if (childId == nil) then 412 | local deviceId = tDeviceLookupNumType[tonumber(deviceType)] 413 | if (deviceId ~= nil) then 414 | local splitted = altId:split(";") 415 | local nodeId = splitted[1] 416 | local childId = splitted[2] 417 | local name 418 | 419 | -- A new child sensor has been found. Create it! 420 | local deviceType = tDeviceTypes[deviceId] 421 | -- Create device if device sent presentation 422 | if (newDevices == 0) then 423 | child_devices = luup.chdev.start(ARDUINO_DEVICE) 424 | end 425 | 426 | 427 | -- append newly found sensor device 428 | name = inclusionResultTitle[altId] 429 | if (name == nil) then 430 | if (childId == NODE_CHILD_ID) then 431 | name = nodeId 432 | else 433 | name = childId .. " (" .. nodeId .. ")" 434 | end 435 | name = "Arduino " .. deviceType[4]..name 436 | else 437 | name = name .. " (" .. nodeId .. ")" 438 | end 439 | 440 | luup.chdev.append(ARDUINO_DEVICE, child_devices, altId, name, deviceType[2],deviceType[3],"","",false) 441 | newDevices = newDevices + 1 442 | else 443 | log("Found unknown device type ".. deviceType ..". Inclusion aborted. Please try again.", 1) 444 | newDevices = -100 445 | end 446 | else 447 | log("Device "..altId.." already exists"); 448 | end 449 | end 450 | if (newDevices > 0) then 451 | -- Append all old device children 452 | for k, v in pairs(luup.devices) do 453 | if v.device_num_parent == ARDUINO_DEVICE then 454 | luup.chdev.append(ARDUINO_DEVICE, child_devices, v.id, v.description, v.device_type,v.device_file,"","",false) 455 | end 456 | end 457 | task ("Found new sensor(s). Need to restart. Please wait.",TASK_BUSY) 458 | luup.chdev.sync(ARDUINO_DEVICE,child_devices) 459 | return 460 | end 461 | else 462 | setVariableIfChanged(ARDUINO_SID, "InclusionFoundCountHR", "0 devices found", ARDUINO_DEVICE) 463 | end 464 | elseif (varType == "CHILDREN") then 465 | setVariableIfChanged(var[2], var[3], data, iChildId) 466 | elseif (varType == "LOG_MESSAGE" or varType == "GATEWAY_READY") then 467 | log("Log: "..data) 468 | else 469 | log("Incoming internal command '" .. table.concat(incomingData, ";") .. "' discarded for child: " .. (iChildId ~= nil and iChildId or "nil"), 2) 470 | end 471 | end 472 | 473 | local function requestStatus(incomingData, childId, altId) 474 | log("Requesting status for: "..altId) 475 | -- A device request its current status from vera (when staring up) 476 | local index = tonumber(incomingData[5]); 477 | local varType = tVarLookupNumType[index] 478 | 479 | -- Requested variable value from one of the sensors 480 | local variable = tVarTypes[varType] 481 | if (variable[2] ~= nil and childId ~= nil) then 482 | local value = luup.variable_get(variable[2], variable[3], childId) 483 | log("Request status for ".. variable[3]) 484 | if (value ~= nil) then 485 | -- Send variable value to actuator 486 | sendRequestResponse(altId,varType,value) 487 | else 488 | -- Create the missing variable and send default value to actuator 489 | setVariableIfChanged(variable[2], variable[3], variable[4], childId) 490 | sendRequestResponse(altId,varType,variable[4]) 491 | end 492 | end 493 | 494 | end 495 | 496 | 497 | 498 | function sendCommandWithMessageType(altid, messageType, ack, variableId, value) 499 | local cmd = altid..";".. msgType[messageType] .. ";" .. ack .. ";" .. variableId .. ";" .. value 500 | log("Sending: " .. cmd) 501 | 502 | if (luup.io.write(cmd) == false) then 503 | task("Cannot send command - communications error", TASK_ERROR) 504 | luup.set_failure(true) 505 | return false 506 | end 507 | return true 508 | end 509 | 510 | 511 | function setUnit(unit) 512 | setVariableIfChanged(ARDUINO_SID, "Unit", unit, ARDUINO_DEVICE) 513 | end 514 | 515 | 516 | -- Arduino GW device commands 517 | function startInclusion(device) 518 | return sendInternalCommand("0;0","INCLUSION_MODE","1") 519 | end 520 | 521 | function stopInclusion(device) 522 | return sendInternalCommand("0;0","INCLUSION_MODE","0") 523 | end 524 | 525 | -- Arduino relay node device commands 526 | 527 | function clearChildren(device) 528 | local variable = tInternalTypes["CHILDREN"] 529 | setVariableIfChanged(variable[2], variable[3], "Clearing...", device) 530 | sendInternalCommand(luup.devices[device].id,"CHILDREN","C") 531 | end 532 | 533 | 534 | -- Window covering commands 535 | 536 | function windowCovering(device, action) 537 | sendCommand(luup.devices[device].id,action,"") 538 | end 539 | 540 | -- Power and dimmer commands 541 | function switchPower(device, newTargetValue) 542 | sendCommand(luup.devices[device].id,"LIGHT",newTargetValue) 543 | end 544 | 545 | function sendIrCommand(device, irCodeNumber) 546 | sendCommand(luup.devices[device].id,"IR_SEND",irCodeNumber) 547 | end 548 | 549 | function recordIrCode(device, irCodeNumber, newIrCodeName) 550 | setVariableIfChanged(tVarTypes.IR_RECORD[2], "IrCodeName" .. irCodeNumber, newIrCodeName, device) 551 | sendCommand(luup.devices[device].id,"IR_RECORD", irCodeNumber) 552 | end 553 | 554 | function setDimmerLevel(device, newLoadlevelTarget) 555 | sendCommand(luup.devices[device].id,"DIMMER",newLoadlevelTarget) 556 | end 557 | 558 | function setLockStatus(device, newTargetValue) 559 | sendCommand(luup.devices[device].id,"LOCK",newTargetValue) 560 | end 561 | 562 | 563 | -- Heater commands 564 | function SetpointHeat(device, NewCurrentSetpoint) 565 | sendCommand(luup.devices[device].id,"HVAC_SETPOINT_HEAT",NewCurrentSetpoint) 566 | sendCommand(luup.devices[device].id,"LEVEL",NewCurrentSetpoint) 567 | luup.log("New Current SetPoint Heat " .. NewCurrentSetpoint) 568 | end 569 | 570 | function SetpointCool(device, NewCurrentSetpoint) 571 | sendCommand(luup.devices[device].id,"HVAC_SETPOINT_COOL",NewCurrentSetpoint) 572 | sendCommand(luup.devices[device].id,"LEVEL",NewCurrentSetpoint) 573 | luup.log("New Current SetPoint Cool " .. NewCurrentSetpoint) 574 | end 575 | 576 | function SetOperatingMode(device, NewModeTarget) 577 | sendCommand(luup.devices[device].id,"HVAC_FLOW_STATE",NewModeTarget) 578 | end 579 | 580 | function SetFanMode(device, NewMode) 581 | sendCommand(luup.devices[device].id,"HVAC_FLOW_MODE",NewMode) 582 | end 583 | 584 | function SetLcdText(device, NewText) 585 | sendCommand(luup.devices[device].id, "TEXT", NewText) 586 | setVariableIfChanged(tVarTypes.TEXT[2], tVarTypes.TEXT[3], NewText, device) 587 | end 588 | 589 | -- Security commands 590 | function setArmed(device, newArmedValue) 591 | sendCommand(luup.devices[device].id,"ARMED",newArmedValue) 592 | setVariableIfChanged(tVarTypes.ARMED[2], tVarTypes.ARMED[3], newArmedValue, device) 593 | end 594 | 595 | 596 | function updateLookupTables(radioId, childId, deviceId) 597 | childIdLookupTable[radioId..";"..childId] = deviceId 598 | availableIds[radioId] = false 599 | end 600 | 601 | -- splits a string by a pattern 602 | -- returns an array of the pieces 603 | function string:split(delimiter) 604 | local result = { } 605 | local from = 1 606 | local delim_from, delim_to = string.find( self, delimiter, from ) 607 | while delim_from do 608 | table.insert( result, string.sub( self, from , delim_from-1 ) ) 609 | from = delim_to + 1 610 | delim_from, delim_to = string.find( self, delimiter, from ) 611 | end 612 | table.insert( result, string.sub( self, from ) ) 613 | return result 614 | end 615 | 616 | function processIncoming(s) 617 | local incomingData = s:split(";") 618 | if (#incomingData >=4) then 619 | local nodeId = incomingData[1] 620 | local childId = incomingData[2] 621 | local messageType = incomingData[3]; 622 | 623 | local altId = nodeId .. ";" .. childId 624 | local device = childIdLookupTable[altId] 625 | 626 | if (messageType==msgType.SET) then 627 | log("Set variable: ".. s) 628 | setVariable(incomingData, device, nodeId) 629 | elseif (messageType==msgType.PRESENTATION) then 630 | log("Presentation: ".. s) 631 | presentation(incomingData, device, childId, altId) 632 | elseif (messageType==msgType.REQUEST) then 633 | log("Request: ".. s) 634 | requestStatus(incomingData, device, altId) 635 | elseif (messageType == msgType.INTERNAL) then 636 | processInternalMessage(incomingData, device, altId, nodeId) 637 | else 638 | log("Receive error: No handler for data: "..s, 1) 639 | end 640 | end 641 | end 642 | 643 | 644 | function startup(lul_device) 645 | ARDUINO_DEVICE = lul_device 646 | 647 | setVariableIfChanged(ARDUINO_SID, "PluginVersion", PLUGIN_VERSION, ARDUINO_DEVICE) 648 | 649 | local ipa = luup.devices[ARDUINO_DEVICE].ip 650 | 651 | local ipAddress = string.match(ipa, '^(%d%d?%d?%.%d%d?%d?%.%d%d?%d?%.%d%d?%d?)') 652 | local ipPort = string.match(ipa, ':(%d+)$') 653 | 654 | if (ipAddress ~= nil) then 655 | if (ipPort == nil) then ipPort = IP_PORT end 656 | 657 | log('Using network connection: IP address is '..ipAddress..':'..ipPort) 658 | luup.io.open(ARDUINO_DEVICE, ipAddress, ipPort) 659 | 660 | else -- use serial 661 | log('Trying for a serial connection') 662 | 663 | local IOdevice = luup.variable_get("urn:micasaverde-com:serviceId:HaDevice1", "IODevice", ARDUINO_DEVICE) 664 | if ((luup.io.is_connected(ARDUINO_DEVICE) == false) or (IOdevice == nil)) then 665 | log("Serial port not connected. First choose the serial port and restart the lua engine.", 1) 666 | task("Choose the Serial Port", TASK_ERROR_PERM) 667 | return false 668 | end 669 | 670 | log("Serial port is connected") 671 | 672 | -- Check serial settings 673 | local baud = luup.variable_get("urn:micasaverde-org:serviceId:SerialPort1", "baud", tonumber(IOdevice)) 674 | if ((baud == nil) or (baud ~= BAUD_RATE)) then 675 | log("Incorrect setup of the serial port. Select ".. BAUD_RATE .." bauds.", 1) 676 | task("Select ".. BAUD_RATE .." bauds for the Serial Port", TASK_ERROR_PERM) 677 | return false 678 | end 679 | log("Baud is ".. BAUD_RATE) 680 | end 681 | 682 | for i=1,MAX_RADIO_ID do 683 | availableIds[i] = true; 684 | end 685 | 686 | -- build an lookup table for child device ids (altid -> id) 687 | for k, v in pairs(luup.devices) do 688 | -- if I am the parent device 689 | if v.device_num_parent == ARDUINO_DEVICE then 690 | childIdLookupTable[v.id] = k 691 | local split = v.id:split(";") 692 | local radioId = tonumber(split[1]) 693 | availableIds[radioId] = false; 694 | end 695 | end 696 | 697 | -- create lookup table for variables: numeric value -> key 698 | for k, v in pairs(tVarTypes) do 699 | tVarLookupNumType[v[1]] = k 700 | end 701 | 702 | for k, v in pairs(tInternalTypes) do 703 | tInternalLookupNumType[v[1]] = k 704 | end 705 | 706 | for k, v in pairs(tDeviceTypes) do 707 | tDeviceLookupNumType[v[1]] = k 708 | end 709 | 710 | 711 | local variable = tInternalTypes["UNIT"] 712 | local unit = luup.variable_get(ARDUINO_SID, "Unit", ARDUINO_DEVICE) 713 | if (unit == nil) then 714 | -- Set default value for unit to metric system 715 | setVariableIfChanged(ARDUINO_SID, "Unit", "M", ARDUINO_DEVICE) 716 | end 717 | 718 | 719 | 720 | GATEWAY_VERSION = luup.variable_get(ARDUINO_SID, "ArduinoLibVersion", ARDUINO_DEVICE) 721 | 722 | -- Request version info from Arduino gateway 723 | sendCommandWithMessageType("0;0","INTERNAL",0,tonumber(tInternalTypes["VERSION"][1]),"Get Version") 724 | 725 | end 726 | -------------------------------------------------------------------------------- /LcdText/D_LcdText1.json: -------------------------------------------------------------------------------- 1 | { 2 | "flashicon": "icons\/intro.png", 3 | "imgIconBody": "", 4 | "imgIconDimmable": "", 5 | "imgIconTurnable": "", 6 | "imgIconMin": "", 7 | "imgIconMax": "", 8 | "halloIconsDir": "pics/hallo", 9 | "inScene": "0", 10 | "DisplayStatus": {}, 11 | "doc_url": { 12 | "doc_language": 1, 13 | "doc_manual": 1, 14 | "doc_version": 1, 15 | "doc_platform": 0, 16 | "doc_page": "sensors" 17 | }, 18 | "Tabs": [ 19 | { 20 | "Label": { 21 | "lang_tag": "tabname_control", 22 | "text": "Information" 23 | }, 24 | "Position": "0", 25 | "TabType": "flash", 26 | "SceneGroup": [ 27 | { 28 | "id": "1", 29 | "top": "1.0", 30 | "left": "0", 31 | "x": "2", 32 | "y": "2" 33 | } 34 | ], 35 | "ControlGroup": [ 36 | { 37 | "id": "1", 38 | "scenegroup": "1", 39 | "type": "info" 40 | } 41 | ], 42 | "Control": [ 43 | { 44 | "ControlType": "label", 45 | "Label": { 46 | "lang_tag": "Lcdtext", 47 | "text": "Current Text:" 48 | }, 49 | "Display": { 50 | "Top": 55, 51 | "Left": 50, 52 | "Width": 75, 53 | "Height": 20 54 | } 55 | }, 56 | { 57 | "ControlGroup": "1", 58 | "ControlPair": "1", 59 | "ControlHeader": "1", 60 | "top": "0.25", 61 | "left": "0", 62 | "x": "1", 63 | "ControlType": "variable", 64 | "Display": { 65 | "Service": "urn:upnp-org:serviceId:LcdText1", 66 | "Variable": "LcdText", 67 | "Top": 55, 68 | "Left": 150, 69 | "Width": 600, 70 | "Height": 20 71 | } 72 | }, 73 | { 74 | "ControlType": "label", 75 | "Label": { 76 | "lang_tag": "Lcdtext", 77 | "text": "New Text:" 78 | }, 79 | "Display": { 80 | "Top": 84, 81 | "Left": 50, 82 | "Width": 75, 83 | "Height": 20 84 | } 85 | }, 86 | { 87 | "ControlType": "input", 88 | "ID": "NewLcdText", 89 | "Display": { 90 | "Top": 80, 91 | "Left": 150, 92 | "Width": 300, 93 | "Height": 20 94 | } 95 | }, 96 | { 97 | "ControlType": "button", 98 | "Label": { 99 | "lang_tag": "cmd_add", 100 | "text": "Set New Text" 101 | }, 102 | "Display": { 103 | "Top": 80, 104 | "Left": 470, 105 | "Width": 110, 106 | "Height": 20 107 | }, 108 | "Command": { 109 | "Service": "urn:upnp-org:serviceId:LcdText1", 110 | "Action": "SetLcdText", 111 | "Parameters": [ 112 | { 113 | "Name": "NewLcdText", 114 | "ID": "NewLcdText" 115 | } 116 | ] 117 | } 118 | }, 119 | 120 | ] 121 | }, 122 | { 123 | "Label": { 124 | "lang_tag": "advanced", 125 | "text": "Advanced" 126 | }, 127 | "Position": "1", 128 | "TabType": "javascript", 129 | "ScriptName": "shared.js", 130 | "Function": "advanced_device" 131 | }, 132 | { 133 | "Label": { 134 | "lang_tag": "logs", 135 | "text": "Logs" 136 | }, 137 | "Position": "2", 138 | "TabType": "javascript", 139 | "ScriptName": "shared.js", 140 | "Function": "device_logs" 141 | }, 142 | { 143 | "Label": { 144 | "lang_tag": "notifications", 145 | "text": "Notifications" 146 | }, 147 | "Position": "3", 148 | "TabType": "javascript", 149 | "ScriptName": "shared.js", 150 | "Function": "device_notifications" 151 | } 152 | ], 153 | "eventList2": [ ], 154 | "DeviceType": "urn:schemas-micasaverde-com:device:LcdText:1" 155 | } 156 | -------------------------------------------------------------------------------- /LcdText/D_LcdText1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | urn:schemas-upnp-org:device:LcdText:1 9 | 12 10 | D_LcdText1.json 11 | 12 | 13 | urn:schemas-upnp-org:service:LcdText:1 14 | urn:upnp-org:serviceId:LcdText1 15 | S_LcdText1.xml 16 | 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /LcdText/S_LcdText1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | 9 | LcdText 10 | yes 11 | string 12 | LcdText 13 | 14 | 15 | 16 | 17 | SetLcdText 18 | 19 | 20 | NewLcdText 21 | in 22 | LcdText 23 | 24 | 25 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /Multimeter/D_Multimeter1.json: -------------------------------------------------------------------------------- 1 | { 2 | "flashicon": "icons\/PowerMeter.png", 3 | "imgIconBody": "", 4 | "imgIconDimmable": "", 5 | "imgIconTurnable": "", 6 | "imgIconMin": "", 7 | "imgIconMax": "", 8 | "halloIconsDir": "pics/hallo", 9 | "inScene": "0", 10 | "DisplayStatus": {}, 11 | "doc_url": { 12 | "doc_language": 1, 13 | "doc_manual": 1, 14 | "doc_version": 1, 15 | "doc_platform": 0, 16 | "doc_page": "sensors" 17 | }, 18 | "Tabs": [ 19 | { 20 | "Label": { 21 | "lang_tag": "tabname_control", 22 | "text": "Information" 23 | }, 24 | "Position": "0", 25 | "TabType": "flash", 26 | "SceneGroup": [ 27 | { 28 | "id": "1", 29 | "top": "1.0", 30 | "left": "0", 31 | "x": "2", 32 | "y": "2" 33 | } 34 | ], 35 | "ControlGroup": [ 36 | { 37 | "id": "1", 38 | "scenegroup": "1", 39 | "type": "info" 40 | }, 41 | { 42 | "id": "2", 43 | "scenegroup": "1", 44 | "type": "info" 45 | }, 46 | { 47 | "id": "3", 48 | "scenegroup": "1", 49 | "type": "info" 50 | } 51 | ], 52 | "Control": [ 53 | { 54 | "ControlType": "label", 55 | "Label": { 56 | "lang_tag": "impedance", 57 | "text": "Impedance" 58 | }, 59 | "Display": { 60 | "Top": 55, 61 | "Left": 50, 62 | "Width": 75, 63 | "Height": 20 64 | } 65 | }, 66 | { 67 | "ControlGroup": "1", 68 | "ControlPair": "1", 69 | "ControlHeader": "1", 70 | "top": "0.25", 71 | "left": "0", 72 | "x": "1", 73 | "ControlType": "variable", 74 | "Display": { 75 | "Service": "urn:micasaverde-com:serviceId:ScaleSensor1", 76 | "Variable": "Impedance", 77 | "Top": 55, 78 | "Left": 150, 79 | "Width": 25, 80 | "Height": 20 81 | } 82 | }, 83 | { 84 | "ControlGroup": "1", 85 | "ControlPair": "1", 86 | "ControlHeader": "1", 87 | "top": "0.25", 88 | "left": "1.25", 89 | "x": "1", 90 | 91 | "ControlType": "label", 92 | "Label": { 93 | "lang_tag": "uF", 94 | "text": "uF" 95 | }, 96 | "Display": { 97 | "Top": 55, 98 | "Left": 200, 99 | "Width": 25, 100 | "Height": 20 101 | } 102 | }, 103 | { 104 | "ControlType": "label", 105 | "Label": { 106 | "lang_tag": "current", 107 | "text": "Current" 108 | }, 109 | "Display": { 110 | "Top": 80, 111 | "Left": 50, 112 | "Width": 75, 113 | "Height": 20 114 | } 115 | }, 116 | { 117 | "ControlGroup": "2", 118 | "ControlPair": "1", 119 | "ControlHeader": "1", 120 | "top": "1", 121 | "left": "0", 122 | "x": "1", 123 | "ControlType": "variable", 124 | "Display": { 125 | "Service": "urn:micasaverde-com:serviceId:EnergyMetering1", 126 | "Variable": "Current", 127 | "Top": 80, 128 | "Left": 150, 129 | "Width": 25, 130 | "Height": 20 131 | } 132 | }, 133 | { 134 | "ControlGroup": "2", 135 | "ControlPair": "1", 136 | "ControlHeader": "1", 137 | "top": "1", 138 | "left": "1.25", 139 | "x": "1", 140 | 141 | "ControlType": "label", 142 | "Label": { 143 | "lang_tag": "amps", 144 | "text": "A" 145 | }, 146 | "Display": { 147 | "Top": 80, 148 | "Left": 200, 149 | "Width": 25, 150 | "Height": 20 151 | } 152 | }, 153 | { 154 | "ControlType": "label", 155 | "Label": { 156 | "lang_tag": "volts", 157 | "text": "Voltages" 158 | }, 159 | "Display": { 160 | "Top": 105, 161 | "Left": 50, 162 | "Width": 75, 163 | "Height": 20 164 | } 165 | }, 166 | { 167 | "ControlGroup": "3", 168 | "ControlPair": "1", 169 | "ControlHeader": "1", 170 | "top": "1.75", 171 | "left": "0", 172 | "x": "1", 173 | "ControlType": "variable", 174 | "Display": { 175 | "Service": "urn:micasaverde-com:serviceId:EnergyMetering1", 176 | "Variable": "Voltage", 177 | "Top": 105, 178 | "Left": 150, 179 | "Width": 25, 180 | "Height": 20 181 | } 182 | }, 183 | { 184 | "ControlGroup": "3", 185 | "ControlPair": "1", 186 | "ControlHeader": "1", 187 | "top": "1.75", 188 | "left": "1.25", 189 | "x": "1", 190 | 191 | "ControlType": "label", 192 | "Label": { 193 | "lang_tag": "volts", 194 | "text": "V" 195 | }, 196 | "Display": { 197 | "Top": 105, 198 | "Left": 200, 199 | "Width": 25, 200 | "Height": 20 201 | } 202 | } 203 | 204 | ] 205 | }, 206 | { 207 | "Label": { 208 | "lang_tag": "advanced", 209 | "text": "Advanced" 210 | }, 211 | "Position": "1", 212 | "TabType": "javascript", 213 | "ScriptName": "shared.js", 214 | "Function": "advanced_device" 215 | }, 216 | { 217 | "Label": { 218 | "lang_tag": "logs", 219 | "text": "Logs" 220 | }, 221 | "Position": "2", 222 | "TabType": "javascript", 223 | "ScriptName": "shared.js", 224 | "Function": "device_logs" 225 | }, 226 | { 227 | "Label": { 228 | "lang_tag": "notifications", 229 | "text": "Notifications" 230 | }, 231 | "Position": "3", 232 | "TabType": "javascript", 233 | "ScriptName": "shared.js", 234 | "Function": "device_notifications" 235 | } 236 | ], 237 | "eventList2": [ 238 | { 239 | "id": 1, 240 | "label": { 241 | "lang_tag": "impedance_goes_above", 242 | "text": "Impedance goes above" 243 | }, 244 | "serviceId": "urn:micasaverde-com:serviceId:ScaleSensor1", 245 | "norepeat": "1", 246 | "argumentList": [ 247 | { 248 | "id": 1, 249 | "dataType": "i2", 250 | "name": "Impedance", 251 | "comparisson": ">", 252 | "prefix": { 253 | "lang_tag": "Impedance", 254 | "text": "Impedance" 255 | }, 256 | "suffix": { 257 | "lang_tag": "uf_unit", 258 | "text": "uF" 259 | }, 260 | "HumanFriendlyText": { 261 | "lang_tag": "impedance_goes_above", 262 | "text": "Impendance for _DEVICE_NAME_ goes above _ARGUMENT_VALUE_" 263 | } 264 | } 265 | ] 266 | }, 267 | { 268 | "id": 2, 269 | "label": { 270 | "lang_tag": "impendance_goes_below", 271 | "text": "Impendance goes below" 272 | }, 273 | "serviceId": "urn:micasaverde-com:serviceId:ScaleSensor1", 274 | "norepeat": "1", 275 | "argumentList": [ 276 | { 277 | "id": 1, 278 | "dataType": "i2", 279 | "name": "Impedance", 280 | "comparisson": "<", 281 | "prefix": { 282 | "lang_tag": "Impedance", 283 | "text": "Impedance" 284 | }, 285 | "suffix": { 286 | "lang_tag": "uf_unit", 287 | "text": "uF" 288 | }, 289 | "HumanFriendlyText": { 290 | "lang_tag": "impendance_goes_below", 291 | "text": "Impendance for _DEVICE_NAME_ goes below _ARGUMENT_VALUE_" 292 | } 293 | } 294 | ] 295 | }, 296 | { 297 | "id": 3, 298 | "label": { 299 | "lang_tag": "voltage_goes_above", 300 | "text": "Voltage goes above" 301 | }, 302 | "serviceId": "urn:micasaverde-com:serviceId:EnergyMetering1", 303 | "norepeat": "1", 304 | "argumentList": [ 305 | { 306 | "id": 1, 307 | "dataType": "i2", 308 | "name": "Voltage", 309 | "comparisson": ">", 310 | "prefix": { 311 | "lang_tag": "Volt", 312 | "text": "Voltage" 313 | }, 314 | "suffix": { 315 | "lang_tag": "volts", 316 | "text": "V" 317 | }, 318 | "HumanFriendlyText": { 319 | "lang_tag": "voltage_goes_above", 320 | "text": "Voltage for _DEVICE_NAME_ goes above _ARGUMENT_VALUE_" 321 | } 322 | } 323 | ] 324 | }, 325 | { 326 | "id": 4, 327 | "label": { 328 | "lang_tag": "voltage_goes_below", 329 | "text": "Voltage goes below" 330 | }, 331 | "serviceId": "urn:micasaverde-com:serviceId:EnergyMetering1", 332 | "norepeat": "1", 333 | "argumentList": [ 334 | { 335 | "id": 1, 336 | "dataType": "i2", 337 | "name": "Voltage", 338 | "comparisson": "<", 339 | "prefix": { 340 | "lang_tag": "Volt", 341 | "text": "Voltage" 342 | }, 343 | "suffix": { 344 | "lang_tag": "volts", 345 | "text": "V" 346 | }, 347 | "HumanFriendlyText": { 348 | "lang_tag": "voltage_goes_below", 349 | "text": "Voltage for _DEVICE_NAME_ goes below _ARGUMENT_VALUE_" 350 | } 351 | } 352 | ] 353 | }, 354 | { 355 | "id": 5, 356 | "label": { 357 | "lang_tag": "current_goes_above", 358 | "text": "Current goes above" 359 | }, 360 | "serviceId": "urn:micasaverde-com:serviceId:EnergyMetering1", 361 | "norepeat": "1", 362 | "argumentList": [ 363 | { 364 | "id": 1, 365 | "dataType": "i2", 366 | "name": "Current", 367 | "comparisson": ">", 368 | "prefix": { 369 | "lang_tag": "Amp", 370 | "text": "Current" 371 | }, 372 | "suffix": { 373 | "lang_tag": "amps", 374 | "text": "A" 375 | }, 376 | "HumanFriendlyText": { 377 | "lang_tag": "current_goes_above", 378 | "text": "Current for _DEVICE_NAME_ goes above _ARGUMENT_VALUE_" 379 | } 380 | } 381 | ] 382 | }, 383 | { 384 | "id": 6, 385 | "label": { 386 | "lang_tag": "current_goes_below", 387 | "text": "Current goes below" 388 | }, 389 | "serviceId": "urn:micasaverde-com:serviceId:EnergyMetering1", 390 | "norepeat": "1", 391 | "argumentList": [ 392 | { 393 | "id": 1, 394 | "dataType": "i2", 395 | "name": "Current", 396 | "comparisson": "<", 397 | "prefix": { 398 | "lang_tag": "Amp", 399 | "text": "Current" 400 | }, 401 | "suffix": { 402 | "lang_tag": "amps", 403 | "text": "A" 404 | }, 405 | "HumanFriendlyText": { 406 | "lang_tag": "current_goes_below", 407 | "text": "Current for _DEVICE_NAME_ goes below _ARGUMENT_VALUE_" 408 | } 409 | } 410 | ] 411 | } 412 | ], 413 | "DeviceType": "urn:schemas-micasaverde-com:device:EnergyMetering:1" 414 | } 415 | -------------------------------------------------------------------------------- /Multimeter/D_Multimeter1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | urn:schemas-micasaverde-com:device:EnergyMetering:1 9 | 12 10 | D_Multimeter1.json 11 | 12 | 13 | urn:schemas-micasaverde-com:service:EnergyMetering:1 14 | urn:micasaverde-com:serviceId:EnergyMetering1 15 | S_Multimeter1.xml 16 | 17 | 18 | urn:schemas-micasaverde-com:service:HaDevice:1 19 | urn:micasaverde-com:serviceId:HaDevice1 20 | S_HaDevice1.xml 21 | 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /Multimeter/S_Multimeter1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | 9 | Impedance 10 | yes 11 | i2 12 | impedance 13 | 14 | 15 | Voltage 16 | yes 17 | i2 18 | voltage 19 | 20 | 21 | Current 22 | yes 23 | i2 24 | current 25 | 26 | 27 | 28 | 29 | GetImpedance 30 | 31 | 32 | ImpedanceValue 33 | out 34 | Impedance 35 | 36 | 37 | 38 | 39 | GetVoltage 40 | 41 | 42 | VoltageValue 43 | out 44 | Voltage 45 | 46 | 47 | 48 | 49 | GetCurrent 50 | 51 | 52 | CurrentValue 53 | out 54 | Current 55 | 56 | 57 | 58 | 59 | 60 | -------------------------------------------------------------------------------- /S_Arduino.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | 9 | InclusionMode 10 | no 11 | string 12 | 13 | 14 | InclusionFoundCount 15 | no 16 | string 17 | 18 | 19 | Unit 20 | no 21 | string 22 | 23 | 24 | PluginVersion 25 | no 26 | string 27 | 28 | 29 | ArduinoLibVersion 30 | no 31 | string 32 | 33 | 34 | 35 | 36 | 37 | SetUnit 38 | 39 | 40 | unit 41 | in 42 | A_ARG_TYPE_unit 43 | 44 | 45 | 46 | 47 | 48 | 49 | SendCommand 50 | 51 | 52 | radioId 53 | in 54 | A_ARG_TYPE_radioId 55 | 56 | 57 | variableId 58 | in 59 | A_ARG_TYPE_variableId 60 | 61 | 62 | value 63 | in 64 | A_ARG_TYPE_value 65 | 66 | 67 | 68 | 69 | 70 | StartInclusion 71 | 72 | 73 | 74 | 75 | StopInclusion 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | -------------------------------------------------------------------------------- /S_ArduinoNode.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | 9 | ArduinoLibVersion 10 | no 11 | string 12 | 13 | 14 | Children 15 | no 16 | string 17 | 18 | 19 | RelayNode 20 | no 21 | string 22 | 23 | 24 | RelayNodeHR 25 | no 26 | string 27 | 28 | 29 | SketchName 30 | no 31 | string 32 | 33 | 34 | SketchVersion 35 | no 36 | string 37 | 38 | 39 | LastUpdateHR 40 | no 41 | string 42 | 43 | 44 | 45 | 46 | 47 | SendNodeCommand 48 | 49 | 50 | variableId 51 | in 52 | A_ARG_TYPE_variableId 53 | 54 | 55 | value 56 | in 57 | A_ARG_TYPE_value 58 | 59 | 60 | 61 | 62 | 63 | ClearChildren 64 | 65 | 66 | 67 | 68 | 69 | -------------------------------------------------------------------------------- /WindSensor/D_WindSensor1.json: -------------------------------------------------------------------------------- 1 | { 2 | "flashicon": "http://www.mysensors.org/icon/wind.png", 3 | "imgIconBody": "", 4 | "imgIconDimmable": "", 5 | "imgIconTurnable": "", 6 | "imgIconMin": "", 7 | "imgIconMax": "", 8 | "halloIconsDir": "pics/hallo", 9 | "inScene": "0", 10 | "DisplayStatus": {}, 11 | "doc_url": { 12 | "doc_language": 1, 13 | "doc_manual": 1, 14 | "doc_version": 1, 15 | "doc_platform": 0, 16 | "doc_page": "sensors" 17 | }, 18 | "Tabs": [ 19 | { 20 | "Label": { 21 | "lang_tag": "tabname_control", 22 | "text": "Information" 23 | }, 24 | "Position": "0", 25 | "TabType": "flash", 26 | "SceneGroup": [ 27 | { 28 | "id": "1", 29 | "top": "1.5", 30 | "left": "0", 31 | "x": "2", 32 | "y": "2" 33 | } 34 | ], 35 | "ControlGroup": [ 36 | { 37 | "id": "1", 38 | "scenegroup": "1", 39 | "type": "info" 40 | }, 41 | { 42 | "id": "3", 43 | "scenegroup": "1", 44 | "type": "info" 45 | }, 46 | { 47 | "id": "2", 48 | "scenegroup": "1", 49 | "type": "info" 50 | } 51 | ], 52 | "Control": [ 53 | { 54 | "ControlGroup": "1", 55 | "ControlPair": "1", 56 | "ControlHeader": "1", 57 | "top": "0", 58 | "left": "1.25", 59 | "x": "0.75", 60 | "ControlType": "variable", 61 | "Display": { 62 | "Service": "urn:upnp-org:serviceId:WindSensor1", 63 | "Variable": "AvgSpeed", 64 | "Top": 30, 65 | "Left": 150, 66 | "Width": 25, 67 | "Height": 20 68 | } 69 | }, 70 | { 71 | "ControlType": "label", 72 | "Label": { 73 | "lang_tag": "pressure_unit", 74 | "text": "km/h" 75 | }, 76 | "Display": { 77 | "Top": 30, 78 | "Left": 200, 79 | "Width": 25, 80 | "Height": 20 81 | } 82 | }, 83 | { 84 | "ControlGroup": "2", 85 | "ControlPair": "1", 86 | "ControlHeader": "1", 87 | "top": "0", 88 | "left": "0", 89 | "x": "1.25", 90 | "ControlType": "label", 91 | "Label": { 92 | "lang_tag": "speed", 93 | "text": "AVG Speed" 94 | }, 95 | "Display": { 96 | "Top": 30, 97 | "Left": 50, 98 | "Width": 75, 99 | "Height": 20 100 | } 101 | }, 102 | { 103 | "ControlGroup": "2", 104 | "ControlPair": "1", 105 | "ControlHeader": "1", 106 | "top": "0.5", 107 | "left": "0", 108 | "x": "1.25", 109 | "ControlType": "label", 110 | "Label": { 111 | "lang_tag": "speed", 112 | "text": "Gust Speed" 113 | }, 114 | "Display": { 115 | "Top": 55, 116 | "Left": 50, 117 | "Width": 75, 118 | "Height": 20 119 | } 120 | }, 121 | { 122 | "ControlGroup": "2", 123 | "ControlPair": "1", 124 | "ControlHeader": "1", 125 | "top": "0.5", 126 | "left": "1.25", 127 | "x": "0.75", 128 | "ControlType": "variable", 129 | "Display": { 130 | "Service": "urn:upnp-org:serviceId:WindSensor1", 131 | "Variable": "GustSpeed", 132 | "Top": 55, 133 | "Left": 150, 134 | "Width": 25, 135 | "Height": 20 136 | } 137 | }, 138 | 139 | { 140 | "ControlType": "label", 141 | "Label": { 142 | "lang_tag": "pressure_unit", 143 | "text": "km/h" 144 | }, 145 | "Display": { 146 | "Top": 55, 147 | "Left": 200, 148 | "Width": 25, 149 | "Height": 20 150 | } 151 | }, 152 | { 153 | "ControlType": "label", 154 | "Label": { 155 | "lang_tag": "direction", 156 | "text": "Direction" 157 | }, 158 | "Display": { 159 | "Top": 80, 160 | "Left": 50, 161 | "Width": 75, 162 | "Height": 20 163 | } 164 | }, 165 | { 166 | "ControlGroup": "3", 167 | "top": "1", 168 | "left": "0", 169 | "x": "2", 170 | "ControlType": "variable", 171 | "Display": { 172 | "Service": "urn:upnp-org:serviceId:WindSensor1", 173 | "Variable": "Direction", 174 | "Top": 80, 175 | "Left": 150, 176 | "Width": 100, 177 | "Height": 20 178 | } 179 | } 180 | ] 181 | }, 182 | { 183 | "Label": { 184 | "lang_tag": "advanced", 185 | "text": "Advanced" 186 | }, 187 | "Position": "1", 188 | "TabType": "javascript", 189 | "ScriptName": "shared.js", 190 | "Function": "advanced_device" 191 | }, 192 | { 193 | "Label": { 194 | "lang_tag": "logs", 195 | "text": "Logs" 196 | }, 197 | "Position": "2", 198 | "TabType": "javascript", 199 | "ScriptName": "shared.js", 200 | "Function": "device_logs" 201 | }, 202 | { 203 | "Label": { 204 | "lang_tag": "notifications", 205 | "text": "Notifications" 206 | }, 207 | "Position": "3", 208 | "TabType": "javascript", 209 | "ScriptName": "shared.js", 210 | "Function": "device_notifications" 211 | } 212 | ], 213 | "eventList2": [ 214 | { 215 | "id": 1, 216 | "label": { 217 | "lang_tag": "pressure_goes_above", 218 | "text": "AVG Wind goes above" 219 | }, 220 | "serviceId": "urn:upnp-org:serviceId:WindSensor1", 221 | "norepeat": "1", 222 | "argumentList": [ 223 | { 224 | "id": 1, 225 | "dataType": "i2", 226 | "name": "AVGSpeed", 227 | "comparisson": ">", 228 | "prefix": { 229 | "lang_tag": "speed", 230 | "text": "Speed" 231 | }, 232 | "suffix": { 233 | "lang_tag": "pressure_unit", 234 | "text": "kmh" 235 | }, 236 | "HumanFriendlyText": { 237 | "lang_tag": "hft_pressure_goes_above", 238 | "text": "AVG Winnd for _DEVICE_NAME_ goes above _ARGUMENT_VALUE_" 239 | } 240 | } 241 | ] 242 | }, 243 | { 244 | "id": 2, 245 | "label": { 246 | "lang_tag": "pressure_goes_below", 247 | "text": "Wind gust goes above" 248 | }, 249 | "serviceId": "urn:upnp-org:serviceId:WindSensor1", 250 | "norepeat": "1", 251 | "argumentList": [ 252 | { 253 | "id": 1, 254 | "dataType": "i2", 255 | "name": "GustSpeed", 256 | "comparisson": ">", 257 | "prefix": { 258 | "lang_tag": "speed", 259 | "text": "Speed" 260 | }, 261 | "suffix": { 262 | "lang_tag": "pressure_unit", 263 | "text": "kmh" 264 | }, 265 | "HumanFriendlyText": { 266 | "lang_tag": "hft_pressure_goes_below", 267 | "text": "Wind gust for _DEVICE_NAME_ goes above _ARGUMENT_VALUE_" 268 | } 269 | } 270 | ] 271 | }, 272 | ], 273 | "DeviceType": "urn:schemas-micasaverde-com:device:WindSensor:1" 274 | } 275 | -------------------------------------------------------------------------------- /WindSensor/D_WindSensor1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | urn:schemas-micasaverde-com:device:WindSensor:1 9 | 12 10 | D_WindSensor1.json 11 | 12 | 13 | urn:schemas-upnp-org:service:WindSensor:1 14 | urn:upnp-org:serviceId:WindSensor1 15 | S_WindSensor1.xml 16 | 17 | 18 | urn:schemas-micasaverde-com:service:HaDevice:1 19 | urn:micasaverde-com:serviceId:HaDevice1 20 | S_HaDevice1.xml 21 | 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /WindSensor/S_WindSensor1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | 9 | AvgSpeed 10 | yes 11 | i2 12 | avgspeed 13 | 14 | 15 | GustSpeed 16 | yes 17 | i2 18 | gustspeed 19 | 20 | 21 | Direction 22 | yes 23 | string 24 | direction 25 | 26 | 27 | 28 | GetAVGSpeed 29 | 30 | 31 | AVGSpeedValue 32 | out 33 | AvgSpeed 34 | 35 | 36 | 37 | 38 | GetGustSpeed 39 | 40 | 41 | GustSpeedValue 42 | out 43 | GustSpeed 44 | 45 | 46 | 47 | 48 | 49 | -------------------------------------------------------------------------------- /barometer/D_BarometerSensor1.json: -------------------------------------------------------------------------------- 1 | { 2 | "default_icon" : "https://media.vsm.net.ua/vera/icons/col2/unknown.png", 3 | "state_icons" : [ 4 | { 5 | "img": "https://media.vsm.net.ua/vera/icons/col2/stable.png", 6 | "conditions": [ 7 | { 8 | "service": "urn:upnp-org:serviceId:BarometerSensor1", 9 | "variable": "Forecast", 10 | "operator": "==", 11 | "value": "stable" 12 | } 13 | ] 14 | }, 15 | { 16 | "img": "https://media.vsm.net.ua/vera/icons/col2/sunny.png", 17 | "conditions": [ 18 | { 19 | "service": "urn:upnp-org:serviceId:BarometerSensor1", 20 | "variable": "Forecast", 21 | "operator": "==", 22 | "value": "sunny" 23 | } 24 | ] 25 | }, 26 | { 27 | "img": "https://media.vsm.net.ua/vera/icons/col2/cloudy.png", 28 | "conditions": [ 29 | { 30 | "service": "urn:upnp-org:serviceId:BarometerSensor1", 31 | "variable": "Forecast", 32 | "operator": "==", 33 | "value": "cloudy" 34 | } 35 | ] 36 | }, 37 | { 38 | "img": "https://media.vsm.net.ua/vera/icons/col2/unstable.png", 39 | "conditions": [ 40 | { 41 | "service": "urn:upnp-org:serviceId:BarometerSensor1", 42 | "variable": "Forecast", 43 | "operator": "==", 44 | "value": "unstable" 45 | } 46 | ] 47 | }, 48 | { 49 | "img": "https://media.vsm.net.ua/vera/icons/col2/thunderstorm.png", 50 | "conditions": [ 51 | { 52 | "service": "urn:upnp-org:serviceId:BarometerSensor1", 53 | "variable": "Forecast", 54 | "operator": "==", 55 | "value": "thunderstorm" 56 | } 57 | ] 58 | }, 59 | { 60 | "img": "https://media.vsm.net.ua/vera/icons/col2/unknown.png", 61 | "conditions": [ 62 | { 63 | "service": "urn:upnp-org:serviceId:BarometerSensor1", 64 | "variable": "Forecast", 65 | "operator": "==", 66 | "value": "unknown" 67 | } 68 | ] 69 | } 70 | ], 71 | "imgIconBody" : "", 72 | "imgIconDimmable" : "", 73 | "imgIconTurnable" : "", 74 | "imgIconMin" : "", 75 | "imgIconMax" : "", 76 | "halloIconsDir" : "pics/hallo", 77 | "x": "3", 78 | "y": "4", 79 | "inScene": "0", 80 | "DisplayStatus": {}, 81 | "doc_url": { 82 | "doc_language": 1, 83 | "doc_manual": 1, 84 | "doc_version": 1, 85 | "doc_platform": 0, 86 | "doc_page": "sensors" 87 | }, 88 | "Tabs":[ 89 | { 90 | "Label": { 91 | "lang_tag": "tabname_control", 92 | "text": "Information" 93 | }, 94 | "Position": "0", 95 | "TabType": "flash", 96 | "SceneGroup": [ 97 | { 98 | "id": "1", 99 | "top": "1", 100 | "left": "0", 101 | "x": "2", 102 | "y": "3" 103 | } 104 | ], 105 | "ControlGroup": [ 106 | { 107 | "id": "1", 108 | "scenegroup": "1", 109 | "type": "info" 110 | } 111 | ], 112 | "Control": [ 113 | { 114 | "ControlGroup": 1, 115 | "ControlType": "spacer", 116 | "HorizontalMultiplier": "0.7" 117 | }, 118 | { 119 | "ControlGroup": "1", 120 | "ControlPair": "1", 121 | "ControlHeader": "1", 122 | "ControlType": "label", 123 | "top": 0, 124 | "left": 0, 125 | "x": 1.25, 126 | "Label": { 127 | "lang_tag": "Pressure", 128 | "text": "Pressure:" 129 | }, 130 | "Display": { 131 | "Top": 30, 132 | "Left": 50, 133 | "Width": 75, 134 | "Height": 20 135 | } 136 | }, 137 | { 138 | "ControlGroup": "1", 139 | "ControlPair": "1", 140 | "ControlHeader": "1", 141 | "ControlType": "variable", 142 | "top": "0", 143 | "left": "1.25", 144 | "x": "0.75", 145 | "Display": { 146 | "Service": "urn:upnp-org:serviceId:BarometerSensor1", 147 | "Variable": "CurrentPressure", 148 | "Top": 30, 149 | "Left": 150, 150 | "Width": 25, 151 | "Height": 20 152 | } 153 | }, 154 | { 155 | "ControlGroup": 1, 156 | "ControlType": "spacer", 157 | "HorizontalMultiplier": "0.3" 158 | }, 159 | { 160 | "ControlGroup": "1", 161 | "ControlPair": "1", 162 | "ControlHeader": "1", 163 | "ControlType": "label", 164 | "Label": { 165 | "lang_tag": "pressure_unit", 166 | "text": "hPa" 167 | }, 168 | "Display": { 169 | "Top": 30, 170 | "Left": 200, 171 | "Width": 25, 172 | "Height": 20 173 | } 174 | }, 175 | { 176 | "ControlGroup": 1, 177 | "ControlType": "line_break" 178 | }, 179 | { 180 | "ControlGroup": 1, 181 | "ControlType": "spacer", 182 | "HorizontalMultiplier": "0.7" 183 | }, 184 | { 185 | "ControlGroup": "1", 186 | "ControlPair": "1", 187 | "ControlHeader": "1", 188 | "ControlType": "label", 189 | "Label": { 190 | "lang_tag": "forecast", 191 | "text": "Forecast:" 192 | }, 193 | "Display": { 194 | "Top": 55, 195 | "Left": 50, 196 | "Width": 100, 197 | "Height": 20 198 | } 199 | }, 200 | { 201 | "ControlGroup": 1, 202 | "ControlType": "spacer", 203 | "HorizontalMultiplier": "0.3" 204 | }, 205 | { 206 | "ControlGroup": "1", 207 | "ControlPair": "1", 208 | "ControlHeader": "1", 209 | "top": "1", 210 | "left": "0", 211 | "x": "2", 212 | "ControlType": "variable", 213 | "Display": { 214 | "Service": "urn:upnp-org:serviceId:BarometerSensor1", 215 | "Variable": "Forecast", 216 | "Top": 55, 217 | "Left": 150, 218 | "Width": 100, 219 | "Height": 20 220 | } 221 | } 222 | 223 | ] 224 | }, 225 | { 226 | "Label": { 227 | "lang_tag": "advanced", 228 | "text": "Advanced" 229 | }, 230 | "Position": "1", 231 | "TabType": "javascript", 232 | "ScriptName": "shared.js", 233 | "Function": "advanced_device" 234 | }, 235 | { 236 | "Label": { 237 | "lang_tag": "logs", 238 | "text": "Logs" 239 | }, 240 | "Position": "2", 241 | "TabType": "javascript", 242 | "ScriptName": "shared.js", 243 | "Function": "device_logs" 244 | }, 245 | { 246 | "Label": { 247 | "lang_tag": "notifications", 248 | "text": "Notifications" 249 | }, 250 | "Position": "3", 251 | "TabType": "javascript", 252 | "ScriptName": "shared.js", 253 | "Function": "device_notifications" 254 | } 255 | ], 256 | "eventList2": [ 257 | { 258 | "id": 1, 259 | "label": { 260 | "lang_tag": "pressure_goes_above", 261 | "text": "Pressure goes above" 262 | }, 263 | "serviceId": "urn:upnp-org:serviceId:BarometerSensor1", 264 | "norepeat": "1", 265 | "argumentList": [ 266 | { 267 | "id": 1, 268 | "dataType": "i2", 269 | "name": "CurrentPressure", 270 | "comparisson": ">", 271 | "prefix": { 272 | "lang_tag": "pressure", 273 | "text": "Pressure" 274 | }, 275 | "suffix": { 276 | "lang_tag": "pressure_unit", 277 | "text": "hPa" 278 | }, 279 | "HumanFriendlyText": { 280 | "lang_tag": "hft_pressure_goes_above", 281 | "text": "Pressure for _DEVICE_NAME_ goes above _ARGUMENT_VALUE_" 282 | } 283 | } 284 | ] 285 | }, 286 | { 287 | "id": 2, 288 | "label": { 289 | "lang_tag": "pressure_goes_below", 290 | "text": "Pressure goes below" 291 | }, 292 | "serviceId": "urn:upnp-org:serviceId:BarometerSensor1", 293 | "norepeat": "1", 294 | "argumentList": [ 295 | { 296 | "id": 1, 297 | "dataType": "i2", 298 | "name": "CurrentPressure", 299 | "comparisson": "<", 300 | "prefix": { 301 | "lang_tag": "pressure", 302 | "text": "Pressure" 303 | }, 304 | "suffix": { 305 | "lang_tag": "pressure_unit", 306 | "text": "hPa" 307 | }, 308 | "HumanFriendlyText": { 309 | "lang_tag": "hft_pressure_goes_below", 310 | "text": "Pressure for _DEVICE_NAME_ goes below _ARGUMENT_VALUE_" 311 | } 312 | } 313 | ] 314 | }, 315 | { 316 | "id": 3, 317 | "label": { 318 | "lang_tag": "forecast_reaches", 319 | "text": "Forecast is" 320 | }, 321 | "serviceId": "urn:upnp-org:serviceId:BarometerSensor1", 322 | "norepeat": "1", 323 | "argumentList": [ 324 | { 325 | "id": 1, 326 | "dataType": "string", 327 | "name": "Forecast", 328 | "allowedValueList" : [ 329 | { 330 | "value": "stable", 331 | "HumanFriendlyText": { 332 | "lang_tag": "hft_stable", 333 | "text": "_DEVICE_NAME_: Forecast is 'stable' weather" 334 | } 335 | }, 336 | { 337 | "value": "sunny", 338 | "HumanFriendlyText": { 339 | "lang_tag": "hft_sunny", 340 | "text": "_DEVICE_NAME_: Forecast is 'clear/sunny' slowly raising h-pressure" 341 | } 342 | }, 343 | { 344 | "value": "cloudy", 345 | "HumanFriendlyText": { 346 | "lang_tag": "hft_cloudy", 347 | "text": "_DEVICE_NAME_: Forecast is 'cloudy/rain' slowly falling l-pressure" 348 | } 349 | }, 350 | { 351 | "value": "unstable", 352 | "HumanFriendlyText": { 353 | "lang_tag": "hft_unstable", 354 | "text": "_DEVICE_NAME_: Forecast is 'not stable' quickly rising h-pressure" 355 | } 356 | }, 357 | { 358 | "value": "thunderstorm", 359 | "HumanFriendlyText": { 360 | "lang_tag": "hft_thunderstorm", 361 | "text": "_DEVICE_NAME_: Forecast is 'thunderstorm' quickly falling l-pressure" 362 | } 363 | }, 364 | { 365 | "value": "unknown", 366 | "HumanFriendlyText": { 367 | "lang_tag": "hft_unknown", 368 | "text": "_DEVICE_NAME_: Forecast is 'unknown'" 369 | } 370 | } 371 | ], 372 | "prefix": { 373 | "lang_tag": "forecast", 374 | "text": "Forecast" 375 | }, 376 | "suffix": { 377 | } 378 | } 379 | ] 380 | } 381 | ], 382 | "device_type": "urn:schemas-micasaverde-com:device:BarometerSensor:1" 383 | } 384 | -------------------------------------------------------------------------------- /barometer/D_BarometerSensor1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | urn:schemas-micasaverde-com:device:BarometerSensor:1 9 | 12 10 | D_BarometerSensor1.json 11 | 12 | 13 | urn:schemas-upnp-org:service:BarometerSensor:1 14 | urn:upnp-org:serviceId:BarometerSensor1 15 | S_BarometerSensor1.xml 16 | 17 | 18 | urn:schemas-micasaverde-com:service:HaDevice:1 19 | urn:micasaverde-com:serviceId:HaDevice1 20 | S_HaDevice1.xml 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /barometer/S_BarometerSensor1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | 9 | CurrentPressure 10 | yes 11 | i2 12 | pressure 13 | 14 | 15 | Forecast 16 | yes 17 | string 18 | forecast 19 | 20 | 21 | 22 | GetCurrentPressure 23 | 24 | 25 | PressureValue 26 | out 27 | CurrentPressure 28 | 29 | GetForecast 30 | 31 | 32 | ForecastValue 33 | out 34 | Forecast 35 | 36 | -------------------------------------------------------------------------------- /distance/D_DistanceSensor1.json: -------------------------------------------------------------------------------- 1 | { 2 | "flashicon": "http://code.mios.com/trac/mios_arduino-sensor/raw-attachment/wiki/DistanceSensor/tmeasure.png", 3 | "imgIconBody": "", 4 | "imgIconDimmable": "", 5 | "imgIconTurnable": "", 6 | "imgIconMin": "", 7 | "imgIconMax": "", 8 | "halloIconsDir": "pics/hallo", 9 | "inScene": "0", 10 | "DisplayStatus": {}, 11 | "doc_url": { 12 | "doc_language": 1, 13 | "doc_manual": 1, 14 | "doc_version": 1, 15 | "doc_platform": 0, 16 | "doc_page": "sensors" 17 | }, 18 | "Tabs": [ 19 | { 20 | "Label": { 21 | "lang_tag": "tabname_control", 22 | "text": "Information" 23 | }, 24 | "Position": "0", 25 | "TabType": "flash", 26 | "SceneGroup": [ 27 | { 28 | "id": "1", 29 | "top": "1.5", 30 | "left": "0", 31 | "x": "2", 32 | "y": "2" 33 | } 34 | ], 35 | "ControlGroup": [ 36 | { 37 | "id": "1", 38 | "scenegroup": "1", 39 | "type": "info" 40 | }, 41 | { 42 | "id": "2", 43 | "scenegroup": "1", 44 | "type": "info" 45 | } 46 | ], 47 | "Control": [ 48 | { 49 | "ControlGroup": "1", 50 | "ControlPair": "1", 51 | "ControlHeader": "1", 52 | "top": "0", 53 | "left": "0", 54 | "x": "1.25", 55 | "ControlType": "label", 56 | "Label": { 57 | "lang_tag": "distance", 58 | "text": "Distance" 59 | }, 60 | "Display": { 61 | "Top": 30, 62 | "Left": 50, 63 | "Width": 75, 64 | "Height": 20 65 | } 66 | }, 67 | { 68 | "ControlGroup": "1", 69 | "ControlPair": "1", 70 | "ControlHeader": "1", 71 | "top": "0", 72 | "left": "1.25", 73 | "x": "0.75", 74 | "ControlType": "variable", 75 | "Display": { 76 | "Service": "urn:micasaverde-com:serviceId:DistanceSensor1", 77 | "Variable": "CurrentDistance", 78 | "Top": 30, 79 | "Left": 150, 80 | "Width": 25, 81 | "Height": 20 82 | } 83 | }, 84 | { 85 | "ControlType": "label", 86 | "Label": { 87 | "lang_tag": "distance_unit", 88 | "text": "cm" 89 | }, 90 | "Display": { 91 | "Top": 30, 92 | "Left": 200, 93 | "Width": 25, 94 | "Height": 20 95 | } 96 | } 97 | ] 98 | }, 99 | { 100 | "Label": { 101 | "lang_tag": "advanced", 102 | "text": "Advanced" 103 | }, 104 | "Position": "1", 105 | "TabType": "javascript", 106 | "ScriptName": "shared.js", 107 | "Function": "advanced_device" 108 | }, 109 | { 110 | "Label": { 111 | "lang_tag": "logs", 112 | "text": "Logs" 113 | }, 114 | "Position": "2", 115 | "TabType": "javascript", 116 | "ScriptName": "shared.js", 117 | "Function": "device_logs" 118 | }, 119 | { 120 | "Label": { 121 | "lang_tag": "notifications", 122 | "text": "Notifications" 123 | }, 124 | "Position": "3", 125 | "TabType": "javascript", 126 | "ScriptName": "shared.js", 127 | "Function": "device_notifications" 128 | } 129 | ], 130 | "eventList2": [ 131 | { 132 | "id": 1, 133 | "label": { 134 | "lang_tag": "disatance_goes_above", 135 | "text": "Distance goes above" 136 | }, 137 | "serviceId": "urn:micasaverde-com:serviceId:DistanceSensor1", 138 | "norepeat": "1", 139 | "argumentList": [ 140 | { 141 | "id": 1, 142 | "dataType": "i2", 143 | "name": "CurrentDistance", 144 | "comparisson": ">", 145 | "prefix": { 146 | "lang_tag": "distance", 147 | "text": "Distance" 148 | }, 149 | "suffix": { 150 | "lang_tag": "distance_unit", 151 | "text": "cm" 152 | }, 153 | "HumanFriendlyText": { 154 | "lang_tag": "hft_distance_goes_above", 155 | "text": "Distance for _DEVICE_NAME_ goes above _ARGUMENT_VALUE_" 156 | } 157 | } 158 | ] 159 | }, 160 | { 161 | "id": 2, 162 | "label": { 163 | "lang_tag": "distance_goes_below", 164 | "text": "Distance goes below" 165 | }, 166 | "serviceId": "urn:micasaverde-com:serviceId:DistanceSensor1", 167 | "norepeat": "1", 168 | "argumentList": [ 169 | { 170 | "id": 1, 171 | "dataType": "i2", 172 | "name": "CurrentDistance", 173 | "comparisson": "<", 174 | "prefix": { 175 | "lang_tag": "distance", 176 | "text": "Distance" 177 | }, 178 | "suffix": { 179 | "lang_tag": "distance_unit", 180 | "text": "cm" 181 | }, 182 | "HumanFriendlyText": { 183 | "lang_tag": "hft_distance_goes_below", 184 | "text": "Distance for _DEVICE_NAME_ goes below _ARGUMENT_VALUE_" 185 | } 186 | } 187 | ] 188 | } 189 | ], 190 | "DeviceType": "urn:schemas-micasaverde-com:device:DistanceSensor:1" 191 | } -------------------------------------------------------------------------------- /distance/D_DistanceSensor1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | urn:schemas-micasaverde-com:device:DistanceSensor:1 9 | 12 10 | D_DistanceSensor1.json 11 | 12 | 13 | urn:schemas-upnp-org:service:DistanceSensor:1 14 | urn:upnp-org:serviceId:DistanceSensor1 15 | S_DistanceSensor1.xml 16 | 17 | 18 | urn:schemas-micasaverde-com:service:HaDevice:1 19 | urn:micasaverde-com:serviceId:HaDevice1 20 | S_HaDevice1.xml 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /distance/S_DistanceSensor1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | 9 | CurrentDistance 10 | yes 11 | i2 12 | dist 13 | 14 | 15 | 16 | 17 | GetCurrentDistance 18 | 19 | 20 | DistanceValue 21 | out 22 | CurrentDistance 23 | 24 | 25 | -------------------------------------------------------------------------------- /raingauge/D_RainSensor1.json: -------------------------------------------------------------------------------- 1 | { 2 | "flashicon": "icons/Humidity_Sensor.swf", 3 | "imgIconBody": "", 4 | "imgIconDimmable": "", 5 | "imgIconTurnable": "", 6 | "imgIconMin": "", 7 | "imgIconMax": "", 8 | "halloIconsDir": "pics\/hallo", 9 | "inScene": "0", 10 | "DisplayStatus": {}, 11 | "doc_url": { 12 | "doc_language": 1, 13 | "doc_manual": 1, 14 | "doc_version": 1, 15 | "doc_platform": 0, 16 | "doc_page": "sensors" 17 | }, 18 | 19 | "Tabs": [ 20 | { 21 | "Label": { 22 | "lang_tag": "tabname_control", 23 | "text": "Information" 24 | }, 25 | "Position": "0", 26 | "TabType": "flash", 27 | "SceneGroup": [ 28 | { 29 | "id": "1", 30 | "top": "1.5", 31 | "left": "0", 32 | "x": "2", 33 | "y": "2" 34 | } 35 | ], 36 | "ControlGroup": [ 37 | { 38 | "id": "1", 39 | "scenegroup": "1", 40 | "type": "info" 41 | }, 42 | { 43 | "id": "2", 44 | "scenegroup": "1", 45 | "type": "info" 46 | } 47 | ], 48 | "Control": [ 49 | { 50 | "ControlGroup":"1", 51 | "ControlPair": "1", 52 | "ControlHeader": "1", 53 | "top": "1", 54 | "left": "0", 55 | "x": "1.25", 56 | "ControlType": "label", 57 | "Label": { 58 | "lang_tag": "rain_rate", 59 | "text": "Rate of Rain" 60 | }, 61 | "Display": { 62 | "Top": 20, 63 | "Left": 50, 64 | "Width": 75, 65 | "Height": 20 66 | } 67 | }, 68 | { 69 | "ControlGroup":"1", 70 | "ControlPair": "1", 71 | "ControlHeader": "1", 72 | "top": "1", 73 | "left": "1.25", 74 | "x": "0.75", 75 | "ControlType": "variable", 76 | "Display": { 77 | "Service": "urn:upnp-org:serviceId:RainSensor1", 78 | "Variable": "CurrentRain", 79 | "Top": 20, 80 | "Left": 150, 81 | "Width": 25, 82 | "Height": 20 83 | } 84 | }, 85 | { 86 | "ControlType": "label", 87 | "Label": { 88 | "lang_tag": "total_rain_unit", 89 | "text": "mm/hr" 90 | }, 91 | "Display": { 92 | "Top": 20, 93 | "Left": 200, 94 | "Width": 25, 95 | "Height": 20 96 | } 97 | }, 98 | { 99 | "ControlGroup":"2", 100 | "ControlPair": "2", 101 | "ControlHeader": "1", 102 | "top": "0", 103 | "left": "0", 104 | "x": "1.25", 105 | "ControlType": "label", 106 | "Label": { 107 | "lang_tag": "total_rain", 108 | "text": "Rain Today:", 109 | }, 110 | "Display": { 111 | "Top": 55, 112 | "Left": 50, 113 | "Width": 75, 114 | "Height": 20 115 | } 116 | }, 117 | { 118 | "ControlGroup":"2", 119 | "ControlPair": "2", 120 | "ControlHeader": "1", 121 | "top": "0", 122 | "left": "1.25", 123 | "x": "0.75", 124 | "ControlType": "variable", 125 | "Display": { 126 | "Service": "urn:upnp-org:serviceId:RainSensor1", 127 | "Variable": "CurrentTRain", 128 | "Top": 55, 129 | "Left": 150, 130 | "Width": 25, 131 | "Height": 20 132 | } 133 | }, 134 | { 135 | "ControlType": "label", 136 | "Label": { 137 | "lang_tag": "rain_rate_unit", 138 | "text": "mm" 139 | }, 140 | "Display": { 141 | "Top": 55, 142 | "Left": 200, 143 | "Width": 25, 144 | "Height": 20 145 | } 146 | }, 147 | { 148 | "ControlGroup":"3", 149 | "ControlPair": "3", 150 | "ControlHeader": "1", 151 | "top": "0", 152 | "left": "0", 153 | "x": "1.25", 154 | "ControlType": "label", 155 | "Label": { 156 | "lang_tag": "rain_forty", 157 | "text": "Yesterday:" 158 | }, 159 | "Display": { 160 | "Top": 80, 161 | "Left": 50, 162 | "Width": 75, 163 | "Height": 20 164 | } 165 | }, 166 | { 167 | "ControlGroup":"3", 168 | "ControlPair": "3", 169 | "ControlHeader": "1", 170 | "top": "0", 171 | "left": "1.25", 172 | "x": "0.75", 173 | "ControlType": "variable", 174 | "Display": { 175 | "Service": "urn:upnp-org:serviceId:VContainer1", 176 | "Variable": "Variable2", 177 | "Top": 80, 178 | "Left": 150, 179 | "Width": 25, 180 | "Height": 20 181 | } 182 | }, 183 | { 184 | "ControlType": "label", 185 | "Label": { 186 | "lang_tag": "rain_unit", 187 | "text": "mm" 188 | }, 189 | "Display": { 190 | "Top": 80, 191 | "Left": 200, 192 | "Width": 25, 193 | "Height": 20 194 | } 195 | }, 196 | { 197 | "ControlGroup":"4", 198 | "ControlPair": "4", 199 | "ControlHeader": "1", 200 | "top": "0", 201 | "left": "0", 202 | "x": "1.25", 203 | "ControlType": "label", 204 | "Label": { 205 | "lang_tag": "rain_seventy", 206 | "text": "3 Days Ago:" 207 | }, 208 | "Display": { 209 | "Top": 105, 210 | "Left": 50, 211 | "Width": 75, 212 | "Height": 20 213 | } 214 | }, 215 | { 216 | "ControlGroup":"4", 217 | "ControlPair": "4", 218 | "ControlHeader": "1", 219 | "top": "0", 220 | "left": "1.25", 221 | "x": "0.75", 222 | "ControlType": "variable", 223 | "Display": { 224 | "Service": "urn:upnp-org:serviceId:VContainer1", 225 | "Variable": "Variable3", 226 | "Top": 105, 227 | "Left": 150, 228 | "Width": 25, 229 | "Height": 20 230 | } 231 | }, 232 | { 233 | "ControlType": "label", 234 | "Label": { 235 | "lang_tag": "rain_unit1", 236 | "text": "mm" 237 | }, 238 | "Display": { 239 | "Top": 105, 240 | "Left": 200, 241 | "Width": 25, 242 | "Height": 20 243 | } 244 | }, 245 | { 246 | "ControlGroup":"5", 247 | "ControlPair": "5", 248 | "ControlHeader": "1", 249 | "top": "0", 250 | "left": "0", 251 | "x": "1.25", 252 | "ControlType": "label", 253 | "Label": { 254 | "lang_tag": "rain_forty", 255 | "text": "4 Days Ago:" 256 | }, 257 | "Display": { 258 | "Top": 130, 259 | "Left": 50, 260 | "Width": 75, 261 | "Height": 20 262 | } 263 | }, 264 | { 265 | "ControlGroup":"5", 266 | "ControlPair": "5", 267 | "ControlHeader": "1", 268 | "top": "0", 269 | "left": "1.25", 270 | "x": "0.75", 271 | "ControlType": "variable", 272 | "Display": { 273 | "Service": "urn:upnp-org:serviceId:VContainer1", 274 | "Variable": "Variable4", 275 | "Top": 130, 276 | "Left": 150, 277 | "Width": 25, 278 | "Height": 20 279 | } 280 | }, 281 | { 282 | "ControlType": "label", 283 | "Label": { 284 | "lang_tag": "rain_unit2", 285 | "text": "mm" 286 | }, 287 | "Display": { 288 | "Top": 130, 289 | "Left": 200, 290 | "Width": 25, 291 | "Height": 20 292 | } 293 | }, 294 | { 295 | "ControlGroup":"6", 296 | "ControlPair": "6", 297 | "ControlHeader": "1", 298 | "top": "0", 299 | "left": "0", 300 | "x": "1.25", 301 | "ControlType": "label", 302 | "Label": { 303 | "lang_tag": "rain_hundred", 304 | "text": "5 Days Ago:" 305 | }, 306 | "Display": { 307 | "Top": 155, 308 | "Left": 50, 309 | "Width": 75, 310 | "Height": 20 311 | } 312 | }, 313 | { 314 | "ControlGroup":"6", 315 | "ControlPair": "6", 316 | "ControlHeader": "1", 317 | "top": "0", 318 | "left": "1.25", 319 | "x": "0.75", 320 | "ControlType": "variable", 321 | "Display": { 322 | "Service": "urn:upnp-org:serviceId:VContainer1", 323 | "Variable": "Variable5", 324 | "Top": 155, 325 | "Left": 150, 326 | "Width": 25, 327 | "Height": 20 328 | } 329 | }, 330 | { 331 | "ControlType": "label", 332 | "Label": { 333 | "lang_tag": "rain_unit3", 334 | "text": "mm" 335 | }, 336 | "Display": { 337 | "Top": 155, 338 | "Left": 200, 339 | "Width": 25, 340 | "Height": 20 341 | } 342 | } 343 | ] 344 | }, 345 | { 346 | "Label": { 347 | "lang_tag": "advanced", 348 | "text": "Advanced" 349 | }, 350 | "Position": "1", 351 | "TabType": "javascript", 352 | "ScriptName": "shared.js", 353 | "Function": "advanced_device" 354 | }, 355 | { 356 | "Label": { 357 | "lang_tag": "logs", 358 | "text": "Logs" 359 | }, 360 | "Position": "2", 361 | "TabType": "javascript", 362 | "ScriptName": "shared.js", 363 | "Function": "device_logs" 364 | }, 365 | { 366 | "Label": { 367 | "lang_tag": "notifications", 368 | "text": "Notifications" 369 | }, 370 | "Position": "3", 371 | "TabType": "javascript", 372 | "ScriptName": "shared.js", 373 | "Function": "device_notifications" 374 | } 375 | ], 376 | "eventList2": [ 377 | { 378 | "id": 1, 379 | "label": { 380 | "lang_tag": "total_rain_goes_above", 381 | "text": "Total rain goes above" 382 | }, 383 | "serviceId": "urn:upnp-org:serviceId:RainSensor1", 384 | "norepeat": "1", 385 | "argumentList": [ 386 | { 387 | "id": 1, 388 | "dataType": "r8", 389 | "name": "CurrentTRain", 390 | "comparisson": ">", 391 | "prefix": { 392 | "lang_tag": "total_rain", 393 | "text": "Total rain" 394 | }, 395 | "suffix": { 396 | "lang_tag": "total_rain_unit", 397 | "text": "mm" 398 | }, 399 | "HumanFriendlyText": { 400 | "lang_tag": "hft_total_rain_goes_above", 401 | "text": "Total rain for _DEVICE_NAME_ goes above _ARGUMENT_VALUE_" 402 | } 403 | } 404 | ] 405 | }, 406 | { 407 | "id": 2, 408 | "label": { 409 | "lang_tag": "total_rain_goes_below", 410 | "text": "Total rain goes below" 411 | }, 412 | "serviceId": "urn:upnp-org:serviceId:RainSensor1", 413 | "norepeat": "1", 414 | "argumentList": [ 415 | { 416 | "id": 1, 417 | "dataType": "r8", 418 | "name": "CurrentTRain", 419 | "comparisson": "<", 420 | "prefix": { 421 | "lang_tag": "total_rain", 422 | "text": "Total rain" 423 | }, 424 | "suffix": { 425 | "lang_tag": "total_rain_unit", 426 | "text": "mm" 427 | }, 428 | "HumanFriendlyText": { 429 | "lang_tag": "hft_total_rain_goes_below", 430 | "text": "Total rain for _DEVICE_NAME_ goes below _ARGUMENT_VALUE_" 431 | } 432 | } 433 | ] 434 | }, 435 | { 436 | "id": 3, 437 | "label": { 438 | "lang_tag": "rain_rate_goes_above", 439 | "text": "Current rain goes above" 440 | }, 441 | "serviceId": "urn:upnp-org:serviceId:RainSensor1", 442 | "norepeat": "1", 443 | "argumentList": [ 444 | { 445 | "id": 1, 446 | "dataType": "r8", 447 | "name": "CurrentRain", 448 | "comparisson": ">", 449 | "prefix": { 450 | "lang_tag": "rain_rate", 451 | "text": "Current rain" 452 | }, 453 | "suffix": { 454 | "lang_tag": "rain_rate_unit", 455 | "text": "mm/hr" 456 | }, 457 | "HumanFriendlyText": { 458 | "lang_tag": "hft_rain_rate_goes_above", 459 | "text": "Current rain for _DEVICE_NAME_ goes above _ARGUMENT_VALUE_" 460 | } 461 | } 462 | ] 463 | }, 464 | { 465 | "id": 4, 466 | "label": { 467 | "lang_tag": "rain_rate_goes_below", 468 | "text": "Current rain goes below" 469 | }, 470 | "serviceId": "urn:upnp-org:serviceId:RainSensor1", 471 | "norepeat": "1", 472 | "argumentList": [ 473 | { 474 | "id": 1, 475 | "dataType": "r8", 476 | "name": "CurrentRain", 477 | "comparisson": "<", 478 | "prefix": { 479 | "lang_tag": "rain_rate", 480 | "text": "Current rain" 481 | }, 482 | "suffix": { 483 | "lang_tag": "rain_rate_unit", 484 | "text": "mm/hr" 485 | }, 486 | "HumanFriendlyText": { 487 | "lang_tag": "hft_rain_rate_goes_below", 488 | "text": "Current rain for _DEVICE_NAME_ goes below _ARGUMENT_VALUE_" 489 | } 490 | } 491 | ] 492 | }, 493 | { 494 | "id": 5, 495 | "label": { 496 | "lang_tag": "battery_level_goes_below", 497 | "text": "Battery level goes below" 498 | }, 499 | "serviceId": "urn:micasaverde-com:serviceId:HaDevice1", 500 | "argumentList": [ 501 | { 502 | "id": 1, 503 | "prefix": { 504 | "lang_tag": "Level", 505 | "text": "Level" 506 | }, 507 | "dataType": "i4", 508 | "name": "BatteryLevel", 509 | "comparisson": "<", 510 | "suffix": { 511 | "lang_tag": "percent_sign", 512 | "text": "%" 513 | }, 514 | "HumanFriendlyText": { 515 | "lang_tag": "hft_battery_level_goes_below", 516 | "text": "Battery level for _DEVICE_NAME_ go below _ARGUMENT_VALUE_%" 517 | } 518 | } 519 | ] 520 | } 521 | ], 522 | "DeviceType": "urn:schemas-micasaverde-com:device:RainSensor:1" 523 | } -------------------------------------------------------------------------------- /raingauge/D_RainSensor1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | urn:schemas-micasaverde-com:device:RainSensor:1 9 | 12 10 | D_RainSensor1.json 11 | 12 | 13 | urn:schemas-upnp-org:service:RainSensor:1 14 | urn:upnp-org:serviceId:RainSensor1 15 | S_RainSensor1.xml 16 | 17 | 18 | urn:schemas-micasaverde-com:service:HaDevice:1 19 | urn:micasaverde-com:serviceId:HaDevice1 20 | S_HaDevice1.xml 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /raingauge/S_Rainsensor1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | 9 | CurrentTRain 10 | yes 11 | r8 12 | total_rain 13 | 14 | 15 | CurrentRain 16 | yes 17 | r8 18 | rain_rate 19 | 20 | 21 | 22 | 23 | GetCurrentTRain 24 | 25 | 26 | RainValue 27 | out 28 | CurrentTRain 29 | 30 | 31 | 32 | 33 | GetCurrentRain 34 | 35 | 36 | RainValue 37 | out 38 | CurrentRain 39 | 40 | 41 | 42 | 43 | -------------------------------------------------------------------------------- /scale/D_ScaleSensor1.json: -------------------------------------------------------------------------------- 1 | { 2 | "flashicon": "http://www.mysensors.org/icon/scale.png", 3 | "imgIconBody": "", 4 | "imgIconDimmable": "", 5 | "imgIconTurnable": "", 6 | "imgIconMin": "", 7 | "imgIconMax": "", 8 | "halloIconsDir": "pics/hallo", 9 | "inScene": "0", 10 | "DisplayStatus": {}, 11 | "doc_url": { 12 | "doc_language": 1, 13 | "doc_manual": 1, 14 | "doc_version": 1, 15 | "doc_platform": 0, 16 | "doc_page": "sensors" 17 | }, 18 | "Tabs": [ 19 | { 20 | "Label": { 21 | "lang_tag": "tabname_control", 22 | "text": "Information" 23 | }, 24 | "Position": "0", 25 | "TabType": "flash", 26 | "SceneGroup": [ 27 | { 28 | "id": "1", 29 | "top": "1.5", 30 | "left": "0", 31 | "x": "2", 32 | "y": "2" 33 | } 34 | ], 35 | "ControlGroup": [ 36 | { 37 | "id": "1", 38 | "scenegroup": "1", 39 | "type": "info" 40 | }, 41 | { 42 | "id": "2", 43 | "scenegroup": "1", 44 | "type": "info" 45 | } 46 | ], 47 | "Control": [ 48 | { 49 | "ControlGroup": "1", 50 | "ControlPair": "1", 51 | "ControlHeader": "1", 52 | "top": "0", 53 | "left": "0", 54 | "x": "1.25", 55 | "ControlType": "label", 56 | "Label": { 57 | "lang_tag": "weight", 58 | "text": "Weight" 59 | }, 60 | "Display": { 61 | "Top": 30, 62 | "Left": 50, 63 | "Width": 75, 64 | "Height": 20 65 | } 66 | }, 67 | { 68 | "ControlGroup": "1", 69 | "ControlPair": "1", 70 | "ControlHeader": "1", 71 | "top": "0", 72 | "left": "1.25", 73 | "x": "0.75", 74 | "ControlType": "variable", 75 | "Display": { 76 | "Service": "urn:micasaverde-com:serviceId:ScaleSensor1", 77 | "Variable": "Weight", 78 | "Top": 30, 79 | "Left": 150, 80 | "Width": 25, 81 | "Height": 20 82 | } 83 | }, 84 | { 85 | "ControlType": "label", 86 | "Label": { 87 | "lang_tag": "weight_unit", 88 | "text": "kg" 89 | }, 90 | "Display": { 91 | "Top": 30, 92 | "Left": 200, 93 | "Width": 25, 94 | "Height": 20 95 | } 96 | } 97 | ] 98 | }, 99 | { 100 | "Label": { 101 | "lang_tag": "advanced", 102 | "text": "Advanced" 103 | }, 104 | "Position": "1", 105 | "TabType": "javascript", 106 | "ScriptName": "shared.js", 107 | "Function": "advanced_device" 108 | }, 109 | { 110 | "Label": { 111 | "lang_tag": "logs", 112 | "text": "Logs" 113 | }, 114 | "Position": "2", 115 | "TabType": "javascript", 116 | "ScriptName": "shared.js", 117 | "Function": "device_logs" 118 | }, 119 | { 120 | "Label": { 121 | "lang_tag": "notifications", 122 | "text": "Notifications" 123 | }, 124 | "Position": "3", 125 | "TabType": "javascript", 126 | "ScriptName": "shared.js", 127 | "Function": "device_notifications" 128 | } 129 | ], 130 | "eventList2": [ 131 | { 132 | "id": 1, 133 | "label": { 134 | "lang_tag": "disatance_goes_above", 135 | "text": "Weight goes above" 136 | }, 137 | "serviceId": "urn:micasaverde-com:serviceId:ScaleSensor1", 138 | "norepeat": "1", 139 | "argumentList": [ 140 | { 141 | "id": 1, 142 | "dataType": "i2", 143 | "name": "Weight", 144 | "comparisson": ">", 145 | "prefix": { 146 | "lang_tag": "weight", 147 | "text": "Weight" 148 | }, 149 | "suffix": { 150 | "lang_tag": "weight_unit", 151 | "text": "kg" 152 | }, 153 | "HumanFriendlyText": { 154 | "lang_tag": "hft_weight_goes_above", 155 | "text": "Weight for _DEVICE_NAME_ goes above _ARGUMENT_VALUE_" 156 | } 157 | } 158 | ] 159 | }, 160 | { 161 | "id": 2, 162 | "label": { 163 | "lang_tag": "weight_goes_below", 164 | "text": "Weight goes below" 165 | }, 166 | "serviceId": "urn:micasaverde-com:serviceId:ScaleSensor1", 167 | "norepeat": "1", 168 | "argumentList": [ 169 | { 170 | "id": 1, 171 | "dataType": "i2", 172 | "name": "Weight", 173 | "comparisson": "<", 174 | "prefix": { 175 | "lang_tag": "weight", 176 | "text": "Weight" 177 | }, 178 | "suffix": { 179 | "lang_tag": "weight_unit", 180 | "text": "kg" 181 | }, 182 | "HumanFriendlyText": { 183 | "lang_tag": "hft_weight_goes_below", 184 | "text": "Weight for _DEVICE_NAME_ goes below _ARGUMENT_VALUE_" 185 | } 186 | } 187 | ] 188 | } 189 | ], 190 | "DeviceType": "urn:schemas-micasaverde-com:device:ScaleSensor:1" 191 | } -------------------------------------------------------------------------------- /scale/D_ScaleSensor1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | urn:schemas-micasaverde-com:device:ScaleSensor:1 9 | 12 10 | D_ScaleSensor1.json 11 | 12 | 13 | urn:schemas-upnp-org:service:ScaleSensor:1 14 | urn:upnp-org:serviceId:ScaleSensor1 15 | S_ScaleSensor1.xml 16 | 17 | 18 | urn:schemas-micasaverde-com:service:HaDevice:1 19 | urn:micasaverde-com:serviceId:HaDevice1 20 | S_HaDevice1.xml 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /scale/S_ScaleSensor.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | 9 | Weight 10 | yes 11 | i2 12 | weight 13 | 14 | 15 | 16 | 17 | GetWeight 18 | 19 | 20 | WeightValue 21 | out 22 | Weight 23 | 24 | 25 | -------------------------------------------------------------------------------- /watermeter/D_WaterMeter1.json: -------------------------------------------------------------------------------- 1 | { 2 | "flashicon": "http://www.mysensors.org/icon/Water.png", 3 | "imgIconBody": "", 4 | "imgIconDimmable": "", 5 | "imgIconTurnable": "", 6 | "imgIconMin": "", 7 | "imgIconMax": "", 8 | "halloIconsDir": "pics/hallo", 9 | "x": "2", 10 | "y": "3", 11 | "inScene": "0", 12 | "DisplayStatus": { 13 | "Service": "urn:micasaverde-com:serviceId:WaterMetering1", 14 | "Variable": "Flow", 15 | "MinValue": "0", 16 | "MaxValue": "100" 17 | }, 18 | "doc_url": { 19 | "doc_language": 1, 20 | "doc_manual": 1, 21 | "doc_version": 1, 22 | "doc_platform": 0, 23 | "doc_page": "devices" 24 | }, 25 | "Tabs": [ 26 | { 27 | "Label": { 28 | "lang_tag": "tabname_control", 29 | "text": "Control" 30 | }, 31 | "Position": "0", 32 | "TabType": "flash", 33 | "ControlGroup": [ 34 | { 35 | "id": "1", 36 | "scenegroup": "1" 37 | }, 38 | { 39 | "id": "2", 40 | "scenegroup": "2" 41 | } 42 | ], 43 | "SceneGroup": [ 44 | { 45 | "id": "1", 46 | "top": "1", 47 | "left": "0", 48 | "x": "2", 49 | "y": "1" 50 | }, 51 | { 52 | "id": "2", 53 | "top": "2", 54 | "left": "0", 55 | "x": "2", 56 | "y": "1", 57 | "isSingle": "1" 58 | } 59 | ], 60 | "Control": [ 61 | { 62 | "ControlGroup": "1", 63 | "ControlType": "label", 64 | "top": "0", 65 | "left": "0", 66 | "Label": { 67 | "lang_tag": "flow", 68 | "text": "Flow:" 69 | }, 70 | "Display": { 71 | "Top": 60, 72 | "Left": 20, 73 | "Width": 75, 74 | "Height": 20 75 | } 76 | }, 77 | { 78 | "ControlGroup": "1", 79 | "ControlType": "variable", 80 | "top": "0", 81 | "left": "0.4", 82 | "Display": { 83 | "Service": "urn:micasaverde-com:serviceId:WaterMetering1", 84 | "Variable": "Flow", 85 | "Top": 60, 86 | "Left": 80, 87 | "Width": 75, 88 | "Height": 20 89 | } 90 | }, 91 | { 92 | "ControlGroup":"1", 93 | "ControlPair": "1", 94 | "ControlHeader": "1", 95 | "ControlType": "label", 96 | "top": "0", 97 | "left": "0.8", 98 | "Label": { 99 | "lang_tag": "flow", 100 | "text": "x/min" 101 | }, 102 | "Display": { 103 | "Top": 60, 104 | "Left": 150, 105 | "Width": 75, 106 | "Height": 20 107 | } 108 | }, 109 | 110 | 111 | { 112 | "ControlGroup": "2", 113 | "ControlType": "label", 114 | "top": "1", 115 | "left": "0", 116 | "Label": { 117 | "lang_tag": "volume", 118 | "text": "Volume:" 119 | }, 120 | "Display": { 121 | "Top": 90, 122 | "Left": 20, 123 | "Width": 75, 124 | "Height": 20 125 | } 126 | }, 127 | { 128 | "ControlGroup": "2", 129 | "ControlType": "variable", 130 | "top": "1", 131 | "left": "0.7", 132 | "Display": { 133 | "Service": "urn:micasaverde-com:serviceId:WaterMetering1", 134 | "Variable": "Volume", 135 | "Top": 90, 136 | "Left": 80, 137 | "Width": 75, 138 | "Height": 20 139 | } 140 | }, 141 | { 142 | "ControlGroup":"2", 143 | "ControlPair": "1", 144 | "ControlHeader": "1", 145 | "ControlType": "label", 146 | "top": "1", 147 | "left": "1.2", 148 | "Label": { 149 | "lang_tag": "volume", 150 | "text": " m3" 151 | }, 152 | "Display": { 153 | "Top": 90, 154 | "Left": 150, 155 | "Width": 75, 156 | "Height": 20 157 | } 158 | } 159 | 160 | 161 | ] 162 | }, 163 | { 164 | "Label": { 165 | "lang_tag": "settings", 166 | "text": "Settings" 167 | }, 168 | "Position": "1", 169 | "TabType": "javascript", 170 | "ScriptName": "shared.js", 171 | "Function": "simple_device" 172 | }, 173 | { 174 | "Label": { 175 | "lang_tag": "advanced", 176 | "text": "Advanced" 177 | }, 178 | "Position": "2", 179 | "TabType": "javascript", 180 | "ScriptName": "shared.js", 181 | "Function": "advanced_device" 182 | }, 183 | { 184 | "Label": { 185 | "lang_tag": "device_options", 186 | "text": "Device Options" 187 | }, 188 | "Position": "3", 189 | "TabType": "javascript", 190 | "ScriptName": "shared.js", 191 | "Function": "device_zwave_options" 192 | }, 193 | { 194 | "Label": { 195 | "lang_tag": "logs", 196 | "text": "Logs" 197 | }, 198 | "Position": "4", 199 | "TabType": "javascript", 200 | "ScriptName": "shared.js", 201 | "Function": "device_logs" 202 | }, 203 | { 204 | "Label": { 205 | "lang_tag": "notifications", 206 | "text": "Notifications" 207 | }, 208 | "Position": "5", 209 | "TabType": "javascript", 210 | "ScriptName": "shared.js", 211 | "Function": "device_notifications" 212 | } 213 | ], 214 | "eventList2": [ 215 | { 216 | "id": 1, 217 | "label": { 218 | "lang_tag": "waterflow_usage_goes_above", 219 | "text": "Waterflow usage goes above" 220 | }, 221 | "serviceId": "urn:micasaverde-com:serviceId:WaterMetering1", 222 | "argumentList": [ 223 | { 224 | "id": 1, 225 | "dataType": "i4", 226 | "name": "l/min", 227 | "comparisson": ">", 228 | "prefix": "l/min: ", 229 | "suffix": "", 230 | "HumanFriendlyText": { 231 | "lang_tag": "hft_waterflow_usage_goes_above", 232 | "text": "Water usage for _DEVICE_NAME_ goes above _ARGUMENT_VALUE_ l/min" 233 | } 234 | } 235 | ] 236 | }, 237 | { 238 | "id": 2, 239 | "label": { 240 | "lang_tag": "waterflow_usage_goes_below", 241 | "text": "Waterflow usage goes below" 242 | }, 243 | "serviceId": "urn:micasaverde-com:serviceId:WaterMetering1", 244 | "argumentList": [ 245 | { 246 | "id": 1, 247 | "dataType": "i4", 248 | "name": "l/min", 249 | "comparisson": "<", 250 | "prefix": "l/min: ", 251 | "suffix": {}, 252 | "HumanFriendlyText": { 253 | "lang_tag": "hft_waterflow_usage_goes_below", 254 | "text": "Water usage for _DEVICE_NAME_ go below _ARGUMENT_VALUE_ l/min" 255 | } 256 | } 257 | ] 258 | }, 259 | { 260 | "id": 3, 261 | "label": { 262 | "lang_tag": "battery_level_goes_below", 263 | "text": "Battery level goes below" 264 | }, 265 | "serviceId": "urn:micasaverde-com:serviceId:HaDevice1", 266 | "argumentList": [ 267 | { 268 | "id": 1, 269 | "prefix": { 270 | "lang_tag":"Level", 271 | "text":"Level" 272 | }, 273 | "dataType": "i4", 274 | "name": "BatteryLevel", 275 | "comparisson": "<", 276 | "suffix": { 277 | "lang_tag":"percent_sign", 278 | "text":"%" 279 | }, 280 | "HumanFriendlyText": { 281 | "lang_tag": "hft_battery_level_goes_below", 282 | "text": "Battery level for _DEVICE_NAME_ goes below _ARGUMENT_VALUE_%" 283 | } 284 | } 285 | ] 286 | } 287 | ], 288 | "DeviceType": "urn:schemas-micasaverde-com:device:WaterMeter:1" 289 | } -------------------------------------------------------------------------------- /watermeter/D_WaterMeter1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | urn:schemas-micasaverde-com:device:WaterMeter:1 9 | D_WaterMeter1.json 10 | 11 | 12 | urn:schemas-micasaverde-com:service:WaterMetering:1 13 | urn:micasaverde-com:serviceId:WaterMetering1 14 | S_WaterMeter1.xml 15 | 16 | 17 | urn:schemas-micasaverde-com:service:HaDevice:1 18 | urn:micasaverde-com:serviceId:HaDevice1 19 | S_HaDevice1.xml 20 | 21 | 22 | 23 | -------------------------------------------------------------------------------- /watermeter/S_WaterMeter1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1 5 | 0 6 | 7 | 8 | 9 | Flow 10 | ui4 11 | flow 12 | 13 | 14 | ActualUsage 15 | boolean 16 | 17 | 18 | WholeHouse 19 | boolean 20 | wholehouse 21 | 22 | 23 | Pulse 24 | ui4 25 | pulse 26 | 27 | 28 | UserSuppliedFlow 29 | ui4 30 | 31 | 32 | Volume 33 | ui4 34 | volume 35 | 36 | 37 | 38 | 39 | ResetVolume 40 | 41 | 42 | 43 | --------------------------------------------------------------------------------