-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathparameterbox.h
61 lines (50 loc) · 1.56 KB
/
parameterbox.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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
#ifndef PARAMETERBOX_H
#define PARAMETERBOX_H
#include "motorparameter.h"
class ParameterBox
{
public:
ParameterBox();
ParameterBox(MotorParameter *fptr, int fcount, unsigned char saddr, unsigned char fbyteCount, int tokener);
ParameterBox(MotorParameter *fptr, int fcount, int tokener);
void popParams(MotorParameter *fptr, int fcount, int tokener);
void setMotorParameter(MotorParameter param, int position);
void genParams(int scount);
void setUp(int scount, unsigned char addr, int boxIndex, int ftype);
void setByteCount();
void assignValues(unsigned char* cData, int cLength);
void setToken(int tokener);
void upTransient(int cardCount, QString ftransient);
void setTitle(QString title);
void setType (int ftype);
void setPage(int tpage);
bool checkWrite(int boxToken, int cardToken);
MotorParameter getMotorParameter(int position);
void copyBox(ParameterBox in);
void copyBox(ParameterBox *in);
void overwriteBox(ParameterBox newBox);
void overwriteBox(ParameterBox *newBox);
bool resetBinaries();
void printContents();
int getCount();
MotorParameter *getPtr();
int getToken();
unsigned char getAddr();
int getByteCount();
QString getTitle();
int getType();
int getPage();
private:
MotorParameter *ptr;
int count;
unsigned char StartAddr;
int byteCount;
int token;
QString tabTitle;
//0 -> stable parameterset
//1 -> mutable parameterset
//2 -> flag parameterset
int pollType;
int page;
};
#endif // PARAMETERBOX_H