Main Content

UDP Write

Send UDP packets to remote host

  • Library:
  • SoC Blockset / Processor I/O

    SoC Blockset / Host I/O

  • UDP Write block

Description

The UDP Write block sends UDP (User Datagram Protocol) packets from the application on target to a remote host. The remote host is the computer or hardware to which you want to send UDP packets.

Ports

Input

expand all

Input data, specified as a numeric vector. The block sends this data as UDP packet to the remote host. To set the byte order in which you want to send this UDP data, set the Byte order parameter. The block converts this input data to the specified byte order type.

Data Types: single | double | int8 | int16 | int32 | uint8 | uint16 | uint32

Output

expand all

This message port sends UDP packets, as messages, to a connected IO Data Sink block. For more information on messages, see Messages.

Note

This output is used only during simulation. and does nothing in code generation and external mode simulation.

Data Types: SoCData

Parameters

expand all

Specify the remote IP address of the host to which you want to send UDP packets.

Specify the port number of the host to which you want to send UDP packets.

Specify the port number of the application on the target from which you want to send the UDP packets. The default value -1, sets the local port number to a random available port number and uses that port to send the UDP packets.

Byte order of the UDP packets, specified as one of these values:

  • LittleEndian — Sets the byte order of UDP packets to little endian.

  • BigEndian — Sets the byte order of UDP packets to big endian.

Extended Capabilities

Introduced in R2019a