When I am working with JN-AN-1189-ZigBee-HA-Demo, I enabled the DEBUG=HW, but the bin file's name will not add -hwdbg.
Is the project unable to enable hardware debug with JTAG???
And I fould these in the SDK config_ba2.mk:
# Debug Support
ifeq ($(DEBUG), HW)
DISABLE_LTO ?= 1
CFLAGS += -g -DGDB
LDFLAGS += -g
# Optimise at level 0 instead of size
CFLAGS := $(subst -Os,-O0,$(CFLAGS))
LDFLAGS := $(subst -Os,-O0,$(LDFLAGS))
HARDWARE_DEBUG_ENABLED=1
endif
ifeq ($(DEBUG), HW_SIZEOPT)
DISABLE_LTO ?= 1
CFLAGS += -g -DGDB
LDFLAGS += -g
HARDWARE_DEBUG_ENABLED=1
$(info No optimisation enabled with HW debug ...)
endif
ifeq ($(HARDWARE_DEBUG_ENABLED), 1)
# Set DEBUG_PORT to UART0 or UART1 dependant on connection to serial port on board
CFLAGS += -D$(DEBUG_PORT)_DEBUG
CFLAGS += -DHWDEBUG
BIN_SUFFIX ?= _hwdbg
$(info Building HW debug version ...)
endif
So this is the root cause?
BIN_SUFFIX should be +=, not ?=
JN-AN-1180-802-15-4-Home-Sensor-Demo is ok, I think BIN_SUFFIX is empty here.
Am I correct?
Tks!!