diff --git a/src/platforms/ctxlink/Makefile.inc b/src/platforms/ctxlink/Makefile.inc index 16f7d3261cf..5df15450d44 100644 --- a/src/platforms/ctxlink/Makefile.inc +++ b/src/platforms/ctxlink/Makefile.inc @@ -29,11 +29,18 @@ VPATH += platforms/common/stm32 SRC += \ platform.c \ traceswodecode.c \ - traceswo.c \ serialno.c \ timing.c \ timing_stm32.c +ifeq ($(TRACESWO_PROTOCOL), 1) +SRC += traceswo.c +CFLAGS += -DTRACESWO_PROTOCOL=1 +else +SRC += traceswoasync.c +CFLAGS += -DTRACESWO_PROTOCOL=2 +endif + ifneq ($(BMP_BOOTLOADER), 1) all: blackmagic.bin else