SysSockSendTo (FUN)ΒΆ

FUNCTION SysSockSendTo : __XINT

Send a message over a connectionless socket (UDP).
InOut:

Scope

Name

Type

Comment

Return

SysSockSendTo

__XINT

Number of bytes received.

Input

hSocket

RTS_IEC_HANDLE

Handle to the socket

pbyBuffer

POINTER TO BYTE

Buffer with send data

diBufferSize

__XINT

Length of data to send. If diBufferSize = 0 ERR_PARAMETER is returned

diFlags

DINT

The flags parameter can be used to influence the behavior of the function beyond the options specified for the associated socket. The semantics of this function are determined by the socket options and the flags parameter. The latter is constructed by using the bitwise OR operator with any of the SOCKET_MSG values.

pSockAddr

POINTER TO SOCKADDRESS

Socket address and port to sent data to

diSockAddrSize

DINT

Size of socket address structure

pResult

POINTER TO RTS_IEC_RESULT

Pointer to runtime system error code (see CmpErrors.library)