Files
Spherebot-Host-GUI/Spherebot_UI/rxthread.h
Alex aec078c865 rxthread
outsourced the receiving to a seperate thread. This allows us to use
much lower baudrates but still have a responsive UI. Set Baudrate to
57600 baud
2014-12-23 19:01:23 +01:00

29 lines
434 B
C++

#ifndef RXTHREAD_H
#define RXTHREAD_H
#include <QThread>
#include "spherebot.h"
#include <QTimer>
#include <QString>
class rxThread : public QThread
{
Q_OBJECT
public:
rxThread(spherebot *);
void set(QString textfile,spherebot &bot);
void run();
~rxThread();
signals:
void lineReceived(QString);
public slots:
void receiveData();
private:
QString line;
spherebot *bot;
};
#endif // RXTHREAD_H