Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- [
- {
- "id": "c4b6978530b3d880",
- "type": "mqtt in",
- "z": "de3d4dee.ee9e8",
- "name": "",
- "topic": "/home/Koss/Gas/Oben/#",
- "qos": "2",
- "datatype": "auto-detect",
- "broker": "595dfa51.2c1224",
- "nl": false,
- "rap": true,
- "rh": 0,
- "inputs": 0,
- "x": 170,
- "y": 680,
- "wires": [
- [
- "2a51711fd1f24589"
- ]
- ]
- },
- {
- "id": "5be7bc08a5469cec",
- "type": "moment",
- "z": "de3d4dee.ee9e8",
- "name": "",
- "topic": "",
- "input": "payload",
- "inputType": "msg",
- "inTz": "ETC/GMT",
- "adjAmount": "0",
- "adjType": "hours",
- "adjDir": "subtract",
- "format": "dd DD. MMMM YYYY HH:mm:ss ",
- "locale": "de_DE",
- "output": "",
- "outputType": "msg",
- "outTz": "Europe/Berlin",
- "x": 1020,
- "y": 680,
- "wires": [
- [
- "e989f482dec35eab"
- ]
- ]
- },
- {
- "id": "e989f482dec35eab",
- "type": "debug",
- "z": "de3d4dee.ee9e8",
- "name": "",
- "active": false,
- "tosidebar": true,
- "console": false,
- "tostatus": true,
- "complete": "payload",
- "targetType": "msg",
- "statusVal": "payload",
- "statusType": "auto",
- "x": 1030,
- "y": 720,
- "wires": []
- },
- {
- "id": "7d6606e8f9143736",
- "type": "function",
- "z": "de3d4dee.ee9e8",
- "name": "function 3",
- "func": "var words = msg.topic.split('/');\nvar KnotenName = (words[3]);\n\nvar Count = msg.payload[0];\nvar Total = msg.payload[1];\nvar Time = msg.payload[2];\n\nvar Influx = [{\n Room: KnotenName,\n Count: Count,\n Total: Total,\n Time: Time\n}]\n\nvar Influx1 = { payload: Influx };\n\nInflux1.topic = \"/home/Koss/\" + KnotenName + \"/\";\n\n\n\nnode.status({ fill: \"blue\",\n shape: \"ring\", \n text: KnotenName +\n \" - Count: \" + Count +\n \", Total: \" + Total +\n \", Time: \" + Time + \"msec\"\n });\n\nvar time = Date.now();\nvar Time2 = { payload: time };\n\nreturn [Influx1, Time2];\n",
- "outputs": 2,
- "noerr": 0,
- "initialize": "",
- "finalize": "",
- "libs": [],
- "x": 740,
- "y": 680,
- "wires": [
- [
- "423ad0582809ba26",
- "3a583c7fc083e9c8"
- ],
- [
- "5be7bc08a5469cec"
- ]
- ],
- "inputLabels": [
- "merged Input"
- ],
- "outputLabels": [
- "Influx",
- "Msg last sent"
- ]
- },
- {
- "id": "d783bf4e0949e529",
- "type": "join",
- "z": "de3d4dee.ee9e8",
- "name": "",
- "mode": "custom",
- "build": "array",
- "property": "payload",
- "propertyType": "msg",
- "key": "topic",
- "joiner": "\\n",
- "joinerType": "str",
- "accumulate": false,
- "timeout": "1",
- "count": "",
- "reduceRight": false,
- "reduceExp": "",
- "reduceInit": "",
- "reduceInitType": "num",
- "reduceFixup": "",
- "x": 550,
- "y": 680,
- "wires": [
- [
- "7d6606e8f9143736"
- ]
- ]
- },
- {
- "id": "2a51711fd1f24589",
- "type": "switch",
- "z": "de3d4dee.ee9e8",
- "name": "Total",
- "property": "topic",
- "propertyType": "msg",
- "rules": [
- {
- "t": "eq",
- "v": "/home/Koss/Gas/Oben/Count",
- "vt": "str"
- },
- {
- "t": "eq",
- "v": "/home/Koss/Gas/Oben/Total",
- "vt": "str"
- },
- {
- "t": "eq",
- "v": "/home/Koss/Gas/Oben/Time",
- "vt": "str"
- }
- ],
- "checkall": "true",
- "repair": false,
- "outputs": 3,
- "x": 390,
- "y": 680,
- "wires": [
- [
- "d783bf4e0949e529"
- ],
- [
- "d783bf4e0949e529"
- ],
- [
- "d783bf4e0949e529"
- ]
- ]
- },
- {
- "id": "3a583c7fc083e9c8",
- "type": "debug",
- "z": "de3d4dee.ee9e8",
- "name": "debug 6",
- "active": true,
- "tosidebar": true,
- "console": false,
- "tostatus": false,
- "complete": "false",
- "statusVal": "",
- "statusType": "auto",
- "x": 1060,
- "y": 640,
- "wires": []
- },
- {
- "id": "595dfa51.2c1224",
- "type": "mqtt-broker",
- "name": "Miti16",
- "broker": "192.168.123.16",
- "port": "1883",
- "clientid": "",
- "autoConnect": true,
- "usetls": false,
- "protocolVersion": "4",
- "keepalive": "60",
- "cleansession": true,
- "birthTopic": "",
- "birthQos": "0",
- "birthPayload": "",
- "birthMsg": {},
- "closeTopic": "",
- "closePayload": "",
- "closeMsg": {},
- "willTopic": "",
- "willQos": "0",
- "willPayload": "",
- "willMsg": {},
- "sessionExpiry": ""
- }
- ]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement