altosdroid: initial implementation of telemetry logging.
[fw/altos] / src / telefire-v0.1 / Makefile
1 #
2 # TeleFire build file
3 #
4
5 TELEFIRE_VER=0.1
6 TELEFIRE_DEF=0_1
7
8 vpath %.c ..:../core:../cc1111:../drivers:../product
9 vpath %.h ..:../core:../cc1111:../drivers:../product
10 vpath ao-make-product.5c ../util
11
12 ifndef VERSION
13 include ../Version
14 endif
15
16 INC = \
17         ao.h \
18         ao_pins.h \
19         ao_arch.h \
20         ao_arch_funcs.h \
21         ao_pad.h \
22         cc1111.h \
23         ao_product.h
24
25 CORE_SRC = \
26         ao_cmd.c \
27         ao_config.c \
28         ao_convert.c \
29         ao_mutex.c \
30         ao_panic.c \
31         ao_stdio.c \
32         ao_storage.c \
33         ao_task.c \
34         ao_freq.c
35
36 CC1111_SRC = \
37         ao_adc.c \
38         ao_aes.c \
39         ao_beep.c \
40         ao_dma.c \
41         ao_intflash.c \
42         ao_radio.c \
43         ao_radio_cmac.c \
44         ao_romconfig.c \
45         ao_serial.c \
46         ao_spi.c \
47         ao_string.c \
48         ao_timer.c \
49         ao_usb.c \
50         _bp.c
51
52 DRIVER_SRC = \
53         ao_pca9922.c \
54         ao_74hc497.c \
55         ao_pad.c \
56         ao_radio_cmac_cmd.c
57
58 PRODUCT_SRC = \
59         ao_telefire.c
60
61 SRC = \
62         $(CORE_SRC) \
63         $(CC1111_SRC) \
64         $(DRIVER_SRC) \
65         $(PRODUCT_SRC)
66
67 PROGNAME = telefire-v$(TELEFIRE_VER)
68 PROG = $(PROGNAME)-$(VERSION).ihx
69 PRODUCT=TeleFire-v$(TELEFIRE_VER)
70 PRODUCT_DEF=-DTELEFIRE_V_$(TELEFIRE_DEF)
71 IDPRODUCT=0x000f
72 CODESIZE=0x6700
73
74 include ../cc1111/Makefile.cc1111
75
76 NICKLE=nickle
77 CHECK_STACK=sh ../util/check-stack
78
79 V=0
80 # The user has explicitly enabled quiet compilation.
81 ifeq ($(V),0)
82 quiet = @printf "  $1 $2 $@\n"; $($1)
83 endif
84 # Otherwise, print the full command line.
85 quiet ?= $($1)
86
87 all: ../$(PROG)
88
89 ../$(PROG): $(REL) Makefile
90         $(call quiet,CC) $(LDFLAGS) $(CFLAGS) -o $(PROG) $(REL) && cp $(PROG) $(PMAP) ..
91         $(call quiet,CHECK_STACK) ../cc1111/ao_arch.h $(PMEM)  || rm $@
92
93 ao_product.h: ao-make-product.5c ../Version
94         $(call quiet,NICKLE,$<) $< -m altusmetrum.org -i $(IDPRODUCT) -p $(PRODUCT) -v $(VERSION) > $@
95
96 distclean:      clean
97
98 clean: clean-cc1111
99
100 install:
101
102 uninstall:
103