altos: Try RDF mode for TX calibration
[fw/altos] / src / product / Makefile.telebt
1 #
2 # TeleBT build file
3 #
4 # Define TELEBT_VER, TELEBT_DEF, TELEBT_INC and TELEBT_SRC
5 # and include this file
6
7 vpath %.c ..:../core:../cc1111:../drivers:../product
8 vpath %.h ..:../core:../cc1111:../drivers:../product
9 vpath ao-make-product.5c ../util
10
11 ifndef VERSION
12 include ../Version
13 endif
14
15 INC = \
16         ao.h \
17         ao_pins.h \
18         ao_arch.h \
19         ao_arch_funcs.h \
20         cc1111.h \
21         ao_product.h \
22         $(TELEBT_INC)
23
24 CORE_SRC = \
25         ao_cmd.c \
26         ao_config.c \
27         ao_gps_print.c \
28         ao_monitor.c \
29         ao_mutex.c \
30         ao_panic.c \
31         ao_state.c \
32         ao_stdio.c \
33         ao_task.c \
34         ao_freq.c
35
36 CC1111_SRC = \
37         ao_dbg.c \
38         ao_dma.c \
39         ao_led.c \
40         ao_packet.c \
41         ao_packet_master.c \
42         ao_radio.c \
43         ao_romconfig.c \
44         ao_serial.c \
45         ao_string.c \
46         ao_timer.c \
47         ao_usb.c \
48         _bp.c
49
50 DRIVER_SRC = \
51         ao_btm.c
52
53 PRODUCT_SRC = \
54         ao_telebt.c
55
56 SRC = \
57         $(CORE_SRC) \
58         $(CC1111_SRC) \
59         $(DRIVER_SRC) \
60         $(PRODUCT_SRC) \
61         $(TELEBT_SRC)
62
63 PROGNAME = telebt-v$(TELEBT_VER)
64 PROG = $(PROGNAME)-$(VERSION).ihx
65 PRODUCT=TeleBT-v$(TELEBT_VER)
66 PRODUCT_DEF=-DTELEBT_V_$(TELEBT_DEF)
67 IDPRODUCT=0x000e
68
69 include ../cc1111/Makefile.cc1111
70
71 NICKLE=nickle
72 CHECK_STACK=sh ../util/check-stack
73
74 V=0
75 # The user has explicitly enabled quiet compilation.
76 ifeq ($(V),0)
77 quiet = @printf "  $1 $2 $@\n"; $($1)
78 endif
79 # Otherwise, print the full command line.
80 quiet ?= $($1)
81
82 all: $(PROG)
83
84 $(PROG): $(REL) Makefile
85         $(call quiet,CC) $(LDFLAGS) $(CFLAGS) -o $(PROG) $(REL) && cp $(PROG) $(PMAP) ..
86         $(call quiet,CHECK_STACK) ../cc1111/ao_arch.h $(PMEM) || rm $@
87
88 ao_product.h: ao-make-product.5c ../Version
89         $(call quiet,NICKLE,$<) $< -m altusmetrum.org -i $(IDPRODUCT) -p $(PRODUCT) -v $(VERSION) > $@
90
91 distclean:      clean
92
93 clean: clean-cc1111
94
95 install:
96
97 uninstall: