A-65
Appendices
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
A-7 TCP State Transitions
A
A-7 TCP State Transitions
TCP protocol operates in 11 states for connections.
You can check the TCP state of the socket service with the TCP connection status that is output by the
SktGetTCPStatus (Read TCP Socket Status) instruction.
The TCP states and their meanings are given in the following table.
The TCP state changes as requests and acknowledgements are received from the remote node, and
as TCP socket connection and close instructions are executed in the user program.
When the state changes, connection requests (SYN), close requests (FIN), and acknowledgements
(ACK) to those requests are sent to and received from the remote node.
TCP state Meaning
CLOSED The connection was closed.
LISTEN The server is waiting for a connection request (SYN) with a passive open.
SYN SENT The client sent a connection request (SYN) for an active open and is waiting for
acknowledgement (SYN + ACK).
SYN RECEIVED The server sent an acknowledgement (SYN + ACK) to a connection request (SYN)
and is waiting for acknowledgement (ACK).
ESTABLISHED A connection was established.
CLOSE WAIT The server sent acknowledgement (ACK) to a connection close request (FIN) and is
waiting for the server application to be ready to close.
FIN WAIT-1 The client sent a connection close request (FIN) and is waiting for acknowledgement
(ACK).
CLOSING The client and server simultaneously received a connection close request (FIN) and
are waiting for acknowledgement (ACK).
LAST-ACK The server sent a connection close request (FIN) and is waiting for acknowledgement
(ACK).
FIN WAIT-2 The client is waiting for a connection close request (FIN).
TIME WAIT The client received acknowledgement (ACK) to a connection close request (FIN) and
is waiting for it to be received and processed by the server.