Add SetKey for RescueOps

This commit is contained in:
Armel FAUVEAU
2024-11-13 06:17:32 +01:00
parent cd5caff593
commit 397561e0e1
7 changed files with 55 additions and 8 deletions

View File

@@ -158,6 +158,9 @@ const t_menu_item MenuList[] =
#ifdef ENABLE_FEAT_F4HWN_VOL
{"SetVol", MENU_SET_VOL },
#endif
#ifdef ENABLE_FEAT_F4HWN_MENU_LOCK
{"SetKey", MENU_SET_KEY },
#endif
#endif
// hidden menu items from here on
// enabled if pressing both the PTT and upper side button at power-on
@@ -397,6 +400,17 @@ const char gSubMenu_SCRAMBLER[][7] =
"NARROWER"
};
#endif
#ifdef ENABLE_FEAT_F4HWN_MENU_LOCK
const char gSubMenu_SET_KEY[][9] =
{
"KEY_MENU",
"KEY_UP",
"KEY_DOWN",
"KEY_EXIT",
"KEY_STAR"
};
#endif
#endif
const t_sidefunction gSubMenu_SIDEFUNCTIONS[] =
@@ -1065,6 +1079,12 @@ void UI_DisplayMenu(void)
(gEeprom.DAC_GAIN << 0)); // AF DAC Gain (after Gain-1 and Gain-2)
break;
#endif
#ifdef ENABLE_FEAT_F4HWN_MENU_LOCK
case MENU_SET_KEY:
strcpy(String, gSubMenu_SET_KEY[gSubMenuSelection]);
break;
#endif
#endif
}

View File

@@ -147,6 +147,9 @@ enum
#ifdef ENABLE_FEAT_F4HWN_VOL
MENU_SET_VOL,
#endif
#ifdef ENABLE_FEAT_F4HWN_MENU_LOCK
MENU_SET_KEY,
#endif
#endif
MENU_BATCAL, // battery voltage calibration
MENU_F1SHRT,
@@ -187,6 +190,9 @@ extern const char gSubMenu_D_RSP[4][11];
#ifdef ENABLE_FEAT_F4HWN_NARROWER
extern const char gSubMenu_SET_NFM[2][9];
#endif
#ifdef ENABLE_FEAT_F4HWN_MENU_LOCK
extern const char gSubMenu_SET_KEY[][9];
#endif
#endif
extern const char* const gSubMenu_PTT_ID[5];