Modbus Device not Connecting

I’m using Ignition 7.28 and have recently added two new modbus devices to the project. The first modbus device is connected but frequently disconnects and the second one won’t connect.
I’m getting the same sort of error for both:
For the MCPM device I get:

20:52:32 MCPM [MCPM] Socket connection closed. DriverState was Connected.
java.io.IOException: End of stream reached.
at com.inductiveautomation.ignition.common.io.SocketIOSession.run(SocketIOSession.java:71)
at java.lang.Thread.run(Unknown Source)

For the EMR device I get:

20:52:24 EMR [EMR] Socket connection closed. DriverState was Connected.
java.io.IOException: End of stream reached.
at com.inductiveautomation.ignition.common.io.SocketIOSession.run(SocketIOSession.java:71)
at java.lang.Thread.run(Unknown Source)

The project has 2 more modbus devices which are fine. Any ideas on where to look for a fix or thing to try would be greatly appreciated.

I can’t tell without more logs, but it looks like both are connecting and then the device is severing the connection. Often, Modbus devices will close a connection after N seconds if you aren’t actually reading or writing data. Do you have tags subscribed on these devices?

Many thanks for the reply, this may be the problem. I only have about 10 tags for one slave id configured on a slow scan class of 10 seconds (since I was testing the system). So possibly the device is closing the connection in between scans of the tags.
I’ll configure up more tags on the system and see how that works.

The same is happening to me with a Siemens S7-400 and Ignition v7.9.3.
I have zero tags configured.
But the deviced had never connected. Always in state Disconnected.

Could the problem be the same that “Dodonnell999” had ? Or in this case the problem is another??

This is the error in the console:

Socket connection closed; DriverState was Connecting.
java.net.SocketException: Connection reset
at java.net.SocketInputStream.read(Unknown Source)
at java.net.SocketInputStream.read(Unknown Source)
at java.net.SocketInputStream.read(Unknown Source)
at com.inductiveautomation.iosession.socket.AsyncSocketIOSession.run(AsyncSocketIOSession.java:71)
at java.lang.Thread.run(Unknown Source)

Thanks in advanced.

This is indeed standard behavior, and an annoying one at that; in the past, we had a tag pointing to a PLC counter that would increment every ‘n’ seconds only to avoid the noise in the logs…

There is this setting on the modbus driver (under “Show advanced properties”) that may or may not be related (the documentation is as vague as it gets :slight_smile: )

Try unchecking the option and see if your device keeps disconnecting when there are no data changes.

Thanks Oscar, I tried that and nothing happened.

The thing is that the device has never been connected. Not even once. And the funny thing is that I can see the IP Address when I do a “ping” in the command console.

I really running out of ideas to try to get it connected.

Some other thing you may think of ?

Thanks a lot

Have you tried connecting to the ModbusTCP device using another client? ( I use Modbus Poll, for example).
Have you also made sure that ModbusTCP is enabled on the S7 side? I seem to recall that the MODBUSPN function block needs to be set to “Server” mode.

Oscar.