update docs

This commit is contained in:
Dorian Zedler 2020-10-26 22:48:15 +01:00
parent d75f55a3a1
commit 86ad00899b
Signed by: dorian
GPG key ID: D3B255CB8BC7CD37

View file

@ -45,29 +45,35 @@
* QBluetoothLeUart::init(); * QBluetoothLeUart::init();
* \endcode * \endcode
* somewhere before app.exec(); in your main.cpp. * somewhere before app.exec(); in your main.cpp.
*
* \section Getting started
* This library currently supports: BluetoothLE UART client
* \subsection BluetoothLE UART client
* To get started with the BLE client, see the docs of QBluetoothLeUartClient.
*
*/ */
/*! /*!
* \brief The QBluetoothLeUart class can be used to talk to BluetoothLE devices via UART effordlessly. * \brief The QBluetoothLeUartClient class can be used to talk to BluetoothLE devices via UART effordlessly.
* It can be used via C++ and QML. * It can be used via C++ and QML.
* *
* C++ example: * C++ example:
* \code{.cpp} * \code{.cpp}
* #include <qbluetoothleuart.h> * #include <qbluetoothleuartClient.h>
* class MyBluetoothLeClass : QObject { * class MyBluetoothLeClass : QObject {
* public: * public:
* MyBluetoothLeClass(QObject* parent = nullptr) : QObject(parent) { * MyBluetoothLeClass(QObject* parent = nullptr) : QObject(parent) {
* this->ble = new QBluetoothLeUart(); * this->ble = new QBluetoothLeUartClient();
* *
* connect(this->ble, &QBluetoothLeUart::foundNewDevice, this, &MyBluetoothLeClass::handleFoundNewDevice); * connect(this->ble, &QBluetoothLeUartClient::foundNewDevice, this, &MyBluetoothLeClass::handleFoundNewDevice);
* connect(this->ble, &QBluetoothLeUart::connectedToDevice, this, &MyBluetoothLeClass::handleBluetoothDeviceConected); * connect(this->ble, &QBluetoothLeUartClient::connectedToDevice, this, &MyBluetoothLeClass::handleBluetoothDeviceConected);
* connect(this->ble, &QBluetoothLeUart::dataReceived, this, &MyBluetoothLeClass::handleDataReceived); * connect(this->ble, &QBluetoothLeUartClient::dataReceived, this, &MyBluetoothLeClass::handleDataReceived);
* *
* this->ble->startScanningForDevices(); * this->ble->startScanningForDevices();
* } * }
* *
* private: * private:
* QBluetoothLeUart *ble; * QBluetoothLeUartClient *ble;
* *
* private slots: * private slots:
* void handleFoundNewDevice(QBluetoothLeUartDevice* device) { * void handleFoundNewDevice(QBluetoothLeUartDevice* device) {
@ -93,7 +99,7 @@
* \code{.qml} * \code{.qml}
* import de.itsblue.bluetoothleuart 1.0 * import de.itsblue.bluetoothleuart 1.0
* *
* QBluetoothLeUart { * QBluetoothLeUartClient {
* id: ble * id: ble
* Component.onCompleted: { * Component.onCompleted: {
* ble.startScanningForDevices() * ble.startScanningForDevices()