1 # Makefile for the MCU firmware
3 # Must supply TOOLPATH, ARCH, MCU either in local.mk or in the make command line
4 # Example (toolchain in the system default location):
14 $(error Must supply TOOLPATH, ARCH, MCU)
18 INC = $(TOOLPATH)/$(ARCH)/include
19 LIB = $(TOOLPATH)/$(ARCH)/lib
20 CC = $(BIN)/$(ARCH)-gcc
21 OBC = $(BIN)/$(ARCH)-objcopy
22 CFLAGS = -mmcu=$(MCU) -g -ffunction-sections -fdata-sections -DDEPRECATED -I $(INC)
23 LDFLAGS = -mmcu=$(MCU) -g -ffunction-sections -fdata-sections -Wl,--gc-sections -L $(INC)
24 ifneq (,$(findstring msp430g2,$(MCU)))
25 LOAD = mspdebug rf2500 'prog main'
27 LOAD = MSP430Flasher -w main.hex