Documentation

UDP Send

Send data over UDP network to a remote device

  • Library:
  • Real-Time UDP

Description

The UDP Send block sends data over a UDP network to a remote device. The block can send data by using the connection between the development and target computers or by using a dedicated Ethernet card.

The parameter Local IP address applies only when the block executes on a target computer. If your model is running in Simulink® on the development computer, you can use this block to transmit data to a remote device. In this case, the Windows® operating system determines the network connection.

To broadcast to all devices, set To IP address to 255.255.255.255, otherwise set To IP address to a valid IP address.

Ports

Input

expand all

Vector of uint8 containing data to transmit over the UDP network. To determine how many bytes of data to transmit, use the Length input port.

Data Types: uint8

Determines the number of bytes of data to transmit. Specify the width of the Data vector as the maximum number of bytes that you expect to transmit.

Parameters

expand all

When Local IP address is set to Use host-target connection, the block uses the connection between the development and target computers. Otherwise, the block uses the value that you set in the Local IP address parameter of the UDP Configure block.

Specifies local UDP port through which to transmit data.

Specifies IP address of target device. To broadcast, send to 255.255.255.255.

Specify the UDP port of target device. With To IP address, this parameter defines the destination of the data transmission.

Enter the base sample time or a multiple of the base sample time.

See Also

| | |

Introduced in R2016b

Was this topic helpful?