Tidied up CMS related #defines

This commit is contained in:
Martin Budden 2016-11-08 06:11:32 +00:00
parent 30dfe0c3a5
commit 2a2960f584
5 changed files with 6 additions and 16 deletions

View File

@ -332,8 +332,7 @@ void fcTasksInit(void)
setTaskEnabled(TASK_BST_MASTER_PROCESS, true);
#endif
#ifdef CMS
// XXX Should check FEATURE
setTaskEnabled(TASK_CMS, true);
setTaskEnabled(TASK_CMS, feature(FEATURE_OSD) || feature(FEATURE_DASHBOARD));
#endif
}

View File

@ -589,7 +589,7 @@ void dashboardUpdate(uint32_t currentTime)
{
static uint8_t previousArmedState = 0;
#ifdef OLEDCMS
#ifdef CMS
if (displayIsGrabbed(displayPort)) {
return;
}
@ -707,7 +707,7 @@ void dashboardInit(rxConfig_t *rxConfigToUse)
delay(200);
displayPort = displayPortOledInit();
#if defined(CMS) && defined(OLEDCMS)
#if defined(CMS)
cmsDisplayPortRegister(displayPort);
#endif

View File

@ -97,12 +97,9 @@
#define CMS
#define CMS_MAX_DEVICE 4
// Use external display to run CMS
// Use external display connected by MSP to run CMS
#define USE_MSP_DISPLAYPORT
// USE I2C OLED display to run CMS
#define OLEDCMS
// OSD define info:
// feature name (includes source) -> MAX_OSD, used in target.mk
// include the osd code

View File

@ -144,12 +144,9 @@
// Configuratoin Menu System
#define CMS
// Use external display to run CMS
// Use external display connected by MSP to run CMS
#define USE_MSP_DISPLAYPORT
// USE I2C OLED display to run CMS
#define OLEDCMS
#define CONFIG_FASTLOOP_PREFERRED_ACC ACC_DEFAULT
#define USE_SERVOS

View File

@ -145,8 +145,5 @@
// Configuratoin Menu System
#define CMS
// Use external display to run CMS
// Use external display connected by MSP to run CMS
#define USE_MSP_DISPLAYPORT
// USE I2C OLED display to run CMS
#define OLEDCMS