Omron CS1W-ETN01 用户手册

下载
页码 317
125
Using Socket Services with Socket Service Request Switches
Section 6-2
6-2-4
UDP/TCP Socket Status
The status of the UDP and TCP sockets is provided in the Socket Status
Words shown in the following diagram. There is a status word for each socket
for both UDP and TCP. The Socket Status Words are allocated in the CPU
Bus Unit Area in the CPU Area starting at the word n+ 1. The value of n can
be calculated from the unit number as follows:
n = 1500 + (25 x unit number)
The flags shown in the following diagram are provided in the Socket Status
Words for socket service requests made with the Socket Service Request
Switches.
UDP Socket No. 1 Status
TCP Socket No. 1 Status
TCP Socket No. 2 Status
TCP Socket No. 3 Status
TCP Socket No. 4 Status
TCP Socket No. 5 Status
TCP Socket No. 6 Status
TCP Socket No. 7 Status
TCP Socket No. 8 Status
UDP Socket No. 2 Status
UDP Socket No. 3 Status
UDP Socket No. 4 Status
UDP Socket No. 5 Status
UDP Socket No. 6 Status
UDP Socket No. 7 Status
UDP Socket No. 8 Status
n+1
n+2
n+3
n+4
n+5
n+6
n+7
n+8
n+9
n+10
n+11
n+12
n+13
n+14
n+15
n+16
15
8
7
0
Opening Flag
Receiving Flag
Sending Flag
Closing Flag
TCP/UDP Open Flag
15 14 13 12 11 10
9
8
7
6
5
4
3
2
1
0
Bit
Switch
Status Manipulated 
by
Unit operation
0
Opening Flag
ON
Unit
Turns ON when an open request is received.
OFF
Turns OFF when open processing has been completed.
1
Receiving Flag
ON
Turns ON when a receive request is received.
OFF
Turns OFF when receive processing has been completed.
2
Sending Flag
ON
Turns ON when a send request is received.
OFF
Turns OFF when send processing has been completed.
3
Closing Flag
ON
Turns ON when an close request is received.
OFF
Turns OFF when close processing has been completed.
15
Socket Open Flag
ON
Turns ON when open processing has been completed (i.e., when a 
connection is made).
OFF
Turns OFF when close processing has been completed. (Will 
remain OFF when open processing ends in an error.)