I have recently connected two Carrier chillers (unit ID: 32 and unit ID 6) via Modbus RTU to a Pi running Node-RED. The physical wiring is shown below. This is RS485 to USB adapter that I am using.
My flow is quite simple and attached here. I am polling both units using one inject node every 60 seconds and trying to get 3 values from each chiller ( addresses 16393,16394, 16395, which correspond to setpoint, entering fluid temperature, and leaving fluid temperature.
Below is a plot from Grafana showing the irregular nature of the readings. Sometimes Chiller 6 has no readings (underlined in red), while Chiller #32 does. I reversed my nodes (so that it would poll #6 first, then #32), and found the opposite in Grafana, i.e. there would be "gaps" in #32's data.
Other times, it seems the modbus data is completely skipped (you should see 10 dots in each 10 minute interval, and you can see usually 1 or more is missing, as underlined in yellow).
[{"id":"8760ce25e90c533a","type":"modbus-flex-getter","z":"6c39e39024574678","name":"","showStatusActivities":false,"showErrors":false,"logIOActivities":false,"server":"9ab875472411c19f","useIOFile":false,"ioFile":"","useIOForPayload":false,"emptyMsgOnFail":false,"keepMsgProperties":false,"x":510,"y":100,"wires":[["c98b1d1c3bbdca4e"],[]]},{"id":"586eae9839f9f12a","type":"function","z":"6c39e39024574678","name":"Chiller 6","func":"msg.topic = \"chiller_6\"\n\nmsg.payload = {\n value: msg.payload,\n 'fc': 4,\n 'unitid': 6,\n 'address': 16393,\n 'quantity': 3\n}\n\nreturn msg","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":300,"y":100,"wires":[["8760ce25e90c533a"]]},{"id":"5f2dde25fa1ad10e","type":"inject","z":"6c39e39024574678","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"60","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":110,"y":40,"wires":[["1f5725f199c175c9"]]},{"id":"c98b1d1c3bbdca4e","type":"debug","z":"6c39e39024574678","name":"chiller_6","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":720,"y":100,"wires":[]},{"id":"2a45711de6cd2c91","type":"modbus-flex-getter","z":"6c39e39024574678","name":"","showStatusActivities":false,"showErrors":false,"logIOActivities":false,"server":"9ab875472411c19f","useIOFile":false,"ioFile":"","useIOForPayload":false,"emptyMsgOnFail":false,"keepMsgProperties":false,"x":530,"y":40,"wires":[["485a1917dc1cb621","586eae9839f9f12a"],[]]},{"id":"1f5725f199c175c9","type":"function","z":"6c39e39024574678","name":"Chiller 32","func":"msg.topic = \"chiller_32\"\n\nmsg.payload = {\n value: msg.payload,\n 'fc': 4,\n 'unitid': 32,\n 'address': 16393,\n 'quantity': 3\n}\n\nreturn msg","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":300,"y":40,"wires":[["2a45711de6cd2c91"]]},{"id":"485a1917dc1cb621","type":"debug","z":"6c39e39024574678","name":"chiller_32","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":740,"y":40,"wires":[]},{"id":"9ab875472411c19f","type":"modbus-client","name":"","clienttype":"serial","bufferCommands":true,"stateLogEnabled":false,"queueLogEnabled":false,"failureLogEnabled":true,"tcpHost":"127.0.0.1","tcpPort":"502","tcpType":"DEFAULT","serialPort":"/dev/ttyUSB0","serialType":"RTU","serialBaudrate":"19200","serialDatabits":"8","serialStopbits":"1","serialParity":"none","serialConnectionDelay":"2000","serialAsciiResponseStartDelimiter":"0x3A","unit_id":"","commandDelay":50,"clientTimeout":2000,"reconnectOnTimeout":false,"reconnectTimeout":2000,"parallelUnitIdsAllowed":false}]
Is anyone aware of some tweaks to the settings that I can make to get some repeatability here? I do not have to poll every 60 seconds. It could be every 90 seconds, but I do not think that is the problem.
Thanks in advance.