Difference between revisions of "Monitoring Water Hammer"
Line 5: | Line 5: | ||
DP is required to make water flow, but too much will damage equipment. | DP is required to make water flow, but too much will damage equipment. | ||
One of the major problems with current BMS systems is there speed - they are far too slow to spot spikes in pressure. BMS systems typically report values every 15 minutes, so trying to understand an event that may last only 0.5s is impossible. | One of the major problems with current BMS systems is there speed - they are far too slow to spot spikes in pressure. BMS systems typically report values every 15 minutes, so trying to understand an event that may last only 0.5s is impossible. The image below is from a typical BMS system, where the frequency of data logging is far too slow to catch hammer events. From this data everything looks fine, with DP controlled to targets. But the important problems are hidden - on this site something is forcing valves to let by. | ||
[[File:Dpgraphtrend.jpg|frameless|510x510px]] | |||
On the same site we then fitted our open source controls, with resolution down to 1s, and we saw this. A 10 bar spike in DP - far in excess of equipment ratings. | |||
[[File:Dpmon2.png|frameless|1054x1054px]] | |||
In close-up the spike lasts a fraction of a second, and even at 1s resolution we are lucky to catch it. | |||
[[File:Dpmon3.png|frameless|1056x1056px]] | |||
In response, the logging was increased to 1/10th of a second. This is too rapid for discrete values to be communicated, so instead we select to store values into a shift register of 50 values (5s) and send this out as a complete CSV file when a spike is detected. | |||
We then waited for another event. | |||
The flow below runs on a standard Heatweb open controller, and monitors differential pressures at 0.1s intervals. When pressure out of limits is detected, 50 consecutive readings (5 seconds worth) are emailed to engineers concerned for record and analysis, with the spike positioned in the middle of the data so we can see climb and fall in pressure. | The flow below runs on a standard Heatweb open controller, and monitors differential pressures at 0.1s intervals. When pressure out of limits is detected, 50 consecutive readings (5 seconds worth) are emailed to engineers concerned for record and analysis, with the spike positioned in the middle of the data so we can see climb and fall in pressure. | ||
Line 11: | Line 28: | ||
When performing such fine detailed analysis it is important to manage data. Nobody wants 10 readings a second, every second, when things are fine - it simply overloads databases. Using the open controls software it is straightforward to attach conditions when and where to send what data. In this example we send data every minute, if it changes by more than 0.03 bar, or if pressure spikes over 3 bar you get the 5 second rapid data in an email. | When performing such fine detailed analysis it is important to manage data. Nobody wants 10 readings a second, every second, when things are fine - it simply overloads databases. Using the open controls software it is straightforward to attach conditions when and where to send what data. In this example we send data every minute, if it changes by more than 0.03 bar, or if pressure spikes over 3 bar you get the 5 second rapid data in an email. | ||
Revision as of 14:45, 29 July 2022
Monitoring differential pressure is one of the most critical functions in any heat or plumbing network.
DP is required to make water flow, but too much will damage equipment.
One of the major problems with current BMS systems is there speed - they are far too slow to spot spikes in pressure. BMS systems typically report values every 15 minutes, so trying to understand an event that may last only 0.5s is impossible. The image below is from a typical BMS system, where the frequency of data logging is far too slow to catch hammer events. From this data everything looks fine, with DP controlled to targets. But the important problems are hidden - on this site something is forcing valves to let by.
On the same site we then fitted our open source controls, with resolution down to 1s, and we saw this. A 10 bar spike in DP - far in excess of equipment ratings.
In close-up the spike lasts a fraction of a second, and even at 1s resolution we are lucky to catch it.
In response, the logging was increased to 1/10th of a second. This is too rapid for discrete values to be communicated, so instead we select to store values into a shift register of 50 values (5s) and send this out as a complete CSV file when a spike is detected.
We then waited for another event.
The flow below runs on a standard Heatweb open controller, and monitors differential pressures at 0.1s intervals. When pressure out of limits is detected, 50 consecutive readings (5 seconds worth) are emailed to engineers concerned for record and analysis, with the spike positioned in the middle of the data so we can see climb and fall in pressure.
When performing such fine detailed analysis it is important to manage data. Nobody wants 10 readings a second, every second, when things are fine - it simply overloads databases. Using the open controls software it is straightforward to attach conditions when and where to send what data. In this example we send data every minute, if it changes by more than 0.03 bar, or if pressure spikes over 3 bar you get the 5 second rapid data in an email.
[{"id":"a4555f90.bc099","type":"debug","z":"20ef9fcd.7fd3e","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":770,"y":820,"wires":[]},{"id":"fa605d28.a8016","type":"exec","z":"20ef9fcd.7fd3e","command":"megabas 1 adcrd 1","addpay":false,"append":"","useSpawn":"false","timer":"","oldrc":false,"name":"","x":450,"y":360,"wires":[["361e118e.c4b09e","ef54aa54.bad3b8"],[],[]]},{"id":"c09c46bc.52a7a8","type":"inject","z":"20ef9fcd.7fd3e","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"1","crontab":"","once":true,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":110,"y":360,"wires":[["fa605d28.a8016","97a86b74.673b68","bc7c61b1.ad469","f998aa12.cbbb78","8ef93264.96464","5502ed9e.cef0f4","6b208cff.2ea034","9d7267a6.4c2658","8709f44e.8367e8","ec133ec0.68744"]]},{"id":"394ca40d.a5fdec","type":"delay","z":"20ef9fcd.7fd3e","name":"","pauseType":"delay","timeout":"5","timeoutUnits":"milliseconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":210,"y":820,"wires":[["f42ce7ae.5410b8"]]},{"id":"f4eb6a8b.20e0e8","type":"exec","z":"20ef9fcd.7fd3e","command":" megabas 1 wdtr","addpay":false,"append":"","useSpawn":"false","timer":"","oldrc":false,"name":"","x":580,"y":820,"wires":[["a4555f90.bc099"],[],[]]},{"id":"361e118e.c4b09e","type":"debug","z":"20ef9fcd.7fd3e","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":670,"y":400,"wires":[]},{"id":"f42ce7ae.5410b8","type":"trigger","z":"20ef9fcd.7fd3e","name":"","op1":"1","op2":"","op1type":"str","op2type":"nul","duration":"20","extend":false,"overrideDelay":false,"units":"s","reset":"","bytopic":"all","topic":"topic","outputs":1,"x":390,"y":820,"wires":[["f4eb6a8b.20e0e8"]]},{"id":"2ac0c301.03445c","type":"switch","z":"20ef9fcd.7fd3e","name":"","property":"payload","propertyType":"msg","rules":[{"t":"gt","v":"11","vt":"str"},{"t":"else"}],"checkall":"false","repair":false,"outputs":2,"x":830,"y":440,"wires":[[],["375f50a7.2e649"]]},{"id":"375f50a7.2e649","type":"range","z":"20ef9fcd.7fd3e","minin":"0","maxin":"10","minout":"0","maxout":"10","action":"scale","round":false,"property":"payload","name":"","x":970,"y":420,"wires":[["9fd24d04.fbce7"]]},{"id":"9fd24d04.fbce7","type":"function","z":"20ef9fcd.7fd3e","name":"","func":"msg.payload = parseInt(msg.payload*100)/100;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1120,"y":420,"wires":[["c5f23d0e.7d7e4","a4829c9f.6dc1f"]]},{"id":"25c7011b.6ecaae","type":"link out","z":"20ef9fcd.7fd3e","name":"","links":["72fc070f.39dd8","b6a889ac.229498"],"x":1495,"y":360,"wires":[]},{"id":"ef54aa54.bad3b8","type":"function","z":"20ef9fcd.7fd3e","name":"","func":"msg.topic=\"dat/dp1\";\nmsg2={};\nmsg2.topic=\"ana/v1\";\nmsg2.payload = 1*msg.payload;\nreturn [msg,msg2];","outputs":2,"noerr":0,"initialize":"","finalize":"","libs":[],"x":680,"y":460,"wires":[["2ac0c301.03445c"],["48ce857b.9506cc"]]},{"id":"48ce857b.9506cc","type":"link out","z":"20ef9fcd.7fd3e","d":true,"name":"","links":["72fc070f.39dd8"],"x":815,"y":500,"wires":[]},{"id":"c5f23d0e.7d7e4","type":"rbe","z":"20ef9fcd.7fd3e","name":"","func":"deadbandEq","gap":"0.03","start":"","inout":"out","septopics":true,"property":"payload","x":1240,"y":360,"wires":[["82893acd.651698"]]},{"id":"2108ba5e.78c9f6","type":"inject","z":"20ef9fcd.7fd3e","name":"","props":[{"p":"reset","v":"1","vt":"str"}],"repeat":"60","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":990,"y":360,"wires":[["c5f23d0e.7d7e4"]]},{"id":"82893acd.651698","type":"switch","z":"20ef9fcd.7fd3e","name":"","property":"reset","propertyType":"msg","rules":[{"t":"null"}],"checkall":"true","repair":false,"outputs":1,"x":1390,"y":360,"wires":[["25c7011b.6ecaae"]]},{"id":"97a86b74.673b68","type":"delay","z":"20ef9fcd.7fd3e","name":"","pauseType":"delay","timeout":"100","timeoutUnits":"milliseconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":210,"y":420,"wires":[["fa605d28.a8016"]]},{"id":"bc7c61b1.ad469","type":"delay","z":"20ef9fcd.7fd3e","name":"","pauseType":"delay","timeout":"400","timeoutUnits":"milliseconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":210,"y":540,"wires":[["fa605d28.a8016"]]},{"id":"f998aa12.cbbb78","type":"delay","z":"20ef9fcd.7fd3e","name":"","pauseType":"delay","timeout":"600","timeoutUnits":"milliseconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":210,"y":620,"wires":[["fa605d28.a8016"]]},{"id":"8ef93264.96464","type":"delay","z":"20ef9fcd.7fd3e","name":"","pauseType":"delay","timeout":"900","timeoutUnits":"milliseconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":210,"y":740,"wires":[["394ca40d.a5fdec","fa605d28.a8016"]]},{"id":"5502ed9e.cef0f4","type":"delay","z":"20ef9fcd.7fd3e","name":"","pauseType":"delay","timeout":"200","timeoutUnits":"milliseconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":210,"y":460,"wires":[["fa605d28.a8016"]]},{"id":"6b208cff.2ea034","type":"delay","z":"20ef9fcd.7fd3e","name":"","pauseType":"delay","timeout":"300","timeoutUnits":"milliseconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":210,"y":500,"wires":[["fa605d28.a8016"]]},{"id":"9d7267a6.4c2658","type":"delay","z":"20ef9fcd.7fd3e","name":"","pauseType":"delay","timeout":"500","timeoutUnits":"milliseconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":210,"y":580,"wires":[["fa605d28.a8016"]]},{"id":"8709f44e.8367e8","type":"delay","z":"20ef9fcd.7fd3e","name":"","pauseType":"delay","timeout":"700","timeoutUnits":"milliseconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":210,"y":660,"wires":[["fa605d28.a8016"]]},{"id":"ec133ec0.68744","type":"delay","z":"20ef9fcd.7fd3e","name":"","pauseType":"delay","timeout":"800","timeoutUnits":"milliseconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":210,"y":700,"wires":[["fa605d28.a8016"]]},{"id":"a4829c9f.6dc1f","type":"function","z":"20ef9fcd.7fd3e","name":"","func":"var reads50 = flow.get(\"reads50\")||[];\n\nreads50.push(msg.payload);\n\nif (reads50.length > 50) { reads50.shift(); }\n\nflow.set(\"reads50\",reads50);\n\n\nif (reads50[25]) { \n \n if (reads50[25]>3) { \n \n msg.payload = JSON.stringify(reads50);\n return msg;\n }\n}\n\nreturn null;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1300,"y":460,"wires":[["bacde7bc.b26978","419d3ccf.e240c4"]]},{"id":"bacde7bc.b26978","type":"debug","z":"20ef9fcd.7fd3e","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":1480,"y":440,"wires":[]},{"id":"4d64ef54.e4ec9","type":"function","z":"20ef9fcd.7fd3e","name":"attach","func":"var nw = \"fast_dp_\" + global.get(\"Nodeware\") || \"\";\nmsg.attachments = [{ // utf-8 string as an attachment \n filename: nw + '.json',\n content : msg.payload\n }];\n\n\nmsg.payload=\"DP Fast Readings from \"+global.get(\"node\");\nmsg.topic=\"DP Fast Readings from \"+global.get(\"node\");\n\nmsg.to=\"admin@heatweb.com, martin@carbonalternatives.com\";\n\n\nreturn msg;\n\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1530,"y":520,"wires":[["b2ab577e.eda598"]]},{"id":"b2ab577e.eda598","type":"link out","z":"20ef9fcd.7fd3e","name":"","links":["4bf50365.a06d4c","a1744584.91173"],"x":1635,"y":520,"wires":[]},{"id":"419d3ccf.e240c4","type":"trigger","z":"20ef9fcd.7fd3e","name":"","op1":"","op2":"","op1type":"pay","op2type":"nul","duration":"1","extend":false,"overrideDelay":false,"units":"min","reset":"","bytopic":"all","topic":"topic","outputs":1,"x":1370,"y":520,"wires":[["4d64ef54.e4ec9"]]},{"id":"35c4abbf.f68cb4","type":"inject","z":"20ef9fcd.7fd3e","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"6","payloadType":"num","x":1130,"y":480,"wires":[["a4829c9f.6dc1f"]]}]