0
mirror of https://github.com/OneOfEleven/uv-k5-firmware-custom.git synced 2025-04-28 22:31:25 +03:00

Unlocked TX still bound by the frequency table.

This commit is contained in:
OneOfEleven 2023-10-18 13:54:43 +01:00
parent 2bd8db1714
commit 2e880a61e1
6 changed files with 14 additions and 9 deletions

View File

@ -119,7 +119,6 @@ int MENU_GetLimits(uint8_t Cursor, int32_t *pMin, int32_t *pMax)
case MENU_FREQ_LOCK:
*pMin = 0;
// *pMax = ARRAY_SIZE(g_sub_menu_freq_lock) - 1;
*pMax = FREQ_LOCK_LAST - 1;
break;

Binary file not shown.

Binary file not shown.

View File

@ -208,7 +208,13 @@ int TX_freq_check(const uint32_t Frequency)
#ifdef ENABLE_TX_UNLOCK
case FREQ_LOCK_TX_UNLOCK:
{
unsigned int i;
for (i = 0; i < ARRAY_SIZE(FREQ_BAND_TABLE); i++)
if (Frequency >= FREQ_BAND_TABLE[i].lower && Frequency < FREQ_BAND_TABLE[i].upper)
return 0;
break;
}
#endif
}

View File

@ -139,11 +139,11 @@ enum
MENU_SCRAMBLER_EN, // scrambler enable/disable
MENU_FREQ_LOCK, // lock to a selected region
MENU_174_TX, // 174~350MHz TX enable/disable
MENU_350_EN, // 350~400MHz enable/disable
MENU_174_TX, // 174~350MHz TX enable/disable
MENU_350_TX, // 350~400MHz TX enable/disable
MENU_470_TX, // 470MHz and up TX enable/disable
MENU_TX_EN, // can disable the TX entirely
MENU_TX_EN, // disable the TX entirely
// ************************************
// ************************************