add LOGGER option to use rtt

update example readme for debug log. Update bug template to ask for LOG
as well.
This commit is contained in:
hathach
2020-04-22 17:08:41 +07:00
parent 3aa3c35986
commit afc4042375
9 changed files with 61 additions and 2402 deletions
+11 -1
View File
@@ -75,7 +75,17 @@ else
CFLAGS += -Os
endif
# TUSB Logging option
# Log level is mapped to TUSB DEBUG option
ifneq ($(LOG),)
CFLAGS += -DCFG_TUSB_DEBUG=$(LOG)
endif
# Logger: default is UART, can be set to RTT
ifeq ($(LOGGER),rtt)
RTT_SRC = lib/SEGGER_RTT
CFLAGS += -DLOGGER_RTT
INC += $(TOP)/$(RTT_SRC)/RTT
SRC_C += $(RTT_SRC)/RTT/SEGGER_RTT_printf.c
SRC_C += $(RTT_SRC)/RTT/SEGGER_RTT.c
endif