0
mirror of https://github.com/OneOfEleven/uv-k5-firmware-custom.git synced 2025-06-19 14:48:03 +03:00

Added FM radio lower frequency options

This commit is contained in:
OneOfEleven
2023-10-22 23:59:47 +01:00
parent 7aff322458
commit df3d298487
26 changed files with 127 additions and 119 deletions

View File

@ -17,13 +17,13 @@
#include <string.h>
#include "app/dtmf.h"
#if defined(ENABLE_FMRADIO)
#if defined(ENABLE_FMRADIO_68_108) || defined(ENABLE_FMRADIO_76_108) || defined(ENABLE_FMRADIO_875_108)
#include "app/fm.h"
#endif
#include "bsp/dp32g030/gpio.h"
#include "dcs.h"
#include "driver/backlight.h"
#if defined(ENABLE_FMRADIO)
#if defined(ENABLE_FMRADIO_68_108) || defined(ENABLE_FMRADIO_76_108) || defined(ENABLE_FMRADIO_875_108)
#include "driver/bk1080.h"
#endif
#include "driver/bk4819.h"
@ -116,7 +116,7 @@ void FUNCTION_Select(function_type_t Function)
if (prev_func != FUNCTION_RECEIVE)
break;
#if defined(ENABLE_FMRADIO)
#if defined(ENABLE_FMRADIO_68_108) || defined(ENABLE_FMRADIO_76_108) || defined(ENABLE_FMRADIO_875_108)
if (g_fm_radio_mode)
g_fm_restore_count_down_10ms = fm_restore_countdown_10ms;
#endif
@ -198,7 +198,7 @@ void FUNCTION_Select(function_type_t Function)
g_dtmf_rx_live_timeout = 0;
memset(g_dtmf_rx_live, 0, sizeof(g_dtmf_rx_live));
#ifdef ENABLE_FMRADIO
#if defined(ENABLE_FMRADIO_68_108) || defined(ENABLE_FMRADIO_76_108) || defined(ENABLE_FMRADIO_875_108)
// disable the FM radio
if (g_fm_radio_mode)
BK1080_Init(0, false);
@ -281,7 +281,7 @@ void FUNCTION_Select(function_type_t Function)
g_battery_save_count_down_10ms = battery_save_count_10ms;
g_schedule_power_save = false;
#if defined(ENABLE_FMRADIO)
#if defined(ENABLE_FMRADIO_68_108) || defined(ENABLE_FMRADIO_76_108) || defined(ENABLE_FMRADIO_875_108)
g_fm_restore_count_down_10ms = 0;
#endif