Stop using 50ms mixer period when no module enabled
Also adds a 2ms mixer period if internal and external modules are stopped but joystick mode is active
This commit is contained in:
committed by
Peter Feerick
parent
4258684248
commit
31cb282dd2
@@ -45,6 +45,11 @@ uint16_t getMixerSchedulerPeriod()
|
||||
if (mixerSchedules[EXTERNAL_MODULE].period) {
|
||||
return mixerSchedules[EXTERNAL_MODULE].period;
|
||||
}
|
||||
#endif
|
||||
#if defined(STM32) && !defined(SIMU)
|
||||
if (getSelectedUsbMode() == USB_JOYSTICK_MODE) {
|
||||
return MIXER_SCHEDULER_JOYSTICK_PERIOD_US;
|
||||
}
|
||||
#endif
|
||||
return MIXER_SCHEDULER_DEFAULT_PERIOD_US;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user