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