Autopilot configuration reference

Revision as of 10:50, 4 May 2010 by T3r (talk | contribs) (New Page)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
WIP.png Work in progress
This article or section will be worked on in the upcoming hours or days.
See history for the latest developments.

This page serves as a reference for the elements of FlightGear xml autopilot configuration files. It describes all elements available within the autopilot configuration file supported in the bleeding edge CVS sources. Some of the elements may not be available in the current release version of FlightGear. Refer to Howto:_Design_an_autopilot as a guide how to use these elements.

Structure Of a Configuration File

Autopilot configurations live in a separate file, formatted using the well known XML syntax like so many other FlightGear files with a PropertyList node as a root element. A basic skeleton file looks like this:

<?xml version="1.0" encoding="utf8"?>
<PropertyList>
  <params>
    <controls>
      <aileron>controls/flight/aileron</aileron>
      <rudder>controls/flight/rudder</rudder>
      <elevator>controls/flight/elevator</elevator>
    </controls>
  </params>
  
</PropertyList>

Note: Using aliased property names is good style and makes the configuration file more readable. For complex autopilot systems spread over multiple autopilot configuration files, the params section may be included from an extern file using <params include="my-params.xml"/> to avoid duplication of code.


The location and the name of the configuration file is up to the developer. A descriptive name like 'autopilot.xml' might be a good choice. Most developer put these files into the Systems folder of the aircraft.

Adding a Autopilot Configuration to Aircraft

Autopilot configuration files are added to the aircraft by adding

 <autopilot>
   <path>Aircraft/MyAircraft/Systems/my-autopilot.xml</path>
 </autopilot>

to the

<sim>
  <systems>
    <!- - many other elements live here - ->
    <autopilot>
      <path>Aircraft/MyAircraft/Systems/my-autopilot.xml</path>
    </autopilot>
  </systems>
 </sim>

node of your aircraft-set.xml file. Note, that more than one <autopilot> node may be present, each will create a new instance of the autopilot subsystem when running FlightGear. They run in the order of appearance under <systems>.

Available Elements

Input Values

Output Values

filter

gain

exponential

double-exponential

moving-average

noise-spike

reciprocal

pid-controller

pi-simple-controller

predict-simple