Reserved Identifiers
Keywords & Run-Time Library Functions (Cont.)
IP_MC_SERVER_OPEN
IP_SERVER_CLOSE
136
This function opens a server port to listen for UDP multicast messages.
SINTEGER IP_MC_SERVER_OPEN(INTEGER LocalPort, CHAR
MultiCastIP[], LONG ServerPort)
Parameters:
• LocalPort: The local port number to open. This number must be passed to
IP_SERVER_CLOSE to close the port.
• MultiCastIP: A character string representing the multicast address to
receive on in the form of: '239.255.255.250'.
• ServerPort: The UDP multicast port number to listen on.
Result:
This function always returns 0. Errors are returned via the DATA_EVENT
ONERROR method. The following error may be returned:
2: General failure (out of memory)
10: Binding error
11: Listening error
14: Local port already used
15: UDP socket already listening
16: Too many open sockets
Example:
IP_MC_SERVER_OPEN (PORT1,'239.255.255.250',1900)
This function closes a port opened with IP_SERVER_OPEN or
IP_MC_SERVER_OPEN.
IP_SERVER_CLOSE (INTEGER LocalPort)
Parameters:
• LocalPort: The number of the local port to close.
Result: This function always returns 0. Errors are returned via the
DATA_EVENT ONERROR method. The following error may be returned:
9: Already closed
Example:
IP_Server_Close(PORT1)
See the IP Communication section on page 189 for more information.
NetLinx Programming Language Reference Guide