Skip to content

Commit

Permalink
Added spectrum analyzer from fagci
Browse files Browse the repository at this point in the history
  • Loading branch information
egzumer committed Sep 30, 2023
1 parent f4643ad commit 3c44faa
Show file tree
Hide file tree
Showing 8 changed files with 1,547 additions and 6 deletions.
14 changes: 11 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ ENABLE_SWD := 0
ENABLE_OVERLAY := 1
ENABLE_UART := 1
ENABLE_AIRCOPY := 0
ENABLE_FMRADIO := 1
ENABLE_FMRADIO := 0
ENABLE_NOAA := 0
ENABLE_VOICE := 0
ENABLE_ALARM := 0
ENABLE_BIG_FREQ := 0
ENABLE_ALARM := 1
ENABLE_BIG_FREQ := 1
ENABLE_SMALL_BOLD := 1
ENABLE_KEEP_MEM_NAME := 1
ENABLE_WIDE_RX := 1
Expand All @@ -28,6 +28,7 @@ ENABLE_AM_FIX_SHOW_DATA := 1
ENABLE_SQUELCH1_LOWER := 0
ENABLE_RSSI_BAR := 1
ENABLE_AUDIO_BAR := 1
ENABLE_SPECTRUM := 1
#ENABLE_COPY_CHAN_TO_VFO := 1
#ENABLE_SINGLE_VFO_CHAN := 1
#ENABLE_BAND_SCOPE := 1
Expand Down Expand Up @@ -88,6 +89,9 @@ endif
OBJS += app/generic.o
OBJS += app/main.o
OBJS += app/menu.o
ifeq ($(ENABLE_SPECTRUM), 1)
OBJS += app/spectrum.o
endif
OBJS += app/scanner.o
ifeq ($(ENABLE_UART),1)
OBJS += app/uart.o
Expand Down Expand Up @@ -156,6 +160,10 @@ CFLAGS = -Os -Wall -Werror -mcpu=cortex-m0 -fno-builtin -fshort-enums -fno-delet

CFLAGS += -DPRINTF_INCLUDE_CONFIG_H
CFLAGS += -DGIT_HASH=\"$(GIT_HASH)\"

ifeq ($(ENABLE_SPECTRUM),1)
CFLAGS += -DENABLE_SPECTRUM
endif
ifeq ($(ENABLE_SWD),1)
CFLAGS += -DENABLE_SWD
endif
Expand Down
8 changes: 7 additions & 1 deletion app/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@
#include "app/generic.h"
#include "app/main.h"
#include "app/scanner.h"
#ifdef ENABLE_SPECTRUM
#include "app/spectrum.h"
#endif
#include "audio.h"
#include "driver/bk4819.h"
#include "dtmf.h"
Expand Down Expand Up @@ -176,7 +179,10 @@ static void processFKeyFunction(const KEY_Code_t Key, const bool beep)
}
gRequestSaveVFO = true;
gVfoConfigureMode = VFO_CONFIGURE_RELOAD;
#else
#elif defined(ENABLE_SPECTRUM)
APP_RunSpectrum();
gRequestDisplayScreen = DISPLAY_MAIN;
#else
// toggle scanlist-1 and scanlist 2
if (gScreenToDisplay != DISPLAY_SCANNER)
{
Expand Down
Loading

0 comments on commit 3c44faa

Please sign in to comment.