| Contents | Index |
rtw.connectivity.RtIOStreamHostCommunicator(componentArgs,
launcher, rtiostreamLib)
| Constructor | Description |
|---|---|
| RtIOStreamHostCommunicator | Configure host-side communications with the target by loading and initializing a shared library that implements the rtiostream functions. |
| Constructor Arguments | |
|---|---|
| componentArgs | A rtw.connectivity.ComponentArgs object. |
| launcher | A rtw.connectivity.Launcher object. |
| rtiostreamLib | An rtiostream shared library that implements the host side of host-target communications. |
Constructor syntax:
rtw.connectivity.RtIOStreamHostCommunicator(componentArgs, launcher, rtiostreamLib)
This class configures host-side communications with the target by loading and initializing a shared library that implements the rtiostream functions.
Embedded Coder provides an implementation of this shared library to support TCP/IP communications between host and target (all platforms), as well as a Windows only version for serial communications. With TCP/IP or serial, you need only supply the target-side drivers.
For other communications protocols (e.g. USB), you must supply a shared library for the host-side of the communications link as well as the target-side drivers.
To create your instance of rtw.connectivity.RtIOStreamHostCommunicator, you have two options:
Instantiate rtw.connectivity.RtIOStreamHostCommunicator directly, providing custom arguments to supply to the rtiostream shared library.
Alternatively, create a subclass of rtw.connectivity.RtIOStreamHostCommunicator. Consider this when more complex configuration is required. For example, the demo subclass rtw.connectivity.HostTCPIPCommunicator includes additional code to determine the TCP/IP port number on which the executable application is serving, or you could use a subclass to specify a serial port number, or specify verbose or silent operation.
| Methods | |
|---|---|
| setTimeoutRecvSecs | Sets the timeout value for reading data. |
| hostCommunicator.setTimeoutRecvSecs(timeout) configures data reading to time out if no new data is received for a period of greater than timeout seconds. | |
| setInitCommsTimeout | Sets the timeout value for initial setup of the communications channel. |
| hostCommunicator.setInitCommsTimeout(timeout) For some targets you may need to set a timeout value for initial setup of the communications channel. For example, the target processor may take a few seconds before it is ready to open its side of the communications channel. If you set a nonzero timeout value then the communicator repeatedly tries to open the communications channel until the timeout value is reached. | |
rtiostream_wrapper | rtw.connectivity.ComponentArgs | rtw.connectivity.Launcher

Learn more about Simulink through this collection of videos, articles, technical literature and the Getting Started with Simulink Guide.
| © 1984-2012- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |