Skip to content
Snippets Groups Projects
config.mk.dist 1.6 KiB
Newer Older
##
## PLATFORM-INDEPENDENT files
##

CSRCS += \
aci/aci.c \
agc.c \
batvoltage.c \
channelquality.c \
crc.c \
fec.c \
freqsetup.c \
filterio.c \
hamming.c \
main.c \
packetpool.c \
receive.c \
id.c \
send.c \
packetqueue.c \
serializer.c \
spreader.c \
fixpoint.c \
interleaver.c \
ranging.c \
serial_enc.c \
sync.c

INC_PATH += \
hal/dev/ \
hal/interface/ \
hal/boards/${TXAMP} \
hal/boards/${RXAMP} \
hal/ \
aci \
aci/csrc


##
## FIRMWARE CONFIG
##

# enable debug pins
CFLAGS += -DPIN_DEBUG

# enable ACI sample command
CFLAGS += -DACI_SAMPLE_ENABLE

# enable TX gain compensation to equalize hydrophone levels
CFLAGS += -DTXGAIN_COMP

# set spreading/despreading method
# - best bit: only use best bit (ignore all others)
# - majority: make a majority vote (useful only for odd number)
# - magsum:   calculate sum of bits
CFLAGS += -DSPREADER_DESPREAD_BESTBIT
# CFLAGS += -DSPREADER_DESPREAD_MAJORITY
# CFLAGS += -DSPREADER_DESPREAD_MAGSUM

# calculate and use noise floor for preamble detection rather than fixed
# absolute threshold
CFLAGS += -DSYNC_AUTO_NOISE

# use short symbols
# CFLAGS += -DHIGHSPEED

# use wide band
# CFLAGS += -DWIDEBAND

# use higher frequency band (EU regulations)
# CFLAGS += -DHIGHFREQ



##
## GIT REVISION
##

# add git branch, commit, and rev hash to software
GIT_BRANCH = $(shell git branch | grep "^\*" | sed -e 's/^..//')
GIT_COMMIT_COUNT = $(shell git rev-list ${GIT_BRANCH} --count --)
GIT_COMMIT_ID = $(shell git rev-parse --short ${GIT_BRANCH})
FIRMWARE_VERSION_STRING = "${GIT_BRANCH}-${GIT_COMMIT_COUNT}-${GIT_COMMIT_ID}"
CFLAGS += -DFIRMWARE_VERSION_STRING=\"${FIRMWARE_VERSION_STRING}\"