Fix dashboard initialization order

This commit is contained in:
jflyper 2020-02-03 13:05:08 +09:00
parent a573c8972a
commit c172ab3193
1 changed files with 6 additions and 11 deletions

View File

@ -901,17 +901,6 @@ void init(void)
batteryInit(); // always needs doing, regardless of features.
#ifdef USE_DASHBOARD
if (featureIsEnabled(FEATURE_DASHBOARD)) {
#ifdef USE_OLED_GPS_DEBUG_PAGE_ONLY
dashboardShowFixedPage(PAGE_GPS);
#else
dashboardResetPageCycling();
dashboardEnablePageCycling();
#endif
}
#endif
#ifdef USE_RCDEVICE
rcdeviceInit();
#endif // USE_RCDEVICE
@ -1003,6 +992,12 @@ void init(void)
// Dashbord will register with CMS by itself.
if (featureIsEnabled(FEATURE_DASHBOARD)) {
dashboardInit();
#ifdef USE_OLED_GPS_DEBUG_PAGE_ONLY
dashboardShowFixedPage(PAGE_GPS);
#else
dashboardResetPageCycling();
dashboardEnablePageCycling();
#endif
}
#endif