seriallist

List of serial ports connected to your system

Syntax

seriallist

Description

example

seriallist returns a list of all serial ports on a system. The list includes virtual serial ports provided by USB-to-serial devices and Bluetooth Serial Port Profile devices. This provides a list of the serial ports that you have access to on your computer and could use for serial port communication.

Examples

collapse all

The seriallist function displays a list of all serial ports on a system.

Display available serial ports.

seriallist
ans = 

  1×2 string array

  "COM1"    "COM3"

You can now create a serial object and communicate over the serial port.

Introduced in R2017a