Requirements:
- Read the same register/parameter from each slave (IDs 1 → 100)
- Optimize the flow for low CPU utilization
- Ensure efficient polling (avoid unnecessary load or blocking)
- Insert/store each slave’s data into an SQL database
Current Challenges:
- Polling all 100 slaves efficiently without overloading CPU
- Managing timing / scheduling between requests
- Structuring the flow to scale cleanly
- Handling database writes without creating bottlenecks
Questions:
- What is the best approach to iterate through slave IDs (1–100) efficiently in Node-RED?
- Should I use a loop (function node) or split messages with delay/rate limiting?
- Is there a recommended pattern for Modbus polling (sequential vs parallel)?
- How can I batch or optimize SQL inserts for better performance?
- Any best practices for reducing CPU usage in such flows?
Additional Info:
- Using Modbus TCP
- Same register address for all slaves
- Open to using contrib nodes or custom function logic
Any examples, flow designs, or recommendations would be really helpful.
Thanks in advance!