-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathConfig.h
More file actions
78 lines (69 loc) · 1.52 KB
/
Config.h
File metadata and controls
78 lines (69 loc) · 1.52 KB
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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
#ifndef ServoController_h
#define ServoController_h
#include <WString.h>
#define CONFIG_VERSION "RSV2"
#define CONFIG_VERSION_L 5
#define CONFIG_SSID_L 16
#define CONFIG_PASSW_L 64
#define CONFIG_SERVO_PRESET_L 5
#define CONFIG_SERVO_PRESET_MAX 3
#define MIN_IDX 0
#define MAX_IDX 1
typedef enum {
xAxis,
yAxis,
zAxis,
} referenceAxis_t;
typedef enum {
P001,
P010,
P050,
P100,
} precision_t;
typedef enum {
ARC,
CHORD,
VERTICAL_DISTANCE,
} amplitude_calc_method_t;
typedef enum {
jeti,
futaba,
hott,
spektrum,
taranis,
multiplex,
custom
} rc_vendor_t;
// Types 'byte' und 'word' doesn't work!
typedef struct {
char version[CONFIG_VERSION_L];
char wlanSsid[CONFIG_SSID_L];
char wlanPasswd[CONFIG_PASSW_L];
char apSsid[CONFIG_SSID_L];
char apPasswd[CONFIG_PASSW_L];
boolean apIsActive;
referenceAxis_t axis;
int angleInversion;
precision_t anglePrecision;
precision_t amplitudePrecision;
int amplitudeInversion;
amplitude_calc_method_t amplitudeCalcMethod;
int16_t xAccelOffset;
int16_t yAccelOffset;
int16_t zAccelOffset;
int16_t xGyroOffset;
int16_t yGyroOffset;
int16_t zGyroOffset;
int16_t calibrationOffsetHigh;
int16_t calibrationOffsetLow;
boolean calibrationOffsetEnabled;
boolean servoInversion;
rc_vendor_t servoRangeByVendor;
int servoPresets[CONFIG_SERVO_PRESET_L];
int servoPulseWidthPairFullRange[2];
int servoPulseWidthPair100Percent[2];
int16_t rudderSize;
boolean oledFlipped;
boolean rotaryEncoderFlipped;
} configData_t;
#endif