version
This commit is contained in:
@ -26,6 +26,9 @@ ifndef NETWORK
|
|||||||
$(error NETWORK is not set)
|
$(error NETWORK is not set)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
VERSION := $(shell git rev-parse --short=8 HEAD)
|
||||||
|
|
||||||
|
|
||||||
######################################
|
######################################
|
||||||
# target
|
# target
|
||||||
######################################
|
######################################
|
||||||
@ -178,7 +181,7 @@ endif
|
|||||||
# compile gcc flags
|
# compile gcc flags
|
||||||
ASFLAGS = $(MCU) $(AS_DEFS) $(AS_INCLUDES) $(OPT) -Wall -Werror -fdata-sections -ffunction-sections
|
ASFLAGS = $(MCU) $(AS_DEFS) $(AS_INCLUDES) $(OPT) -Wall -Werror -fdata-sections -ffunction-sections
|
||||||
|
|
||||||
CFLAGS = $(MCU) $(C_DEFS) $(C_INCLUDES) $(OPT) -DNETWORK=$(NETWORK) -Wall -Werror -fdata-sections -ffunction-sections
|
CFLAGS = $(MCU) $(C_DEFS) $(C_INCLUDES) $(OPT) -DNETWORK=$(NETWORK) -DVERSION="\"$(VERSION)\"" -Wall -Werror -fdata-sections -ffunction-sections
|
||||||
|
|
||||||
ifeq ($(DEBUG), 1)
|
ifeq ($(DEBUG), 1)
|
||||||
CFLAGS += -g -gdwarf-2
|
CFLAGS += -g -gdwarf-2
|
||||||
|
@ -35,6 +35,7 @@ void my_setup_2() {
|
|||||||
show(LED_RED, OFF);
|
show(LED_RED, OFF);
|
||||||
show(LED_GREEN, BLINK);
|
show(LED_GREEN, BLINK);
|
||||||
logMsg("Application starting");
|
logMsg("Application starting");
|
||||||
|
logMsg("Version: " VERSION);
|
||||||
|
|
||||||
eepromInit();
|
eepromInit();
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user