]> git.gag.com Git - fw/altos/blob - src/product/Makefile.telemetrum
Reduce size of textview.
[fw/altos] / src / product / Makefile.telemetrum
1 #
2 # TeleMetrum build file
3 #
4 # The various telemetrum versions differ only
5 # in which flash and GPS drivers are included,
6 # so the per-board makefiles simply define
7 # TM_VER, TM_DEF, TM_INC and TM_SRC and include
8 # this file
9
10 vpath %.c .:..:../core:../cc1111:../drivers:../product
11 vpath %.h .:..:../core:../cc1111:../drivers:../product
12 vpath ao-make-product.5c ../util
13
14 ifndef VERSION
15 include ../Version
16 endif
17
18 INC = \
19         ao.h \
20         ao_pins.h \
21         ao_arch.h \
22         ao_arch_funcs.h \
23         cc1111.h \
24         altitude.h \
25         ao_kalman.h \
26         ao_product.h \
27         $(TM_INC)
28
29 CORE_SRC = \
30         ao_cmd.c \
31         ao_config.c \
32         ao_convert.c \
33         ao_gps_report.c \
34         ao_mutex.c \
35         ao_panic.c \
36         ao_stdio.c \
37         ao_storage.c \
38         ao_task.c \
39         ao_flight.c \
40         ao_sample.c \
41         ao_kalman.c \
42         ao_log.c \
43         ao_log_big.c \
44         ao_report.c \
45         ao_telemetry.c \
46         ao_freq.c
47
48 CC1111_SRC = \
49         ao_adc.c \
50         ao_beep.c \
51         ao_dbg.c \
52         ao_dma.c \
53         ao_ignite.c \
54         ao_led.c \
55         ao_packet.c \
56         ao_packet_slave.c \
57         ao_radio.c \
58         ao_romconfig.c \
59         ao_serial.c \
60         ao_string.c \
61         ao_spi.c \
62         ao_timer.c \
63         ao_usb.c \
64         _bp.c
65
66 DRIVER_SRC = \
67         $(TM_SRC)
68
69 PRODUCT_SRC = \
70         ao_telemetrum.c
71
72 SRC = \
73         $(CORE_SRC) \
74         $(CC1111_SRC) \
75         $(DRIVER_SRC) \
76         $(PRODUCT_SRC)
77
78 PROGNAME = telemetrum-v$(TM_VER)$(TM_EXTRA)
79 PROG = $(PROGNAME)-$(VERSION).ihx
80 PRODUCT=TeleMetrum-v$(TM_VER)
81 PRODUCT_DEF=-DTELEMETRUM_V_$(TM_DEF)
82 IDPRODUCT=0x000b
83
84 include ../cc1111/Makefile.cc1111
85
86 NICKLE=nickle
87 CHECK_STACK=sh ../util/check-stack
88
89 V=0
90 # The user has explicitly enabled quiet compilation.
91 ifeq ($(V),0)
92 quiet = @printf "  $1 $2 $@\n"; $($1)
93 endif
94 # Otherwise, print the full command line.
95 quiet ?= $($1)
96
97 all: ../$(PROG)
98
99 ../$(PROG): $(REL) Makefile
100         $(call quiet,CC) $(LDFLAGS) $(CFLAGS) -o $(PROG) $(REL) && cp $(PROG) $(PMAP) ..
101         $(call quiet,CHECK_STACK) ../cc1111/ao_arch.h $(PMEM) || rm $@
102
103 ao_product.h: ao-make-product.5c ../Version
104         $(call quiet,NICKLE,$<) $< -m altusmetrum.org -i $(IDPRODUCT) -p $(PRODUCT) -v $(VERSION) > $@
105
106 distclean:      clean
107
108 clean: clean-cc1111
109
110 install:
111
112 uninstall: