0
mirror of https://github.com/OneOfEleven/uv-k5-firmware-custom.git synced 2025-06-20 15:08:37 +03:00

Fast manual up/down frequency scan

This commit is contained in:
OneOfEleven
2023-10-16 06:54:27 +01:00
parent 244c4f1091
commit 7b44bb6253
6 changed files with 12 additions and 3 deletions

View File

@ -723,6 +723,10 @@ static void MAIN_Key_UP_DOWN(bool key_pressed, bool key_held, scan_state_dir_t D
// only update eeprom when the key is released (saves wear and tear)
if (!key_pressed && g_scan_state_dir == SCAN_STATE_DIR_OFF && IS_NOT_NOAA_CHANNEL(Channel) && IS_FREQ_CHANNEL(Channel))
{
// monitor off
if (key_held && !key_pressed && g_current_function == FUNCTION_MONITOR)
APP_start_listening(FUNCTION_RECEIVE, false);
SETTINGS_SaveChannel(g_tx_vfo->channel_save, g_eeprom.tx_vfo, g_tx_vfo, 1);
#if defined(ENABLE_UART) && defined(ENABLE_UART_DEBUG)
@ -794,6 +798,11 @@ static void MAIN_Key_UP_DOWN(bool key_pressed, bool key_held, scan_state_dir_t D
}
else
{ // don't need to go through all the other stuff
// open the squelch
if (key_held && key_pressed && g_current_function != FUNCTION_MONITOR)
APP_start_listening(FUNCTION_MONITOR, false);
BK4819_set_rf_frequency(frequency, true);
//BK4819_PickRXFilterPathBasedOnFrequency(frequency);
}