36 lines
631 B
C
36 lines
631 B
C
|
#ifndef SERIAL_INC_H
|
||
|
#define SERIAL_INC_H
|
||
|
|
||
|
#include <QDebug>
|
||
|
#include <sys/wait.h>
|
||
|
#include <QSerialPort>
|
||
|
#include <QApplication>
|
||
|
#include <iostream>
|
||
|
|
||
|
class ZigbeeMgr : public QSerialPort
|
||
|
{
|
||
|
Q_OBJECT
|
||
|
|
||
|
public:
|
||
|
//QSerialPort * sp;
|
||
|
QByteArray dataRead;
|
||
|
QByteArray dataWrite;
|
||
|
qint64 dataWriteSize;
|
||
|
QString serialDevicePath;
|
||
|
|
||
|
//QAbstractButton * reply;
|
||
|
//QString serialDevicePath;
|
||
|
|
||
|
void write(QString datas);
|
||
|
ZigbeeMgr();
|
||
|
~ZigbeeMgr();
|
||
|
|
||
|
private slots:
|
||
|
void getData();
|
||
|
void confirmWrite(qint16 byte);
|
||
|
};
|
||
|
|
||
|
|
||
|
|
||
|
#endif // SERIAL_INC_H
|