Main Content

rtw.pil.RtIOStreamApplicationFramework

Configure target-side communications

Description

Specify target-specific libraries and source files that are required to build the executable file. The libraries and source files must include the device drivers that implement the target-side of the rtiostream communications channel.

Creation

Description

example

appFrameObj = rtw.pil.RtIOStreamApplicationFramework(componentArgs) returns an object that provides access to an RTW.BuildInfo object containing PIL-specific files (including a PIL main function). rtw.connectivity.MakefileBuilder combines these files with the PIL component libraries to create the PIL application.

Make a subclass of rtw.pil.RtIOStreamApplicationFramework. In addition:

Object Functions

FunctionDescription
getComponentArgscomponentArgs = appFrameObj.getComponentArgs returns the rtw.connectivity.ComponentArgs object associated with appFrameObj.
getBuildInfobuildInfo = appFrameObj.getBuildInfo returns the RTW.BuildInfo object associated with appFrameObj.
addPILMain

To build the PIL application, a main function is required. Use this method to add one of the two provided files to the application framework.

To specify a main function that is adapted for on-target PIL and suitable for most PIL implementations, enter:

appFrameObj.addPILMain('target');

To specify a main function that is adapted for PIL on your development computer, enter:

appFrameObj.addPILMain('host');

Alternatively, you can specify your own main function:

componentArgs = appFrameObj.getComponentArgs;
buildInfo = appFrameObj.getBuildInfo;
buildInfo.addSourcePaths(pathToMyMainC);                            
buildInfo.addSourceFiles(myMainC);

Examples

Using rtw.pil.RtIOStreamApplicationFramework in PIL Connectivity

For an example that shows how to use this object in setting up PIL connectivity, see:

Introduced in R2008b