Logic Machine Forum
Modbus TCP/IP timeout error - Printable Version

+- Logic Machine Forum (https://forum.logicmachine.net)
+-- Forum: LogicMachine eco-system (https://forum.logicmachine.net/forumdisplay.php?fid=1)
+--- Forum: Scripting (https://forum.logicmachine.net/forumdisplay.php?fid=8)
+--- Thread: Modbus TCP/IP timeout error (/showthread.php?tid=442)



Modbus TCP/IP timeout error - Mirco - 27.10.2016

Hi,
I use HomeLynk to communicate with an old central via Modbus TCP/IP and I have to use script, instead of integrate Modbus, because I have to manipulate datas before write or after read.
When I read there's no problem, but when I write, it returns a "Timeout Error".  I tryed to use some Modbus TCP programs for test the communication and I notice that the central answers after few seconds but it answers.
How can I resolve this problem? Is there an istruction to increase the time that HomeLYnk wait until sending a "Timeout Error"?


RE: Modbus TCP/IP timeout error - admin - 27.10.2016

Put mb:setresponsetimeout(seconds) after mb:setslave(...), adjust timeout value as needed.


RE: Modbus TCP/IP timeout error - Mirco - 28.10.2016

Thank you! Big Grin


RE: Modbus TCP/IP timeout error - Mirco - 02.12.2016

Is there a way to do the same with the modbus tool?


RE: Modbus TCP/IP timeout error - admin - 02.12.2016

Do you mean in the profile? There's an optional timeout field which can be set, otherwise the default timeout is 3 seconds for TCP


RE: Modbus TCP/IP timeout error - Mirco - 05.12.2016

Yes, how can I set it? In the manual I don't see any command for do this.. Where can I find the full list of possible command for the .json profiles?


RE: Modbus TCP/IP timeout error - admin - 05.12.2016

You have to edit the profile and add "timeout": 10 after "manufacturer" field. Then you have to create a new device in with new profile for timeout to work. We'll probably make it configurable from the interface in new releases.

Profile reference:
http://openrb.com/docs/modbus.htm


RE: Modbus TCP/IP timeout error - Mirco - 07.12.2016

Thanks! Smile