altos/test: Adjust CRC error rate after FEC fix
[fw/altos] / doc / Makefile.am
1 #
2 # Copyright © 2018 Keith Packard <keithp@keithp.com>
3 #
4 # This program is free software; you can redistribute it and/or modify
5 # it under the terms of the GNU General Public License as published by
6 # the Free Software Foundation, either version 2 of the License, or
7 # (at your option) any later version.
8 #
9 # This program is distributed in the hope that it will be useful, but
10 # WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
12 # General Public License for more details.
13 #
14
15 if FAKETIME
16 FAKETIME=TZ=UTC faketime -f '$(RELEASE_DATE) 00:00:00 i0'
17 endif
18
19 RELNOTES_INC=\
20         release-notes-1.9.6.inc \
21         release-notes-1.9.5.inc \
22         release-notes-1.9.4.inc \
23         release-notes-1.9.3.inc \
24         release-notes-1.9.2.inc \
25         release-notes-1.9.1.inc \
26         release-notes-1.9.inc \
27         release-notes-1.8.7.inc \
28         release-notes-1.8.6.inc \
29         release-notes-1.8.5.inc \
30         release-notes-1.8.4.inc \
31         release-notes-1.8.3.inc \
32         release-notes-1.8.2.inc \
33         release-notes-1.8.1.inc \
34         release-notes-1.8.inc \
35         release-notes-1.7.inc \
36         release-notes-1.6.8.inc \
37         release-notes-1.6.5.inc \
38         release-notes-1.6.4.inc \
39         release-notes-1.6.3.inc \
40         release-notes-1.6.2.inc \
41         release-notes-1.6.1.inc \
42         release-notes-1.6.inc \
43         release-notes-1.5.inc \
44         release-notes-1.4.2.inc \
45         release-notes-1.4.1.inc \
46         release-notes-1.4.inc \
47         release-notes-1.3.2.inc \
48         release-notes-1.3.1.inc \
49         release-notes-1.3.inc \
50         release-notes-1.2.1.inc \
51         release-notes-1.2.inc \
52         release-notes-1.1.1.inc \
53         release-notes-1.1.inc \
54         release-notes-1.0.1.inc \
55         release-notes-0.9.2.inc \
56         release-notes-0.9.inc \
57         release-notes-0.8.inc \
58         release-notes-0.7.1.inc
59
60 IMAGES=\
61         altosui.png \
62         ascent.png \
63         configure-altimeter.png \
64         configure-altosui.png \
65         configure-groundstation.png \
66         configure-pyro.png \
67         descent.png \
68         device-selection.png \
69         easymega.svg \
70         easymega-v1.0-bottom.jpg \
71         easymega-v1.0-top.jpg \
72         easymini.svg \
73         easymini-top.jpg \
74         easytimer.jpg \
75         fire-igniter.png \
76         graph-configure.png \
77         graph-map.png \
78         graph.png \
79         graph-stats.png \
80         ignitor.png \
81         landed.png \
82         launch-pad.png \
83         load-maps.png \
84         micropeak-app.png \
85         micropeak-back.jpg \
86         micropeak-device-dialog.png \
87         micropeak-dime.jpg \
88         micropeak-download.png \
89         micropeak-graph-configure.png \
90         micropeak-graph.png \
91         micropeak-nofont.svg \
92         micropeak-preferences.png \
93         micropeak-raw-data.png \
94         micropeak-save-dialog.png \
95         micropeak-statistics.png \
96         MicroPeakUSB-2.0-inuse.jpg \
97         MicroPeakUSB-2.0.jpg \
98         monitor-idle.png \
99         scan-channels.png \
100         site-map.png \
101         table.png \
102         telegps-configure.png \
103         telegps-graph-configure.png \
104         telegps-graph-graph.png \
105         telegps-graph-map.png \
106         telegps-graph-stats.png \
107         telegps-info.png \
108         telegps-location.png \
109         telegps-map.png \
110         telegps-preferences.png \
111         telegps-scan.png \
112         telegps-status.png \
113         telegps-table.png \
114         telegps-v1.0-top.jpg \
115         telemega.svg \
116         telemega-v1.0-top.jpg \
117         telemetrum.svg \
118         telemetrum-v1.1-thside.jpg \
119         telemetrum-v2.0-th.jpg \
120         telemini-v1.svg \
121         telemini-v1-top.jpg \
122         telemini-v3.svg \
123         telemini-v3.0-top.jpg \
124         telemini-v3.0-bottom.jpg \
125         altusmetrum-oneline.svg \
126         telegps-oneline.svg \
127         micropeak-oneline.svg
128
129 TXT_FILES=altusmetrum.txt
130
131 COMMON_INC_FILES=\
132         config-device.inc \
133         config-ui.inc \
134         load-maps.inc \
135         aprs-operation.inc \
136         handling.inc \
137         release-head.inc
138
139 INC_FILES=\
140         header.inc \
141         dedication.inc \
142         intro.inc \
143         getting-started.inc \
144         usage.inc \
145         telemetrum.inc \
146         telemini.inc \
147         easymini-device.inc \
148         telemega.inc \
149         easymega.inc \
150         easytimer.inc \
151         installation.inc \
152         using-am-products.inc \
153         updating-firmware.inc \
154         altosui.inc \
155         altosdroid.inc \
156         system-operation.inc \
157         pyro-channels.inc \
158         flight-data-recording.inc \
159         specs.inc \
160         $(COMMON_INC_FILES) \
161         release-notes.inc \
162         $(RELNOTES_INC)
163
164 ADOC_FILES=$(TXT_FILES:.txt=.adoc) $(INC_FILES:.inc=.adoc)
165
166 TELELAUNCH_TXT_FILES=telelaunch.txt
167
168 TELELAUNCH_INC_FILES=\
169         header.inc \
170         telelaunch-acknowledgements.inc \
171         telelaunch-intro.inc \
172         telelaunch-configuration.inc \
173         telelaunch-operation.inc \
174         telelaunch-specs.inc \
175         telelaunch-updating-firmware.inc \
176         telelaunch-cables.inc \
177         telelaunch-troubleshooting.inc 
178
179 TELELAUNCH_ADOC_FILES=$(TELELAUNCH_TXT_FILES:.txt=.adoc) $(TELELAUNCH_INC_FILES:.inc=.adoc)
180
181 TELEGPS_INC_FILES=\
182         telegps-dedication.inc \
183         telegps-quick-start.inc \
184         telegps-using.inc \
185         telegps-system-operation.inc \
186         telegps-application.inc \
187         telegps-specs.inc \
188         telegps-updating-firmware.inc \
189         telegps-release-notes.inc \
190         $(COMMON_INC_FILES)
191
192 TELEGPS_TXT_FILES=\
193         telegps.txt
194
195 TELEGPS_ADOC_FILES=$(TELEGPS_TXT_FILES:.txt=.adoc) $(TELEGPS_INC_FILES:.inc=.adoc)
196
197 MICROPEAK_TXT_FILES=\
198         micropeak.txt
199
200 MICROPEAK_INC_FILES=
201
202 MICROPEAK_ADOC_FILES=$(MICROPEAK_TXT_FILES:.txt=.adoc) $(MICROPEAK_INC_FILES:.inc=.adoc)
203
204 EASYMINI_TXT_FILES=\
205         easymini.txt
206
207 EASYMINI_INC_FILES=$(INC_FILES) easymini-release-notes.inc
208
209
210 EASYMINI_ADOC_FILES=$(EASYMINI_TXT_FILES:.txt=.adoc) $(EASYMINI_INC_FILES:.inc=.adoc)
211
212 OUTLINE_TXT_FILES=\
213         easymega-outline.txt \
214         easymini-outline.txt \
215         telemega-outline.txt \
216         telemetrum-outline.txt \
217         telemini-v1-outline.txt \
218         telemini-v3-outline.txt \
219         telegps-outline.txt
220
221 OUTLINE_ADOC_FILES=$(OUTLINE_TXT_FILES:.txt=.adoc)
222
223 OUTLINE_PDF_FILES=$(OUTLINE_TXT_FILES:.txt=.pdf)
224
225 SVG=\
226         easymini.svg \
227         telemega.svg \
228         telemetrum.svg \
229         telemini-v1.svg \
230         telemini-v3.svg \
231         easymega.svg
232
233 RELNOTES_HTML=$(RELNOTES_INC:.inc=.html)
234
235 ONEFILE_TXT_FILES=\
236         altos.txt \
237         companion.txt \
238         telemetry.txt \
239         map-loading.txt
240
241 ONEFILE_ADOC_FILES=$(ONEFILE_TXT_FILES:.txt=.adoc)
242 ONEFILE_PDF_FILES=$(ONEFILE_TXT_FILES:.txt=.pdf)
243 ONEFILE_HTML_FILES=$(ONEFILE_TXT_FILES:.txt=.html)
244
245 AM_HTML=am.html
246
247 PUBLISH_HTML=altusmetrum.html micropeak.html telegps.html easymini.html telelaunch.html $(ONEFILE_HTML_FILES)
248
249 HTML=$(PUBLISH_HTML) $(RELNOTES_HTML)
250
251 if ASCIIDOCTOR_PDF
252 PDF=altusmetrum.pdf micropeak.pdf telegps.pdf easymini.pdf telelaunch.pdf $(ONEFILE_PDF_FILES) \
253         $(OUTLINE_PDF_FILES)
254 endif
255
256 MAP_DOT_FILES=map-loading.dot
257 MAP_SVG_FILES=$(MAP_DOT_FILES:.dot=.svg)
258 STYLESHEET=am.css am-notoc.css
259
260 FONTS=\
261         fonts/DejaVuSansMono-BoldOblique.ttf \
262         fonts/DejaVuSansMono-Bold.ttf \
263         fonts/DejaVuSansMono-Oblique.ttf \
264         fonts/DejaVuSansMono.ttf \
265         fonts/OpenSans-Light.ttf \
266         fonts/OpenSans-LightItalic.ttf \
267         fonts/OpenSans-Regular.ttf \
268         fonts/OpenSans-Italic.ttf \
269         fonts/OpenSans-Semibold.ttf \
270         fonts/OpenSans-SemiboldItalic.ttf
271
272 ICONS=\
273         images/icons/caution.svg \
274         images/icons/important.svg \
275         images/icons/note.svg \
276         images/icons/tip.svg \
277         images/icons/warning.svg
278
279 PDF_CONFIG_FILES=altusmetrum-theme.yml
280 HTML_CONFIG_FILES=
281
282 PUBLISH_DOC=$(PUBLISH_HTML) $(PDF) $(IMAGES) $(MAP_SVG_FILES) $(STYLESHEET)
283
284 DOC=$(HTML) $(PDF) $(IMAGES) $(MAP_SVG_FILES) $(STYLESHEET)
285
286 SUFFIXES = .dot .svg .inc .txt .adoc .pdf .html
287
288 ATTRIBUTES=--attribute="revdate=$(DOC_DATE)" --attribute="version=$(VERSION)"
289
290 .dot.svg:
291         dot -Tsvg -o$@ $*.dot
292
293 .txt.adoc:
294         sed -e 's/^[    ]*//' -e 's/^\\//' $*.txt > $@
295
296 .inc.adoc:
297         sed -e 's/^[    ]*//' -e 's/^\\//' $*.inc > $@
298
299 .adoc.html:
300         asciidoctor $(ATTRIBUTES) -b html5 $*.adoc
301
302 .adoc.pdf:
303         asciidoctor-pdf $(ATTRIBUTES) $*.adoc
304
305 all:    $(HTML) $(PDF)
306
307 map-loading.adoc: $(MAP_SVG_FILES)
308
309 altusmetrum.pdf altusmetrum.html: $(ADOC_FILES) $(IMAGES)
310
311 telelaunch.pdf telelaunch.html: $(TELELAUNCH_ADOC_FILES) $(IMAGES)
312
313 telegps.html telegps.pdf: $(TELEGPS_ADOC_FILES) $(IMAGES)
314
315 micropeak.pdf micropeak.html: $(MICROPEAK_ADOC_FILES) $(IMAGES)
316
317 easymini.pdf easymini.html: $(EASYMINI_ADOC_FILES) $(IMAGES)
318
319 telemini-v1-outline.pdf: telemini-v1-outline.txt telemini-v1.svg
320
321 telemini-v3-outline.pdf: telemini-v3-outline.txt telemini-v3.svg
322
323 install:        all
324
325 WEB_ROOT=/home/bdale/web/
326
327 publish:        $(PUBLISH_DOC) $(FONTS) $(ICONS)
328         cp -a $(PUBLISH_DOC) $(WEB_ROOT)/altusmetrum/AltOS/doc/
329         mkdir -p $(WEB_ROOT)/altusmetrum/AltOS/doc/fonts/
330         cp $(FONTS) $(WEB_ROOT)/altusmetrum/AltOS/doc/fonts/
331         mkdir -p $(WEB_ROOT)/altusmetrum/AltOS/doc/images/icons/
332         cp $(ICONS) $(WEB_ROOT)/altusmetrum/AltOS/doc/images/icons/
333         (cd $(WEB_ROOT)/altusmetrum ; \
334          git add $(WEB_ROOT)/altusmetrum/AltOS/doc/* ; \
335          git add $(WEB_ROOT)/altusmetrum/AltOS/doc/fonts/* ; \
336          git add $(WEB_ROOT)/altusmetrum/AltOS/doc/images/icons/* ;\
337          echo "update docs" | \
338          git commit -F - $(WEB_ROOT)/altusmetrum/AltOS/doc/* $(WEB_ROOT)/altusmetrum/AltOS/doc/fonts/* $(WEB_ROOT)/altusmetrum/AltOS/doc/images/icons ; \
339          git push)
340
341 publish-keithp: am.html $(DOC) $(FONTS)
342         ssh keithp.com 'mkdir -p ~keithp/public_html/altos/fonts ~keithp/public_html/altos/images/icons'
343         scp -p am.html $(DOC) keithp.com:~keithp/public_html/altos
344         scp -p $(FONTS) keithp.com:~keithp/public_html/altos/fonts
345         scp -p $(ICONS) keithp.com:~keithp/public_html/altos/images/icons
346
347 clean:
348         rm -f am.html $(HTML) $(PDF) $(ADOC_FILES) $(TELEGPS_ADOC_FILES) $(MICROPEAK_ADOC_FILES) $(TELELAUNCH_ADOC_FILES)
349
350 distclean: clean
351         rm -f $(HTML) $(PDF)
352
353 $(PDF): $(PDF_CONFIG_FILES)
354 $(HTML): $(HTML_CONFIG_FILES)
355
356 am.html: Makefile make-am-html $(HTML)
357         sh ./make-am-html $(HTML) > $@