Fixes #3937: When executed from Special Functions, Flight Reset cause… (#3942)

* Fixes #3937: When executed from Special Functions, Flight Reset caused a GUI lockup

* Cosmetics
This commit is contained in:
Damjan Adamic
2016-10-21 12:16:33 +02:00
committed by Andre Bernet
parent 81e9fe5201
commit f4b54ea332
4 changed files with 27 additions and 14 deletions
+5 -1
View File
@@ -340,7 +340,11 @@ void evalFunctions()
timerReset(CFN_PARAM(cfn));
break;
case FUNC_RESET_FLIGHT:
#if defined(CPUARM)
mainRequestFlags |= (1 << REQUEST_FLIGHT_RESET); // on systems with threads flightReset() must not be called from the mixers thread!
#else
flightReset();
#endif // defined(CPUARM)
break;
#if defined(TELEMETRY_FRSKY)
case FUNC_RESET_TELEMETRY:
@@ -573,7 +577,7 @@ void evalFunctions()
#if defined(PCBTARANIS)
case FUNC_SCREENSHOT:
if (!(functionsContext.activeSwitches & switch_mask)) {
requestScreenshot = true;
mainRequestFlags |= (1 << REQUEST_SCREENSHOT);
}
break;
#endif