diff --git a/src/main/fc/fc_dispatch.c b/src/main/fc/fc_dispatch.c index cc46e53d5..5080f8891 100644 --- a/src/main/fc/fc_dispatch.c +++ b/src/main/fc/fc_dispatch.c @@ -29,12 +29,12 @@ static dispatchEntry_t *head = NULL; static bool dispatchEnabled = false; -bool isDispatchEnabled(void) +bool dispatchIsEnabled(void) { return dispatchEnabled; } -void dispatchStart(void) +void dispatchEnable(void) { dispatchEnabled = true; } diff --git a/src/main/fc/fc_dispatch.h b/src/main/fc/fc_dispatch.h index bc3b14095..588c33c8e 100644 --- a/src/main/fc/fc_dispatch.h +++ b/src/main/fc/fc_dispatch.h @@ -26,7 +26,7 @@ typedef struct dispatchEntry_s { struct dispatchEntry_s *next; } dispatchEntry_t; -bool isDispatchEnabled(void); -void dispatchStart(void); +bool dispatchIsEnabled(void); +void dispatchEnable(void); void dispatchProcess(uint32_t currentTime); void dispatchAdd(dispatchEntry_t *entry, int delayUs); diff --git a/src/main/fc/fc_tasks.c b/src/main/fc/fc_tasks.c index 1ff15c214..b45ae4477 100644 --- a/src/main/fc/fc_tasks.c +++ b/src/main/fc/fc_tasks.c @@ -235,9 +235,7 @@ void fcTasksInit(void) setTaskEnabled(TASK_BATTERY, feature(FEATURE_VBAT) || feature(FEATURE_CURRENT_METER)); setTaskEnabled(TASK_RX, true); - if (isDispatchEnabled()) { - setTaskEnabled(TASK_DISPATCH, true); - } + setTaskEnabled(TASK_DISPATCH, dispatchIsEnabled()); #ifdef BEEPER setTaskEnabled(TASK_BEEPER, true); diff --git a/src/main/rx/spektrum.c b/src/main/rx/spektrum.c index da0b64fdd..640f7d89e 100644 --- a/src/main/rx/spektrum.c +++ b/src/main/rx/spektrum.c @@ -317,7 +317,7 @@ bool spektrumInit(const rxConfig_t *rxConfig, rxRuntimeConfig_t *rxRuntimeConfig } if (serialPort && srxlEnabled) { - dispatchStart(); + dispatchEnable(); } return serialPort != NULL; }