-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathgloveCalibrator.h
47 lines (37 loc) · 1.05 KB
/
gloveCalibrator.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 GLOVECALIBRATOR_H
#define GLOVECALIBRATOR_H
#include <QObject>
#include <QList>
/**
* @file gloveCalibrator.h
*
* Implementation of the GloveCalibratorClass.
* Used to calibrate all sensors of the glove.
* Uses the FlexSensorCalibrator's to calibrate flex sensors.
*/
class FlexSensorCalibrator;
class GloveCalibrator : public QObject
{
Q_OBJECT
public:
GloveCalibrator();
/// Creates an object of the FlexSensorCalibrator class for each flex sensor.
void startCalibrate();
/// Removes all created FlexSensorCalibrator objects.
void stopCalibrate();
/**
* Writes sensor values from data to corresponding FlexSensorCalibrator objects.
* Can be called only between startCalibrate() and stopCalibrate().
*/
void writeData(const QList<int> &data);
/// Returns the list of min flex sensors values.
QList<int> minCalibratedList();
/// Returns the list of max flex sensors values.
QList<int> maxCalibratedList();
signals:
void calibrated();
private:
bool isCalibrateing;
QList<FlexSensorCalibrator *> mFlexCalibrators;
};
#endif // GLOVECALIBRATOR_H