MicrohardSettings.h 1.03 KB
Newer Older
1 2
/****************************************************************************
 *
3
 *   (c) 2019 QGROUNDCONTROL PROJECT <http://www.qgroundcontrol.org>
4 5 6 7 8 9 10 11 12 13 14 15 16 17
 *
 * QGroundControl is licensed according to the terms in the file
 * COPYING.md in the root of the source code directory.
 *
 ****************************************************************************/

#pragma once

#include "MicrohardHandler.h"

class MicrohardSettings : public MicrohardHandler
{
    Q_OBJECT
public:
18
    explicit MicrohardSettings          (QString address, QObject* parent = nullptr, bool setEncryptionKey = false);
19
    bool    start                       () override;
20
    void    getStatus                   ();
21 22
    void    setEncryptionKey            (QString key);
    bool    loggedIn                    () { return _loggedIn; }
23 24 25 26

protected slots:
    void    _readBytes                  () override;

27 28 29
signals:
    void    updateRSSI                  (int rssi);

30
private:
31
    bool    _loggedIn;
32 33
    int     _rssiVal;
    QString _address;
34
    bool    _setEncryptionKey;
35
};