Main Content

addNewSerialInterface

Class: matlabshared.targetsdk.Hardware
Namespace: matlabshared.targetsdk

Add serial interface to hardware

Syntax

obj = addNewSerialInterface(h,interfaceName)

Description

obj = addNewSerialInterface(h,interfaceName) creates a new SerialInterface object, obj, with the Name property set to the string interfaceName, and adds the new object to the Hardware object, h.

An error is thrown if new SerialInterface object cannot be created.

Input Arguments

expand all

Handle to the object representing the hardware on which the generated code runs.

Name of the SerialInterface object, specified as a string.

Example: 'My PMC RS232 Card'

Data Types: char

Output Arguments

expand all

Handle to the object representing the serial interface.

Version History

Introduced in R2015a