1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-15 12:25:20 +03:00

Improved CMS const correctness. Added CMS and USE_MSP_DISPLAYPORT to common.h

This commit is contained in:
Martin Budden 2016-11-08 15:46:05 +00:00
parent c9b7ac21c1
commit f68e6a4d2f
10 changed files with 110 additions and 110 deletions

View file

@ -64,7 +64,7 @@ static long cmsx_menuImu_onEnter(void)
return 0;
}
static long cmsx_menuImu_onExit(OSD_Entry *self)
static long cmsx_menuImu_onExit(const OSD_Entry *self)
{
UNUSED(self);
@ -97,7 +97,7 @@ static long cmsx_PidOnEnter(void)
}
static long cmsx_PidWriteback(OSD_Entry *self)
static long cmsx_PidWriteback(const OSD_Entry *self)
{
UNUSED(self);
@ -135,12 +135,12 @@ static OSD_Entry cmsx_menuPidEntries[] =
};
static CMS_Menu cmsx_menuPid = {
"XPID",
OME_MENU,
cmsx_PidOnEnter,
cmsx_PidWriteback,
NULL,
cmsx_menuPidEntries,
.GUARD_text = "XPID",
.GUARD_type = OME_MENU,
.onEnter = cmsx_PidOnEnter,
.onExit = cmsx_PidWriteback,
.onGlobalExit = NULL,
.entries = cmsx_menuPidEntries
};
//
@ -155,7 +155,7 @@ static long cmsx_RateExpoRead(void)
return 0;
}
static long cmsx_RateExpoWriteback(OSD_Entry *self)
static long cmsx_RateExpoWriteback(const OSD_Entry *self)
{
UNUSED(self);
@ -164,7 +164,7 @@ static long cmsx_RateExpoWriteback(OSD_Entry *self)
return 0;
}
static long cmsx_menuRcConfirmBack(OSD_Entry *self)
static long cmsx_menuRcConfirmBack(const OSD_Entry *self)
{
if (self && self->type == OME_Back)
return 0;
@ -196,12 +196,12 @@ static OSD_Entry cmsx_menuRateExpoEntries[] =
};
CMS_Menu cmsx_menuRateExpo = {
"MENURATE",
OME_MENU,
cmsx_RateExpoRead,
cmsx_RateExpoWriteback,
NULL,
cmsx_menuRateExpoEntries,
.GUARD_text = "MENURATE",
.GUARD_type = OME_MENU,
.onEnter = cmsx_RateExpoRead,
.onExit = cmsx_RateExpoWriteback,
.onGlobalExit = NULL,
.entries = cmsx_menuRateExpoEntries
};
@ -227,12 +227,12 @@ static OSD_Entry cmsx_menuRcEntries[] =
};
CMS_Menu cmsx_menuRcPreview = {
"XRCPREV",
OME_MENU,
NULL,
cmsx_menuRcConfirmBack,
NULL,
cmsx_menuRcEntries,
.GUARD_text = "XRCPREV",
.GUARD_type = OME_MENU,
.onEnter = NULL,
.onExit = cmsx_menuRcConfirmBack,
.onGlobalExit = NULL,
.entries = cmsx_menuRcEntries
};
@ -256,15 +256,15 @@ static OSD_Entry menuImuMiscEntries[]=
};
CMS_Menu menuImuMisc = {
"XIMUMISC",
OME_MENU,
NULL,
NULL,
NULL,
menuImuMiscEntries,
.GUARD_text = "XIMUMISC",
.GUARD_type = OME_MENU,
.onEnter = NULL,
.onExit = NULL,
.onGlobalExit = NULL,
.entries = menuImuMiscEntries
};
static long onProfileChange(displayPort_t *pDisplay, void *ptr)
static long onProfileChange(displayPort_t *pDisplay, const void *ptr)
{
UNUSED(pDisplay);
UNUSED(ptr);