Issue #469 fixed (Telemetry tab in Companion rewritten - 20% code

removed). More tests needed!
This commit is contained in:
Bertrand Songis
2014-01-31 09:40:34 +01:00
parent 59d8653b61
commit ce2b033ccb
10 changed files with 479 additions and 1709 deletions
+11 -3
View File
@@ -296,7 +296,7 @@ class RawSourceRange
}
float getValue(int value) {
return round(float(value) * step);
return min + float(value) * step;
}
int decimals;
@@ -737,6 +737,14 @@ class FrSkyChannelData {
unsigned int multiplier;
FrSkyAlarmData alarms[2];
float getRatio()
{
if (type==0 || type==1 || type==2)
return float(ratio << multiplier) / 10.0;
else
return ratio << multiplier;
}
void clear() { memset(this, 0, sizeof(FrSkyChannelData)); }
};
@@ -1007,8 +1015,8 @@ enum Capability {
GvarsHaveSources,
GvarsName,
NoTelemetryProtocol,
TelemetryCSFields,
TelemetryColsCSFields,
TelemetryCustomScreens,
TelemetryCustomScreensFieldsPerLine,
TelemetryRSSIModel,
TelemetryAlarm,
TelemetryInternalAlarm,