![]() |
PIDUINO
|
Provides information about existing serial ports. More...
#include <serialport.h>
Public Member Functions | |
Info () | |
Info (const Info &other) | |
Info (const std::string &name) | |
Info (const SerialPort &port) | |
virtual | ~Info () |
Info & | operator= (const Info &other) |
void | swap (Info &other) |
bool | operator== (const Info &other) |
bool | operator!= (const Info &other) |
std::string | portName () const |
std::string | systemLocation () const |
std::string | driverName () const |
std::string | description () const |
std::string | manufacturer () const |
std::string | serialNumber () const |
uint16_t | vendorIdentifier () const |
bool | hasVendorIdentifier () const |
uint16_t | productIdentifier () const |
bool | hasProductIdentifier () const |
bool | isNull () const |
Static Public Member Functions | |
static std::deque< Info > | availablePorts () |
static std::deque< int32_t > | standardBaudRates () |
static Info | defaultPort () |
Information sur le port série par défaut sur la carte Pi Dépend du modèle de carte (informations stockées dans la base de données) | |
Protected Member Functions | |
Info (Private &dd) | |
Protected Attributes | |
std::unique_ptr< Private > | d_ptr |
Provides information about existing serial ports.
Use the static functions to generate a list of SerialPort::Info objects. Each SerialPort::Info object in the list represents a single serial port and can be queried for the port name, system location, description, and manufacturer. The SerialPort::Info class can also be used as an input parameter for the setPort() method of the SerialPort class.
Definition at line 391 of file serialport.h.
Piduino::SerialPort::Info::Info | ( | ) |
Constructs an empty SerialPort::Info object.
Piduino::SerialPort::Info::Info | ( | const Info & | other | ) |
Constructs a copy of other.
|
explicit |
Constructs a SerialPort::Info object from serial port name.
This constructor finds the relevant serial port among the available ones according to the port name name, and constructs the serial port info instance for that port.
|
explicit |
Constructs a SerialPort::Info object from serial port.
|
virtual |
Destroys the SerialPort::Info object. References to the values in the object become invalid.
|
protected |
|
static |
Returns a list of available serial ports on the system.
|
static |
Information sur le port série par défaut sur la carte Pi Dépend du modèle de carte (informations stockées dans la base de données)
std::string Piduino::SerialPort::Info::description | ( | ) | const |
Returns the description string of the serial port, if available; otherwise returns an empty string.
std::string Piduino::SerialPort::Info::driverName | ( | ) | const |
Returns the driver name string of the serial port, if available; otherwise returns an empty string.
bool Piduino::SerialPort::Info::hasProductIdentifier | ( | ) | const |
Returns true
if there is a valid 16-bit
product number present; otherwise returns false
.
bool Piduino::SerialPort::Info::hasVendorIdentifier | ( | ) | const |
Returns true
if there is a valid 16-bit
vendor number present; otherwise returns false
.
bool Piduino::SerialPort::Info::isNull | ( | ) | const |
Returns whether this SerialPort::Info object holds a serial port definition.
std::string Piduino::SerialPort::Info::manufacturer | ( | ) | const |
Returns the manufacturer string of the serial port, if available; otherwise returns an empty string.
bool Piduino::SerialPort::Info::operator!= | ( | const Info & | other | ) |
other |
Sets the SerialPort::Info object to be equal to other.
bool Piduino::SerialPort::Info::operator== | ( | const Info & | other | ) |
other |
std::string Piduino::SerialPort::Info::portName | ( | ) | const |
Returns the name of the serial port.
uint16_t Piduino::SerialPort::Info::productIdentifier | ( | ) | const |
Returns the 16-bit product number for the serial port, if available; otherwise returns zero.
std::string Piduino::SerialPort::Info::serialNumber | ( | ) | const |
Returns the serial number string of the serial port, if available; otherwise returns an empty string.
|
static |
Returns a list of available standard baud rates supported by the target platform.
void Piduino::SerialPort::Info::swap | ( | Info & | other | ) |
Swaps SerialPort::Info other with this SerialPort::Info. This operation is very fast and never fails.
std::string Piduino::SerialPort::Info::systemLocation | ( | ) | const |
Returns the system location of the serial port.
uint16_t Piduino::SerialPort::Info::vendorIdentifier | ( | ) | const |
Returns the 16-bit vendor number for the serial port, if available; otherwise returns zero.
|
protected |
Definition at line 556 of file serialport.h.