EOS Weather - MySQL Dashboard

This can be used to add a weather dashboard. It will use MySQL select statements against the station database. See http://eosweather.ca for more details.

[{"id":"85029446.549688","type":"inject","z":"43603a95.bb0adc","name":"","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"x":154.7222137451172,"y":151.66666793823242,"wires":[["30df9432.5e6a9c"]]},{"id":"30df9432.5e6a9c","type":"ui_text","z":"43603a95.bb0adc","group":"842d2fac.76659","order":0,"width":0,"height":0,"name":"","label":"text","format":"{{msg.payload}}","layout":"row-spread","x":411.3888702392578,"y":177.22221088409424,"wires":[]},{"id":"abe3a13c.f4fe1","type":"switch","z":"43603a95.bb0adc","name":"IsTemp","property":"payload","propertyType":"msg","rules":[{"t":"eq","v":"1","vt":"num"}],"checkall":"true","outputs":1,"x":333.8887176513672,"y":928.9999694824219,"wires":[["76a1b50.b82584c","d71f2226.d9ba4"]]},{"id":"7cafae97.e2ec6","type":"switch","z":"43603a95.bb0adc","name":"IsWind","property":"payload","propertyType":"msg","rules":[{"t":"eq","v":"1","vt":"num"}],"checkall":"true","outputs":1,"x":354.88873291015625,"y":245.9999542236328,"wires":[["3ca9c54.955a13a","235844ad.4bc2bc"]]},{"id":"9ae9fc62.5072c","type":"switch","z":"43603a95.bb0adc","name":"IsPressure","property":"payload","propertyType":"msg","rules":[{"t":"eq","v":"1","vt":"num"}],"checkall":"true","outputs":1,"x":343.5553436279297,"y":1235.999960899353,"wires":[["b81a44ff.e7d7f8"]]},{"id":"d6168c0c.adb56","type":"mysql","z":"43603a95.bb0adc","mydb":"ee7040c0.1be97","name":"Temp DB","x":848.8890991210938,"y":710.9999542236328,"wires":[["40324fbf.b841","baaa5d86.d444c","881bf10.760091"]]},{"id":"b5aef905.f67458","type":"function","z":"43603a95.bb0adc","name":"Get Pressure","func":"data = (msg.payload);\nvar m = {\n topic : \"Select round(REL_PRESS/10,1) as BAR  from PRESSURE order by W_TIME desc limit 0,1;\"     \n };\nreturn m;","outputs":1,"noerr":0,"x":673.5554656982422,"y":1257.000015258789,"wires":[["47cab6db.3f1138"]]},{"id":"3ca9c54.955a13a","type":"function","z":"43603a95.bb0adc","name":"Get Wind","func":"data = (msg.payload);\nvar m = {\n topic : \"Select SPEED from WIND order by W_TIME desc limit 0,1;\"     \n };\nreturn m;","outputs":1,"noerr":0,"x":521.888801574707,"y":243.9999542236328,"wires":[["cd226335.14c55"]]},{"id":"4bc795fa.af505c","type":"function","z":"43603a95.bb0adc","name":"Get Temp","func":"data = (msg.payload);\nvar m = {\n topic : \"Select OUTSIDE, DEWPOINT, REL_HUM from TEMP order by W_TIME desc limit 0,1;\"     \n };\nreturn m;","outputs":1,"noerr":0,"x":685.8886566162109,"y":726.9999542236328,"wires":[["d6168c0c.adb56"]]},{"id":"7803586.113f3a8","type":"ui_gauge","z":"43603a95.bb0adc","name":"","group":"a10448e8.913d58","order":1,"width":"3","height":"3","gtype":"donut","title":"Wind Speed","label":"Kph","format":"{{value}}","min":0,"max":"100","colors":["#00b500","#e6e600","#ca3838"],"x":1293.7230224609375,"y":203.333251953125,"wires":[]},{"id":"1897d9c3.790a76","type":"function","z":"43603a95.bb0adc","name":"Get Speed","func":"msg.payload = msg.payload[0].SPEED;\nmsg.topic = \"Speed\"\nreturn msg","outputs":1,"noerr":0,"x":1039.7227172851562,"y":239.9999542236328,"wires":[["7803586.113f3a8","3815badd.235a66"]]},{"id":"6a7c87c3.6b75b8","type":"mysql","z":"43603a95.bb0adc","mydb":"ee7040c0.1be97","name":"Wind DB","x":847.7222671508789,"y":275.3332824707031,"wires":[["1897d9c3.790a76"]]},{"id":"8c2d6290.4c6b1","type":"ui_gauge","z":"43603a95.bb0adc","name":"","group":"79c85dcd.3828b4","order":1,"width":"6","height":"3","gtype":"gage","title":"","label":"C","format":"{{value}}","min":"-10","max":"30","colors":["#0004b5","#00ff00","#ca3838"],"x":1299.833740234375,"y":623.5554809570312,"wires":[]},{"id":"40324fbf.b841","type":"function","z":"43603a95.bb0adc","name":"Get Temp Value","func":"msg.payload = msg.payload[0].OUTSIDE\nreturn msg","outputs":1,"noerr":0,"x":1087.7229614257812,"y":629.9999389648438,"wires":[["8c2d6290.4c6b1"]]},{"id":"47cab6db.3f1138","type":"mysql","z":"43603a95.bb0adc","mydb":"ee7040c0.1be97","name":"Pressure DB","x":868.388916015625,"y":1235.333251953125,"wires":[["9e7b3bb3.752848"]]},{"id":"9e7b3bb3.752848","type":"function","z":"43603a95.bb0adc","name":"Get Pressure Value","func":"msg.payload = msg.payload[0].BAR\nmsg.topic =\"Bar\"\nreturn msg","outputs":1,"noerr":0,"x":1084.3892059326172,"y":1228.6666412353516,"wires":[["7346a243.2b9b0c","5e2e3358.a9dfbc"]]},{"id":"7346a243.2b9b0c","type":"ui_gauge","z":"43603a95.bb0adc","name":"","group":"506eca8c.10fa34","order":1,"width":"6","height":"3","gtype":"gage","title":"","label":"Kpa","format":"{{value}}","min":"95","max":"105","colors":["#ff0000","#ffff00","#ffffff"],"x":1299.7229461669922,"y":1189.9999542236328,"wires":[]},{"id":"c0ab6c29.1a69c","type":"ui_text","z":"43603a95.bb0adc","group":"a10448e8.913d58","order":4,"width":"","height":"","name":"Average Wind Speed","label":"Average Speed","format":"{{msg.payload}}","layout":"","x":1344.0555419921875,"y":388.3332824707031,"wires":[]},{"id":"d95bfd9d.d67a6","type":"inject","z":"43603a95.bb0adc","name":"Wind Trigger","topic":"","payload":"true","payloadType":"bool","repeat":"5","crontab":"","once":true,"x":165.72206115722656,"y":229.9999237060547,"wires":[["7cafae97.e2ec6","44a5a12b.bf49"]]},{"id":"c9569c85.4abc","type":"inject","z":"43603a95.bb0adc","name":"Update Trigger","topic":"","payload":"true","payloadType":"bool","repeat":"60","crontab":"","once":true,"x":145.72206115722656,"y":1055.9999694824219,"wires":[["abe3a13c.f4fe1","9ae9fc62.5072c","1b82ad75.ecc6a3","40e0cbe2.8a08a4"]]},{"id":"76a1b50.b82584c","type":"delay","z":"43603a95.bb0adc","name":"","pauseType":"delay","timeout":"1","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":481.72203063964844,"y":741.9999542236328,"wires":[["4bc795fa.af505c"]]},{"id":"b81a44ff.e7d7f8","type":"delay","z":"43603a95.bb0adc","name":"","pauseType":"delay","timeout":"5","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":506.7220916748047,"y":1207.6666412353516,"wires":[["b5aef905.f67458"]]},{"id":"539a4389.cc3b2c","type":"function","z":"43603a95.bb0adc","name":"Get Avg Speed","func":"msg.payload = msg.payload[0].WIND_SPEED\nreturn msg","outputs":1,"noerr":0,"x":1056.055419921875,"y":370.99993896484375,"wires":[["c0ab6c29.1a69c"]]},{"id":"1395ec4.0ac0014","type":"function","z":"43603a95.bb0adc","name":"Get Gust","func":"msg.payload = msg.payload[0].WIND_HI\nmsg.topic = \"Hi Gusts\"\nreturn msg","outputs":1,"noerr":0,"x":1041.055419921875,"y":290.99993896484375,"wires":[["f25c8573.ce14d8","1b09ef25.42aeb1"]]},{"id":"f25c8573.ce14d8","type":"ui_text","z":"43603a95.bb0adc","group":"a10448e8.913d58","order":6,"width":"","height":"","name":"Hi Gusts","label":"Hi Speed (10 min)","format":"{{msg.payload}}","layout":"","x":1331.0555419921875,"y":279.6666259765625,"wires":[]},{"id":"97f67474.af2008","type":"function","z":"43603a95.bb0adc","name":"Get Hi Low","func":"data = (msg.payload);\nvar m = {\n topic : \"Select RAIN, SUN_HRS, WIND_HI, WIND_DIR, TEMP_HI, TEMP_LOW, round(CAST(BAR_LOW as Decimal(10,2))/10,1) as BAR_LOW,  round(CAST(BAR_HI as Decimal(10,2))/10,1) as BAR_HI  from CORE_DATE order by WE_DATE desc limit 0,1;\"     \n };\nreturn m;","outputs":1,"noerr":0,"x":712.7220458984375,"y":851,"wires":[["7d651b87.99e884"]]},{"id":"d71f2226.d9ba4","type":"delay","z":"43603a95.bb0adc","name":"","pauseType":"delay","timeout":"2","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":529.7220306396484,"y":906.6666412353516,"wires":[["97f67474.af2008"]]},{"id":"7d651b87.99e884","type":"mysql","z":"43603a95.bb0adc","mydb":"ee7040c0.1be97","name":"HiLow","x":855.7223815917969,"y":1000.6666564941406,"wires":[["3a9122d8.68066e","a7dd022c.7e2cf","88cf71ed.020f","a7d94812.54f128","9507e4ed.8b0d48","670756e7.c51658","67b79b08.c08b04"]]},{"id":"3a9122d8.68066e","type":"function","z":"43603a95.bb0adc","name":"Get HiTemp","func":"msg.payload = msg.payload[0].TEMP_HI\nreturn msg","outputs":1,"noerr":0,"x":1085.722412109375,"y":918.6666412353516,"wires":[["c02434a6.f5a2d8"]]},{"id":"a7dd022c.7e2cf","type":"function","z":"43603a95.bb0adc","name":"Get LowTemp","func":"msg.payload = msg.payload[0].TEMP_LOW\nreturn msg","outputs":1,"noerr":0,"x":1087.722427368164,"y":961.9999322891235,"wires":[["c959d987.54f0c8"]]},{"id":"c02434a6.f5a2d8","type":"ui_text","z":"43603a95.bb0adc","group":"79c85dcd.3828b4","order":5,"width":"","height":"","name":"Daily Hi","label":"Daily Hi","format":"{{msg.payload}}","layout":"","x":1283.72216796875,"y":913.9999542236328,"wires":[]},{"id":"c959d987.54f0c8","type":"ui_text","z":"43603a95.bb0adc","group":"79c85dcd.3828b4","order":6,"width":"","height":"","name":"Daily Low","label":"Daily Low","format":"{{msg.payload}}","layout":"","x":1292.3887786865234,"y":963.999951839447,"wires":[]},{"id":"562d0ead.a19a9","type":"ui_text","z":"43603a95.bb0adc","group":"506eca8c.10fa34","order":4,"width":"","height":"","name":"Hi Pressure","label":"Hi Presure","format":"{{msg.payload}}","layout":"","x":1287.722110748291,"y":1046.0000162124634,"wires":[]},{"id":"e94c36be.e52f28","type":"ui_text","z":"43603a95.bb0adc","group":"506eca8c.10fa34","order":5,"width":"","height":"","name":"Low Pressure","label":"Low Pressure","format":"{{msg.payload}}","layout":"","x":1296.388858795166,"y":1102.0000400543213,"wires":[]},{"id":"88cf71ed.020f","type":"function","z":"43603a95.bb0adc","name":"Get BarLow","func":"msg.payload = msg.payload[0].BAR_LOW\nreturn msg","outputs":1,"noerr":0,"x":1077.7224655151367,"y":1113.3332710266113,"wires":[["e94c36be.e52f28"]]},{"id":"a7d94812.54f128","type":"function","z":"43603a95.bb0adc","name":"Get BarHi","func":"msg.payload = msg.payload[0].BAR_HI\nreturn msg","outputs":1,"noerr":0,"x":1067.0556564331055,"y":1035.3332681655884,"wires":[["562d0ead.a19a9"]]},{"id":"9507e4ed.8b0d48","type":"function","z":"43603a95.bb0adc","name":"Get HiWind","func":"msg.payload = msg.payload[0].WIND_HI\nreturn msg","outputs":1,"noerr":0,"x":1097.7222290039062,"y":821.3332366943359,"wires":[["58d9ef0b.5d995"]]},{"id":"670756e7.c51658","type":"function","z":"43603a95.bb0adc","name":"Get Wind Dir","func":"msg.payload = msg.payload[0].WIND_DIR\nreturn msg","outputs":1,"noerr":0,"x":1095.7222900390625,"y":863.3332672119141,"wires":[["5c28431c.4c346c"]]},{"id":"58d9ef0b.5d995","type":"ui_text","z":"43603a95.bb0adc","group":"a10448e8.913d58","order":5,"width":"","height":"","name":"Hi Wind","label":"Hi Wind Today","format":"{{msg.payload}}","layout":"","x":1293.72216796875,"y":806.6666107177734,"wires":[]},{"id":"5c28431c.4c346c","type":"ui_text","z":"43603a95.bb0adc","group":"a10448e8.913d58","order":7,"width":"","height":"","name":"Wid Dir","label":"Average Direction Today","format":"{{msg.payload}}","layout":"","x":1301.72216796875,"y":860.6666107177734,"wires":[]},{"id":"baaa5d86.d444c","type":"function","z":"43603a95.bb0adc","name":"Get Humidity","func":"msg.payload = msg.payload[0].REL_HUM\nreturn msg","outputs":1,"noerr":0,"x":1075.7224731445312,"y":759.9999542236328,"wires":[["3d73e73b.8cdfe8"]]},{"id":"3d73e73b.8cdfe8","type":"ui_text","z":"43603a95.bb0adc","group":"79c85dcd.3828b4","order":3,"width":"","height":"","name":"Humidity","label":"Humidity","format":"{{msg.payload}}","layout":"","x":1287.7225341796875,"y":752.6666412353516,"wires":[]},{"id":"d0572061.a4b9d","type":"ui_text","z":"43603a95.bb0adc","group":"79c85dcd.3828b4","order":4,"width":"","height":"","name":"Dew Point","label":"Dew Point","format":"{{msg.payload}}","layout":"","x":1299.0555419921875,"y":704.6666412353516,"wires":[]},{"id":"881bf10.760091","type":"function","z":"43603a95.bb0adc","name":"Get Dewpoint","func":"msg.payload = msg.payload[0].DEWPOINT\nreturn msg","outputs":1,"noerr":0,"x":1083.0556030273438,"y":709.3332977294922,"wires":[["d0572061.a4b9d"]]},{"id":"cd226335.14c55","type":"delay","z":"43603a95.bb0adc","name":"","pauseType":"delay","timeout":"1","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":683.7220306396484,"y":257.9999542236328,"wires":[["6a7c87c3.6b75b8"]]},{"id":"3815badd.235a66","type":"ui_chart","z":"43603a95.bb0adc","name":"Wind Speed","group":"a10448e8.913d58","order":3,"width":0,"height":0,"label":"Kph","chartType":"line","legend":"false","xformat":"HH:mm:ss","interpolate":"linear","nodata":"","ymin":"","ymax":"","removeOlder":"30","removeOlderPoints":"","removeOlderUnit":"60","cutout":"","x":1580.388671875,"y":240.66659545898438,"wires":[["809f5dff.76974"],[]]},{"id":"44a5a12b.bf49","type":"switch","z":"43603a95.bb0adc","name":"Is Feed","property":"payload","propertyType":"msg","rules":[{"t":"eq","v":"1","vt":"num"}],"checkall":"true","outputs":1,"x":334.05540466308594,"y":510.4443664550781,"wires":[["dc948762.a6e428"]]},{"id":"dc948762.a6e428","type":"function","z":"43603a95.bb0adc","name":"Get Heart Beat","func":"data = (msg.payload);\nvar m = {\n topic : \"Select count(B1) as C from FEED where IS_Done = 0;\"     \n };\nreturn m;","outputs":1,"noerr":0,"x":540.7220306396484,"y":520.6666107177734,"wires":[["7e1335c6.2309fc"]]},{"id":"7e1335c6.2309fc","type":"mysql","z":"43603a95.bb0adc","mydb":"ee7040c0.1be97","name":"Get Feed","x":842.9441986083984,"y":555.9999389648438,"wires":[["1c4cb4f4.f351cb"]]},{"id":"1c4cb4f4.f351cb","type":"function","z":"43603a95.bb0adc","name":"Feed","func":"msg.payload = msg.payload[0].C\nreturn msg","outputs":1,"noerr":0,"x":1057.3887176513672,"y":531.9999389648438,"wires":[["49352d87.7b4164"]]},{"id":"49352d87.7b4164","type":"ui_chart","z":"43603a95.bb0adc","name":"Feeder","group":"8d946075.edcb5","order":0,"width":0,"height":0,"label":"Heart Beat","chartType":"line","legend":"false","xformat":"HH:mm:ss","interpolate":"linear","nodata":"","ymin":"","ymax":"","removeOlder":"5","removeOlderPoints":"","removeOlderUnit":"60","cutout":"","x":1296.3887176513672,"y":533.6665802001953,"wires":[[],[]]},{"id":"5e2e3358.a9dfbc","type":"ui_chart","z":"43603a95.bb0adc","name":"Pressure Chart","group":"506eca8c.10fa34","order":3,"width":0,"height":0,"label":"Pressure","chartType":"line","legend":"false","xformat":"HH:mm:ss","interpolate":"linear","nodata":"","ymin":"","ymax":"","removeOlder":1,"removeOlderPoints":"","removeOlderUnit":"86400","cutout":"","x":1394.4998779296875,"y":1269.5555419921875,"wires":[["581e34c3.bad35c"],[]]},{"id":"1b82ad75.ecc6a3","type":"switch","z":"43603a95.bb0adc","name":"Is Sloalr","property":"payload","propertyType":"msg","rules":[{"t":"eq","v":"1","vt":"num"}],"checkall":"true","outputs":1,"x":342.8887176513672,"y":1402.333267211914,"wires":[["b6041815.d754f8"]]},{"id":"b6041815.d754f8","type":"function","z":"43603a95.bb0adc","name":"Get Solar","func":"data = (msg.payload);\nvar m = {\n topic : \"Select RAD from SOLAR order by W_TIME desc limit 0,1;\"     \n };\nreturn m;","outputs":1,"noerr":0,"x":526.8887176513672,"y":1400.333267211914,"wires":[["8eaf5e2b.b6204"]]},{"id":"8eaf5e2b.b6204","type":"mysql","z":"43603a95.bb0adc","mydb":"ee7040c0.1be97","name":"Solar DB","x":880.8887176513672,"y":1400.333267211914,"wires":[["67a30e94.d5837"]]},{"id":"67a30e94.d5837","type":"function","z":"43603a95.bb0adc","name":"Get Rad","func":"msg.payload = msg.payload[0].RAD\nmsg.topic = \"Rads\"\nreturn msg","outputs":1,"noerr":0,"x":1070.8887176513672,"y":1416.333267211914,"wires":[["d85969fb.9759e8","c4c5a3ad.66fdd"]]},{"id":"d85969fb.9759e8","type":"ui_gauge","z":"43603a95.bb0adc","name":"","group":"d5b5cb3f.6b68a8","order":3,"width":"6","height":"3","gtype":"gage","title":"","label":"W/m2","format":"{{value}}","min":0,"max":"1000","colors":["#00b500","#e6e600","#ca3838"],"x":1358.888671875,"y":1539.333251953125,"wires":[]},{"id":"c4c5a3ad.66fdd","type":"ui_chart","z":"43603a95.bb0adc","name":"Solar Radiation","group":"d5b5cb3f.6b68a8","order":4,"width":"0","height":"0","label":"Radiation","chartType":"line","legend":"false","xformat":"HH:mm:ss","interpolate":"linear","nodata":"","ymin":"","ymax":"","removeOlder":1,"removeOlderPoints":"","removeOlderUnit":"86400","cutout":"","x":1402.888671875,"y":1387.333251953125,"wires":[["9dd58b6b.cca498"],[]]},{"id":"235844ad.4bc2bc","type":"function","z":"43603a95.bb0adc","name":"Get Direction","func":"data = (msg.payload);\nvar m = {\n topic : \"Select DIRECTION from WIND order by W_TIME desc limit 0,1;\"     \n };\nreturn m;","outputs":1,"noerr":0,"x":547.8887176513672,"y":361.33326721191406,"wires":[["4d48c873.82a838"]]},{"id":"4d48c873.82a838","type":"mysql","z":"43603a95.bb0adc","mydb":"ee7040c0.1be97","name":"WindDirection","x":868.8887176513672,"y":437.33326721191406,"wires":[["d6896447.2ba0c8"]]},{"id":"d6896447.2ba0c8","type":"function","z":"43603a95.bb0adc","name":"Get Dir","func":"msg.payload = msg.payload[0].DIRECTION\nreturn msg","outputs":1,"noerr":0,"x":1042.8887176513672,"y":449.33326721191406,"wires":[["7e6890b0.de90e"]]},{"id":"7e6890b0.de90e","type":"ui_gauge","z":"43603a95.bb0adc","name":"Direction","group":"a10448e8.913d58","order":2,"width":"3","height":"3","gtype":"compass","title":"Direction","label":"","format":"{{value}}","min":0,"max":"360","colors":["#00b500","#e6e600","#ca3838"],"x":1321.888671875,"y":447.3332405090332,"wires":[]},{"id":"1b09ef25.42aeb1","type":"delay","z":"43603a95.bb0adc","name":"","pauseType":"delay","timeout":"1","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":1341.888671875,"y":332.333251953125,"wires":[["3815badd.235a66"]]},{"id":"948b7ff2.f1738","type":"function","z":"43603a95.bb0adc","name":"Get Hi Speed 10 min","func":"data = (msg.payload);\nvar m = {\n topic : \"Select WIND_SPEED, WIND_HI from CORE_DATA order by WE_DATE_TIME desc limit 0,1;\"     \n };\nreturn m;","outputs":1,"noerr":0,"x":546.8887176513672,"y":433.33326721191406,"wires":[["4b750a9b.0079b4"]]},{"id":"4b750a9b.0079b4","type":"mysql","z":"43603a95.bb0adc","mydb":"ee7040c0.1be97","name":"WindArch","x":793.8887176513672,"y":354.33326721191406,"wires":[["1395ec4.0ac0014","539a4389.cc3b2c"]]},{"id":"5c9ed1ba.a1771","type":"inject","z":"43603a95.bb0adc","name":"Archive Interval","topic":"","payload":"true","payloadType":"bool","repeat":"60","crontab":"","once":true,"x":161.8887176513672,"y":347.33326721191406,"wires":[["948b7ff2.f1738"]]},{"id":"f39036b8.bb5288","type":"ui_button","z":"43603a95.bb0adc","name":"","group":"d5b5cb3f.6b68a8","order":6,"width":0,"height":0,"label":"Refresh","color":"","icon":"","payload":"true","payloadType":"bool","topic":"","x":344.8887176513672,"y":1459.333267211914,"wires":[["b6041815.d754f8"]]},{"id":"be6345e7.1d2ae8","type":"ui_button","z":"43603a95.bb0adc","name":"","group":"506eca8c.10fa34","order":0,"width":0,"height":0,"label":"Refresh","color":"","icon":"","payload":"true","payloadType":"bool","topic":"","x":344.8887176513672,"y":1302.333267211914,"wires":[["b5aef905.f67458"]]},{"id":"8f326378.e6843","type":"ui_button","z":"43603a95.bb0adc","name":"","group":"79c85dcd.3828b4","order":0,"width":0,"height":0,"label":"Refresh","color":"","icon":"","payload":"true","payloadType":"bool","topic":"","x":498.8887176513672,"y":805.3332672119141,"wires":[["4bc795fa.af505c","97f67474.af2008"]]},{"id":"67b79b08.c08b04","type":"function","z":"43603a95.bb0adc","name":"Get Rain","func":"msg.payload = msg.payload[0].RAIN\nreturn msg","outputs":1,"noerr":0,"x":1075.5,"y":1179,"wires":[["55de7d89.b52674"]]},{"id":"55de7d89.b52674","type":"ui_gauge","z":"43603a95.bb0adc","name":"Rain","group":"4a00aeb0.fbb84","order":0,"width":"6","height":"3","gtype":"wave","title":"","label":"mm","format":"{{value}}","min":0,"max":"100","colors":["#00b500","#e6e600","#ca3838"],"x":1276.8333282470703,"y":1148.3333282470703,"wires":[]},{"id":"40e0cbe2.8a08a4","type":"switch","z":"43603a95.bb0adc","name":"Is Volts","property":"payload","propertyType":"msg","rules":[{"t":"eq","v":"1","vt":"num"}],"checkall":"true","outputs":1,"x":340.5,"y":1528.4500122070312,"wires":[["89ab6497.6f5da8"]]},{"id":"89ab6497.6f5da8","type":"function","z":"43603a95.bb0adc","name":"Get Board","func":"data = (msg.payload);\nvar m = {\n topic : \"Select B_VOLTAGE, S_VOLTAGE from BOARD order by W_TIME desc limit 0,1;\"     \n };\nreturn m;","outputs":1,"noerr":0,"x":533.5,"y":1531.449951171875,"wires":[["72fd166a.667568"]]},{"id":"72fd166a.667568","type":"mysql","z":"43603a95.bb0adc","mydb":"ee7040c0.1be97","name":"Board","x":867.5,"y":1532.8999633789062,"wires":[["317f41fa.73883e","e9346a60.1e0058"]]},{"id":"317f41fa.73883e","type":"function","z":"43603a95.bb0adc","name":"Get Battery","func":"msg.payload = msg.payload[0].B_VOLTAGE\nmsg.topic = \"Battery\"\nreturn msg","outputs":1,"noerr":0,"x":1101.5,"y":1586.449951171875,"wires":[["f9364c39.c7478"]]},{"id":"e9346a60.1e0058","type":"function","z":"43603a95.bb0adc","name":"Get Source","func":"msg.payload = msg.payload[0].S_VOLTAGE\nmsg.topic = \"Source\"\nreturn msg","outputs":1,"noerr":0,"x":1097.5,"y":1662.449951171875,"wires":[["b11e4c35.c4a13"]]},{"id":"b11e4c35.c4a13","type":"delay","z":"43603a95.bb0adc","name":"","pauseType":"delay","timeout":"1","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":1265.5,"y":1702.449951171875,"wires":[["f9364c39.c7478"]]},{"id":"f9364c39.c7478","type":"ui_chart","z":"43603a95.bb0adc","name":"Voltage","group":"8d946075.edcb5","order":0,"width":0,"height":0,"label":"Volts","chartType":"line","legend":"true","xformat":"HH:mm:ss","interpolate":"linear","nodata":"","ymin":"","ymax":"","removeOlder":"1","removeOlderPoints":"","removeOlderUnit":"86400","cutout":0,"x":1462.5,"y":1634.5,"wires":[[],[]]},{"id":"809f5dff.76974","type":"file","z":"43603a95.bb0adc","name":"Dump Wind","filename":"/home/pi/charts/wind.dump","appendNewline":true,"createDir":true,"overwriteFile":"true","x":1785.5,"y":235.89999389648438,"wires":[]},{"id":"b08dedec.52757","type":"inject","z":"43603a95.bb0adc","name":"","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":true,"x":1041.5,"y":58.149993896484375,"wires":[["68f66c44.6de674"]]},{"id":"2cbf245f.7371ec","type":"json","z":"43603a95.bb0adc","name":"","x":1423.5,"y":171.4499969482422,"wires":[["3815badd.235a66"]]},{"id":"68f66c44.6de674","type":"file in","z":"43603a95.bb0adc","name":"Get Wind File","filename":"/home/pi/charts/wind.dump","format":"utf8","x":1211.5,"y":100.89999389648438,"wires":[["2cbf245f.7371ec"]]},{"id":"581e34c3.bad35c","type":"file","z":"43603a95.bb0adc","name":"Save Pressure","filename":"/home/pi/charts/pressure.dump","appendNewline":true,"createDir":true,"overwriteFile":"false","x":1623.5,"y":1260.9000244140625,"wires":[]},{"id":"db2e46ec.d05378","type":"inject","z":"43603a95.bb0adc","name":"","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":true,"x":864.5,"y":1298.14990234375,"wires":[["e3e10bee.fef3a8","6c3a6f8d.e09c4"]]},{"id":"e3e10bee.fef3a8","type":"file in","z":"43603a95.bb0adc","name":"Get Pressure File","filename":"/home/pi/charts/pressure.dump","format":"utf8","x":1058.5,"y":1314.89990234375,"wires":[["7eb3aa5a.f58c74"]]},{"id":"7eb3aa5a.f58c74","type":"json","z":"43603a95.bb0adc","name":"","x":1230.5,"y":1299.449951171875,"wires":[["5e2e3358.a9dfbc","ea6631fa.dc35e"]]},{"id":"9dd58b6b.cca498","type":"file","z":"43603a95.bb0adc","name":"Save Solar","filename":"/home/pi/charts/solar.dump","appendNewline":true,"createDir":true,"overwriteFile":"false","x":1629.5,"y":1374.89990234375,"wires":[]},{"id":"6c3a6f8d.e09c4","type":"file in","z":"43603a95.bb0adc","name":"Get Solar File","filename":"/home/pi/charts/solar.dump","format":"utf8","x":1060.5,"y":1361.89990234375,"wires":[["12e441d8.223a7e"]]},{"id":"12e441d8.223a7e","type":"json","z":"43603a95.bb0adc","name":"","x":1222.5,"y":1358.4500122070312,"wires":[["c4c5a3ad.66fdd"]]},{"id":"ea6631fa.dc35e","type":"debug","z":"43603a95.bb0adc","name":"","active":true,"console":"false","complete":"false","x":1432.5,"y":1328.300048828125,"wires":[]},{"id":"842d2fac.76659","type":"ui_group","z":"","name":"Default","tab":"922b2348.007c8","disp":true,"width":"6"},{"id":"ee7040c0.1be97","type":"MySQLdatabase","z":"","host":"10.0.1.40","port":"3306","db":"weather","tz":""},{"id":"a10448e8.913d58","type":"ui_group","z":"","name":"Wind","tab":"60becd33.3761d4","order":1,"disp":true,"width":"6"},{"id":"79c85dcd.3828b4","type":"ui_group","z":"","name":"Temperature","tab":"60becd33.3761d4","order":2,"disp":true,"width":"6"},{"id":"506eca8c.10fa34","type":"ui_group","z":"","name":"Pressure","tab":"60becd33.3761d4","order":3,"disp":true,"width":"6"},{"id":"8d946075.edcb5","type":"ui_group","z":"","name":"Station","tab":"60becd33.3761d4","order":6,"disp":true,"width":"6"},{"id":"d5b5cb3f.6b68a8","type":"ui_group","z":"","name":"Solar","tab":"60becd33.3761d4","order":5,"disp":true,"width":"6"},{"id":"4a00aeb0.fbb84","type":"ui_group","z":"","name":"Rain Today","tab":"60becd33.3761d4","order":4,"disp":true,"width":"6"},{"id":"922b2348.007c8","type":"ui_tab","z":"","name":"Test","icon":"dashboard","order":4},{"id":"60becd33.3761d4","type":"ui_tab","z":"","name":"Weather","icon":"dashboard","order":1}]
9thMile

Flow Info

created 1 month, 1 week ago

Node Types

Core
  • debug (x1)
  • delay (x6)
  • file (x3)
  • file in (x3)
  • function (x28)
  • inject (x6)
  • json (x3)
  • switch (x6)
Other

Tags

  • weather
  • mysql
  • dashboard
Copy this flow JSON to your clipboard and then import into Node-RED using the Import From > Clipboard (Ctrl-I) menu option