mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-04-14 10:07:39 +08:00
Output rotor config as XML attributes
This commit is contained in:
parent
628e5c8649
commit
ca7a7dfd10
@ -72,9 +72,13 @@ class XMLOutput():
|
||||
xml_field.text = value
|
||||
for code in param.GetOutputCodes():
|
||||
value = param.GetOutputValue(code)
|
||||
valstrs = value.split(";")
|
||||
xml_field = ET.SubElement(xml_param, "output")
|
||||
xml_field.attrib["name"] = code
|
||||
xml_field.text = value
|
||||
for attrib in valstrs[1:]:
|
||||
attribstrs = attrib.split(":")
|
||||
xml_field.attrib[attribstrs[0].strip()] = attribstrs[1].strip()
|
||||
xml_field.text = valstrs[0]
|
||||
if last_param_name != param.GetName():
|
||||
board_specific_param_set = False
|
||||
indent(xml_parameters)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user