udp
(To be removed) Create UDP object
udp
will be removed in a future release. Use udpport
instead. For more information on updating your code, see
Version History.
Description
creates a UDP object,
u
= udpu
, not associated with a remote host. If you use this
syntax, you must assign a remote host after object creation if you want to send
data. If you want to only receive data, you do not need to set a remote
host.
The UDP object must be bound to the local socket with the
fopen
function. The default local host in multihome
hosts is the system default. The LocalPort
property defaults
to a value of []
, allowing any free local port to be used.
LocalPort
is updated with a value when
fopen
is issued. When the UDP object is created, its
Status
property value is 'closed'
.
Once the object is bound to the local socket with fopen
,
Status
is configured to 'open'
.
The maximum packet size for reading is 8192 bytes. The input buffer can hold
as many packets as defined by the InputBufferSize
property
value. You can write any data size to the output buffer. The data is sent in
packets of at most 4096 bytes.
creates a UDP object associated with the remote host
u
= udp(RemoteHost
)RemoteHost
.
creates a UDP object with the specified remote port value,
u
= udp(RemoteHost
,RemotePort
)RemotePort
. If not specified, the default remote port is
9090.
creates a UDP object and specifies additional options with one or more
name-value pair arguments. If you specify an invalid property name or property
value, the object is not created.u
= udp(___,Name,Value
)