diff --git a/Tools/px4airframes/markdownout.py b/Tools/px4airframes/markdownout.py
index 1d99fbeba8..0512842457 100644
--- a/Tools/px4airframes/markdownout.py
+++ b/Tools/px4airframes/markdownout.py
@@ -5,17 +5,47 @@ import html
class MarkdownTablesOutput():
def __init__(self, groups, board, image_path):
- result = ("# Airframes Reference\n"
- "> **Note** **This list is [auto-generated](https://github.com/PX4/PX4-Autopilot/blob/master/Tools/px4airframes/markdownout.py) from the source code**.\n"
- "> \n"
- "> **AUX** channels may not be present on some flight controllers.\n"
- "> If present, PWM AUX channels are commonly labelled **AUX OUT**.\n"
- "> \n"
- "\n")
-
- result += """This page lists all supported airframes and types including
- the motor assignment and numbering. The motors in **green** rotate clockwise,
- the ones in **blue** counterclockwise.\n\n"""
+ result = """# Airframes Reference
+
+:::note
+**This list is [auto-generated](https://github.com/PX4/PX4-Autopilot/blob/master/Tools/px4airframes/markdownout.py) from the source code** using the build command: `make airframe_metadata`.
+:::
+
+This page lists all supported airframes and types including the motor assignment and numbering.
+The motors in **green** rotate clockwise, the ones in **blue** counterclockwise.
+
+**AUX** channels may not be present on some flight controllers.
+If present, PWM AUX channels are commonly labelled **AUX OUT**.
+
+\n\n"""
type_set = set()
@@ -33,7 +63,7 @@ class MarkdownTablesOutput():
image_name = group.GetImageName()
result += '
\n'
image_name = image_path + image_name
- result += '
![](%s.svg)
\n' % (image_name)
+ result += '
![](%s.svg)
\n' % (image_name)
# check if all outputs are equal for the group: if so, show them
# only once
@@ -63,19 +93,17 @@ class MarkdownTablesOutput():
outputs_prev[i] = ''
if outputs_match[0] or outputs_match[1]:
- result += '
\n'
- result += ' \n'
+ result += '\n'
result += ' \n'
result += ' Common Outputs |
\n'
result += ' \n'
- result += '\n'
- result += '\n | \n
\n' % (outputs_prev[0], outputs_prev[1])
+ result += ' \n'
+ result += '\n | \n
\n' % (outputs_prev[0], outputs_prev[1])
result += '
\n'
result += '\n\n'
- result += '\n'
- result += ' \n'
+ result += '\n'
result += ' \n'
result += ' Name | |
\n'
result += ' \n'
@@ -90,7 +118,7 @@ class MarkdownTablesOutput():
maintainer = param.GetMaintainer()
maintainer_entry = ''
if maintainer != '':
- maintainer_entry = 'Maintainer: %s
' % (html.escape(maintainer))
+ maintainer_entry = 'Maintainer: %s' % (html.escape(maintainer))
url = param.GetFieldValue('url')
name_anchor='id="%s_%s_%s"' % (group.GetClass(),group.GetName(),name)
name_anchor=name_anchor.replace(' ','_').lower()
@@ -120,7 +148,7 @@ class MarkdownTablesOutput():
else:
outputs_entry = ''
- result += ('\n %s | \n %s%s%s | \n\n
\n' %
+ result += ('\n %s | \n %s%s%s | \n
\n' %
(name_anchor, name_entry, maintainer_entry, airframe_id_entry,
outputs_entry))