Hi guys,
I’m observing frequent modbus communication errors and I’d like to understand how to manage them from the automation level.
Such an error is becoming really frequent, so a good point could be understanding why it happens, but, of course, also how to manage and restart the system to make the connection available again.
This is the error:
I’m assuming that perhaps you are either too fast at polling or you are getting occasional corruption.
I think the modbus options for the modbus component can be modified to slow down or handle errors more gracefully.
I don’t remember the options at the moment. Are you receiving the expected register information? If you are and the error is occasionally occurring, then I suspect one or the other is happening.
Thanks for the interest swill008!
With regards the first problem, I understand that it is a USB connection error… I have to understand how to restart the driver in that case.
With regards the second one, I have those random errors on the communication related to different devices (9 devices connected to the hub). This happens after a while.
You say polling time… Maybe.
But I don’t understand how the HA modbus component manages the queue and the channel, so I’m not able to apply a correction.
Is the channel open/closed or is it always open? There is a way to change that behaviour?
My entities requests the state every 15 seconds, is it too fast?
I have same problem you described:
2024-02-10 21:26:09.034 ERROR (SyncWorker_8) [homeassistant.components.modbus.modbus] Pymodbus: SungrowSHx: Error: device: 1 address: 5725 → pymodbus returned isError True
Every 10 seconds, for different addresses.
Have you found a solution for this in the meantime?
Thanks in advance for any feedback.
Home Assistant
Core 2024.2.1
Supervisor 2024.01.1
Operating System 11.5
Frontend 20240207.1
I think I answered it myself.
My integration file contains queries for my inverter, which presumably cannot exist there yet because the system is too new:
Annual kWH export, months March to December, etc.