Autopilot configuration reference: Difference between revisions

Jump to navigation Jump to search
m
 
Line 334: Line 334:
==== Conditional input values <condition> ====
==== Conditional input values <condition> ====
The direct inputs of controller and filter elements support so called input value lists. This is useful, if the input should be connected to one of many separate inputs like autopilots connected to NAV1, NAV2 or the GPS. A standard <syntaxhighlight lang="xml" inline><condition></syntaxhighlight> element is allowed within an input value element. The input value list will be traversed until the first input value with a successful condition is found. The behavior is much like the switch statement in programming languages.
The direct inputs of controller and filter elements support so called input value lists. This is useful, if the input should be connected to one of many separate inputs like autopilots connected to NAV1, NAV2 or the GPS. A standard <syntaxhighlight lang="xml" inline><condition></syntaxhighlight> element is allowed within an input value element. The input value list will be traversed until the first input value with a successful condition is found. The behavior is much like the switch statement in programming languages.
This will also work in specific filter parameters/inputs, like the <syntaxhighlight lang="xml" inline><max-rate-of-change></syntaxhighlight> element of the <code>noise-spike</code> filter to dynamically calculate the filters responsiveness, based on conditions.<ref>For an example, see the [https://github.com/HHS81/c182s/blob/1958e725c6518fff28c8d44f44a6ce4808a47cc4/Systems/engine.xml#L769-L837 C182s implementation of the starter overheat feature] </ref>


<syntaxhighlight lang="xml">
<syntaxhighlight lang="xml">
601

edits

Navigation menu