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

panadapter update

This commit is contained in:
OneOfEleven 2023-11-19 11:11:44 +00:00
parent 39a481231e
commit 735e507cdc
4 changed files with 4 additions and 9 deletions

View File

@ -83,7 +83,7 @@ ENABLE_SIDE_BUTT_MENU := 0
# Key Lock 400 B
ENABLE_KEYLOCK := 0
ENABLE_PANADAPTER := 1
ENABLE_PANADAPTER_PEAK_FREQ := 1
ENABLE_PANADAPTER_PEAK_FREQ := 0
#ENABLE_SINGLE_VFO_CHAN := 0
#############################################################

Binary file not shown.

Binary file not shown.

View File

@ -61,8 +61,6 @@ void PAN_set_freq(void)
void PAN_process_10ms(void)
{
uint16_t rssi;
if (!g_eeprom.config.setting.panadapter ||
#ifdef ENABLE_FMRADIO
g_fm_radio_mode ||
@ -113,11 +111,8 @@ void PAN_process_10ms(void)
{ // we have a signal on the VFO frequency
// save the current RSSI value .. center bin is the VFO frequency
rssi = g_current_rssi[g_eeprom.config.setting.tx_vfo_num];
//if (g_tx_vfo->channel.mod_mode == MOD_MODE_FM)
g_panadapter_rssi[PANADAPTER_BINS] = (rssi <= 255) ? rssi : 255;
// g_update_display = true;
const int16_t rssi = g_current_rssi[g_eeprom.config.setting.tx_vfo_num];
g_panadapter_rssi[PANADAPTER_BINS] = (rssi > 255) ? 255 : (rssi < 0) ? 0 : rssi;
g_panadapter_vfo_mode = 50; // pause scanning for at least another 500ms
return;
@ -127,7 +122,7 @@ void PAN_process_10ms(void)
{ // scanning
// save the current RSSI value
rssi = BK4819_GetRSSI();
const uint16_t rssi = BK4819_GetRSSI();
g_panadapter_rssi[panadapter_rssi_index] = (rssi <= 255) ? rssi : 255;
// next frequency