A RealTimeConnection
which reads from a serial port.
More...
#include <realtimeserialconnection.h>
A RealTimeConnection
which reads from a serial port.
bool RealTimeSerialConnection::isConnected |
( |
| ) |
const |
|
overridevirtual |
virtual QString RealTimeSerialConnection::name |
( |
| ) |
const |
|
overridevirtual |
The name of the serial port being used.
- Returns
- The serial port name.
Implements RealTimeConnection.
bool RealTimeSerialConnection::open |
( |
const QString & |
name, |
|
|
quint32 |
baudRate, |
|
|
bool |
readOnly |
|
) |
| |
Open a serial connection, first disconnecting any existing connection.
- Parameters
-
name | The name of the serial port to open. For example, "/dev/ttyUSB0" or "COM3". |
baudRate | The baud rate at which to open the port. |
readOnly | True to open the connection is a read only mode. |
- Returns
- True on success, false on failure.
int RealTimeSerialConnection::read |
( |
QByteArray & |
buffer | ) |
|
|
overridevirtual |
Read data into the given buffer.
- Parameters
-
buffer | The buffer to read into. |
Implements RealTimeConnection.
int RealTimeSerialConnection::send |
( |
const QByteArray & |
buffer | ) |
|
|
overridevirtual |
Send the given buffer to the source.
- Parameters
-
buffer | The buffer to send. |
Implements RealTimeConnection.
The documentation for this class was generated from the following file: