0
mirror of https://github.com/OneOfEleven/uv-k5-firmware-custom.git synced 2025-04-30 15:21:26 +03:00
This commit is contained in:
OneOfEleven 2023-10-30 00:14:38 +00:00
parent f3e347bc5a
commit dac0cc0d18
7 changed files with 75 additions and 72 deletions

View File

@ -30,7 +30,7 @@ ENABLE_MUTE_RADIO_FOR_VOICE := 0
# Tx on Voice 1.0 kB # Tx on Voice 1.0 kB
ENABLE_VOX := 0 ENABLE_VOX := 0
ENABLE_REDUCE_LOW_MID_TX_POWER := 1 ENABLE_REDUCE_LOW_MID_TX_POWER := 1
# Tx Alarm 0.6 kB # Tx Alarm 600 B
ENABLE_ALARM := 0 ENABLE_ALARM := 0
ENABLE_TX1750 := 1 ENABLE_TX1750 := 1
# MDC1200 2.8 kB # MDC1200 2.8 kB
@ -42,12 +42,12 @@ ENABLE_BIG_FREQ := 0
ENABLE_SMALL_BOLD := 1 ENABLE_SMALL_BOLD := 1
# smallest font 2 kB # smallest font 2 kB
ENABLE_SMALLEST_FONT := 0 ENABLE_SMALLEST_FONT := 0
# trim trailing 0.044 kB # trim trailing 44 B
ENABLE_TRIM_TRAILING_ZEROS := 1 ENABLE_TRIM_TRAILING_ZEROS := 1
ENABLE_KEEP_MEM_NAME := 1 ENABLE_KEEP_MEM_NAME := 1
ENABLE_WIDE_RX := 1 ENABLE_WIDE_RX := 1
ENABLE_TX_WHEN_AM := 0 ENABLE_TX_WHEN_AM := 0
# Freq calibration 0.188 kB # Freq calibration 188 B
ENABLE_F_CAL_MENU := 0 ENABLE_F_CAL_MENU := 0
ENABLE_TX_UNLOCK := 0 ENABLE_TX_UNLOCK := 0
ENABLE_CTCSS_TAIL_PHASE_SHIFT := 1 ENABLE_CTCSS_TAIL_PHASE_SHIFT := 1
@ -59,25 +59,25 @@ ENABLE_SHOW_CHARGE_LEVEL := 0
ENABLE_REVERSE_BAT_SYMBOL := 1 ENABLE_REVERSE_BAT_SYMBOL := 1
ENABLE_FREQ_SEARCH_TIMEOUT := 0 ENABLE_FREQ_SEARCH_TIMEOUT := 0
ENABLE_CODE_SEARCH_TIMEOUT := 0 ENABLE_CODE_SEARCH_TIMEOUT := 0
# Kill and Revive 0.4 kB # Kill and Revive 400 B
ENABLE_KILL_REVIVE := 0 ENABLE_KILL_REVIVE := 0
# AM Fix 0.8 kB # AM Fix 800 B
ENABLE_AM_FIX := 1 ENABLE_AM_FIX := 1
ENABLE_AM_FIX_SHOW_DATA := 0 ENABLE_AM_FIX_SHOW_DATA := 0
# Squelch 0.012 kB .. can't be right ? # Squelch 12 B .. can't be right ?
ENABLE_SQUELCH_MORE_SENSITIVE := 1 ENABLE_SQUELCH_MORE_SENSITIVE := 1
ENABLE_SQ_OPEN_WITH_UP_DN_BUTTS := 1 ENABLE_SQ_OPEN_WITH_UP_DN_BUTTS := 1
ENABLE_FASTER_CHANNEL_SCAN := 1 ENABLE_FASTER_CHANNEL_SCAN := 1
ENABLE_COPY_CHAN_TO_VFO_TO_CHAN := 1 ENABLE_COPY_CHAN_TO_VFO_TO_CHAN := 1
# Rx Signal Bar 0.4 kB # Rx Signal Bar 400 B
ENABLE_RX_SIGNAL_BAR := 0 ENABLE_RX_SIGNAL_BAR := 1
# Tx Timeout Bar 0.2 kB # Tx Timeout Bar 200 B
ENABLE_TX_TIMEOUT_BAR := 0 ENABLE_TX_TIMEOUT_BAR := 0
# Tx Audio Bar 0.3 kB # Tx Audio Bar 300 B
ENABLE_TX_AUDIO_BAR := 1 ENABLE_TX_AUDIO_BAR := 1
# Side Button Menu 0.3 kB # Side Button Menu 300 B
ENABLE_SIDE_BUTT_MENU := 1 ENABLE_SIDE_BUTT_MENU := 1
# Key Lock 0.4 kB # Key Lock 400 B
ENABLE_KEYLOCK := 0 ENABLE_KEYLOCK := 0
#ENABLE_PANADAPTER := 0 #ENABLE_PANADAPTER := 0
#ENABLE_SINGLE_VFO_CHAN := 0 #ENABLE_SINGLE_VFO_CHAN := 0

