Documentation Center

  • Trial Software
  • Product Updates

Contents

Property Reference

The Property Reference Page Format

Each serial port property description contains some or all of this information:

  • The property name

  • A description of the property

  • The property characteristics, including:

    • Read only — The condition under which the property is read only

      A property can be read-only always, never, while the serial port object is open, or while the serial port object is recording. You can configure a property value using the set function or dot notation. You can return the current property value using the get function or dot notation.

    • Data type — the property data type

      This is the data type you use when specifying a property value.

  • Valid property values including the default value

    When property values are given by a predefined list, the default value is usually indicated by {}.

  • An example using the property

  • Related properties and functions

Serial Port Object Properties

The serial port object properties are briefly described below, and organized into categories based on how they are used. Following this section the properties are listed alphabetically and described in detail.

Communications Properties  

BaudRate

Rate at which bits are transmitted

DataBits

Number of data bits to transmit

Parity

Type of parity checking

StopBits

Number of bits used to indicate the end of a byte

Terminator

Terminator character

Write Properties 

BytesToOutput

Number of bytes currently in the output buffer

OutputBufferSize

Size of the output buffer in bytes

Timeout

Waiting time to complete a read or write operation

TransferStatus

Indicate if an asynchronous read or write operation is in progress

ValuesSent

Total number of values written to the device

Read Properties 

BytesAvailable

Number of bytes available in the input buffer

InputBufferSize

Size of the input buffer in bytes

ReadAsyncMode

Specify whether an asynchronous read operation is continuous or manual

Timeout

Waiting time to complete a read or write operation

TransferStatus

Indicate if an asynchronous read or write operation is in progress

ValuesReceived

Total number of values read from the device

Callback Properties 

BreakInterruptFcn

Callback function to execute when a break-interrupt event occurs

BytesAvailableFcn

Callback function to execute when a specified number of bytes is available in the input buffer, or a terminator is read

BytesAvailableFcnCount

Number of bytes that must be available in the input buffer to generate a bytes-available event

BytesAvailableFcnMode

Specify if the bytes-available event is generated after a specified number of bytes is available in the input buffer, or after a terminator is read

ErrorFcn

Callback function to execute when an error event occurs

OutputEmptyFcn

Callback function to execute when the output buffer is empty

PinStatusFcn

Callback function to execute when the CD, CTS, DSR, or RI pins change state

TimerFcn

Callback function to execute when a predefined period of time passes

TimerPeriod

Period of time between timer events

Control Pin Properties  

DataTerminalReady

State of the DTR pin

FlowControl

Data flow control method to use

PinStatus

State of the CD, CTS, DSR, and RI pins

RequestToSend

State of the RTS pin

Recording Properties 

RecordDetail

Amount of information saved to a record file

RecordMode

Specify whether data and event information are saved to one record file or to multiple record files

RecordName

Name of the record file

RecordStatus

Indicate if data and event information are saved to a record file

General Purpose Properties  

ByteOrder

Order in which the device stores bytes

Name

Descriptive name for the serial port object

Port

Platform-specific serial port name

Status

Indicate if the serial port object is connected to the device

Tag

Label to associate with a serial port object

Type

Object type

UserData

Data you want to associate with a serial port object

Was this topic helpful?