-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrotctlsocket.h
46 lines (39 loc) · 899 Bytes
/
rotctlsocket.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
#ifndef ROTCTLSOCKET_H
#define ROTCTLSOCKET_H
#include <QObject>
#include <QTcpSocket>
#include <QDebug>
#include <QString>
#include <QStringList>
#include <QLineEdit>
#include <QAbstractSocket>
#include <QHostAddress>
#include <QMessageBox>
class RotCtlSocket : public QObject
{
Q_OBJECT
public:
explicit RotCtlSocket(QObject *parent = 0);
void Cleanup();
bool connected;
signals:
void bearingReturned(int);
void isConnected(bool connected);
public slots:
void getPresentBearing();
void Connect();
void setBearing(int bearing);
void setIPAddress(QString ipAddressString);
void setPort(int portChange);
QString getIPAddress();
int getPort();
private:
QTcpSocket *socket;
QString bearing;
QString azimuth;
QStringList bearingList;
float azimuthF;
QHostAddress ipAddress;
int port;
};
#endif // ROTCTLSOCKET_H