MATLAB Answers

Check if tcpip connection was closed by remote machine

6 views (last 30 days)
Daniel Hähnke
Daniel Hähnke on 22 Aug 2018
Hello,
I'm trying to set up a communication channel between two PCs that are connected via a local network. I want either of the two machines to close the connection and try to reconnect if the connection was closed by the remote machine, i.e. when the remote ran fclose(), crashed or restarted.
The Status property of the tcpip objects doesn't help here because it still says 'Open' if the connection was closed on the other side. I could periodically use netstat and check if the TCP connection is still listed as ESTABLISHED, but I feel there must be a more elegant way to do this.
Any ideas would be appreciated :)
Daniel

  0 Comments

Sign in to comment.

Answers (0)

Sign in to answer this question.

Products


Release

R2018a