summaryrefslogtreecommitdiffstats
path: root/configuredivecomputerthreads.h
diff options
context:
space:
mode:
authorGravatar Joseph W. Joshua <joejoshw@gmail.com>2014-06-23 18:16:27 +0300
committerGravatar Thiago Macieira <thiago@macieira.org>2014-08-13 10:48:15 -0700
commitcc6c385f3309417727f61b55550d6d47bef004dd (patch)
tree2b86c64b388ad7005cbf952bc3c93ef9abcbb1d3 /configuredivecomputerthreads.h
parent8aa7fddb22cd6ab4d533082598be04649bb1ff21 (diff)
downloadsubsurface-cc6c385f3309417727f61b55550d6d47bef004dd.tar.gz
Start Work on Firmware Update
This patch implements the first step towards OSTC 3 firmware update. Its not much, just file selection, but I will build up on it from there. Implements a thread to initiate firmware updates. Currently, this is for the OSTC 3. Signed-off-by: Joseph W. Joshua <joejoshw@gmail.com> Signed-off-by: Thiago Macieira <thiago@macieira.org>
Diffstat (limited to 'configuredivecomputerthreads.h')
-rw-r--r--configuredivecomputerthreads.h22
1 files changed, 20 insertions, 2 deletions
diff --git a/configuredivecomputerthreads.h b/configuredivecomputerthreads.h
index db54db460..66df7a93b 100644
--- a/configuredivecomputerthreads.h
+++ b/configuredivecomputerthreads.h
@@ -8,7 +8,8 @@
#include <QDateTime>
#include "devicedetails.h"
-class ReadSettingsThread : public QThread {
+class ReadSettingsThread : public QThread
+{
Q_OBJECT
public:
ReadSettingsThread(QObject *parent, device_data_t *data);
@@ -22,7 +23,8 @@ private:
device_data_t *m_data;
};
-class WriteSettingsThread : public QThread {
+class WriteSettingsThread : public QThread
+{
Q_OBJECT
public:
WriteSettingsThread(QObject *parent, device_data_t *data);
@@ -37,4 +39,20 @@ private:
DeviceDetails *m_deviceDetails;
};
+class FirmwareUpdateThread : public QThread
+{
+ Q_OBJECT
+public:
+ FirmwareUpdateThread(QObject *parent, device_data_t *data, QString fileName);
+ virtual void run();
+ QString lastError;
+signals:
+ void progress(int percent);
+ void message(QString msg);
+ void error(QString err);
+private:
+ device_data_t *m_data;
+ QString m_fileName;
+};
+
#endif // CONFIGUREDIVECOMPUTERTHREADS_H