Improved swashR, flightModes & sources
This commit is contained in:
+12
-11
@@ -80,7 +80,7 @@ PACK(struct MixData {
|
||||
uint16_t spare:1 SKIP;
|
||||
int32_t offset:14;
|
||||
int32_t swtch:9 CUST(r_swtchSrc,w_swtchSrc);
|
||||
uint32_t flightModes:9; //TODO ??
|
||||
uint32_t flightModes:9 CUST(r_flightModes, w_flightModes);
|
||||
CurveRef curve;
|
||||
uint8_t delayUp;
|
||||
uint8_t delayDown;
|
||||
@@ -100,7 +100,7 @@ PACK(struct ExpoData {
|
||||
int16_t carryTrim:6;
|
||||
uint32_t chn:5;
|
||||
int32_t swtch:9 CUST(r_swtchSrc,w_swtchSrc);
|
||||
uint32_t flightModes:9; //TODO ??
|
||||
uint32_t flightModes:9 CUST(r_flightModes, w_flightModes);
|
||||
int32_t weight:8 CUST(in_read_weight,in_write_weight);
|
||||
int32_t spare:1 SKIP;
|
||||
NOBACKUP(char name[LEN_EXPOMIX_NAME]);
|
||||
@@ -244,11 +244,11 @@ PACK(struct TimerData {
|
||||
*/
|
||||
|
||||
PACK(struct SwashRingData {
|
||||
uint8_t type;
|
||||
uint8_t type ENUM(SwashType);
|
||||
uint8_t value;
|
||||
uint8_t collectiveSource;
|
||||
uint8_t aileronSource;
|
||||
uint8_t elevatorSource;
|
||||
uint8_t collectiveSource CUST(r_mixSrcRaw,w_mixSrcRaw);
|
||||
uint8_t aileronSource CUST(r_mixSrcRaw,w_mixSrcRaw);
|
||||
uint8_t elevatorSource CUST(r_mixSrcRaw,w_mixSrcRaw);
|
||||
int8_t collectiveWeight;
|
||||
int8_t aileronWeight;
|
||||
int8_t elevatorWeight;
|
||||
@@ -343,7 +343,7 @@ union TelemetryScreenData {
|
||||
#endif
|
||||
|
||||
PACK(struct VarioData {
|
||||
uint8_t source:7; // telemetry sensor idx + 1
|
||||
uint8_t source:7 CUST(r_tele_sensor,w_tele_sensor); // telemetry sensor idx + 1
|
||||
uint8_t centerSilent:1;
|
||||
int8_t centerMax;
|
||||
int8_t centerMin;
|
||||
@@ -615,9 +615,10 @@ PACK(struct CustomScreenData {
|
||||
#endif
|
||||
|
||||
#if defined(PCBX9D) || defined(PCBX9DP) || defined(PCBX9E)
|
||||
// telemetry sensor idx + 1
|
||||
#define TOPBAR_DATA \
|
||||
NOBACKUP(uint8_t voltsSource); \
|
||||
NOBACKUP(uint8_t altitudeSource);
|
||||
NOBACKUP(uint8_t voltsSource CUST(r_tele_sensor,w_tele_sensor)); \
|
||||
NOBACKUP(uint8_t altitudeSource CUST(r_tele_sensor,w_tele_sensor));
|
||||
#else
|
||||
#define TOPBAR_DATA
|
||||
#endif
|
||||
@@ -658,7 +659,7 @@ PACK(struct ModelData {
|
||||
|
||||
LogicalSwitchData logicalSw[MAX_LOGICAL_SWITCHES];
|
||||
CustomFunctionData customFn[MAX_SPECIAL_FUNCTIONS] FUNC(cfn_is_active);
|
||||
SwashRingData swashR;
|
||||
SwashRingData swashR FUNC(swash_is_active);
|
||||
FlightModeData flightModeData[MAX_FLIGHT_MODES] FUNC(fmd_is_active);
|
||||
|
||||
NOBACKUP(uint8_t thrTraceSrc);
|
||||
@@ -668,7 +669,7 @@ PACK(struct ModelData {
|
||||
GVarData gvars[MAX_GVARS];
|
||||
|
||||
NOBACKUP(VarioData varioData);
|
||||
NOBACKUP(uint8_t rssiSource);
|
||||
NOBACKUP(uint8_t rssiSource CUST(r_tele_sensor,w_tele_sensor));
|
||||
|
||||
TOPBAR_DATA
|
||||
|
||||
|
||||
@@ -496,6 +496,12 @@ bool fmd_is_active(void* user, uint8_t* data, uint32_t bitoffs)
|
||||
return is_active;
|
||||
}
|
||||
|
||||
bool swash_is_active(void* user, uint8_t* data, uint32_t bitoffs)
|
||||
{
|
||||
auto swashR = reinterpret_cast<SwashRingData*>(data + (bitoffs >> 3UL));
|
||||
return swashR->type | swashR->value;
|
||||
}
|
||||
|
||||
#define r_swtchWarn nullptr
|
||||
|
||||
bool w_swtchWarn(const YamlNode* node, uint32_t val, yaml_writer_func wf, void* opaque)
|
||||
@@ -667,3 +673,28 @@ uint8_t select_tele_screen_data(void* user, uint8_t* data, uint32_t bitoffs)
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
#define r_tele_sensor nullptr
|
||||
|
||||
bool w_tele_sensor(const YamlNode* node, uint32_t val,
|
||||
yaml_writer_func wf, void* opaque)
|
||||
{
|
||||
if (!val) {
|
||||
return wf(opaque, "none", 4);
|
||||
}
|
||||
|
||||
const char* str = yaml_unsigned2str(val-1);
|
||||
return wf(opaque, str, strlen(str));
|
||||
}
|
||||
|
||||
#define r_flightModes nullptr
|
||||
|
||||
bool w_flightModes(const YamlNode* node, uint32_t val,
|
||||
yaml_writer_func wf, void* opaque)
|
||||
{
|
||||
for (uint32_t i = 0; i < node->size; i++) {
|
||||
uint32_t bit = (val >> i) & 1;
|
||||
if (!wf(opaque, bit ? "1" : "0", 1)) return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -178,6 +178,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -446,7 +455,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -475,7 +484,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -510,11 +519,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -549,7 +558,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -804,13 +813,13 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 72, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 320, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 32, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -171,6 +171,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -416,7 +425,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -445,7 +454,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -480,11 +489,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -519,7 +528,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -777,14 +786,14 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 288, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 16, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 8 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -171,6 +171,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -416,7 +425,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -445,7 +454,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -480,11 +489,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -519,7 +528,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -777,14 +786,14 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 288, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 16, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 8 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -171,6 +171,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -416,7 +425,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -445,7 +454,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -480,11 +489,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -519,7 +528,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -777,14 +786,14 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 288, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 16, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 8 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -171,6 +171,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -416,7 +425,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -445,7 +454,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -480,11 +489,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -519,7 +528,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -777,14 +786,14 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 288, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 16, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 8 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -189,6 +189,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -463,7 +472,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -492,7 +501,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -527,11 +536,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -566,7 +575,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -821,13 +830,13 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 72, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 352, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 32, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -189,6 +189,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -463,7 +472,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -492,7 +501,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -527,11 +536,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -566,7 +575,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -821,13 +830,13 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 72, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 352, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 32, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -171,6 +171,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -416,7 +425,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -445,7 +454,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -480,11 +489,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -519,7 +528,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -777,14 +786,14 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 288, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 16, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 8 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -175,6 +175,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -424,7 +433,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -453,7 +462,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -488,11 +497,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -527,7 +536,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -790,16 +799,16 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 320, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 32, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 16 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED( "voltsSource", 8 ),
|
||||
YAML_UNSIGNED( "altitudeSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED_CUST( "voltsSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED_CUST( "altitudeSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -187,6 +187,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -463,7 +472,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -492,7 +501,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -527,11 +536,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -566,7 +575,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -829,16 +838,16 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 320, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 64, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 32 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED( "voltsSource", 8 ),
|
||||
YAML_UNSIGNED( "altitudeSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED_CUST( "voltsSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED_CUST( "altitudeSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -167,6 +167,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -401,7 +410,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -430,7 +439,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -465,11 +474,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -504,7 +513,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -762,14 +771,14 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 288, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 16, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 8 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -169,6 +169,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -411,7 +420,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -440,7 +449,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -475,11 +484,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -514,7 +523,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -772,14 +781,14 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 288, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 16, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 8 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -169,6 +169,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -408,7 +417,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -437,7 +446,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -472,11 +481,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -511,7 +520,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -769,14 +778,14 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 288, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 16, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 8 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -171,6 +171,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -412,7 +421,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -441,7 +450,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -476,11 +485,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -515,7 +524,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -773,14 +782,14 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 288, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 16, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 8 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -188,12 +188,14 @@ const char * readModelYaml(const char * filename, uint8_t * buffer, uint32_t siz
|
||||
// YAML reader
|
||||
TRACE("YAML model reader");
|
||||
|
||||
bool init_model = true;
|
||||
const YamlNode* data_nodes = nullptr;
|
||||
if (size == sizeof(g_model)) {
|
||||
data_nodes = get_modeldata_nodes();
|
||||
}
|
||||
else if (size == sizeof(PartialModel)) {
|
||||
data_nodes = get_partialmodel_nodes();
|
||||
init_model = false;
|
||||
}
|
||||
else {
|
||||
TRACE("cannot find YAML data nodes for object size (size=%d)", size);
|
||||
@@ -209,16 +211,23 @@ const char * readModelYaml(const char * filename, uint8_t * buffer, uint32_t siz
|
||||
// wipe memory before reading YAML
|
||||
memset(buffer,0,size);
|
||||
|
||||
if (init_model) {
|
||||
auto md = reinterpret_cast<ModelData*>(buffer);
|
||||
#if defined(FLIGHT_MODES) && defined(GVARS)
|
||||
// reset GVars to default values
|
||||
// Note: taken from opentx.cpp::modelDefault()
|
||||
//TODO: new func in gvars
|
||||
for (int p=1; p<MAX_FLIGHT_MODES; p++) {
|
||||
// reset GVars to default values
|
||||
// Note: taken from opentx.cpp::modelDefault()
|
||||
//TODO: new func in gvars
|
||||
for (int p=1; p<MAX_FLIGHT_MODES; p++) {
|
||||
for (int i=0; i<MAX_GVARS; i++) {
|
||||
g_model.flightModeData[p].gvars[i] = GVAR_MAX+1;
|
||||
md->flightModeData[p].gvars[i] = GVAR_MAX+1;
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
// is that necessary ???
|
||||
// md->swashR.collectiveWeight = 100;
|
||||
// md->swashR.aileronWeight = 100;
|
||||
// md->swashR.elevatorWeight = 100;
|
||||
}
|
||||
|
||||
*version = 255; // max version number
|
||||
return readYamlFile(path, YamlTreeWalker::get_parser_calls(), &tree);
|
||||
|
||||
@@ -42,6 +42,7 @@ namespace yaml_conv_220 {
|
||||
bool cfn_is_active(void* user, uint8_t* data, uint32_t bitoffs);
|
||||
bool gvar_is_active(void* user, uint8_t* data, uint32_t bitoffs);
|
||||
bool fmd_is_active(void* user, uint8_t* data, uint32_t bitoffs);
|
||||
bool swash_is_active(void* user, uint8_t* data, uint32_t bitoffs);
|
||||
bool w_beeperMode(const YamlNode* node, uint32_t val, yaml_writer_func wf, void* opaque);
|
||||
bool w_5pos(const YamlNode* node, uint32_t val, yaml_writer_func wf, void* opaque);
|
||||
bool w_vol(const YamlNode* node, uint32_t val, yaml_writer_func wf, void* opaque);
|
||||
@@ -55,6 +56,12 @@ namespace yaml_conv_220 {
|
||||
extern const char* _tele_screen_type_lookup[];
|
||||
bool w_tele_screen_type(void* user, uint8_t* data, uint32_t bitoffs,
|
||||
yaml_writer_func wf, void* opaque);
|
||||
|
||||
bool w_tele_sensor(const YamlNode* node, uint32_t val,
|
||||
yaml_writer_func wf, void* opaque);
|
||||
|
||||
bool w_flightModes(const YamlNode* node, uint32_t val,
|
||||
yaml_writer_func wf, void* opaque);
|
||||
};
|
||||
|
||||
//
|
||||
@@ -595,6 +602,11 @@ static bool fmd_is_active(void* user, uint8_t* data, uint32_t bitoffs)
|
||||
return yaml_conv_220::fmd_is_active(user, data, bitoffs);
|
||||
}
|
||||
|
||||
static bool swash_is_active(void* user, uint8_t* data, uint32_t bitoffs)
|
||||
{
|
||||
return yaml_conv_220::swash_is_active(user, data, bitoffs);
|
||||
}
|
||||
|
||||
static uint32_t r_swtchWarn(const YamlNode* node, const char* val, uint8_t val_len)
|
||||
{
|
||||
// Read from string like 'AdBuC-':
|
||||
@@ -812,3 +824,34 @@ static uint8_t select_tele_screen_data(void* user, uint8_t* data, uint32_t bitof
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
static uint32_t r_tele_sensor(const YamlNode* node, const char* val, uint8_t val_len)
|
||||
{
|
||||
if (val_len == 0 || val[0] < '0' || val[0] > '9') return 0;
|
||||
return yaml_str2uint(val, val_len) + 1;
|
||||
}
|
||||
|
||||
static bool w_tele_sensor(const YamlNode* node, uint32_t val,
|
||||
yaml_writer_func wf, void* opaque)
|
||||
{
|
||||
return yaml_conv_220::w_tele_sensor(node, val, wf, opaque);
|
||||
}
|
||||
|
||||
static uint32_t r_flightModes(const YamlNode* node, const char* val, uint8_t val_len)
|
||||
{
|
||||
uint32_t bits = 0;
|
||||
uint32_t mask = 1;
|
||||
|
||||
for (uint32_t i = 0; i < val_len; i++) {
|
||||
if (val[i] == '1') bits |= mask;
|
||||
mask <<= 1;
|
||||
}
|
||||
|
||||
return bits;
|
||||
}
|
||||
|
||||
static bool w_flightModes(const YamlNode* node, uint32_t val,
|
||||
yaml_writer_func wf, void* opaque)
|
||||
{
|
||||
return yaml_conv_220::w_flightModes(node, val, wf, opaque);
|
||||
}
|
||||
|
||||
@@ -178,6 +178,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -446,7 +455,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -475,7 +484,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -510,11 +519,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -549,7 +558,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -804,13 +813,13 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 72, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 320, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 32, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -171,6 +171,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -416,7 +425,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -445,7 +454,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -480,11 +489,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -519,7 +528,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -777,14 +786,14 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 288, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 16, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 8 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -171,6 +171,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -416,7 +425,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -445,7 +454,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -480,11 +489,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -519,7 +528,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -777,14 +786,14 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 288, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 16, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 8 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -171,6 +171,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -416,7 +425,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -445,7 +454,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -480,11 +489,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -519,7 +528,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -777,14 +786,14 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 288, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 16, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 8 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -171,6 +171,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -416,7 +425,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -445,7 +454,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -480,11 +489,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -519,7 +528,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -777,14 +786,14 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 288, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 16, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 8 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -189,6 +189,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -463,7 +472,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -492,7 +501,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -527,11 +536,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -566,7 +575,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -821,13 +830,13 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 72, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 352, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 32, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -189,6 +189,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -463,7 +472,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -492,7 +501,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -527,11 +536,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -566,7 +575,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -821,13 +830,13 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 72, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 352, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 32, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -171,6 +171,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -416,7 +425,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -445,7 +454,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -480,11 +489,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -519,7 +528,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -777,14 +786,14 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 288, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 16, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 8 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -175,6 +175,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -424,7 +433,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -453,7 +462,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -488,11 +497,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -527,7 +536,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -790,16 +799,16 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 320, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 32, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 16 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED( "voltsSource", 8 ),
|
||||
YAML_UNSIGNED( "altitudeSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED_CUST( "voltsSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED_CUST( "altitudeSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -187,6 +187,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -463,7 +472,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -492,7 +501,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -527,11 +536,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -566,7 +575,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -829,16 +838,16 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 320, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 64, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 32 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED( "voltsSource", 8 ),
|
||||
YAML_UNSIGNED( "altitudeSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED_CUST( "voltsSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED_CUST( "altitudeSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -167,6 +167,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -401,7 +410,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -430,7 +439,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -465,11 +474,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -504,7 +513,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -762,14 +771,14 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 288, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 16, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 8 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -169,6 +169,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -411,7 +420,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -440,7 +449,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -475,11 +484,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -514,7 +523,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -772,14 +781,14 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 288, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 16, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 8 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -169,6 +169,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -408,7 +417,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -437,7 +446,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -472,11 +481,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -511,7 +520,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -769,14 +778,14 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 288, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 16, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 8 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
@@ -171,6 +171,15 @@ const struct YamlIdStr enum_LogicalSwitchesFunctions[] = {
|
||||
{ LS_FUNC_MAX, "FUNC_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwashType[] = {
|
||||
{ SWASH_TYPE_NONE, "TYPE_NONE" },
|
||||
{ SWASH_TYPE_120, "TYPE_120" },
|
||||
{ SWASH_TYPE_120X, "TYPE_120X" },
|
||||
{ SWASH_TYPE_140, "TYPE_140" },
|
||||
{ SWASH_TYPE_90, "TYPE_90" },
|
||||
{ SWASH_TYPE_MAX, "TYPE_MAX" },
|
||||
{ 0, NULL }
|
||||
};
|
||||
const struct YamlIdStr enum_SwitchSources[] = {
|
||||
{ SWSRC_NONE, "NONE" },
|
||||
{ SWSRC_SA0, "SA0" },
|
||||
@@ -412,7 +421,7 @@ static const struct YamlNode struct_MixData[] = {
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_SIGNED( "offset", 14 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_STRUCT("curve", 16, struct_CurveRef, NULL),
|
||||
YAML_UNSIGNED( "delayUp", 8 ),
|
||||
YAML_UNSIGNED( "delayDown", 8 ),
|
||||
@@ -441,7 +450,7 @@ static const struct YamlNode struct_ExpoData[] = {
|
||||
YAML_SIGNED( "carryTrim", 6 ),
|
||||
YAML_UNSIGNED( "chn", 5 ),
|
||||
YAML_SIGNED_CUST( "swtch", 9, r_swtchSrc, w_swtchSrc ),
|
||||
YAML_UNSIGNED( "flightModes", 9 ),
|
||||
YAML_UNSIGNED_CUST( "flightModes", 9, r_flightModes, w_flightModes ),
|
||||
YAML_SIGNED_CUST( "weight", 8, in_read_weight, in_write_weight ),
|
||||
YAML_PADDING( 1 ),
|
||||
YAML_STRING("name", 6),
|
||||
@@ -476,11 +485,11 @@ static const struct YamlNode struct_LogicalSwitchData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_SwashRingData[] = {
|
||||
YAML_UNSIGNED( "type", 8 ),
|
||||
YAML_ENUM("type", 8, enum_SwashType),
|
||||
YAML_UNSIGNED( "value", 8 ),
|
||||
YAML_UNSIGNED( "collectiveSource", 8 ),
|
||||
YAML_UNSIGNED( "aileronSource", 8 ),
|
||||
YAML_UNSIGNED( "elevatorSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "collectiveSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "aileronSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_UNSIGNED_CUST( "elevatorSource", 8, r_mixSrcRaw, w_mixSrcRaw ),
|
||||
YAML_SIGNED( "collectiveWeight", 8 ),
|
||||
YAML_SIGNED( "aileronWeight", 8 ),
|
||||
YAML_SIGNED( "elevatorWeight", 8 ),
|
||||
@@ -515,7 +524,7 @@ static const struct YamlNode struct_GVarData[] = {
|
||||
YAML_END
|
||||
};
|
||||
static const struct YamlNode struct_VarioData[] = {
|
||||
YAML_UNSIGNED( "source", 7 ),
|
||||
YAML_UNSIGNED_CUST( "source", 7, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_UNSIGNED( "centerSilent", 1 ),
|
||||
YAML_SIGNED( "centerMax", 8 ),
|
||||
YAML_SIGNED( "centerMin", 8 ),
|
||||
@@ -773,14 +782,14 @@ static const struct YamlNode struct_ModelData[] = {
|
||||
YAML_ARRAY("points", 8, 512, struct_signed_8, NULL),
|
||||
YAML_ARRAY("logicalSw", 72, 64, struct_LogicalSwitchData, NULL),
|
||||
YAML_ARRAY("customFn", 88, 64, struct_CustomFunctionData, cfn_is_active),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, NULL),
|
||||
YAML_STRUCT("swashR", 64, struct_SwashRingData, swash_is_active),
|
||||
YAML_ARRAY("flightModeData", 288, 9, struct_FlightModeData, fmd_is_active),
|
||||
YAML_UNSIGNED( "thrTraceSrc", 8 ),
|
||||
YAML_UNSIGNED_CUST( "switchWarningState", 16, r_swtchWarn, w_swtchWarn ),
|
||||
YAML_UNSIGNED( "switchWarningEnable", 8 ),
|
||||
YAML_ARRAY("gvars", 56, 9, struct_GVarData, NULL),
|
||||
YAML_STRUCT("varioData", 40, struct_VarioData, NULL),
|
||||
YAML_UNSIGNED( "rssiSource", 8 ),
|
||||
YAML_UNSIGNED_CUST( "rssiSource", 8, r_tele_sensor, w_tele_sensor ),
|
||||
YAML_STRUCT("rssiAlarms", 16, struct_RssiAlarmData, NULL),
|
||||
YAML_PADDING( 3 ),
|
||||
YAML_UNSIGNED( "thrTrimSw", 3 ),
|
||||
|
||||
Reference in New Issue
Block a user