I’m reading several MODBUS variables from 4 devices every 10 seconds with no errors.
I’m sending these variables to a MQTT server every 60 seconds but, for unknown reasons, some routers (same model) avoid some fields just sometimes:
Complete message:
[{“V_l1”:“2431”,“date”:“08/10/2026 13:22:48”},{“V_l2”:“2379”,“date”:“08/10/2026 13:22:48”},{“V_l3”:“2354”,“date”:“08/10/2026 13:22:48”},{“I_l1”:“0”,“date”:“08/10/2026 13:22:48”},{“I_l2”:“100”,“date”:“08/10/2026 13:22:50”},{“I_l3”:“0”,“date”:“08/10/2026 13:22:52”},{“activePower”:“0”,“date”:“08/10/2026 13:22:54”},{“activeEnergy”:“3313”,“date”:“08/10/2026 13:22:56”}]
The MQTT server sometimes receives messages with missing fields:
[{“I_l1”:“0”,“date”:“08/10/2026 13:18:10”},{“I_l2”:“0”,“date”:“08/10/2026 13:18:12”},{“I_l3”:“0”,“date”:“08/10/2026 13:18:14”},{“activePower”:“0”,“date”:“08/10/2026 13:18:17”}]
[{“activeEnergy”:“7”,“date”:“08/10/2026 13:19:09”},{“V_l1”:“2319”,“date”:“08/10/2026 13:19:11”},{“V_l2”:“2286”,“date”:“08/10/2026 13:19:13”},{“V_l3”:“2333”,“date”:“08/10/2026 13:19:15”},{“I_l1”:“0”,“date”:“08/10/2026 13:19:17”}]
How can I avoid this strange problem? Is there any recommendation about MODBUS vs MQTT period?
Thanks in advance.
Edit: it looks that these messages contain the tail of the previous message and the head of the next message.


