SerialPort Type
Constructors
| Constructor |
Description
|
Full Usage:
SerialPort(portId, portName, ?displayName, ?vendorId, ?productId, ?serialNumber, ?usbDriverName, ?deviceInstanceId)
Parameters:
string
-
Unique identifier for the port.
portName : string
-
Name of the port.
?displayName : string
-
A string suitable for display to the user for describing this device.
?vendorId : string
-
The USB vendor ID.
?productId : string
-
The USB product ID.
?serialNumber : string
-
The USB device serial number.
?usbDriverName : string
-
⚠ OS Compatibility: WIN ❌ | MAC ✔ | LIN ❌ | MAS ❌ || Represents a single serial
port on macOS can be enumerated by multiple drivers.
?deviceInstanceId : string
-
⚠ OS Compatibility: WIN ✔ | MAC ❌ | LIN ❌ | MAS ❌ || A stable identifier on
Windows that can be used for device permissions.
Returns: SerialPort
|
|
Instance members
| Instance member |
Description
|
Full Usage:
this.deviceInstanceId
|
⚠ OS Compatibility: WIN ✔ | MAC ❌ | LIN ❌ | MAS ❌ A stable identifier on Windows that can be used for device permissions. |
Full Usage:
this.displayName
|
A string suitable for display to the user for describing this device. |
Full Usage:
this.portId
|
Unique identifier for the port. |
Full Usage:
this.portName
|
Name of the port. |
Full Usage:
this.productId
|
The USB product ID. |
Full Usage:
this.serialNumber
|
The USB device serial number. |
Full Usage:
this.usbDriverName
|
⚠ OS Compatibility: WIN ❌ | MAC ✔ | LIN ❌ | MAS ❌ Represents a single serial port on macOS can be enumerated by multiple drivers. |
Full Usage:
this.vendorId
|
The USB vendor ID. |
fable-electron-docs-api