Skip to content

Commit

Permalink
Add compile-time flag for PCB 2.1 GPIO fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrej authored and Tunas1337 committed Jun 16, 2024
1 parent b594316 commit 0dbfdd7
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
5 changes: 5 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ ENABLE_TX_BAR ?= 1
ENABLE_SLOWER_RSSI_TIMER ?= 1
ENABLE_SPECTRUM ?= 1
ENABLE_KEEP_MONITOR_MODE_UP_DN ?= 0
PCB_VER_2_1 ?= 0


# Spectrum presets - 1.4 kB
ENABLE_SPECTRUM_PRESETS ?= 1
Expand Down Expand Up @@ -207,6 +209,9 @@ endif
ifeq ($(ENABLE_AM_FIX),1)
CFLAGS += -DENABLE_AM_FIX
endif
ifeq ($(PCB_VER_2_1),1)
CFLAGS += -DPCB_VER_2_1
endif
ifeq ($(ENABLE_ALT_SQUELCH),1)
CFLAGS += -DENABLE_ALT_SQUELCH
endif
Expand Down
6 changes: 5 additions & 1 deletion driver/bk4819.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,11 @@

enum {
GPIO_FILTER_UHF = 1U << 5,
GPIO_FILTER_VHF = 1U << 6,
#ifdef PCB_VER_2_1
GPIO_FILTER_VHF = 1U << 3,
#else
GPIO_FILTER_VHF = 1U << 6,
#endif
GPIO_FILTER_UNKWOWN = 1U << 7,
};

Expand Down

0 comments on commit 0dbfdd7

Please sign in to comment.