forked from apsystems/GrblHoming
-
Notifications
You must be signed in to change notification settings - Fork 0
/
readthread.h
47 lines (38 loc) · 777 Bytes
/
readthread.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
47
#ifndef READTHREAD_H
#define READTHREAD_H
#include <QFile>
#include <QThread>
#include <QTextStream>
#include "rs232.h"
#include "definitions.h"
class ReadThread : public QThread
{
Q_OBJECT
public:
explicit ReadThread(QObject *parent = 0);
//variables
QString path;
int port_nr;
bool toolChange;
float toolChangeXYZ[3];
//objects
RS232 port;
//methods
bool goHome;
protected:
void run();
signals:
void addList(QString line);
void sendMsg(QString msg);
void sendAxis(QString axis);
public slots:
void stopsig();
private:
//methods
QString removeInvalid(QString line);
int SendGcode(QString line);
void toolChangeRoutine();
//variables
bool abort;
};
#endif // READTHREAD_H