View File

@ -99,10 +99,11 @@ void ACTION_Monitor(void)
if (!g_monitor_enabled) // (g_current_function != FUNCTION_MONITOR) if (!g_monitor_enabled) // (g_current_function != FUNCTION_MONITOR)
{ // enable monitor mode { // enable monitor mode
g_beep_to_play = BEEP_NONE;
g_monitor_enabled = true; g_monitor_enabled = true;
// g_squelch_open = true; g_beep_to_play = BEEP_NONE;
if (!g_squelch_open && GPIO_CheckBit(&GPIOC->DATA, GPIOC_PIN_SPEAKER))
BK4819_StopTones(g_current_function == FUNCTION_TRANSMIT);
#ifdef ENABLE_NOAA #ifdef ENABLE_NOAA
// if (g_rx_vfo->channel_save >= NOAA_CHANNEL_FIRST && g_is_noaa_mode) // if (g_rx_vfo->channel_save >= NOAA_CHANNEL_FIRST && g_is_noaa_mode)

View File

@ -95,7 +95,8 @@ static void APP_update_rssi(const int vfo)
g_current_rssi[vfo] = rssi; g_current_rssi[vfo] = rssi;
UI_update_rssi(rssi, vfo); if (g_squelch_open)
UI_update_rssi(rssi, vfo);
} }
static void APP_check_for_new_receive(void) static void APP_check_for_new_receive(void)
@ -166,6 +167,7 @@ done:
#endif #endif
APP_update_rssi(g_eeprom.rx_vfo); APP_update_rssi(g_eeprom.rx_vfo);
g_update_rssi = true; g_update_rssi = true;
} }
} }
@ -404,7 +406,7 @@ Skip:
case END_OF_RX_MODE_END: case END_OF_RX_MODE_END:
if (!g_monitor_enabled) if (!g_monitor_enabled)
g_speaker_enabled = false; g_speaker_enabled = false;
RADIO_setup_registers(true); RADIO_setup_registers(true);
#ifdef ENABLE_NOAA #ifdef ENABLE_NOAA
@ -487,16 +489,18 @@ bool APP_start_listening(void)
case SCAN_RESUME_TIME: case SCAN_RESUME_TIME:
if (!g_scan_pause_time_mode) if (!g_scan_pause_time_mode)
{ {
g_scan_pause_tick_10ms = g_eeprom.scan_hold_time_500ms * 50; g_scan_pause_tick_10ms = g_eeprom.scan_hold_time_500ms * 50;
g_scan_pause_time_mode = true; g_scan_pause_time_mode = true;
} }
break; break;
case SCAN_RESUME_CARRIER: case SCAN_RESUME_CARRIER:
g_scan_pause_tick_10ms = g_eeprom.scan_hold_time_500ms * 50; g_scan_pause_tick_10ms = g_eeprom.scan_hold_time_500ms * 50;
g_scan_pause_time_mode = false; g_scan_pause_time_mode = false;
break; break;
case SCAN_RESUME_STOP: case SCAN_RESUME_STOP:
g_scan_pause_tick_10ms = 0; g_scan_pause_tick_10ms = 0;
g_scan_pause_time_mode = false; g_scan_pause_time_mode = false;
break; break;
} }
@ -509,7 +513,7 @@ bool APP_start_listening(void)
g_rx_vfo->p_rx->frequency = NOAA_FREQUENCY_TABLE[g_noaa_channel]; g_rx_vfo->p_rx->frequency = NOAA_FREQUENCY_TABLE[g_noaa_channel];
g_rx_vfo->p_tx->frequency = NOAA_FREQUENCY_TABLE[g_noaa_channel]; g_rx_vfo->p_tx->frequency = NOAA_FREQUENCY_TABLE[g_noaa_channel];
g_eeprom.screen_channel[chan] = g_rx_vfo->channel_save; g_eeprom.screen_channel[chan] = g_rx_vfo->channel_save;
g_noaa_tick_10ms = 5000 / 10; // 5 sec g_noaa_tick_10ms = 5000 / 10; // 5 sec
g_schedule_noaa = false; g_schedule_noaa = false;
} }
#endif #endif
@ -523,17 +527,16 @@ bool APP_start_listening(void)
{ // dual watch is active { // dual watch is active
g_dual_watch_tick_10ms = g_eeprom.scan_hold_time_500ms * 50; g_dual_watch_tick_10ms = g_eeprom.scan_hold_time_500ms * 50;
g_rx_vfo_is_active = true; g_rx_vfo_is_active = true;
g_update_status = true;
g_update_status = true;
} }
// AF gain - original QS values // AF gain - original QS values
if (g_rx_vfo->am_mode) // if (g_rx_vfo->am_mode)
{ // {
BK4819_WriteRegister(0x48, 0xB3A8); // 1011 0011 1010 1000 // BK4819_WriteRegister(0x48, 0xB3A8); // 1011 0011 1010 1000
} // }
else // else
{ {
BK4819_WriteRegister(0x48, BK4819_WriteRegister(0x48,
(11u << 12) | // ??? .. 0 ~ 15, doesn't seem to make any difference (11u << 12) | // ??? .. 0 ~ 15, doesn't seem to make any difference
@ -562,7 +565,7 @@ bool APP_start_listening(void)
if (g_current_display_screen != DISPLAY_MENU) if (g_current_display_screen != DISPLAY_MENU)
GUI_SelectNextDisplay(DISPLAY_MAIN); GUI_SelectNextDisplay(DISPLAY_MAIN);
g_update_status = true; g_update_status = true;
g_update_display = true; g_update_display = true;
return true; return true;
@ -927,7 +930,7 @@ void APP_process_radio_interrupts(void)
if (interrupt_bits & BK4819_REG_02_CDCSS_LOST) if (interrupt_bits & BK4819_REG_02_CDCSS_LOST)
{ {
g_cdcss_lost = true; g_cdcss_lost = true;
g_cdcss_code_type = BK4819_get_CDCSS_code_type(); g_cdcss_code_type = BK4819_get_CDCSS_code_type();
} }
@ -947,29 +950,29 @@ void APP_process_radio_interrupts(void)
#ifdef ENABLE_VOX #ifdef ENABLE_VOX
if (interrupt_bits & BK4819_REG_02_VOX_LOST) if (interrupt_bits & BK4819_REG_02_VOX_LOST)
{ {
g_vox_lost = true; g_vox_lost = true;
g_vox_pause_tick_10ms = 10; g_vox_pause_tick_10ms = 10;
if (g_eeprom.vox_switch) if (g_eeprom.vox_switch)
{ {
if (g_current_function == FUNCTION_POWER_SAVE && !g_rx_idle_mode) if (g_current_function == FUNCTION_POWER_SAVE && !g_rx_idle_mode)
{ {
g_power_save_tick_10ms = power_save2_10ms; g_power_save_tick_10ms = power_save2_10ms;
g_power_save_expired = false; g_power_save_expired = false;
} }
if (g_eeprom.dual_watch != DUAL_WATCH_OFF && if (g_eeprom.dual_watch != DUAL_WATCH_OFF &&
(g_dual_watch_tick_10ms == 0 || g_dual_watch_tick_10ms < dual_watch_delay_after_vox_10ms)) (g_dual_watch_tick_10ms == 0 || g_dual_watch_tick_10ms < dual_watch_delay_after_vox_10ms))
{ {
g_dual_watch_tick_10ms = dual_watch_delay_after_vox_10ms; g_dual_watch_tick_10ms = dual_watch_delay_after_vox_10ms;
g_update_status = true; g_update_status = true;
} }
} }
} }
if (interrupt_bits & BK4819_REG_02_VOX_FOUND) if (interrupt_bits & BK4819_REG_02_VOX_FOUND)
{ {
g_vox_lost = false; g_vox_lost = false;
g_vox_pause_tick_10ms = 0; g_vox_pause_tick_10ms = 0;
} }
#endif #endif
@ -977,13 +980,14 @@ void APP_process_radio_interrupts(void)
if (interrupt_bits & BK4819_REG_02_SQUELCH_CLOSED) if (interrupt_bits & BK4819_REG_02_SQUELCH_CLOSED)
{ {
g_squelch_open = false; g_squelch_open = false;
// g_squelch_open = g_monitor_enabled;
BK4819_set_GPIO_pin(BK4819_GPIO6_PIN2_GREEN, false); // LED off BK4819_set_GPIO_pin(BK4819_GPIO6_PIN2_GREEN, false); // LED off
#if defined(ENABLE_UART) && defined(ENABLE_UART_DEBUG) #if defined(ENABLE_UART) && defined(ENABLE_UART_DEBUG)
UART_SendText("sq close\r\n"); UART_SendText("sq close\r\n");
#endif #endif
g_update_display = true;
} }
if (interrupt_bits & BK4819_REG_02_SQUELCH_OPENED) if (interrupt_bits & BK4819_REG_02_SQUELCH_OPENED)
@ -993,6 +997,11 @@ void APP_process_radio_interrupts(void)
#if defined(ENABLE_UART) && defined(ENABLE_UART_DEBUG) #if defined(ENABLE_UART) && defined(ENABLE_UART_DEBUG)
UART_SendText("sq open\r\n"); UART_SendText("sq open\r\n");
#endif #endif
if (g_monitor_enabled)
BK4819_set_GPIO_pin(BK4819_GPIO6_PIN2_GREEN, true); // LED on
g_update_display = true;
} }
} }
} }
@ -1003,28 +1012,28 @@ void APP_end_tx(void)
RADIO_tx_eot(); RADIO_tx_eot();
if (g_current_vfo->p_tx->code_type != CODE_TYPE_NONE) if (g_current_vfo->p_tx->code_type != CODE_TYPE_NONE)
{ // CTCSS/DCS is enabled { // CTCSS/CDCSS is enabled
//if (g_eeprom.tail_note_elimination && g_eeprom.repeater_tail_tone_elimination > 0) //if (g_eeprom.tail_note_elimination && g_eeprom.repeater_tail_tone_elimination > 0)
if (g_eeprom.tail_note_elimination) if (g_eeprom.tail_note_elimination)
{ // send the CTCSS/DCS tail tone - allows the receivers to mute the usual FM squelch tail/crash { // send the CTCSS/DCS tail tone - allows the receivers to mute the usual FM squelch tail/crash
RADIO_EnableCxCSS(); RADIO_EnableCxCSS();
} }
#if 0 #if 1
else else
{ // TX a short blank carrier { // TX a short blank carrier after disabling the CTCSS/CDCSS
// this gives the receivers time to mute RX audio before we drop carrier // this gives the receivers time to mute their RX audio before we drop carrier
BK4819_ExitSubAu(); BK4819_ExitSubAu();
SYSTEM_DelayMs(200); SYSTEM_DelayMs(200);
} }
#endif #endif
} }
g_speaker_enabled = false;
RADIO_setup_registers(false); RADIO_setup_registers(false);
if (!g_speaker_enabled && !g_monitor_enabled) if (g_monitor_enabled)
GPIO_ClearBit(&GPIOC->DATA, GPIOC_PIN_SPEAKER);
else
APP_start_listening(); APP_start_listening();
} }
@ -1381,7 +1390,7 @@ void APP_cancel_user_input_modes(void)
GPIO_ClearBit(&GPIOC->DATA, GPIOC_PIN_SPEAKER); GPIO_ClearBit(&GPIOC->DATA, GPIOC_PIN_SPEAKER);
else else
GPIO_SetBit(&GPIOC->DATA, GPIOC_PIN_SPEAKER); GPIO_SetBit(&GPIOC->DATA, GPIOC_PIN_SPEAKER);
if (g_current_display_screen != DISPLAY_MENU) // 1of11 .. don't close the menu if (g_current_display_screen != DISPLAY_MENU) // 1of11 .. don't close the menu
g_request_display_screen = DISPLAY_MAIN; g_request_display_screen = DISPLAY_MAIN;
} }
@ -1458,7 +1467,7 @@ void APP_process_flash_light_10ms(void)
GPIO_SetBit(&GPIOC->DATA, GPIOC_PIN_FLASHLIGHT); GPIO_SetBit(&GPIOC->DATA, GPIOC_PIN_FLASHLIGHT);
#ifdef ENABLE_FLASH_LIGHT_SOS_TONE #ifdef ENABLE_FLASH_LIGHT_SOS_TONE
if (!g_squelch_open && !g_monitor_enabled && !GPIO_CheckBit(&GPIOC->DATA, GPIOC_PIN_SPEAKER)) if (!g_squelch_open && !g_monitor_enabled && !GPIO_CheckBit(&GPIOC->DATA, GPIOC_PIN_SPEAKER))
BK4819_StartTone1(880, 127, true); BK4819_StartTone1(880, 50, true);
#endif #endif
} }
} }
@ -1468,7 +1477,7 @@ void APP_process_flash_light_10ms(void)
{ // LED off { // LED off
GPIO_ClearBit(&GPIOC->DATA, GPIOC_PIN_FLASHLIGHT); // OFF GPIO_ClearBit(&GPIOC->DATA, GPIOC_PIN_FLASHLIGHT); // OFF
#ifdef ENABLE_FLASH_LIGHT_SOS_TONE #ifdef ENABLE_FLASH_LIGHT_SOS_TONE
if (GPIO_CheckBit(&GPIOC->DATA, GPIOC_PIN_SPEAKER)) if (!g_squelch_open && !g_monitor_enabled && GPIO_CheckBit(&GPIOC->DATA, GPIOC_PIN_SPEAKER))
BK4819_StopTones(g_current_function == FUNCTION_TRANSMIT); BK4819_StopTones(g_current_function == FUNCTION_TRANSMIT);
#endif #endif
} }
@ -1885,7 +1894,7 @@ void APP_process_functions(void)
case FUNCTION_NEW_RECEIVE: case FUNCTION_NEW_RECEIVE:
APP_process_new_receive(); APP_process_new_receive();
break; break;
case FUNCTION_RECEIVE: case FUNCTION_RECEIVE:
APP_process_rx(); APP_process_rx();
break; break;
@ -1897,7 +1906,7 @@ void APP_process_functions(void)
case FUNCTION_PANADAPTER: case FUNCTION_PANADAPTER:
break; break;
default: default:
break; break;
} }
@ -1906,7 +1915,7 @@ void APP_process_functions(void)
void APP_process_power_save(void) void APP_process_power_save(void)
{ {
bool power_save = true; bool power_save = true;
if (g_monitor_enabled || if (g_monitor_enabled ||
#ifdef ENABLE_FMRADIO #ifdef ENABLE_FMRADIO
g_fm_radio_mode || g_fm_radio_mode ||
@ -1924,7 +1933,7 @@ void APP_process_power_save(void)
{ {
power_save = false; power_save = false;
} }
#ifdef ENABLE_NOAA #ifdef ENABLE_NOAA
if (IS_NOAA_CHANNEL(g_eeprom.screen_channel[0]) || if (IS_NOAA_CHANNEL(g_eeprom.screen_channel[0]) ||
IS_NOAA_CHANNEL(g_eeprom.screen_channel[1]) || IS_NOAA_CHANNEL(g_eeprom.screen_channel[1]) ||
@ -1948,7 +1957,7 @@ void APP_process_power_save(void)
{ // enter power save { // enter power save
FUNCTION_Select(FUNCTION_POWER_SAVE); FUNCTION_Select(FUNCTION_POWER_SAVE);
} }
g_schedule_power_save = false; g_schedule_power_save = false;
#ifdef ENABLE_VOICE #ifdef ENABLE_VOICE
@ -2295,7 +2304,7 @@ void APP_time_slice_500ms(void)
if (--g_fm_resume_tick_500ms == 0) if (--g_fm_resume_tick_500ms == 0)
{ {
RADIO_Setg_vfo_state(VFO_STATE_NORMAL); RADIO_Setg_vfo_state(VFO_STATE_NORMAL);
if (g_current_function != FUNCTION_RECEIVE && if (g_current_function != FUNCTION_RECEIVE &&
!g_monitor_enabled && !g_monitor_enabled &&
g_fm_radio_mode) g_fm_radio_mode)
@ -2306,7 +2315,7 @@ void APP_time_slice_500ms(void)
} }
} }
} }
if (g_fm_radio_mode && g_fm_radio_tick_500ms == 0) if (g_fm_radio_mode && g_fm_radio_tick_500ms == 0)
return; return;
#endif #endif
@ -2465,7 +2474,7 @@ void APP_time_slice_10ms(void)
if (g_monitor_enabled) if (g_monitor_enabled)
APP_start_listening(); APP_start_listening();
GUI_SelectNextDisplay(DISPLAY_MAIN); GUI_SelectNextDisplay(DISPLAY_MAIN);
} }
@ -2530,9 +2539,7 @@ void APP_time_slice_10ms(void)
if (g_vox_pause_tick_10ms > 0) if (g_vox_pause_tick_10ms > 0)
g_vox_pause_tick_10ms--; g_vox_pause_tick_10ms--;
#endif
#ifdef ENABLE_VOX
if (g_eeprom.vox_switch) if (g_eeprom.vox_switch)
APP_process_vox(); APP_process_vox();
#endif #endif
@ -3011,7 +3018,7 @@ Skip:
if (g_speaker_enabled || g_monitor_enabled) if (g_speaker_enabled || g_monitor_enabled)
APP_start_listening(); APP_start_listening();
g_flag_reconfigure_vfos = false; g_flag_reconfigure_vfos = false;
} }

