#ifndef FREQUENCYTUNING_H
#define FREQUENCYTUNING_H

#include <QObject>

#include "device/DeviceBase.h"
#include "protocol/FrequencyTuningProtocolTX.h"
#include "protocol/dto/FrequencyTuningStatusFreqDto.h"
#include "protocol/dto/FrequencyTuningStatusLockDto.h"

class FrequencyTuning : public DeviceBase
{
    Q_OBJECT
public:
    explicit FrequencyTuning(QObject *parent = nullptr);
    ~FrequencyTuning();

    void frameParse(QList<QByteArray> frameList);

    void mockReceivData();
    void mockReceivCmdReply(){}

    void afterFrameParse(DeviceFrameBaseDto * frameDto);
    void afterCommandReply(DeviceFrameBaseDto * frameDto);
    void sendDataToSerial(QByteArray data);

signals:
    void sendDataToDraw(DeviceFrameBaseDto * frameData);
    void sendCommandToDisplay(QJsonObject command);

public slots:
    void dataReceivedHandler(QByteArray data);
    void commandReceivedHandler(QJsonObject command);

};

#endif // FREQUENCYTUNING_H
