Node-RED Flows

Core Elemente

Abhängigkeit / dependence: https://flows.nodered.org/node/node-red-contrib-pixelit

Das Core-Element ist nun über Node-Red installierbar :)  

[{"id":"25c6592e.4dd736","type":"change","z":"e3aa70fa.b265f","name":"Display Playlist","rules":[{"t":"set","p":"payload","pt":"msg","to":"[     {         \"screenName\": \"octoprint_1\"     },     {         \"screenName\": \"octoprint_2\"     },     {         \"screenName\": \"instagram\"     },     {         \"screenName\": \"internal_clock\"     },     {         \"screenName\": \"internet_traffic\"     },     {         \"screenName\": \"matomo_bastelbunker_de\"     },     {         \"screenName\": \"weather_stuhr\"     } ]","tot":"json"}],"action":"","property":"","from":"","to":"","reg":false,"x":260,"y":1540,"wires":[["42c12d75.303a94"]]},{"id":"6f232a2.8c935d4","type":"inject","z":"e3aa70fa.b265f","name":"Instant","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":true,"onceDelay":"1","x":100,"y":1540,"wires":[["25c6592e.4dd736"]]},{"id":"a243ca38.db19b8","type":"comment","z":"e3aa70fa.b265f","name":"Display Playlist","info":"","x":100,"y":1500,"wires":[]},{"id":"df7f7c66.5d7ce","type":"link in","z":"e3aa70fa.b265f","name":"Screen Data Update Link","links":["4907b83e.c0c618","527249d1.144878","82589adf.3289c8","c28af3f9.bdac9","e821d0c9.7728a","ef68cb39.109dc8","f1b06b62.d293a8"],"x":35,"y":1380,"wires":[["69331df2.de7164"]]},{"id":"9590c2af.b689","type":"link in","z":"e3aa70fa.b265f","name":"Alert Screen Link","links":["b268b4d3.04f758","69f70866.14f788"],"x":35,"y":1340,"wires":[["2cf533f5.1dc38c"]]},{"id":"de85246c.e30708","type":"link in","z":"e3aa70fa.b265f","name":"Matrix Control Link","links":["253162af.59107e","869b90c9.21c74","5fcd9f44.f79b1"],"x":35,"y":1420,"wires":[["1d259eb2.a9fef1"]]},{"id":"c9444c41.ad148","type":"link in","z":"e3aa70fa.b265f","name":"Playlist Update Link","links":["42c12d75.303a94"],"x":35,"y":1460,"wires":[["cdd7d973.b4e898"]]},{"id":"42c12d75.303a94","type":"link out","z":"e3aa70fa.b265f","name":"Display Playlist Link","links":["c9444c41.ad148"],"x":375,"y":1540,"wires":[]},{"id":"2cf533f5.1dc38c","type":"Alert Screen","z":"e3aa70fa.b265f","name":"Alert Screen","x":230,"y":1340,"wires":[["be6884dd.76ee18"]]},{"id":"69331df2.de7164","type":"Screen Data Update","z":"e3aa70fa.b265f","name":"Screen Data Update","x":260,"y":1380,"wires":[["be6884dd.76ee18"]]},{"id":"1d259eb2.a9fef1","type":"Matrix Control","z":"e3aa70fa.b265f","name":"Matrix Control","x":240,"y":1420,"wires":[["be6884dd.76ee18"]]},{"id":"cdd7d973.b4e898","type":"Playlist Update","z":"e3aa70fa.b265f","name":"Playlist Update","x":240,"y":1460,"wires":[["be6884dd.76ee18"]]},{"id":"be6884dd.76ee18","type":"Core","z":"e3aa70fa.b265f","name":"Core","ip":"","x":490,"y":1380,"wires":[]},{"id":"2fca6e29.8dba62","type":"inject","z":"e3aa70fa.b265f","name":"Set","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"onceDelay":"0","x":90,"y":1300,"wires":[["445017b6.1130c8"]]},{"id":"445017b6.1130c8","type":"Matrix Config","z":"e3aa70fa.b265f","name":"Matrix Config","matrixtBrightness":"85","matrixType":"2","clockTimeZone":"22","scrollTextDefaultDelay":110,"mqttAktiv":"false","mqttServer":"192.168.0.251","mqttPort":1883,"mqttUser":"","mqttPassword":"","mqttMasterTopic":"Haus/PixelIt","x":230,"y":1300,"wires":[["be6884dd.76ee18"]]}]

Internal Pixel It Clock

[{"id":"66f43fb9.968e8","type":"comment","z":"e3aa70fa.b265f","name":"Internal Pixel It Clock [internal_clock]","info":"","x":160,"y":420,"wires":[]},{"id":"c550cef1.a7857","type":"inject","z":"e3aa70fa.b265f","name":"Init","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":true,"onceDelay":"0.1","x":90,"y":460,"wires":[["a5c29622.c02d38"]]},{"id":"c28af3f9.bdac9","type":"link out","z":"e3aa70fa.b265f","name":"Internal Pixel It Clock [internal_clock] Link","links":["567381de.f98d2","df7f7c66.5d7ce"],"x":655,"y":460,"wires":[]},{"id":"a5c29622.c02d38","type":"Screen Init","z":"e3aa70fa.b265f","name":"Screen Init","inscreenName":"internal_clock","induration":"10","x":230,"y":460,"wires":[["9eaa8c7f.8c677"]]},{"id":"9eaa8c7f.8c677","type":"Switch Animation","z":"e3aa70fa.b265f","name":"Switch Animation","aktiv":"true","animation":"fade","x":410,"y":460,"wires":[["ea47d02.2215a3"]]},{"id":"ea47d02.2215a3","type":"Clock","z":"e3aa70fa.b265f","name":"Clock","inswitchAktiv":"true","inswitchSec":"6","inwithSeconds":"false","incolorR":"0","incolorG":"255","incolorB":"0","x":570,"y":460,"wires":[["c28af3f9.bdac9"]]}]

Alert

[{"id":"72bbaf0b.9a812","type":"comment","z":"e3aa70fa.b265f","name":"Alert Message","info":"","x":90,"y":20,"wires":[]},{"id":"eab3e4e6.a0a6f8","type":"inject","z":"e3aa70fa.b265f","name":"Push","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"onceDelay":"0","x":90,"y":60,"wires":[["56175a9c.6b8ca4"]]},{"id":"b268b4d3.04f758","type":"link out","z":"e3aa70fa.b265f","name":"Alert Message Link","links":["bcef5682.360dc8","9590c2af.b689"],"x":655,"y":60,"wires":[]},{"id":"a4bdba65.355308","type":"Switch Animation","z":"e3aa70fa.b265f","name":"Switch Animation","aktiv":"false","animation":"coloredBarWipe","x":410,"y":60,"wires":[["8dc76d08.a7d73"]]},{"id":"8dc76d08.a7d73","type":"Text","z":"e3aa70fa.b265f","name":"Text","intextString":"Pixel!!!","inbigFont":"false","inscrollText":"false","inscrollTextDelay":"0","incenterText":"true","inposX":"7","inposY":"1","incolorR":"255","incolorG":"255","incolorB":"255","x":570,"y":60,"wires":[["b268b4d3.04f758"]]},{"id":"56175a9c.6b8ca4","type":"Screen Init","z":"e3aa70fa.b265f","name":"Screen Init","inscreenName":"","induration":"10","x":230,"y":60,"wires":[["a4bdba65.355308"]]}]

Brightness Automatic

Abhängigkeit / dependence: https://flows.nodered.org/node/node-red-contrib-isonline

[{"id":"39a3f9cb.dd93b6","type":"http request","z":"e3aa70fa.b265f","name":"Get Lux","method":"GET","ret":"txt","url":"http://<PIXEL IT IP>/api/luxsensor","tls":"","x":480,"y":1000,"wires":[["593a5da4.04f414"]]},{"id":"593a5da4.04f414","type":"json","z":"e3aa70fa.b265f","name":"Pars JSON","property":"payload","action":"","pretty":false,"x":630,"y":1000,"wires":[["b5975ee6.d3795"]]},{"id":"a5e2aaf8.5aa2a8","type":"inject","z":"e3aa70fa.b265f","name":"Every 3s","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":true,"onceDelay":"0","x":100,"y":1000,"wires":[["3907d87b.1932d8"]]},{"id":"3907d87b.1932d8","type":"is online","z":"e3aa70fa.b265f","name":"check PIXEL IT is online","url":"PIXEL IT IP","action":"1","x":290,"y":1000,"wires":[["39a3f9cb.dd93b6"]]},{"id":"b5975ee6.d3795","type":"function","z":"e3aa70fa.b265f","name":"Brightness Logic","func":"var lux = msg.payload.lux;\nvar brightness = 255;\nvar currentBrightness = context.get(\"currentBrightness\")||-1;\n\nif (lux <= 1)\n{\n    brightness = 20;\n}\nelse if (lux <= 5)\n{\n    brightness = 30;\n}\nelse if (lux <= 10)\n{\n    brightness = 45;\n}\nelse if (lux <= 20)\n{\n    brightness = 60;\n}\nelse if (lux <= 100)\n{\n    brightness = 80;\n}\nelse if (lux <= 250)\n{\n    brightness = 100;\n}\n\nmsg.provider = \"Brightness Logic\";\nmsg.brightness = brightness;\nnode.status({ fill: \"yellow\", shape: \"ring\", text: \"Lux: \" + lux.toFixed(3) +\" | Bri: \" + brightness });\n\nif (currentBrightness != brightness)\n{\n    node.status({ fill: \"green\", shape: \"ring\", text: \"Lux: \" + lux.toFixed(3) +\" | Bri: \" + brightness +\" send!\" });\n    context.set(\"currentBrightness\", brightness);\n    return msg;\n}","outputs":1,"noerr":0,"x":810,"y":1000,"wires":[["253162af.59107e"]]},{"id":"e1c478d2.8d5b28","type":"comment","z":"e3aa70fa.b265f","name":"Brightness Automatic","info":"","x":120,"y":960,"wires":[]},{"id":"253162af.59107e","type":"link out","z":"e3aa70fa.b265f","name":"Brightness Automatic Link","links":["de85246c.e30708"],"x":975,"y":1000,"wires":[]}]

OctoPrint

Abhängigkeit / dependence: https://flows.nodered.org/node/node-red-contrib-isonline

[{"id":"d68d865e.d13b98","type":"comment","z":"e3aa70fa.b265f","name":"OctoPrint [octoprint_1 / octoprint_2]","info":"","x":160,"y":320,"wires":[]},{"id":"2069760.de9c08a","type":"http request","z":"e3aa70fa.b265f","name":"Get Job State","method":"GET","ret":"txt","url":"http://192.168.0.250/api/job?apikey=<KEY>","tls":"","x":720,"y":340,"wires":[["bc1be689.c1cab8"]]},{"id":"bc1be689.c1cab8","type":"json","z":"e3aa70fa.b265f","name":"Pars JSON","property":"payload","action":"","pretty":false,"x":890,"y":340,"wires":[["e3fed49c.060ca8"]]},{"id":"e3fed49c.060ca8","type":"function","z":"e3aa70fa.b265f","name":"Split Payload","func":"var printTimeLeft = msg.payload.progress.printTimeLeft;\nvar completion = msg.payload.progress.completion;\nvar state = msg.payload.state;\nvar displayOne = { payload:\"\",bars:\"\"};\nvar displayTwo = { payload:\"\", text:{bigFont:true}, progessBar:\"\"};\nvar date = new Date(null);\ndate.setSeconds(printTimeLeft); // specify value for SECONDS here\nvar result = date.toISOString().substr(11, 5);\nvar progessBar = (9+(completion / 4)).toFixed(0);\n   \n//displayOne.bars = '[{\"position\": {\"x\": 7,\"y\": 7,\"x2\": 31,\"y2\": 7},\"color\": {\"r\": 35,\"g\": 196,\"b\": 43}}, {\"position\": {\"x\": 8,\"y\": 6,\"x2\": '+ pixelProgressbar +',\"y2\": 6},\"color\": {\"r\": 35,\"g\": 196,\"b\": 43}}]'\n//displayTwo.bars = '[{\"position\": {\"x\": 7,\"y\": 7,\"x2\": 31,\"y2\": 7},\"color\": {\"r\": 35,\"g\": 196,\"b\": 43}}, {\"position\": {\"x\": 8,\"y\": 6,\"x2\": '+ pixelProgressbar +',\"y2\": 6},\"color\": {\"r\": 35,\"g\": 196,\"b\": 43}}]'  \ndisplayOne.progessBar= progessBar;\ndisplayTwo.progessBar= progessBar;\nif (completion > 99.9)\n{\n    displayTwo.payload = \"Finish\";\n    displayTwo.text.bigFont = false;\n}\nelse\n{\n    displayTwo.payload = (completion ? completion.toFixed(0):0) + '%';\n}\n\ndisplayOne.payload = result;\n\nreturn [displayOne,displayTwo];\n","outputs":2,"noerr":0,"x":1050,"y":340,"wires":[["7785aeb7.9e3dd"],["c6888f65.bcebe"]]},{"id":"1105c042.2ef01","type":"is online","z":"e3aa70fa.b265f","name":"","url":"192.168.0.250","action":"0","x":260,"y":360,"wires":[["e824a69c.f6b118"]]},{"id":"e824a69c.f6b118","type":"change","z":"e3aa70fa.b265f","name":"Show Screen","rules":[{"t":"set","p":"show","pt":"msg","to":"payload","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":420,"y":360,"wires":[["12a7d2dc.0db1dd"]]},{"id":"733d889c.ed4da8","type":"inject","z":"e3aa70fa.b265f","name":"Every 15s","topic":"","payload":"","payloadType":"date","repeat":"15","crontab":"","once":true,"onceDelay":"0.1","x":110,"y":360,"wires":[["1105c042.2ef01"]]},{"id":"12a7d2dc.0db1dd","type":"function","z":"e3aa70fa.b265f","name":"Aktiv?","func":"if (msg.payload)\n{\n    return [msg,null];\n}\nelse\n{\n    return [null,msg];\n}","outputs":2,"noerr":0,"x":570,"y":360,"wires":[["2069760.de9c08a"],["c6888f65.bcebe","7785aeb7.9e3dd"]]},{"id":"527249d1.144878","type":"link out","z":"e3aa70fa.b265f","name":"OctoPrint [octoprint_1 / octoprint_2] Link","links":["567381de.f98d2","df7f7c66.5d7ce"],"x":1775,"y":360,"wires":[]},{"id":"7785aeb7.9e3dd","type":"Screen Init","z":"e3aa70fa.b265f","name":"Screen Init","inscreenName":"octoprint_1","induration":"5","x":1210,"y":340,"wires":[["a9a564d5.364cf8"]]},{"id":"c6888f65.bcebe","type":"Screen Init","z":"e3aa70fa.b265f","name":"Screen Init","inscreenName":"octoprint_2","induration":"5","x":1210,"y":380,"wires":[["b027351f.069038"]]},{"id":"a9a564d5.364cf8","type":"Switch Animation","z":"e3aa70fa.b265f","name":"Switch Animation","aktiv":"true","animation":"fade","x":1390,"y":340,"wires":[["41f9ab6b.0ab0f4"]]},{"id":"b027351f.069038","type":"Switch Animation","z":"e3aa70fa.b265f","name":"Switch Animation","aktiv":"false","animation":"fade","x":1390,"y":380,"wires":[["41f9ab6b.0ab0f4"]]},{"id":"41f9ab6b.0ab0f4","type":"Text","z":"e3aa70fa.b265f","name":"Text","intextString":"{{payload}}","inbigFont":"false","inscrollText":"false","inscrollTextDelay":"0","incenterText":"true","inposX":"7","inposY":"1","incolorR":"255","incolorG":"255","incolorB":"255","x":1550,"y":360,"wires":[["14ab7a16.b08b06"]]},{"id":"14ab7a16.b08b06","type":"Bitmap","z":"e3aa70fa.b265f","name":"Bitmap","indata":"[0,0,34192,34192,34192,34192,0,0,0,34192,65535,34192,34192,65535,34192,0,0,0,34192,34192,34192,34192,0,0,34192,34192,0,34192,34192,0,34192,34192,0,0,34192,53241,53241,34192,0,0,34192,34192,34192,53241,53241,34192,34192,34192,0,0,34192,34192,34192,34192,0,0,34192,34192,0,0,0,0,34192,34192]","inposX":"0","inposY":"0","inwidth":"8","inheight":"8","x":1680,"y":360,"wires":[["527249d1.144878"]]}]

OpenWeatherMap

Abhängigkeit / dependence: https://flows.nodered.org/node/node-red-node-openweathermap

[{"id":"31d761a1.1a1bbe","type":"comment","z":"e3aa70fa.b265f","name":"Weather Stuhr [weather_stuhr]","info":"","x":140,"y":520,"wires":[]},{"id":"c1f457a9.e8c918","type":"function","z":"e3aa70fa.b265f","name":"Bitmap + Text","func":"var icon = msg.payload.icon;\n//\tclear sky\nif (icon == \"01d\")\n{\n    msg.bmp = \"[0,0,65504,0,0,65504,0,0,0,0,0,0,0,0,0,0,65504,0,65504,65504,65504,65504,0,65504,0,0,65504,65504,65504,65504,0,0,0,0,65504,65504,65504,65504,0,0,65504,0,65504,65504,65504,65504,0,65504,0,0,0,0,0,0,0,0,0,0,65504,0,0,65504,0,0]\"\n}\nif (icon == \"01n\")\n{\n    msg.bmp = \"[0,0,25388,25388,25388,25388,0,0,0,25388,46486,46486,40147,33808,25388,0,25388,46486,40147,59196,46486,59196,46486,25388,25388,59196,46486,46486,46486,46486,46486,25388,25388,40147,40147,46486,40147,46486,40147,25388,25388,46486,59196,46486,46486,63390,46486,25388,0,25388,46486,40147,46486,40147,25388,0,0,0,25388,25388,25388,25388,0,0]\"\n}\n// few clouds\nelse if (icon == \"02d\" || icon == \"02n\")\n{\n    msg.bmp = \"[0,0,0,0,0,0,0,0,0,65513,0,0,0,0,65513,0,0,0,65513,65513,65513,46486,46486,0,0,65513,65513,46486,46486,65535,65535,46486,0,65513,46486,65535,65535,65535,65535,46486,0,46486,65535,65535,65535,65535,65535,46486,0,46486,46486,46486,46486,46486,46486,0,0,0,0,0,0,0,0,0]\"\n}\n// scattered clouds\nelse if (icon == \"03d\" || icon == \"03n\")\n{\n    msg.bmp = \"[0,0,0,0,0,0,0,0,0,0,0,0,0,46486,46486,0,0,0,0,46486,46486,65535,65535,46486,0,0,46486,65535,65535,65535,65535,46486,0,0,46486,65535,65535,65535,65535,46486,0,46486,46486,46486,46486,46486,46486,46486,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]\"\n}\n// broken clouds\nelse if (icon == \"04d\" || icon == \"04n\")\n{\n    msg.bmp = \"[0,0,0,0,0,0,0,0,0,0,0,0,0,46486,46486,0,0,0,0,46486,46486,59196,59196,46486,0,0,46486,59196,59196,59196,59196,46486,0,0,46486,59196,59196,59196,59196,46486,0,46486,46486,46486,46486,46486,46486,46486,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]\"\n}\n// shower rain\nelse if (icon == \"09d\" || icon == \"09n\" || icon == \"10n\")\n{\n    msg.bmp = \"[0,0,0,0,0,0,0,0,0,0,0,0,0,46486,46486,0,0,0,0,46486,46486,59196,59196,46486,0,0,46486,59196,59196,59196,59196,46486,0,0,46486,59196,59196,59196,59196,46486,0,46486,46486,46486,46486,46486,46486,46486,0,6547,0,6547,0,6547,0,6547,6547,0,6547,0,6547,0,6547,0]\"\n}\n// rain\nelse if (icon == \"10d\")\n{\n    msg.bmp = \"[0,65513,0,0,0,0,65513,0,0,65513,65513,65513,65513,46486,46486,0,0,0,65513,46486,46486,65535,65535,46486,0,65513,46486,65535,65535,65535,65535,46486,0,65513,46486,65535,65535,65535,65535,46486,0,46486,46486,46486,46486,46486,46486,46486,0,6547,0,6547,0,6547,0,6547,6547,0,6547,0,6547,0,6547,0]\"\n}\nelse if (icon == \"11d\" || icon == \"11n\")\n{\n    msg.bmp = \"[0,0,0,0,0,0,0,0,0,0,0,0,0,46486,46486,0,0,0,0,46486,46486,65535,65535,46486,0,0,46486,65535,65535,65516,65535,46486,0,0,46486,65535,65516,65535,65535,46486,0,46486,46486,46486,46486,65516,46486,46486,0,0,0,0,65516,0,0,0,0,0,0,65516,0,0,0,0]\"\n}\nelse if (icon == \"13d\" || icon == \"13n\")\n{\n    msg.bmp = \"[0,0,0,0,0,0,0,0,0,0,0,0,0,46486,46486,0,0,0,0,46486,46486,65535,65535,46486,0,0,46486,65535,65535,65535,65535,46486,0,0,46486,65535,65535,65535,65535,46486,0,46486,46486,46486,46486,46486,46486,46486,0,65535,0,65535,0,65535,0,65535,65535,0,65535,0,65535,0,65535,0]\"\n}\nelse if (icon == \"50d\" || icon == \"50n\")\n{\n    msg.bmp = \"[0,0,0,0,0,0,0,0,0,0,46486,46486,0,0,0,0,46486,46486,0,0,46486,0,0,46486,0,0,0,0,0,46486,46486,0,0,0,0,0,0,0,0,0,0,0,46486,46486,0,0,0,0,46486,46486,0,0,46486,0,0,46486,0,0,0,0,0,46486,46486,0]\"\n}\nmsg.humidity = 7 + (msg.payload.humidity / 4).toFixed(0);\nmsg.temp = msg.payload.tempc.toFixed(1) + \"~\"\n\nreturn msg;\n\n","outputs":1,"noerr":0,"x":360,"y":560,"wires":[["e6cb9f94.46a3d"]]},{"id":"82589adf.3289c8","type":"link out","z":"e3aa70fa.b265f","name":"Weather Stuhr [weather_stuhr] Link","links":["567381de.f98d2","df7f7c66.5d7ce"],"x":1095,"y":560,"wires":[]},{"id":"33819d10.b02a52","type":"openweathermap in","z":"e3aa70fa.b265f","name":"Get Push Weather Stuhr","wtype":"current","lon":"8.776990","lat":"53.016392","city":"","country":"","language":"de","x":130,"y":560,"wires":[["c1f457a9.e8c918"]]},{"id":"e6cb9f94.46a3d","type":"Screen Init","z":"e3aa70fa.b265f","name":"Screen Init","inscreenName":"weather_stuhr","induration":"10","x":530,"y":560,"wires":[["7264b719.f32748"]]},{"id":"7264b719.f32748","type":"Switch Animation","z":"e3aa70fa.b265f","name":"Switch Animation","aktiv":"true","animation":"fade","x":710,"y":560,"wires":[["719e28f3.b4c5f8"]]},{"id":"cbe43e33.dc5db","type":"Bitmap","z":"e3aa70fa.b265f","name":"Bitmap","indata":"{{bmp}}","inposX":"0","inposY":"0","inwidth":"8","inheight":"8","x":1000,"y":560,"wires":[["82589adf.3289c8"]]},{"id":"719e28f3.b4c5f8","type":"Text","z":"e3aa70fa.b265f","name":"Text","intextString":"{{temp}}","inbigFont":"false","inscrollText":"false","inscrollTextDelay":"0","incenterText":"true","inposX":"7","inposY":"1","incolorR":"255","incolorG":"255","incolorB":"255","x":870,"y":560,"wires":[["cbe43e33.dc5db"]]}]

Matomo (Piwik)

[{"id":"621884cd.12da9c","type":"comment","z":"e3aa70fa.b265f","name":"Bastelbunker Matomo [matomo_bastelbunker_de]","info":"","x":200,"y":720,"wires":[]},{"id":"1fc2cbf3.9a5934","type":"http request","z":"e3aa70fa.b265f","name":"Live.getCounters","method":"GET","ret":"txt","url":"https://matomo.dietru.de/index.php?module=API&method=Live.getCounters&idSite=1&lastMinutes=3&format=JSON&token_auth=<KEY>","tls":"","x":290,"y":760,"wires":[["c7d06304.3b03e"]]},{"id":"c7d06304.3b03e","type":"json","z":"e3aa70fa.b265f","name":"Pars JSON","property":"payload","action":"","pretty":false,"x":470,"y":760,"wires":[["ba4db195.994b8"]]},{"id":"ce196f55.83188","type":"inject","z":"e3aa70fa.b265f","name":"Every 15s","topic":"","payload":"","payloadType":"date","repeat":"15","crontab":"","once":true,"onceDelay":"0.1","x":110,"y":760,"wires":[["1fc2cbf3.9a5934"]]},{"id":"ef68cb39.109dc8","type":"link out","z":"e3aa70fa.b265f","name":"Bastelbunker Matomo [matomo_bastelbunker_de] Link","links":["567381de.f98d2","df7f7c66.5d7ce"],"x":1195,"y":760,"wires":[]},{"id":"4fa4fe18.8783a","type":"Text","z":"e3aa70fa.b265f","name":"Text","intextString":"{{payload[0].visits}}","inbigFont":"true","inscrollText":"false","inscrollTextDelay":"0","incenterText":"true","inposX":"7","inposY":"1","incolorR":"255","incolorG":"255","incolorB":"255","x":970,"y":760,"wires":[["a302950b.9ebec8"]]},{"id":"1dfc5964.955167","type":"Switch Animation","z":"e3aa70fa.b265f","name":"Switch Animation","aktiv":"true","animation":"fade","x":810,"y":760,"wires":[["4fa4fe18.8783a"]]},{"id":"ba4db195.994b8","type":"Screen Init","z":"e3aa70fa.b265f","name":"Screen Init","inscreenName":"matomo_bastelbunker_de","induration":"10","x":630,"y":760,"wires":[["1dfc5964.955167"]]},{"id":"a302950b.9ebec8","type":"Bitmap","z":"e3aa70fa.b265f","name":"Bitmap","indata":"[0,0,0,0,0,0,0,0,0,6547,6547,0,0,64908,64908,0,12918,6547,6547,0,0,64908,64908,34192,12918,12918,0,6547,6547,0,34192,34192,12918,0,0,6547,6547,0,0,34192,53247,0,0,0,0,0,0,34192,53247,0,0,0,0,0,0,34192,0,0,0,0,0,0,0,0]","inposX":"0","inposY":"0","inwidth":"8","inheight":"8","x":1100,"y":760,"wires":[["ef68cb39.109dc8"]]}]

Sonos Change Title Alert

Abhängigkeit / dependence: https://flows.nodered.org/node/node-red-contrib-better-sonos

[{"id":"fd0ff451.5db9b8","type":"inject","z":"e3aa70fa.b265f","name":"Every 2s","topic":"","payload":"","payloadType":"date","repeat":"2","crontab":"","once":false,"onceDelay":"0.1","x":100,"y":160,"wires":[["3bfd56e4.4585ea"]]},{"id":"3bfd56e4.4585ea","type":"better-sonos-status","z":"e3aa70fa.b265f","confignode":"5e99da71.3ed3f4","name":"","x":260,"y":160,"wires":[["d8c66e26.7fcf6"]]},{"id":"d8c66e26.7fcf6","type":"function","z":"e3aa70fa.b265f","name":"Create Message and View handling","func":"var oldVal =  context.get(\"oldVal\")||\"\";\nvar newVal =  msg.track.artist + \" : \" + msg.track.title;\n\n//newVal = newVal.toUpperCase();\n\nif (newVal != oldVal)\n{\n    context.set(\"oldVal\", newVal);\n    msg.payload = newVal;\n    msg.duration = newVal.length /2.3;\n    return msg;\n}\n","outputs":1,"noerr":0,"x":500,"y":160,"wires":[["a2d878a.9077988"]]},{"id":"5882054b.eb9f9c","type":"comment","z":"e3aa70fa.b265f","name":"Alert: Sonos Change Title ","info":"","x":130,"y":120,"wires":[]},{"id":"69f70866.14f788","type":"link out","z":"e3aa70fa.b265f","name":"Alert: Sonos Change Title Link","links":["9590c2af.b689"],"x":1355,"y":160,"wires":[]},{"id":"51a596ec.919e68","type":"Switch Animation","z":"e3aa70fa.b265f","name":"Switch Animation","aktiv":"true","animation":"coloredBarWipe","x":910,"y":160,"wires":[["a4c763e.f3d33a"]]},{"id":"a4c763e.f3d33a","type":"Text","z":"e3aa70fa.b265f","name":"Text","intextString":"{{msg.payload}}","inbigFont":"false","inscrollText":"true","inscrollTextDelay":"35","incenterText":"false","inposX":7,"inposY":1,"incolorR":255,"incolorG":255,"incolorB":255,"x":1070,"y":160,"wires":[["32eff210.64e64e"]]},{"id":"a2d878a.9077988","type":"Screen Init","z":"e3aa70fa.b265f","name":"Screen Init","inscreenName":"instagram","induration":"{{msg.duration}}","x":730,"y":160,"wires":[["51a596ec.919e68"]]},{"id":"32eff210.64e64e","type":"Bitmap Animation","z":"e3aa70fa.b265f","name":"Bitmap Animation","indata":"[43008,0,0,0,0,0,0,0,64170,0,0,0,0,0,0,0,64853,0,0,0,0,64853,0,0,65535,65535,0,0,0,65535,0,0,65535,65535,0,65535,0,65535,0,65535,65535,65535,0,65535,65535,65535,0,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535],  [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64853,0,0,0,0,0,0,0,65535,0,0,0,0,0,0,65535,65535,65535,0,0,65535,0,0,65535,65535,65535,65535,65535,65535,65535,0,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535],  [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,65535,0,0,0,65535,0,0,65535,65535,65535,0,65535,65535,65535,0,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535],  [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,65535,0,0,65535,0,0,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535],  [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,65535,0,0,0,65535,0,0,65535,65535,0,0,0,65535,65535,0,65535,65535,0,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535],  [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64853,0,0,0,0,0,65535,0,65535,0,0,0,0,65535,65535,0,65535,65535,0,65535,0,65535,65535,65535,65535,65535,0,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535]","inanimationDelay":"100","inrubberbanding":"false","inlimitLoops":"0","x":1230,"y":160,"wires":[["69f70866.14f788"]]},{"id":"5e99da71.3ed3f4","type":"better-sonos-config","z":"","name":"Sonos-Büro","serialnum":"","ipaddress":"192.168.0.152"}]

Der Einsteiger Beispiel Flow

Um den Start etwas zu vereinfachen kann man sich diesen Flow mal importieren.
Und etwas daran rumwerkeln und probieren!

Abhängigkeit / dependence: https://flows.nodered.org/node/node-red-contrib-isonline

Hier der dazugehörige Formbeitrag: https://forum.bastelbunker.de/d/29-der-einsteiger-beispiel-flow

[{"id":"35ecb3fe.70a82c","type":"Core","z":"eeacac8e.84e57","name":"Core","ip":"","masterTopic":"","x":1750,"y":480,"wires":[[]]},{"id":"2ae8103e.2bfa8","type":"Alert Screen","z":"eeacac8e.84e57","name":"Alert Screen","x":1540,"y":440,"wires":[["35ecb3fe.70a82c"]]},{"id":"a6448772.da11e8","type":"Screen Data Update","z":"eeacac8e.84e57","name":"Screen Data Update","x":1510,"y":480,"wires":[["35ecb3fe.70a82c"]]},{"id":"5d1d17a4.067008","type":"Matrix Control","z":"eeacac8e.84e57","name":"Matrix Control","x":1530,"y":520,"wires":[["35ecb3fe.70a82c"]]},{"id":"aaebf8a3.b93f98","type":"Playlist Update","z":"eeacac8e.84e57","name":"Playlist Update","x":1530,"y":560,"wires":[["35ecb3fe.70a82c"]]},{"id":"86e00ce2.a6505","type":"Matrix Config","z":"eeacac8e.84e57","name":"Matrix Config","matrixtBrightness":85,"matrixType":2,"clockTimeZone":1,"scrollTextDefaultDelay":110,"mqttAktiv":"false","mqttServer":"","mqttPort":1883,"mqttUser":"","mqttPassword":"","mqttMasterTopic":"","x":1540,"y":400,"wires":[["35ecb3fe.70a82c"]]},{"id":"8dda7744.154fc8","type":"comment","z":"eeacac8e.84e57","name":"Alert Message","info":"","x":470,"y":380,"wires":[]},{"id":"2ae3a14.25d9d5e","type":"inject","z":"eeacac8e.84e57","name":"Push","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"onceDelay":"0","x":630,"y":380,"wires":[["b3f96a15.ff4fb8"]]},{"id":"8ad9260b.cf8098","type":"Switch Animation","z":"eeacac8e.84e57","name":"Switch Animation","aktiv":"true","animation":"fade","x":1150,"y":380,"wires":[["b3ad9478.01eb48"]]},{"id":"b3ad9478.01eb48","type":"Text","z":"eeacac8e.84e57","name":"Text","intextString":"Pixel!!","inbigFont":"false","inscrollText":"true","inscrollTextDelay":"0","incenterText":"false","inposX":"8","inposY":"1","incolorR":"255","incolorG":"255","incolorB":"255","x":1310,"y":380,"wires":[["2ae8103e.2bfa8"]]},{"id":"a8d0668.e8c4098","type":"Screen Init","z":"eeacac8e.84e57","name":"Screen Init","inscreenName":"bra","induration":"10","x":970,"y":380,"wires":[["8ad9260b.cf8098"]]},{"id":"b3f96a15.ff4fb8","type":"Bitmap Animation","z":"eeacac8e.84e57","name":"Bitmap Animation","indata":"[43008,0,0,0,0,0,0,0,64170,0,0,0,0,0,0,0,64853,0,0,0,0,64853,0,0,65535,65535,0,0,0,65535,0,0,65535,65535,0,65535,0,65535,0,65535,65535,65535,0,65535,65535,65535,0,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535],  [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64853,0,0,0,0,0,0,0,65535,0,0,0,0,0,0,65535,65535,65535,0,0,65535,0,0,65535,65535,65535,65535,65535,65535,65535,0,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535],  [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,65535,0,0,0,65535,0,0,65535,65535,65535,0,65535,65535,65535,0,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535],  [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,65535,0,0,65535,0,0,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535],  [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,65535,0,0,0,65535,0,0,65535,65535,0,0,0,65535,65535,0,65535,65535,0,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535],  [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64853,0,0,0,0,0,65535,0,65535,0,0,0,0,65535,65535,0,65535,65535,0,65535,0,65535,65535,65535,65535,65535,0,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535,65535]","inanimationDelay":"100","inrubberbanding":"false","inlimitLoops":"0","x":790,"y":380,"wires":[["a8d0668.e8c4098"]]},{"id":"f3f2a895.193e38","type":"http request","z":"eeacac8e.84e57","name":"Get Lux","method":"GET","ret":"txt","url":"http://192.168.0.137/api/luxsensor","tls":"","x":960,"y":580,"wires":[["d0be6521.9a50c8"]]},{"id":"d0be6521.9a50c8","type":"json","z":"eeacac8e.84e57","name":"Pars JSON","property":"payload","action":"","pretty":false,"x":1110,"y":580,"wires":[["b4533301.6b818"]]},{"id":"5206c6e3.422eb8","type":"inject","z":"eeacac8e.84e57","name":"Every 3s","topic":"","payload":"","payloadType":"date","repeat":"3","crontab":"","once":true,"onceDelay":"0","x":580,"y":580,"wires":[["66da05c9.5ef47c"]]},{"id":"66da05c9.5ef47c","type":"is online","z":"eeacac8e.84e57","name":"check PIXEL IT is online","url":"192.168.0.137","action":"1","x":770,"y":580,"wires":[["f3f2a895.193e38"]]},{"id":"b4533301.6b818","type":"function","z":"eeacac8e.84e57","name":"Brightness Logic","func":"var lux = msg.payload.lux;\nvar brightness = 255;\nvar currentBrightness = context.get(\"currentBrightness\")||-1;\n\nif (lux <= 1)\n{\n    brightness = 20;\n}\nelse if (lux <= 5)\n{\n    brightness = 30;\n}\nelse if (lux <= 10)\n{\n    brightness = 45;\n}\nelse if (lux <= 20)\n{\n    brightness = 60;\n}\nelse if (lux <= 100)\n{\n    brightness = 80;\n}\nelse if (lux <= 250)\n{\n    brightness = 100;\n}\n\nmsg.provider = \"Brightness Logic\";\nmsg.brightness = brightness;\nnode.status({ fill: \"yellow\", shape: \"ring\", text: \"Lux: \" + lux.toFixed(3) +\" | Bri: \" + brightness });\n\nif (currentBrightness != brightness)\n{\n    node.status({ fill: \"green\", shape: \"ring\", text: \"Lux: \" + lux.toFixed(3) +\" | Bri: \" + brightness +\" send!\" });\n    context.set(\"currentBrightness\", brightness);\n    return msg;\n}","outputs":1,"noerr":0,"x":1290,"y":580,"wires":[["5d1d17a4.067008"]]},{"id":"b127dcc7.abdee","type":"comment","z":"eeacac8e.84e57","name":"Brightness Automatic","info":"","x":380,"y":580,"wires":[]},{"id":"ab30e681.56e698","type":"comment","z":"eeacac8e.84e57","name":"Internal Pixel It Clock [internal_clock]","info":"","x":620,"y":460,"wires":[]},{"id":"e2f79120.fb761","type":"inject","z":"eeacac8e.84e57","name":"Init","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":true,"onceDelay":"0.1","x":850,"y":460,"wires":[["341fc2fc.7d033e"]]},{"id":"341fc2fc.7d033e","type":"Screen Init","z":"eeacac8e.84e57","name":"Screen Init","inscreenName":"internal_clock","induration":"10","x":990,"y":460,"wires":[["4c2acf36.39c45"]]},{"id":"4c2acf36.39c45","type":"Switch Animation","z":"eeacac8e.84e57","name":"Switch Animation","aktiv":"true","animation":"fade","x":1170,"y":460,"wires":[["9729bfde.a1f27"]]},{"id":"9729bfde.a1f27","type":"Clock","z":"eeacac8e.84e57","name":"Clock","inswitchAktiv":"true","inswitchSec":"6","inwithSeconds":"false","incolorR":"255","incolorG":"255","incolorB":"255","x":1330,"y":460,"wires":[["a6448772.da11e8"]]},{"id":"b92c80c4.a60e9","type":"change","z":"eeacac8e.84e57","name":"Display Playlist","rules":[{"t":"set","p":"payload","pt":"msg","to":"[{\"screenName\":\"Instagram\"},{\"screenName\":\"internal_clock\"}]","tot":"json"}],"action":"","property":"","from":"","to":"","reg":false,"x":1300,"y":640,"wires":[["aaebf8a3.b93f98"]]},{"id":"2723a613.25f89a","type":"inject","z":"eeacac8e.84e57","name":"Instant","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":true,"onceDelay":"1","x":1120,"y":640,"wires":[["b92c80c4.a60e9"]]},{"id":"c97178af.32b168","type":"comment","z":"eeacac8e.84e57","name":"Display Playlist","info":"","x":940,"y":640,"wires":[]},{"id":"e964f00e.834e6","type":"http request","z":"eeacac8e.84e57","name":"","method":"GET","ret":"txt","url":"https://www.instagram.com/_o0dennis0o_/","tls":"","x":490,"y":520,"wires":[["7eeaa50.ee7705c"]]},{"id":"7eeaa50.ee7705c","type":"function","z":"eeacac8e.84e57","name":"Extract Follower","func":"var myRegexp = /edge_followed_by\":{\"count\":(.*?)}/g;\nvar match = myRegexp.exec(msg.payload);\nmsg.payload = match[1];\nreturn msg;","outputs":1,"noerr":0,"x":680,"y":520,"wires":[["a5a65c0c.f2497"]]},{"id":"dd221267.735cb","type":"inject","z":"eeacac8e.84e57","name":"Every 30min","topic":"","payload":"","payloadType":"date","repeat":"1800","crontab":"","once":true,"onceDelay":0.1,"x":300,"y":520,"wires":[["e964f00e.834e6"]]},{"id":"ae1584ea.048d98","type":"Text","z":"eeacac8e.84e57","name":"Text","intextString":"{{payload}}","inbigFont":"true","inscrollText":"false","inscrollTextDelay":"0","incenterText":"true","inposX":"7","inposY":"1","incolorR":"255","incolorG":"255","incolorB":"255","x":1190,"y":520,"wires":[["ef71268e.6f2fc8"]]},{"id":"df87efe.91ab01","type":"Switch Animation","z":"eeacac8e.84e57","name":"Switch Animation","aktiv":"true","animation":"fade","x":1030,"y":520,"wires":[["ae1584ea.048d98"]]},{"id":"a5a65c0c.f2497","type":"Screen Init","z":"eeacac8e.84e57","name":"Screen Init","inscreenName":"Instagram","induration":"10","x":850,"y":520,"wires":[["df87efe.91ab01"]]},{"id":"ef71268e.6f2fc8","type":"Bitmap","z":"eeacac8e.84e57","name":"Bitmap","indata":"[0, 14783, 25023, 37375, 37375, 49598, 49598, 0, 35294, 35294, 65535, 65535, 65535, 65535, 63999, 63928, 53791, 65535, 63928, 63928, 63928, 65535, 65535, 63928, 61983, 65535, 63928, 65535, 65535, 63928, 65535, 63928, 59885, 65535, 59885, 65535, 65535, 63928, 65535, 63928, 64518, 65535, 64518, 64518, 64518, 59885, 65535, 63928, 64901, 65260, 65535, 65535, 65535, 65535, 59885, 63928, 0, 65461, 65461, 65166, 64967, 62502, 64166, 0]","inposX":"0","inposY":"0","inwidth":"8","inheight":"8","x":1320,"y":520,"wires":[["a6448772.da11e8"]]},{"id":"5638a83a.89b728","type":"comment","z":"eeacac8e.84e57","name":"Instagram Follower","info":"","x":90,"y":520,"wires":[]},{"id":"2c5b612a.f90aee","type":"inject","z":"eeacac8e.84e57","name":"Set","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"onceDelay":"0","x":1300,"y":320,"wires":[["86e00ce2.a6505"]]}]