CTI 2572-B / 2500C-2572-B Installation and Operation Manual 39
Offset 3 Protocol Manager Number - Protocol Managers control the operation of the serial and
network ports. The Protocol Manager Number for the CAMP Client protocol manager is
decimal 36 (hex 24).
Offset 4 Startup Option Bits
Bit 15 - IP Address Location
REATE
OCKET
1 = Use IP Address in MEMORY TRANSFER Command Block
(UDP Only)
When bit 15 is set to 1 (Offset 4 = 0x0002) and the UDP protocol is selected (in Offset 5), the
Command Blocks used for Memory Transfer (R
EAD REMOTE, WRITE REMOTE, and MEMORY
EXCHANGE) will specify the IP Address and Port Number for the remote device.
This feature allows you to use a single socket to communicate with different remote devices.
When bit 15 is set to 0, the IP address and port number entered in this C
REATE SOCKET
command block will be used. The TCP protocol, since it is connection-oriented, will always
use the IP address and port number in this CREATE SOCKET command block. If you select TCP
and set bit 15 to 1, the 2572-B will return an error.
NOTE:
Even if you set bit 15 to 1, you still must provide a valid IP address and Port number in the
Command Block of the CREATE SOCKET command. If you don’t do this, a Command Error will be
generated when you execute the CREATE SOCKET command.
Offset 5 Type of Service - Selects TCP or UDP/Multicast service. Using TCP, a connection is established
with the other node. If the TCP connection cannot be established, the 2572-B will indicate an
error. Using UDP/Multicast, the local socket is created but no connection is established with
the target node.
NOTE:
If TCP is selected and the connection with the target node (remote host) is lost, the 2572-B will
report a socket connection error code (such as 240A - Socket not Connected) the next time you
attempt to read/write data. After the error is acknowledged, the 2572-B will complete error recovery
by automatically closing the socket. A subsequent attempt to read/write data will result in a 00A6
(connection not active) error. See Appendix B for error code listings. Your logic should re-execute
the Create Socket command if the connection is not active.
Offset 6-7 IP Address - If the IP
ADDRESS SELECTION option bit in Offset 4 is set to 0, these words specify
the IP address of the destination node. Since the IP address consists of 32 bits, the address is
contained in two 16 bit words. An IP address of 0.0.0.0 will return an error. If you are using
TCP, the largest valid IP address is 223.255.255.255. If you are using UDP/Multicast, you can
also enter multicast addresses ranging from 224.0.0.2 through 239.255.255.255.
Offset 8 Unused - This word is not used when creating a TCP/IP socket. It should be set to 0.