Reset SF can now reset individual telemetry items (fix #161)
This commit is contained in:
@@ -41,6 +41,7 @@ CustomFunctionsContext modelFunctionsContext = { 0 };
|
||||
|
||||
#if defined(CPUARM)
|
||||
CustomFunctionsContext globalFunctionsContext = { 0 };
|
||||
extern TelemetryItem telemetryItems[];
|
||||
#endif
|
||||
|
||||
|
||||
@@ -355,6 +356,12 @@ void evalFunctions()
|
||||
break;
|
||||
#endif
|
||||
}
|
||||
#if defined(CPUARM)
|
||||
if (CFN_PARAM(cfn)>=FUNC_RESET_PARAM_FIRST_TELEM) {
|
||||
TelemetryItem * telemetryItem = & telemetryItems[CFN_PARAM(cfn)-FUNC_RESET_PARAM_FIRST_TELEM];
|
||||
telemetryItem->clear();
|
||||
}
|
||||
#endif
|
||||
break;
|
||||
|
||||
#if defined(CPUARM)
|
||||
|
||||
Reference in New Issue
Block a user