Hi, I am trying to monitor modbus register values with library "node-red-contrib-modbus". Although it works just fine but the issue is that, whenever there is a long disconnection time, let's say hours. My modbus nodes do not reconnect with the PLC hence showing reconnecting but not getting connected.In order to retain connection I have to Restart all flows.
Attached is my current flow
[{"id":"4a09007c.72828","type":"ui_gauge","z":"677d8905.de2b08","name":"","group":"e15b0c94.455b6","order":1,"width":0,"height":0,"gtype":"donut","title":"Simporter Main Belt Current","label":"Amps","format":"{{value}}","min":0,"max":"200","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":660,"y":20,"wires":[]},{"id":"1cbbb40.8c3c94c","type":"function","z":"677d8905.de2b08","name":"","func":"msg.payload= msg.payload;\n return[msg,null];","outputs":1,"noerr":0,"initialize":"","finalize":"","x":380,"y":20,"wires":[["4a09007c.72828"]]},{"id":"fcc1016e.0a7e9","type":"function","z":"677d8905.de2b08","name":"","func":"msg.payload= msg.payload/10;\n return[msg,null];","outputs":1,"noerr":0,"initialize":"","finalize":"","x":380,"y":80,"wires":[["144885d3.7039ea"]]},{"id":"144885d3.7039ea","type":"ui_gauge","z":"677d8905.de2b08","name":"","group":"e15b0c94.455b6","order":3,"width":0,"height":0,"gtype":"donut","title":"Simporter Central Feeder Current","label":"Amps","format":"{{value}}","min":0,"max":"100","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":660,"y":80,"wires":[]},{"id":"1f02c1ef.f75f5e","type":"function","z":"677d8905.de2b08","name":"","func":"msg.payload= msg.payload/10;\n return[msg,null];","outputs":1,"noerr":0,"initialize":"","finalize":"","x":360,"y":160,"wires":[["21c18e55.f5de02"]]},{"id":"21c18e55.f5de02","type":"ui_gauge","z":"677d8905.de2b08","name":"","group":"e15b0c94.455b6","order":2,"width":0,"height":0,"gtype":"donut","title":"Simporter External Feeder Current","label":"Amps","format":"{{value}}","min":0,"max":"100","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":720,"y":160,"wires":[]},{"id":"a54d6b37.772a58","type":"ui_gauge","z":"677d8905.de2b08","name":"","group":"7c1d895d.4278f8","order":1,"width":0,"height":0,"gtype":"donut","title":"Simporter Main Belt Freq.","label":"Hz","format":"{{value}}","min":0,"max":"70","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":670,"y":280,"wires":[]},{"id":"74e3d08.7de5d3","type":"function","z":"677d8905.de2b08","name":"","func":"msg.payload= msg.payload/10;\n return[msg,null];","outputs":1,"noerr":0,"initialize":"","finalize":"","x":390,"y":280,"wires":[["a54d6b37.772a58"]]},{"id":"410ad4d.234442c","type":"function","z":"677d8905.de2b08","name":"","func":"msg.payload= msg.payload/10;\n return[msg,null];","outputs":1,"noerr":0,"initialize":"","finalize":"","x":360,"y":340,"wires":[["a38c8d42.00acb"]]},{"id":"a38c8d42.00acb","type":"ui_gauge","z":"677d8905.de2b08","name":"","group":"7c1d895d.4278f8","order":2,"width":0,"height":0,"gtype":"donut","title":"Simporter External Feeder Freq.","label":"Hz","format":"{{value}}","min":0,"max":"70","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":670,"y":340,"wires":[]},{"id":"814fee4e.25eb5","type":"function","z":"677d8905.de2b08","name":"","func":"msg.payload= msg.payload/10;\n return[msg,null];","outputs":1,"noerr":0,"initialize":"","finalize":"","x":340,"y":220,"wires":[["dc8c1dfc.c2534"]]},{"id":"dc8c1dfc.c2534","type":"ui_gauge","z":"677d8905.de2b08","name":"","group":"7c1d895d.4278f8","order":3,"width":0,"height":0,"gtype":"donut","title":"Simporter Central Feeder Freq.","label":"Hz","format":"{{value}}","min":0,"max":"70","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":670,"y":220,"wires":[]},{"id":"e3f91e3e.8ae5e","type":"modbus-read","z":"677d8905.de2b08","name":"Simporter PLC","topic":"","showStatusActivities":false,"logIOActivities":false,"showErrors":false,"unitid":"","dataType":"HoldingRegister","adr":"4111","quantity":"1","rate":"500","rateUnit":"ms","delayOnStart":false,"startDelayTime":"","server":"68b35801.5c2f08","useIOFile":false,"ioFile":"","useIOForPayload":false,"emptyMsgOnFail":true,"x":120,"y":20,"wires":[["1cbbb40.8c3c94c"],[]]},{"id":"d55b483b.a74da8","type":"modbus-read","z":"677d8905.de2b08","name":"Simporter PLC","topic":"","showStatusActivities":false,"logIOActivities":false,"showErrors":false,"unitid":"","dataType":"HoldingRegister","adr":"4118","quantity":"1","rate":"500","rateUnit":"ms","delayOnStart":false,"startDelayTime":"","server":"68b35801.5c2f08","useIOFile":false,"ioFile":"","useIOForPayload":false,"emptyMsgOnFail":true,"x":120,"y":80,"wires":[["fcc1016e.0a7e9"],[]]},{"id":"d73847c3.5cdcf8","type":"modbus-read","z":"677d8905.de2b08","name":"Simporter PLC","topic":"","showStatusActivities":false,"logIOActivities":false,"showErrors":false,"unitid":"","dataType":"HoldingRegister","adr":"4136","quantity":"1","rate":"500","rateUnit":"ms","delayOnStart":false,"startDelayTime":"","server":"68b35801.5c2f08","useIOFile":false,"ioFile":"","useIOForPayload":false,"emptyMsgOnFail":true,"x":120,"y":140,"wires":[["1f02c1ef.f75f5e"],[]]},{"id":"ec4ee7dc.6f8358","type":"modbus-read","z":"677d8905.de2b08","name":"Simporter PLC Main Belt (Hz)","topic":"","showStatusActivities":false,"logIOActivities":false,"showErrors":false,"unitid":"","dataType":"HoldingRegister","adr":"4126","quantity":"1","rate":"500","rateUnit":"ms","delayOnStart":false,"startDelayTime":"","server":"68b35801.5c2f08","useIOFile":false,"ioFile":"","useIOForPayload":false,"emptyMsgOnFail":true,"x":140,"y":280,"wires":[["74e3d08.7de5d3"],[]]},{"id":"ac72652e.5d3ef8","type":"modbus-read","z":"677d8905.de2b08","name":"Simporter PLC External(Hz)","topic":"","showStatusActivities":false,"logIOActivities":false,"showErrors":false,"unitid":"","dataType":"HoldingRegister","adr":"4127","quantity":"1","rate":"500","rateUnit":"ms","delayOnStart":false,"startDelayTime":"","server":"68b35801.5c2f08","useIOFile":false,"ioFile":"","useIOForPayload":false,"emptyMsgOnFail":true,"x":120,"y":360,"wires":[["410ad4d.234442c"],[]]},{"id":"5a186e34.ef817","type":"modbus-read","z":"677d8905.de2b08","name":"Simporter PLC Centeral (Hz)","topic":"","showStatusActivities":false,"logIOActivities":false,"showErrors":false,"unitid":"","dataType":"HoldingRegister","adr":"4128","quantity":"1","rate":"500","rateUnit":"ms","delayOnStart":false,"startDelayTime":"","server":"68b35801.5c2f08","useIOFile":false,"ioFile":"","useIOForPayload":false,"emptyMsgOnFail":true,"x":120,"y":220,"wires":[["814fee4e.25eb5"],[]]},{"id":"e15b0c94.455b6","type":"ui_group","name":"Current Rate","tab":"6572373e.e86d98","order":1,"disp":true,"width":"6","collapse":false},{"id":"7c1d895d.4278f8","type":"ui_group","name":"Frequency Rate","tab":"6572373e.e86d98","order":2,"disp":true,"width":"6","collapse":false},{"id":"68b35801.5c2f08","type":"modbus-client","name":"Simporter PLC","clienttype":"tcp","bufferCommands":false,"stateLogEnabled":false,"queueLogEnabled":false,"tcpHost":"192.50.100.160","tcpPort":"502","tcpType":"DEFAULT","serialPort":"/dev/ttyUSB","serialType":"RTU-BUFFERD","serialBaudrate":"9600","serialDatabits":"8","serialStopbits":"1","serialParity":"none","serialConnectionDelay":"100","unit_id":"1","commandDelay":"1","clientTimeout":"12000","reconnectOnTimeout":true,"reconnectTimeout":"5000","parallelUnitIdsAllowed":false},{"id":"6572373e.e86d98","type":"ui_tab","name":"SIMPORTER","icon":"dashboard","disabled":false,"hidden":false}]