Orange Pi Zero 3 System Monitoring Dashboard
Orange Pi Zero 3 System Monitoring Dashboard
[{"id":"9cf3a6d.1104258","type":"tab","label":"Orange Pi Monitoring","disabled":false,"info":""},{"id":"2be04c82.d0af74","type":"inject","z":"9cf3a6d.1104258","name":"","repeat":"3","crontab":"","once":true,"onceDelay":"","topic":"","payload":"","payloadType":"date","x":130,"y":60,"wires":[["92285ea6.f97a7","c0ffe68.afd6e18"]]},{"id":"cf3854e6.653878","type":"exec","z":"9cf3a6d.1104258","command":"sudo reboot","addpay":false,"append":"","useSpawn":"","timer":"","name":"Reboot","x":322.00007247924805,"y":311.7778015136719,"wires":[[],[],[]]},{"id":"4de9dba1.ed7854","type":"exec","z":"9cf3a6d.1104258","command":"sudo shutdown -h now","addpay":false,"append":"","useSpawn":"","timer":"","name":"Shutdown","x":331.2778129577637,"y":368.4722480773926,"wires":[[],[],[]]},{"id":"92285ea6.f97a7","type":"exec","z":"9cf3a6d.1104258","command":"top -d 0.5 -b -n2 | grep \"Cpu(s)\"|tail -n 1 | awk '{print $2 + $4}'","addpay":false,"append":"","useSpawn":"","timer":"","winHide":false,"name":"CPU Load","x":325.2221908569336,"y":66.33333683013916,"wires":[["404f06.1e77b0fc","fe6303f14bfa5e20"],[],[]]},{"id":"c0ffe68.afd6e18","type":"exec","z":"9cf3a6d.1104258","command":"free | awk 'NR==2 {printf \"%.2f\\n\", ($7 / $2) * 100}'","addpay":false,"append":"","useSpawn":"","timer":"","winHide":false,"name":"Free Memory","x":330,"y":160,"wires":[["8cf70ed5.e49ec"],[],[]]},{"id":"a508a5b7.89a128","type":"exec","z":"9cf3a6d.1104258","command":"df -h","addpay":false,"append":"","useSpawn":"","timer":"","winHide":false,"name":"Disk Usage","x":330,"y":240,"wires":[["a8dc2f34.5e32b"],[],[]]},{"id":"a8dc2f34.5e32b","type":"function","z":"9cf3a6d.1104258","name":"","func":"var re = /\\/dev\\/mmcblk0p1.*?([0-9]+)%/; // Regex to find the mmcblk0p1 line and capture the percentage\nvar str = msg.payload;\nvar match = str.match(re); // Match the line with mmcblk0p1 and capture percentage\n\nif (match) {\n msg.payload = match[1]; // Extract only the numeric percentage value\n} else {\n msg.payload = null; // If no match is found, set payload to null\n}\n\nreturn msg;\n","outputs":1,"timeout":"","noerr":0,"initialize":"","finalize":"","libs":[],"x":480,"y":240,"wires":[["ad4498e0.e7c278"]]},{"id":"5e6e69bb.0e1d38","type":"inject","z":"9cf3a6d.1104258","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"60","crontab":"","once":true,"onceDelay":"","topic":"","payload":"","payloadType":"date","x":130,"y":240,"wires":[["a508a5b7.89a128"]]},{"id":"19fadb42.3d0c25","type":"inject","z":"9cf3a6d.1104258","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"10","crontab":"","once":true,"onceDelay":"","topic":"","payload":"","payloadType":"date","x":126.01936721801758,"y":427.3448371887207,"wires":[["9cce8e0f.766f7"]]},{"id":"9cce8e0f.766f7","type":"exec","z":"9cf3a6d.1104258","command":"hostname","addpay":false,"append":"-I","useSpawn":"","timer":"","name":"Get Local IP","x":330.5749206542969,"y":427.84485054016113,"wires":[["620c2ccf.7c7584","b1e5e669.f1fd48"],[],[]]},{"id":"b1e5e669.f1fd48","type":"mqtt out","z":"9cf3a6d.1104258","d":true,"name":"Send IP thru MQTT","topic":"raspberrypi3_ip_gama","qos":"0","retain":"true","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"14bc5267.4d798e","x":617.111156463623,"y":381.7777557373047,"wires":[]},{"id":"f4592b30.2f0528","type":"ui_button","z":"9cf3a6d.1104258","name":"","group":"dd70abe0.14cb38","order":1,"width":0,"height":0,"passthru":false,"label":"Reboot","tooltip":"","color":"","bgcolor":"","className":"","icon":"","payload":"","payloadType":"str","topic":"","topicType":"str","x":121.77785110473633,"y":311.7778253555298,"wires":[["cf3854e6.653878"]]},{"id":"4b4a0861.092b28","type":"ui_button","z":"9cf3a6d.1104258","name":"","group":"dd70abe0.14cb38","order":2,"width":0,"height":0,"passthru":false,"label":"Shutdown","tooltip":"","color":"","bgcolor":"red","className":"","icon":"","payload":"","payloadType":"str","topic":"","topicType":"str","x":111.3889274597168,"y":368.25005435943604,"wires":[["4de9dba1.ed7854"]]},{"id":"620c2ccf.7c7584","type":"ui_text","z":"9cf3a6d.1104258","group":"dd70abe0.14cb38","order":2,"width":"6","height":"2","name":"","label":"IP Address","format":"{{value.substring(0, value.indexOf(\" \"))}}","layout":"col-center","className":"","style":false,"font":"","fontSize":"","color":"#000000","x":597.111156463623,"y":441.7777557373047,"wires":[]},{"id":"404f06.1e77b0fc","type":"ui_gauge","z":"9cf3a6d.1104258","name":"","group":"9cb4bc4d.96552","order":4,"width":"4","height":"4","gtype":"gage","title":"CPU","label":"CPU%","format":"{{value}}","min":0,"max":"100","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","diff":false,"className":"","x":510,"y":60,"wires":[]},{"id":"8cf70ed5.e49ec","type":"ui_gauge","z":"9cf3a6d.1104258","name":"","group":"9cb4bc4d.96552","order":2,"width":"4","height":"4","gtype":"gage","title":"Memory free","label":"%","format":"{{value}}","min":0,"max":"100","colors":["#ca3838","#e6e600","#00b500"],"seg1":"","seg2":"","diff":false,"className":"","x":530,"y":160,"wires":[]},{"id":"ad4498e0.e7c278","type":"ui_gauge","z":"9cf3a6d.1104258","name":"","group":"9cb4bc4d.96552","order":3,"width":"4","height":"4","gtype":"gage","title":"Disk Space","label":"%","format":"{{value}}","min":0,"max":"100","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","diff":false,"className":"","x":630,"y":240,"wires":[]},{"id":"fe6303f14bfa5e20","type":"ui_chart","z":"9cf3a6d.1104258","name":"","group":"9cb4bc4d.96552","order":5,"width":"8","height":"6","label":"CPU Load%","chartType":"line","legend":"false","xformat":"HH:mm:ss","interpolate":"linear","nodata":"","dot":false,"ymin":"","ymax":"","removeOlder":"30","removeOlderPoints":"","removeOlderUnit":"60","cutout":0,"useOneColor":false,"useUTC":false,"colors":["#1f77b4","#aec7e8","#ff7f0e","#2ca02c","#98df8a","#d62728","#ff9896","#9467bd","#c5b0d5"],"outputs":1,"useDifferentColor":false,"className":"","x":530,"y":100,"wires":[[]]},{"id":"14bc5267.4d798e","type":"mqtt-broker","name":"","broker":"test.mosquitto.org","port":"1883","clientid":"","usetls":false,"compatmode":true,"keepalive":"60","cleansession":true,"birthTopic":"raspberry_do_gama_alive","birthQos":"0","birthRetain":"true","birthPayload":"Raspberry ativo","closeTopic":"","closePayload":"","willTopic":"","willQos":"0","willPayload":""},{"id":"dd70abe0.14cb38","type":"ui_group","name":"OS","tab":"ad4a1223.94ae8","order":5,"disp":true,"width":"6","collapse":false,"className":""},{"id":"9cb4bc4d.96552","type":"ui_group","name":"System","tab":"ad4a1223.94ae8","order":1,"disp":true,"width":"16","collapse":false,"className":""},{"id":"ad4a1223.94ae8","type":"ui_tab","z":"9cf3a6d.1104258","name":"Orange Pi (Control Panel)","icon":"dashboard","order":1,"disabled":false,"hidden":false}]