Jump to content

Condition to close a socket on V700


Recommended Posts

  • MVP 2023

If the connection is lost, the socket is already closed, is it not? Isn't the socket being open the definition of a connection? Just reconnect. In fact, if you gate the socket connect function with an inverted contact of a bit that is on when the socket is open, you can trigger a reconnect as often as you like and it will do nothing until the connection is lost.

 

Unitronics Forum 170621.jpg

Link to comment
Share on other sites

Thanks for your reply!

I am not shure, if connection is lost, the socket is allready closed.

With a Modbus-Master on a V1210 once I expierenced longer (~ 1min) delays before reconnect, when I removed ethernet cable and plugged it in again. I have shortened the delay by explicitly closing the socket. From then on I always used this in my Modbus-Sequence - not really shure, if this is really needed.

V130-socket-close.PNG.736a3a7acade7eb8593512709ee54fa3.PNG

On a Vision700 this proven procedure fails. I am getting the status bits with:

V700-socket-state.PNG.6a2679eed81fa18e7585ce4da4718a55.PNG

And trying to close the socket with:

V700-socket-close.PNG.2fc7411185224133d1f6149a59b3ff9f.PNG

I think it failes, because the socket status bits are not continuously ON during a cycle. In Online-Test I can see a flicker.

But - nevertheless - my Modbus-Sequence is working even without socket close. By now reconnect times do not seem to be critical.

Maybe the reconnect delay depends on Socket-Timeout-Values on both machines. With short timeouts, no socket close would be needed.

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...