I came across similar trouble using serial (rs485) Modbus. Using several flex getter and flex write nodes is asking for instability. Better concentrate the Modbus communication in one flow. Use only one flex getter node and one flex write node in your system. For every command read or write you have to wait for the response before you can issue a next read or write command. This is essential for the reliability.
I use MQTT to communicate to the Modbus flow. The Modbus commands are queued and only after a command is processed the next command is released from the queue. I keep a queue of max 10 commands. There are no delays build in the communication itself so the command processing is always at maximum speed. Problems can occur when the line is broken but this will not cause trouble in the software. Once reconnected the system will smoothly continue again.
[{"id":"10bf8854.2715a8","type":"subflow","name":"Log telegram","info":"msg.payload = \"telegram message\"","category":"","in":[{"x":320,"y":180,"wires":[{"id":"a671d8a45d9081b5"}]}],"out":[],"env":[],"meta":{},"color":"#DDAA99"},{"id":"cbfc7c50.4160b","type":"mqtt out","z":"10bf8854.2715a8","name":"","topic":"notify_to_telegram","qos":"","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"ddcae42b.d2a648","x":1030,"y":180,"wires":[]},{"id":"c1a55339c5a25232","type":"change","z":"10bf8854.2715a8","name":"","rules":[{"t":"set","p":"topic","pt":"msg","to":"Bericht van uw Domotica systeem","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":790,"y":180,"wires":[["cbfc7c50.4160b"]]},{"id":"a671d8a45d9081b5","type":"simpletime","z":"10bf8854.2715a8","name":"dts","mydate":true,"myymd":false,"myyear":false,"mymonth":false,"mymonthn":false,"mydom":false,"mydoy":false,"myday":false,"myhourpm":false,"myhour":false,"mytime":true,"mytimes":false,"myminute":false,"myminutes":false,"mysecond":false,"mymillis":false,"myepoch":false,"myrawdate":false,"mypm":false,"x":470,"y":180,"wires":[["94b8fd1303b384d7"]]},{"id":"94b8fd1303b384d7","type":"function","z":"10bf8854.2715a8","name":"prep msg","func":"msg.payload = msg.mydate + \" \" + msg.mytime + \" \" + msg.payload; \nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":620,"y":180,"wires":[["c1a55339c5a25232"]]},{"id":"638a76dc.d3cf28","type":"subflow","name":"Log email","info":"msg.payload = \"email message\"","category":"","in":[{"x":240,"y":140,"wires":[{"id":"66e2850f.56402c"}]}],"out":[],"env":[],"meta":{},"color":"#DDAA99"},{"id":"66e2850f.56402c","type":"mqtt out","z":"638a76dc.d3cf28","name":"","topic":"notify_to_email","qos":"","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"ddcae42b.d2a648","x":520,"y":140,"wires":[]},{"id":"28322648.b9e59a","type":"subflow","name":"Log notification","info":"msg.payload = \"notification\"","category":"","in":[{"x":220,"y":120,"wires":[{"id":"f66b845a.608628"}]}],"out":[],"env":[],"meta":{},"color":"#DDAA99"},{"id":"f66b845a.608628","type":"mqtt out","z":"28322648.b9e59a","name":"Notification","topic":"notification","qos":"","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"ddcae42b.d2a648","x":450,"y":120,"wires":[]},{"id":"50764a8442578d57","type":"modbus-flex-getter","z":"b7c41944ac2e6897","name":"Modbus read","showStatusActivities":false,"showErrors":false,"showWarnings":true,"logIOActivities":false,"server":"7abf41938dcd043f","useIOFile":false,"ioFile":"","useIOForPayload":false,"emptyMsgOnFail":false,"keepMsgProperties":false,"delayOnStart":false,"startDelayTime":"","x":1190,"y":240,"wires":[["f355d90a46325cdd","0cfe9b4f60508e0e"],[]]},{"id":"995bc3172e02b7de","type":"function","z":"b7c41944ac2e6897","name":"Test FC","func":"if (msg.payload.fc <= 4)\n return ([msg, null]);\nelse\n return ([null, msg]);","outputs":2,"noerr":0,"initialize":"","finalize":"","libs":[],"x":960,"y":280,"wires":[["50764a8442578d57"],["bfa6470c8837d5b3"]]},{"id":"bfa6470c8837d5b3","type":"modbus-flex-write","z":"b7c41944ac2e6897","name":"Modbus write","showStatusActivities":false,"showErrors":false,"showWarnings":true,"server":"7abf41938dcd043f","emptyMsgOnFail":false,"keepMsgProperties":false,"delayOnStart":false,"startDelayTime":"","x":1190,"y":320,"wires":[["f355d90a46325cdd","0cfe9b4f60508e0e"],[]]},{"id":"560c13e77e569b2c","type":"function","z":"b7c41944ac2e6897","name":"Trigger sender","func":"msg.payload.device = flow.get('device');\nmsg.topic = flow.get('link');\nif (msg.hasOwnProperty ('responseBuffer')) {\n msg.payload = {};\n msg.payload.responseBuffer = msg.responseBuffer;\n msg.payload.device = flow.get('device');\n}\nif (flow.get ('q_status') === \"queue\") return [{ topic: \"control\", payload: \"trigger\" }, msg, msg];\nelse return [{ topic: \"control\", payload: \"open\" }, msg, msg];","outputs":3,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1480,"y":300,"wires":[["d6dfe994ca8d5c91"],["e7145ece35a12849"],["121cf92d1e53a65f"]]},{"id":"6c18635bb22b1392","type":"function","z":"b7c41944ac2e6897","name":"Reset retry trigger","func":"msg.reset = true;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":930,"y":220,"wires":[["0e82d5a35279eb24"]]},{"id":"0e82d5a35279eb24","type":"trigger","z":"b7c41944ac2e6897","name":"Retry","op1":"","op2":"","op1type":"pay","op2type":"pay","duration":"-5","extend":false,"overrideDelay":false,"units":"s","reset":"","bytopic":"all","topic":"topic","outputs":1,"x":790,"y":280,"wires":[["995bc3172e02b7de"]]},{"id":"d29d125c448855cd","type":"function","z":"b7c41944ac2e6897","name":"reset","func":"if (msg.payload === \"reset\") {\n msg.reset = true;\n return msg;\n}\nreturn null;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":430,"y":280,"wires":[["0e82d5a35279eb24","df76670751b34000"]]},{"id":"99fd05c58fc23c83","type":"function","z":"b7c41944ac2e6897","name":"queue","func":"return { topic: \"control\", payload: \"queue\" };","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":510,"y":340,"wires":[["40ee8e216cced271"]]},{"id":"e2353733815ddf2e","type":"trigger","z":"b7c41944ac2e6897","name":"","op1":"","op2":"reset","op1type":"nul","op2type":"str","duration":"-5","extend":false,"overrideDelay":false,"units":"min","reset":"","bytopic":"all","topic":"topic","outputs":1,"x":1490,"y":180,"wires":[["603bfb43948efa1b"]]},{"id":"f887e9ae8bd1b51b","type":"function","z":"b7c41944ac2e6897","name":"reset queue","func":"return { topic: \"control\", payload: \"reset\" };","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1710,"y":160,"wires":[["653900719ea0d554"]]},{"id":"4d24a679ade999c1","type":"link out","z":"b7c41944ac2e6897","name":"link out 13","mode":"link","links":["149e72d43db375ae","7461cb4e72f2ba99"],"x":1855,"y":140,"wires":[]},{"id":"149e72d43db375ae","type":"link in","z":"b7c41944ac2e6897","name":"link in 9","links":["90fecb8d8f6a8da6","4d24a679ade999c1","d6dfe994ca8d5c91"],"x":305,"y":420,"wires":[["40ee8e216cced271"]]},{"id":"d6dfe994ca8d5c91","type":"link out","z":"b7c41944ac2e6897","name":"link out 14","mode":"link","links":["149e72d43db375ae"],"x":1685,"y":260,"wires":[]},{"id":"121cf92d1e53a65f","type":"link out","z":"b7c41944ac2e6897","name":"link out 15","mode":"link","links":["7461cb4e72f2ba99"],"x":1685,"y":340,"wires":[]},{"id":"7461cb4e72f2ba99","type":"link in","z":"b7c41944ac2e6897","name":"link in 10","links":["4d24a679ade999c1","121cf92d1e53a65f"],"x":755,"y":220,"wires":[["6c18635bb22b1392"]]},{"id":"1ea7a838a29e58e9","type":"function","z":"b7c41944ac2e6897","name":"open queue","func":"return { topic: \"control\", payload: \"open\" };","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":2070,"y":180,"wires":[["90fecb8d8f6a8da6"]]},{"id":"f1a9550741cdf529","type":"delay","z":"b7c41944ac2e6897","name":"","pauseType":"delay","timeout":"2","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"allowrate":false,"outputs":1,"x":1900,"y":180,"wires":[["1ea7a838a29e58e9"]]},{"id":"90fecb8d8f6a8da6","type":"link out","z":"b7c41944ac2e6897","name":"link out 16","mode":"link","links":["149e72d43db375ae"],"x":2205,"y":180,"wires":[]},{"id":"df76670751b34000","type":"link out","z":"b7c41944ac2e6897","name":"link out 17","mode":"link","links":["e06e6cc699df0fd7"],"x":755,"y":60,"wires":[]},{"id":"e06e6cc699df0fd7","type":"link in","z":"b7c41944ac2e6897","name":"link in 11","links":["df76670751b34000"],"x":1525,"y":60,"wires":[["603bfb43948efa1b"]]},{"id":"02f6466dbd522429","type":"inject","z":"b7c41944ac2e6897","name":"Start","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":true,"onceDelay":"2","topic":"","payload":"","payloadType":"date","x":1210,"y":180,"wires":[["f355d90a46325cdd"]]},{"id":"40ee8e216cced271","type":"q-gate","z":"b7c41944ac2e6897","name":"Modbus cmd queue","controlTopic":"control","defaultState":"open","openCmd":"open","closeCmd":"close","toggleCmd":"toggle","queueCmd":"queue","defaultCmd":"default","triggerCmd":"trigger","flushCmd":"flush","resetCmd":"reset","peekCmd":"peek","dropCmd":"drop","statusCmd":"status","maxQueueLength":"10","keepNewest":true,"qToggle":true,"persist":true,"storeName":"storeOnSD","x":470,"y":420,"wires":[["0e82d5a35279eb24","e8f7b6ec728ae4b7","99fd05c58fc23c83"]]},{"id":"f1545e03d0ffeda9","type":"function","z":"b7c41944ac2e6897","name":"if queuing = 0 ==> open","func":"if (msg.status.text === \"queuing: 0\") {flow.set('q_status', 'open'); node.status (\"\")} else flow.set('q_status', 'queue'); \nif (msg.status.text === \"queuing: 10\") {\n msg.payload = \"Modbus communicatie gestopt\";\n node.status (\"Modbus comm failure\");\n return msg;\n};\nreturn null;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":670,"y":520,"wires":[["d804570b3db34b39"]]},{"id":"e8f7b6ec728ae4b7","type":"function","z":"b7c41944ac2e6897","name":"Keep msg link","func":"flow.set('link', msg.payload.link);\nflow.set('device', msg.payload.device);\nreturn null;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":760,"y":420,"wires":[[]]},{"id":"8f163902463e194c","type":"mqtt in","z":"b7c41944ac2e6897","name":"Modbus","topic":"modbus_action","qos":"2","datatype":"auto-detect","broker":"ddcae42b.d2a648","nl":false,"rap":true,"rh":0,"inputs":0,"x":140,"y":280,"wires":[["4090dc1b2d84e5cc"]]},{"id":"e7145ece35a12849","type":"mqtt out","z":"b7c41944ac2e6897","name":"Modbus out","topic":"","qos":"","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"ddcae42b.d2a648","x":2150,"y":300,"wires":[]},{"id":"3b03e7f983d4c819","type":"status","z":"b7c41944ac2e6897","name":"Queue status","scope":["40ee8e216cced271"],"x":450,"y":520,"wires":[["f1545e03d0ffeda9"]]},{"id":"0b6e135ba0a202a2","type":"subflow:28322648.b9e59a","z":"b7c41944ac2e6897","name":"","x":1120,"y":480,"wires":[]},{"id":"dec3b55cce8212e8","type":"subflow:638a76dc.d3cf28","z":"b7c41944ac2e6897","name":"","x":1100,"y":520,"wires":[]},{"id":"20495cf3f956580c","type":"subflow:10bf8854.2715a8","z":"b7c41944ac2e6897","name":"","x":1110,"y":560,"wires":[]},{"id":"d804570b3db34b39","type":"trigger","z":"b7c41944ac2e6897","name":"","op1":"","op2":"","op1type":"pay","op2type":"nul","duration":"1","extend":true,"overrideDelay":false,"units":"hr","reset":"","bytopic":"all","topic":"topic","outputs":1,"x":880,"y":520,"wires":[["02e4db45f9aafa7a"]]},{"id":"10bf0aed4eab82a6","type":"inject","z":"b7c41944ac2e6897","name":"Start","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":true,"onceDelay":"2","topic":"","payload":"","payloadType":"date","x":1490,"y":120,"wires":[["603bfb43948efa1b"]]},{"id":"4090dc1b2d84e5cc","type":"junction","z":"b7c41944ac2e6897","x":250,"y":280,"wires":[["40ee8e216cced271","d29d125c448855cd"]]},{"id":"603bfb43948efa1b","type":"junction","z":"b7c41944ac2e6897","x":1620,"y":160,"wires":[["f887e9ae8bd1b51b"]]},{"id":"653900719ea0d554","type":"junction","z":"b7c41944ac2e6897","x":1800,"y":160,"wires":[["4d24a679ade999c1","f1a9550741cdf529"]]},{"id":"f355d90a46325cdd","type":"junction","z":"b7c41944ac2e6897","x":1370,"y":180,"wires":[["e2353733815ddf2e"]]},{"id":"0cfe9b4f60508e0e","type":"junction","z":"b7c41944ac2e6897","x":1370,"y":300,"wires":[["560c13e77e569b2c"]]},{"id":"02e4db45f9aafa7a","type":"junction","z":"b7c41944ac2e6897","x":980,"y":520,"wires":[["0b6e135ba0a202a2","dec3b55cce8212e8","20495cf3f956580c"]]},{"id":"7abf41938dcd043f","type":"modbus-client","name":"Modbus USB","clienttype":"serial","bufferCommands":true,"stateLogEnabled":false,"queueLogEnabled":false,"failureLogEnabled":true,"tcpHost":"127.0.0.1","tcpPort":"502","tcpType":"DEFAULT","serialPort":"$(MODBUSPORT)","serialType":"RTU-BUFFERD","serialBaudrate":"9600","serialDatabits":"8","serialStopbits":"1","serialParity":"none","serialConnectionDelay":"100","serialAsciiResponseStartDelimiter":"0x3A","unit_id":1,"commandDelay":15,"clientTimeout":1000,"reconnectOnTimeout":true,"reconnectTimeout":2000,"parallelUnitIdsAllowed":false,"showWarnings":true,"showLogs":true},{"id":"ddcae42b.d2a648","type":"mqtt-broker","name":"MQTT-broker","broker":"localhost","port":"1883","clientid":"","autoConnect":true,"usetls":false,"protocolVersion":"4","keepalive":"60","cleansession":true,"birthTopic":"","birthQos":"0","birthPayload":"","birthMsg":{},"closeTopic":"","closeQos":"0","closePayload":"","closeMsg":{},"willTopic":"","willQos":"0","willPayload":"","willMsg":{},"userProps":"","sessionExpiry":""}]