TCP Send
Add-On Required: This feature requires the Embedded Coder Support Package for STMicroelectronics STM32 Processors add-on.
Libraries:
Embedded Coder Support Package for STMicroelectronics STM32 Processors /
STM32F4xx Based Boards
Embedded Coder Support Package for STMicroelectronics STM32 Processors /
STM32F7xx Based Boards
Embedded Coder Support Package for STMicroelectronics STM32 Processors /
STM32H7xx Based Boards
Embedded Coder Support Package for STMicroelectronics STM32 Processors /
STM32F2xx Based Boards
Description
The TCP Send block sends data to a remote host or another hardware
board over a TCP/IP network. You can set the Connection mode of the
block to Server
or Client
. When you set
Connection mode to Client
, you must provide
the Server IP Address and the Server IP Port
on the server to which you want to send data. When you set Connection
mode to Server
, you must provide the Local
IP Port. This Local IP Port acts as a listening port
on the TCP/IP server. The server must be up and running before deploying the model that
contains the TCP Send block to the target.
The block sends data either in blocking mode or in non-blocking mode. In blocking mode, the model blocks the execution while it waits for the data to be sent completely. In non-blocking mode, the model runs continuously. To set the block in blocking mode, select the Wait until data received option.
Note
Ensure to configure the Ethernet options in STM32CubeMX project. For more, see Configure Ethernet Options in STM32CubeMX for STM32 Processor Based Boards.
Ports
Input
Output
Parameters
Version History
Introduced in R2022b