Binary file not shown.

Binary file not shown.

11
radio.c
View File

@ -695,12 +695,11 @@ void RADIO_setup_registers(bool switch_to_function_foreground)
BK4819_set_GPIO_pin(BK4819_GPIO0_PIN28_RX_ENABLE, true); BK4819_set_GPIO_pin(BK4819_GPIO0_PIN28_RX_ENABLE, true);
// AF RX Gain and DAC // AF RX Gain and DAC
// BK4819_WriteRegister(0x48, 0xB3A8); // 1011 00 111010 1000 // if (g_rx_vfo->am_mode)
if (g_rx_vfo->am_mode) // {
{ // BK4819_WriteRegister(0x48, 0xB3A8); // 1011 0011 1010 1000
BK4819_WriteRegister(0x48, 0xB3A8); // 1011 0011 1010 1000 // }
} // else
else
{ {
BK4819_WriteRegister(0x48, BK4819_WriteRegister(0x48,
(11u << 12) | // ??? .. 0 ~ 15, doesn't seem to make any difference (11u << 12) | // ??? .. 0 ~ 15, doesn't seem to make any difference

View File

@ -587,8 +587,7 @@ void UI_DisplayMain(void)
else else
{ // receiving .. show the RX symbol { // receiving .. show the RX symbol
mode = 2; mode = 2;
if ((g_current_function == FUNCTION_RECEIVE || g_current_function == FUNCTION_NEW_RECEIVE) && if ((g_current_function == FUNCTION_RECEIVE && g_squelch_open) && g_eeprom.rx_vfo == vfo_num)
g_eeprom.rx_vfo == vfo_num)
{ {
#ifdef ENABLE_SMALL_BOLD #ifdef ENABLE_SMALL_BOLD
UI_PrintStringSmallBold("RX", 14, 0, line); UI_PrintStringSmallBold("RX", 14, 0, line);
@ -829,11 +828,8 @@ void UI_DisplayMain(void)
else else
if (mode == 2) if (mode == 2)
{ // RX signal level { // RX signal level
//#ifndef ENABLE_RX_SIGNAL_BAR if (g_vfo_rssi_bar_level[vfo_num] > 0)
// antenna bar graph Level = g_vfo_rssi_bar_level[vfo_num];
if (g_vfo_rssi_bar_level[vfo_num] > 0)
Level = g_vfo_rssi_bar_level[vfo_num];
//#endif
} }
UI_drawBars(p_line1 + LCD_WIDTH, Level); UI_drawBars(p_line1 + LCD_WIDTH, Level);
@ -917,7 +913,7 @@ void UI_DisplayMain(void)
g_dtmf_call_state == DTMF_CALL_STATE_NONE) g_dtmf_call_state == DTMF_CALL_STATE_NONE)
{ // we're free to use the middle line { // we're free to use the middle line
const bool rx = (g_current_function == FUNCTION_RECEIVE); const bool rx = (g_current_function == FUNCTION_RECEIVE && g_squelch_open) ? true : false;
#ifdef ENABLE_TX_TIMEOUT_BAR #ifdef ENABLE_TX_TIMEOUT_BAR
// show the TX timeout count down // show the TX timeout count down