You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

33 lines
515 B

#ifndef MODBUSMASTER_H
#define MODBUSMASTER_H
#include <QObject>
#include <QModbusDataUnit>
class QModbusClient;
class QModbusReply;
class modBusMaster : public QObject
{
Q_OBJECT
public:
explicit modBusMaster(QObject *parent = nullptr);
void init();
void open(QString serialPort, quint16 pid);
void start();
void deinit();
void close();
void stop();
signals:
public slots:
private:
QModbusReply *lastRequest;
QModbusClient *modbusDevice;
};
#endif // MODBUSMASTER_H