Object Detection
5.0
Image Processing Using Qt and Opencv
serialhandler.h
1
#ifndef SERIALHANDLER_H
2
#define SERIALHANDLER_H
3
4
#include <QObject>
5
#include <QSerialPort>
6
#include <abstractdevicewriter.h>
7
#include "observer.h"
8
#include "devicehandler_global.h"
9
10
namespace
Devices
{
11
class
DECLARE_LIB
SerialHandler
;
12
}
13
using namespace
Devices
;
14
class
Devices::SerialHandler
:
public
AbstractDeviceWriter
15
{
16
Q_OBJECT
17
private
:
18
class
_SerialHandlerImpl;
19
std::unique_ptr<_SerialHandlerImpl> _pimpl;
20
public
:
21
explicit
SerialHandler
(QObject *parent =
nullptr
);
22
virtual
~
SerialHandler
();
23
QSerialPort* getPort();
24
signals:
25
public
slots:
26
void
setPort(QSerialPort* port);
27
28
// AbstractDeviceWriter interface
29
public
:
30
virtual
void
writeToDevice(
const
QString &str)
override
;
31
32
// AbstractDeviceWriter interface
33
public
:
34
virtual
void
closeDevice()
override
;
35
virtual
void
openDevice()
override
;
36
};
37
38
39
#endif // SERIALHANDLER_H
Devices
Definition:
abstractdevicewriter.h:10
Devices::SerialHandler
Definition:
serialhandler.h:14
Devices::AbstractDeviceWriter
Definition:
abstractdevicewriter.h:14
object-detector
src
DevicesInterfaces
DeviceHandler
Serial
serialhandler.h
Generated by
1.8.13