<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>http://wiki.paparazziuav.org/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Garrosh</id>
	<title>PaparazziUAV - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="http://wiki.paparazziuav.org/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Garrosh"/>
	<link rel="alternate" type="text/html" href="http://wiki.paparazziuav.org/wiki/Special:Contributions/Garrosh"/>
	<updated>2026-04-20T13:38:01Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.37.1</generator>
	<entry>
		<id>http://wiki.paparazziuav.org/w/index.php?title=Installation/Linux&amp;diff=19092</id>
		<title>Installation/Linux</title>
		<link rel="alternate" type="text/html" href="http://wiki.paparazziuav.org/w/index.php?title=Installation/Linux&amp;diff=19092"/>
		<updated>2014-10-29T14:02:01Z</updated>

		<summary type="html">&lt;p&gt;Garrosh: Improper invocation of tar command&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;categorytree style=&amp;quot;float:right; clear:right; margin-left:1ex; border: 1px solid gray; padding: 0.7ex;&amp;quot; mode=pages&amp;gt;Installation&amp;lt;/categorytree&amp;gt;&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
'''&amp;lt;span style=&amp;quot;color:red&amp;quot;&amp;gt;This page only describes the installation of the prerequisite tools and dependencies on Debian/Ubuntu needed for Paparazzi.&amp;lt;/span&amp;gt;'''&lt;br /&gt;
&lt;br /&gt;
'''See the general [[Installation]] page for how to [[Installation#Getting_the_Source_Code|download Paparazzi]] and [[Installation#Launching_the_Software|launching it]] after you followed the instructions here.'''&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
Paparazzi is very easily installed on any laptop or workstation running [http://www.ubuntu.com/ Ubuntu], [http://www.debian.org/ Debian] (or any of their derivatives).&lt;br /&gt;
&lt;br /&gt;
The steps required to install the software needed to be able to let your UAS fly &lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;[[Installation/Linux#Installation_of_dependencies|Install the basic Paparazzi dependencies]] and the [[Installation/Linux#ARM_embedded_toolchain|ARM cross compiling toolchain.]]&lt;br /&gt;
&amp;lt;li&amp;gt;[[Installation#Getting_the_Source_Code|Download the source code from the source repository.]]&lt;br /&gt;
&amp;lt;li&amp;gt;Allow access to your PC hardware connection by adding appropriate [[Udev]] rules.&lt;br /&gt;
&amp;lt;li&amp;gt;[[Installation#Launching_the_Software|Compile the binaries from the sources and launch the software.]]&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Users of other Linux flavors than a recent Ubuntu or Debian and anyone needing manual control of each individual package can [[Installation/Manual|install them independently]].&lt;br /&gt;
&lt;br /&gt;
===For the impatient===&lt;br /&gt;
&lt;br /&gt;
For Ubuntu add the [https://launchpad.net/~paparazzi-uav/+archive/ppa paparazzi-uav ppa] &amp;lt;tt&amp;gt;sudo add-apt-repository ppa:paparazzi-uav/ppa&amp;lt;/tt&amp;gt; and install the &amp;lt;tt&amp;gt;paparazzi-dev&amp;lt;/tt&amp;gt; package.&lt;br /&gt;
&lt;br /&gt;
Since Paparazzi v5.0 the [https://launchpad.net/gcc-arm-embedded/ gcc-arm-embedded toolchain] is recommended.&lt;br /&gt;
Available as of Ubuntu 14.04, on older versions it can be [[Installation/Linux#ARM_embedded_toolchain|installed via tarball]].&lt;br /&gt;
&lt;br /&gt;
Or just use the [[Installation#Quickstart_on_Ubuntu_12.04|Quickstart for Ubuntu 12.04 LTS]].&lt;br /&gt;
&lt;br /&gt;
== Installation video Tutorials ==&lt;br /&gt;
&lt;br /&gt;
{{#ev:youtubehd|SshFJrBuku8}} {{#ev:youtubehd|eW0PCSjrP78}}&lt;br /&gt;
&lt;br /&gt;
== Installation of dependencies ==&lt;br /&gt;
&lt;br /&gt;
=== Ubuntu ===&lt;br /&gt;
&lt;br /&gt;
Add the installation sources for the Paparazzi software packages. Run from a terminal:&lt;br /&gt;
 sudo add-apt-repository ppa:paparazzi-uav/ppa&lt;br /&gt;
&lt;br /&gt;
Then update the systems package inventory and install the main Paparazzi software dependencies. This will take some time.&lt;br /&gt;
 sudo apt-get update &lt;br /&gt;
 sudo apt-get install paparazzi-dev&lt;br /&gt;
&lt;br /&gt;
=== Debian ===&lt;br /&gt;
&lt;br /&gt;
For Debian Squeeze (6.0) and Wheezy (7.0) packages are built using the [http://openbuildservice.org/ Open Build Service (OBS)] on [https://build.opensuse.org/project/show?project=home%3Aflixr%3Apaparazzi-uav OpenSUSE Build Service project home:flixr:paparazzi-uav]&lt;br /&gt;
&lt;br /&gt;
[http://software.opensuse.org/download/package?project=home:flixr:paparazzi-uav&amp;amp;package=paparazzi-dev Install paparazzi-dev]&lt;br /&gt;
&lt;br /&gt;
First add the key:&lt;br /&gt;
 wget -q &amp;quot;http://download.opensuse.org/repositories/home:/flixr:/paparazzi-uav/Debian_7.0/Release.key&amp;quot; -O- | apt-key add -&lt;br /&gt;
&lt;br /&gt;
Add the appropriate repo, depending on your Debian version to sources.list&lt;br /&gt;
 echo &amp;quot;deb http://download.opensuse.org/repositories/home:/flixr:/paparazzi-uav/Debian_6.0/ ./&amp;quot; | tee -a /etc/apt/sources.list&lt;br /&gt;
 echo &amp;quot;deb http://download.opensuse.org/repositories/home:/flixr:/paparazzi-uav/Debian_7.0/ ./&amp;quot; | tee -a /etc/apt/sources.list&lt;br /&gt;
&lt;br /&gt;
Update the systems package inventory and install the main Paparazzi software dependencies.&lt;br /&gt;
 sudo apt-get update &lt;br /&gt;
 sudo apt-get install paparazzi-dev&lt;br /&gt;
&lt;br /&gt;
== ARM embedded toolchain ==&lt;br /&gt;
&lt;br /&gt;
For current Paparazzi versions (v5.0 and above) the [https://launchpad.net/gcc-arm-embedded/ gcc-arm-embedded toolchain] is recommended, which also supports the STM32F4 with FPU (hardware floating point).&lt;br /&gt;
&lt;br /&gt;
The most common way is to download and unpack the tarball and add it to your PATH:&lt;br /&gt;
&lt;br /&gt;
[http://pixhawk.org/dev/toolchain_installation_lin The Pixhawk Devs have mentioned the 4.8 as buggy.]&lt;br /&gt;
&lt;br /&gt;
 cd ~&lt;br /&gt;
 wget https://launchpad.net/gcc-arm-embedded/4.7/4.7-2013-q2-update/+download/gcc-arm-none-eabi-4_7-2013q2-20130614-linux.tar.bz2&lt;br /&gt;
 tar -vjxf gcc-arm-none-eabi-4_7-2013q2-20130614-linux.tar.bz2 -C /opt&lt;br /&gt;
 rm -r gcc-arm-none-eabi-4_7-2013q2-20130614-linux.tar.bz2&lt;br /&gt;
 exportline=&amp;quot;PATH=$PATH:/opt/gcc-arm-none-eabi-4_7-2013q2/bin&amp;quot;&lt;br /&gt;
 if grep -Fxq &amp;quot;$exportline&amp;quot; ~/.profile; then echo nothing to do ; else echo $exportline &amp;gt;&amp;gt; ~/.profile; fi&lt;br /&gt;
 source ~/.profile&lt;br /&gt;
&lt;br /&gt;
The file .profile will be sourced in every bash after logging out and in again. Until then,&lt;br /&gt;
 source ~/.profile&lt;br /&gt;
can be used for every bash individually.&lt;br /&gt;
&lt;br /&gt;
If you can not access your toolchain with PATH working, look a the [[Installation/Linux#Troubleshooting]].&lt;br /&gt;
&lt;br /&gt;
==== ARM gcc-arm-embedded toolchain (from launchpad) - Debian Quick (Manual) Install Process ====&lt;br /&gt;
&lt;br /&gt;
This approach is quick and low risk as it does not rely on any packages or make modifications to the system.&lt;br /&gt;
&lt;br /&gt;
* Download latest gcc-arm-none-eabi-*-*-linux.tar.bz2 from [https://launchpad.net/gcc-arm-embedded/+download External Downloads] section of ARM gcc-arm-embedded project&lt;br /&gt;
* Create /opt/paparazzi folder if it does not exist&lt;br /&gt;
 sudo mkdir /opt/paparazzi&lt;br /&gt;
* Decompress file to /opt/&lt;br /&gt;
 sudo tar -xvf [name_of_downloaded_bz2_file] -C /opt&lt;br /&gt;
* Create symlink so Paparazzi Makefile can find the library&lt;br /&gt;
 sudo ln -s /opt/[gcc-arm-xxxxxxx_name_of_folder] /opt/paparazzi/arm-multilib&lt;br /&gt;
* Attempt to build paparazzi autopilot firmware (example, Paparazzi Center build target ap)&lt;br /&gt;
&lt;br /&gt;
=== gcc-arm-none-eabi as Debian/Ubuntu package ===&lt;br /&gt;
&lt;br /&gt;
Note that there are actually two '''different''' toolchains available that unfortunately have the same package name!&lt;br /&gt;
* [https://launchpad.net/gcc-arm-embedded/ ARM gcc-arm-embedded toolchain]&lt;br /&gt;
** includes libstdc++ and newlib-nano&lt;br /&gt;
* [https://packages.debian.org/jessie/gcc-arm-none-eabi Debian gcc-arm-none-eabi toolchain]&lt;br /&gt;
** does not include libstdc++&lt;br /&gt;
** does not include newlib-nano&lt;br /&gt;
&lt;br /&gt;
Both toolchains ''should'' work for most use-cases (if you don't need C++ or nano specs), although the [https://launchpad.net/gcc-arm-embedded/ ARM gcc-arm-embedded toolchain] is better tested.&lt;br /&gt;
&lt;br /&gt;
==== gcc-arm-embedded toolchain ====&lt;br /&gt;
&lt;br /&gt;
On ''most'' Ubuntu versions (currently lucid, precise, raring, saucy and trusty) the [https://launchpad.net/gcc-arm-embedded/ gcc-arm-embedded toolchain] can be installed as a debian package from the [https://launchpad.net/~terry.guo/+archive/gcc-arm-embedded ppa]:&lt;br /&gt;
 sudo add-apt-repository ppa:terry.guo/gcc-arm-embedded&lt;br /&gt;
 sudo apt-get update&lt;br /&gt;
 sudo apt-get install gcc-arm-none-eabi&lt;br /&gt;
&lt;br /&gt;
!!! If you are using Ubuntu 14.04 and later, please be careful because there are packages with same name but produced by Debian and inherited by Ubuntu. Simply follow the above 3 steps, you may end up with gcc-arm-none-eabi from Ubuntu. So to install gcc-arm-none-eabi from ARM, steps are:&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get remove binutils-arm-none-eabi gcc-arm-none-eabi&lt;br /&gt;
 sudo add-apt-repository ppa:terry.guo/gcc-arm-embedded&lt;br /&gt;
 sudo apt-get update&lt;br /&gt;
 sudo apt-get install gcc-arm-none-eabi=4.8.4.2014q3-0trusty11&lt;br /&gt;
Meanwhile we are working with Debian to consolidate and unify this toolchain.&lt;br /&gt;
&lt;br /&gt;
==== gcc-arm-none-eabi Debian toolchain ====&lt;br /&gt;
&lt;br /&gt;
Debian testing ('''jessie''') and Ubuntu 14.04 ('''trusty''') have the gcc-arm-none-eabi package in the official repositories ('''universe'''), and can be installed with:&lt;br /&gt;
 sudo apt-get update&lt;br /&gt;
 sudo apt-get install gcc-arm-none-eabi&lt;br /&gt;
&lt;br /&gt;
=== Old toolchain for Paparazzi v4.x and earlier ===&lt;br /&gt;
&lt;br /&gt;
'''For Paparazzi v4.x''' and earlier you need to install the &amp;lt;tt&amp;gt;paparazzi-arm-multilib&amp;lt;/tt&amp;gt; package. It has support for both ARM7 (i.e. Tiny,TWOG,YAPA autopilot boards) as well as STM32F1 (i.e. LISA boards).&amp;lt;br&amp;gt;&lt;br /&gt;
'''This toolchain does not properly support STM32F4 based autopilots!!'''&lt;br /&gt;
&lt;br /&gt;
You can install it explicitly with:&lt;br /&gt;
 sudo apt-get install paparazzi-arm-multilib&lt;br /&gt;
&lt;br /&gt;
== Optional Packages ==&lt;br /&gt;
&lt;br /&gt;
The packages &amp;lt;b&amp;gt;lpc21isp&amp;lt;/b&amp;gt; and &amp;lt;b&amp;gt;openocd&amp;lt;/b&amp;gt; are normally '''automatically installed''' as they are recommended packages of paparazzi-dev, '''if not''' you can manually install them via:&lt;br /&gt;
 &lt;br /&gt;
 sudo apt-get install lpc21isp openocd&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tt&amp;gt;lpc21isp&amp;lt;/tt&amp;gt; is needed to serially flash the LPC2148 based autopilots (e.g. bootloader for tiny, twog, umarim), &amp;lt;tt&amp;gt;openocd&amp;lt;/tt&amp;gt; is for flashing via JTAG (e.g. for Lisa boards) and debugging.&lt;br /&gt;
&lt;br /&gt;
== Installing and running Paparazzi ==&lt;br /&gt;
&lt;br /&gt;
Please see [[Installation#Getting_the_Source_Code|Getting the Source Code on the general Installation page]] for details on downloading the Paparazzi source code, compiling and running it.&lt;br /&gt;
&lt;br /&gt;
== Udev rules ==&lt;br /&gt;
&lt;br /&gt;
Add the appropriate [[Udev]] rule (available in fhe file ''50-paparazzi.rules'') to the USB handler.  Simply copy as root &amp;lt;tt&amp;gt;conf/system/udev/rules/50-paparazzi.rules&amp;lt;/tt&amp;gt; to &amp;lt;tt&amp;gt;/etc/udev/rules.d/&amp;lt;/tt&amp;gt;, e.g in a terminal:&lt;br /&gt;
&lt;br /&gt;
 cd &amp;lt;your paparazzi directory&amp;gt;&lt;br /&gt;
 sudo cp conf/system/udev/rules/50-paparazzi.rules /etc/udev/rules.d/&lt;br /&gt;
&lt;br /&gt;
See the [[Udev]] page for more details.&lt;br /&gt;
&lt;br /&gt;
== Troubleshooting ==&lt;br /&gt;
&lt;br /&gt;
=== No access rights for USB devices ===&lt;br /&gt;
&lt;br /&gt;
Some Linux distributions, don't allow standard (non admin) users to directly access the USB bus by default. On recent Ubuntu/Debian versions the first/main user is already a member of the ''plugdev'' group which should be sufficient for most cases.&amp;lt;br&amp;gt;&lt;br /&gt;
If you have problems, make yourself a member of the ''plugdev'' and ''dialout'' groups:&lt;br /&gt;
&lt;br /&gt;
 sudo adduser &amp;lt;your login&amp;gt; plugdev&lt;br /&gt;
 sudo adduser &amp;lt;your login&amp;gt; dialout&lt;br /&gt;
&lt;br /&gt;
Logout and login again.&lt;br /&gt;
&lt;br /&gt;
=== arm-none-eabi-gcc: Command not found ===&lt;br /&gt;
Appeared on Debian Wheezy 7 (gcc-arm-none-eabi-4_8-2013q4 installed via tarball)&amp;lt;br/&amp;gt;&lt;br /&gt;
If this error occurs, maybe the [https://packages.debian.org/de/wheezy/ia32-libs ia32-libs] are missing.&lt;br /&gt;
&lt;br /&gt;
Enable multiarch and install ia32-libs:&lt;br /&gt;
 dpkg --add-architecture i386&lt;br /&gt;
 apt-get update&lt;br /&gt;
 apt-get install ia32-libs&lt;br /&gt;
&lt;br /&gt;
===arm-none-eabi-gdb: error with libncurses.so.5===&lt;br /&gt;
Appeared on Xubuntu 14.04 LTS (gcc-arm-none-eabi-4_8-2013q4 installed via tarball)&amp;lt;br/&amp;gt;&lt;br /&gt;
Terminal output: arm-none-eabi-gdb: error while loading shared libraries: libncurses.so.5: cannot open shared object file: No such file or directory&lt;br /&gt;
&lt;br /&gt;
If this error occours, maybe [http://packages.ubuntu.com/search?keywords=lib32ncurses5 lib32ncurses5] is missing. &amp;lt;br/&amp;gt;&lt;br /&gt;
Found on [https://answers.launchpad.net/gcc-arm-embedded/+question/226680 launchpad q&amp;amp;a]&lt;br /&gt;
&lt;br /&gt;
=== FTDI serial adapter not working on old Ubuntu version ===&lt;br /&gt;
&lt;br /&gt;
On older Linux distributions (not needed for lucid and later), the Braille TTY driver interferes with FTDI USB Serial adapters. If somehow your FTDI serial adapter does not work, remove the package via:&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get remove brltty&lt;br /&gt;
&lt;br /&gt;
=== Code not starting on autopilot after changing gcc ===&lt;br /&gt;
&lt;br /&gt;
If you changed the toolchain (e.g. installed a new one for having FPU-Support for the F4), you need to run&lt;br /&gt;
&lt;br /&gt;
 make clean &amp;amp;&amp;amp; make&lt;br /&gt;
&lt;br /&gt;
in sw/ext in order to rebuild the libs. Otherwise the embedded code can behave strange (most likely not start)&lt;br /&gt;
&lt;br /&gt;
[[Category:Software]] [[Category:User_Documentation]] [[Category:Installation]]&lt;/div&gt;</summary>
		<author><name>Garrosh</name></author>
	</entry>
	<entry>
		<id>http://wiki.paparazziuav.org/w/index.php?title=Airframe_Configuration&amp;diff=18245</id>
		<title>Airframe Configuration</title>
		<link rel="alternate" type="text/html" href="http://wiki.paparazziuav.org/w/index.php?title=Airframe_Configuration&amp;diff=18245"/>
		<updated>2014-02-13T17:29:59Z</updated>

		<summary type="html">&lt;p&gt;Garrosh: Removed TeX non breaking space since they don't seem to be possible to do&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;categorytree style=&amp;quot;float:right; clear:right; margin-left:1ex; border: 1px solid gray; padding: 0.7ex;&amp;quot; mode=pages&amp;gt;Airframe_Configuration&amp;lt;/categorytree&amp;gt;&lt;br /&gt;
== About ==&lt;br /&gt;
The airframe file is the most important configuration file and contains all the hardware and software settings for your airframe. It describes what hardware you have and which firmware, sensors, algorithms, etc. you want to use and also holds your configuration parameters. All gains, trims, and behavior settings are defined with standard XML elements.&lt;br /&gt;
&lt;br /&gt;
The XML airframe configuration file is located in &amp;lt;tt&amp;gt;conf/airframes/&amp;lt;yourairframe&amp;gt;.xml&amp;lt;/tt&amp;gt; and always begins with a &amp;lt;!DOCTYPE airframe SYSTEM &amp;quot;airframe.dtd&amp;quot;&amp;gt; line and should look like this&lt;br /&gt;
{{Box Code|conf/airframes/&amp;lt;yourairframe&amp;gt;.xml|&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;!DOCTYPE airframe SYSTEM &amp;quot;airframe.dtd&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;airframe name=&amp;quot;yourairframe&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;!-- The airframe configuration goes here. --&amp;gt;&lt;br /&gt;
&amp;lt;/airframe&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;b&amp;gt;Also see the wiki pages for [[Fixedwing_Configuration|fixedwing specific configuration]] and [[Rotorcraft_Configuration|rotorcraft specific configuration]].&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Creating a new Aircraft ==&lt;br /&gt;
While the airframe file is where you configure most aspects of your aircraft, a fully specified aircraft needs several XML configuration files:&lt;br /&gt;
* Airframe (what this page is about)&lt;br /&gt;
* [[Flight_Plans|Flight Plan]]&lt;br /&gt;
* [[Settings]]&lt;br /&gt;
* [[Radio_Control|Radio]] (if you use a PPM based R/C system)&lt;br /&gt;
* [[Telemetry]]&lt;br /&gt;
Each aircraft is assigned a name, unique ID and the associated configuration files in [[Conf.xml|&amp;lt;tt&amp;gt;conf/conf.xml&amp;lt;/tt&amp;gt;]]. To create a new Aircraft, click new in the menu A/C in the [[Paparazzi_Center|Paparazzi Center]] and select your new airframe file, etc. (or specify it by hand in [[Conf.xml|&amp;lt;tt&amp;gt;conf/conf.xml&amp;lt;/tt&amp;gt;]]).&lt;br /&gt;
&lt;br /&gt;
== Firmware and Hardware definitions ==&lt;br /&gt;
First you should specify which firmware you want to use, that is if you have a &amp;lt;tt&amp;gt;[[Fixedwing_Configuration|fixedwing]]&amp;lt;/tt&amp;gt; aircraft or a &amp;lt;tt&amp;gt;[[Rotorcraft_Configuration|rotorcraft]]&amp;lt;/tt&amp;gt;:&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;firmware name=&amp;quot;fixedwing or rotorcraft&amp;quot;&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
  &amp;lt;/firmware&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
=== Select your Board ===&lt;br /&gt;
To specify autopilot hardware you are using and it's low-level settings you have to add a ''target''-tag.&lt;br /&gt;
Each ''target'' has two attributes, which are ''name'' and a corresponding ''board'' attribute.&lt;br /&gt;
The ''name'' attribute is either &amp;quot;ap&amp;quot; (autopilot) or &amp;quot;sim&amp;quot; (simulation).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;firmware name=&amp;quot;fixedwing or rotorcraft&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;target name=&amp;quot;sim&amp;quot; board=&amp;quot;pc&amp;quot;/&amp;gt; &amp;lt;!-- For simulation. --&amp;gt;&lt;br /&gt;
    &amp;lt;target name=&amp;quot;ap&amp;quot;  board=&amp;quot;lisa_m_1.0&amp;quot;/&amp;gt; &amp;lt;!-- Select your board here --&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
  &amp;lt;/firmware&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==== Simulation targets ====&lt;br /&gt;
target name=&amp;quot;sim&amp;quot;,&amp;quot;jsbsim&amp;quot;,&amp;quot;nps&amp;quot;&amp;lt;br/&amp;gt;&lt;br /&gt;
board=&amp;quot;pc&amp;quot;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
More Information at [[Simulation]].&lt;br /&gt;
&lt;br /&gt;
==== Board targets ====&lt;br /&gt;
target name=&amp;quot;ap&amp;quot;&amp;lt;br/&amp;gt;&lt;br /&gt;
board=&lt;br /&gt;
&amp;quot;apogee_0.99&amp;quot;,&lt;br /&gt;
&amp;quot;apogee_1.0&amp;quot;,&lt;br /&gt;
&amp;quot;ardrone2_raw&amp;quot;,&lt;br /&gt;
&amp;quot;ardrone2_sdk&amp;quot;,&lt;br /&gt;
&amp;quot;booz_1.0&amp;quot;,&lt;br /&gt;
&amp;quot;classix&amp;quot;,&lt;br /&gt;
&amp;quot;hb_1.1&amp;quot;,&lt;br /&gt;
&amp;quot;krooz_sd&amp;quot;,&lt;br /&gt;
&amp;quot;lisa_l_1.0&amp;quot;, &lt;br /&gt;
&amp;quot;lisa_l_1.1&amp;quot;, &lt;br /&gt;
&amp;quot;lisa_m_1.0&amp;quot;, &lt;br /&gt;
&amp;quot;lisa_m_2.0&amp;quot;,&lt;br /&gt;
&amp;quot;logom_2.6&amp;quot;,&lt;br /&gt;
&amp;quot;navgo_1.0&amp;quot;, &lt;br /&gt;
&amp;quot;sdlog_1.0&amp;quot;, &lt;br /&gt;
&amp;quot;stm32f4_discovery&amp;quot;,&lt;br /&gt;
&amp;quot;tiny_0.99&amp;quot;, &lt;br /&gt;
&amp;quot;tiny_1.1&amp;quot;, &lt;br /&gt;
&amp;quot;tiny_2.1&amp;quot;, &lt;br /&gt;
&amp;quot;tiny_2.11&amp;quot;, &lt;br /&gt;
&amp;quot;twog_1.0&amp;quot;, &lt;br /&gt;
&amp;quot;umarim_1.0&amp;quot;,&lt;br /&gt;
&amp;quot;umarim_lite_2.0&amp;quot;,&lt;br /&gt;
&amp;quot;yapa_2.0&amp;quot;,&lt;br /&gt;
&lt;br /&gt;
==== Direct Makefile ====&lt;br /&gt;
Optionally you can also add a raw [http://en.wikipedia.org/wiki/Makefile Makefile] section. This is only needed in very advanced setups. For example when testing newly developed hardware.&lt;br /&gt;
&lt;br /&gt;
=== LEDs ===&lt;br /&gt;
You can configure the LEDs on the autopilot to be used for different status indicators:&lt;br /&gt;
; ''SYS_TIME_LED'': blinks with 1Hz&lt;br /&gt;
; ''AHRS_ALIGNER_LED'': blinks until the AHRS is aligned (gyro bias initilalized) and then stays on&lt;br /&gt;
; ''GPS_LED'': blinking if trying to get a fix, on if 3D fix&lt;br /&gt;
; ''RADIO_CONTROL_LED'': on if RC signal is ok&lt;br /&gt;
; ''BARO_LED'' : only on booz and navgo boards: blinks until baro offset is initialized and then stays on&lt;br /&gt;
&lt;br /&gt;
Depending on your board some of the LEDs on it are already assigned to some indicators by default, check the appropriate autopilot board page for the defaults.&lt;br /&gt;
Use a configure node in the firmware section to assign an indicator to a LED number or disable that with ''none'':&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;firmware name=&amp;quot;fixedwing or rotorcraft&amp;quot;&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
     &amp;lt;configure name=&amp;quot;SYS_TIME_LED&amp;quot; value=&amp;quot;1&amp;quot;/&amp;gt;&lt;br /&gt;
     &amp;lt;configure name=&amp;quot;RADIO_CONTROL_LED&amp;quot; value=&amp;quot;2&amp;quot;/&amp;gt;&lt;br /&gt;
     &amp;lt;configure name=&amp;quot;GPS_LED&amp;quot; value=&amp;quot;none&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;/firmware&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
Beware that you can only assign '''one''' indicator to a LED number. So if the LED you want to use is already in use because another indicator is set to that number by default you have to disable that other indicator by setting it to ''none''.&lt;br /&gt;
&lt;br /&gt;
== Subsystems ==&lt;br /&gt;
&lt;br /&gt;
Each autopilot features certain [[Subsystems|subsystems]] which need to be configured properly.&lt;br /&gt;
The most important ones are described below.&lt;br /&gt;
&lt;br /&gt;
=== IMU ===&lt;br /&gt;
Add the [[Subsystem/imu|imu subsystem]] with the type you are using.&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;firmware name=&amp;quot;fixedwing or rotorcraft&amp;quot;&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
    &amp;lt;subsystem name=&amp;quot;imu&amp;quot;       type=&amp;quot;aspirin_v1.5&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;/firmware&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
See the [[Subsystem/imu|imu subsystem]] page for more details.&lt;br /&gt;
Also see the [[ImuCalibration|IMU calibration]] page.&lt;br /&gt;
&lt;br /&gt;
=== AHRS ===&lt;br /&gt;
The [[Subsystem/ahrs|AHRS subsystem]] specifies which attitude estimation filter you are using, e.g. for the complementary filter:&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;firmware name=&amp;quot;fixedwing or rotorcraft&amp;quot;&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
    &amp;lt;subsystem name=&amp;quot;ahrs&amp;quot; type=&amp;quot;int_cmpl_euler&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;/firmware&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
All AHRS algorithms depend on an imu subsystem, except for the ahrs_infrared which depends on the infrared module.&lt;br /&gt;
See the [[Subsystem/ahrs|AHRS subsystem page]] for more details.&lt;br /&gt;
&lt;br /&gt;
If the magnetometer should be used the [[Subsystem/ahrs#Local_Magnetic_Field|local magnetic field section]] must be filled in.&lt;br /&gt;
&lt;br /&gt;
=== Radio Control ===&lt;br /&gt;
&lt;br /&gt;
Supported types are:&lt;br /&gt;
* ''ppm''&lt;br /&gt;
* ''spektrum''&lt;br /&gt;
* ''datalink''&lt;br /&gt;
&lt;br /&gt;
Just specify the appropriate [[Subsystem/radio_control|radio control subsystem]] in your firmware section, e.g.:&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;firmware name=&amp;quot;fixedwing or rotorcraft&amp;quot;&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
    &amp;lt;subsystem name=&amp;quot;radio_control&amp;quot;     type=&amp;quot;ppm&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;/firmware&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Telemetry (Modem) ===&lt;br /&gt;
The modem protocol and baud rate must be set in both the airframe file and ground station.  Any standard baud rate can be used, with 9600 being adequate and 57600 recommended for most users to allow high speed telemetry for more detailed flight data analysis.  The actual data rate is determined by the number of messages being sent and the period of each message as defined in your [[Telemetry|telemetry file]], e.g. &amp;lt;tt&amp;gt;conf/telemetry/default.xml&amp;lt;/tt&amp;gt;.  Those wishing to experiment with &amp;quot;alternative&amp;quot; modems can reduce the number and period of each telemetry message to fit within most any bandwidth constraint.&lt;br /&gt;
&lt;br /&gt;
The [[Subsystem/telemetry|telemetry subsystem]] supports the following modem protocols:&lt;br /&gt;
* Standard transparent serial (pprz) - this is compatible with all modems and can be used to connect the autopilot directly to a PC for testing without a modem.&lt;br /&gt;
* Maxstream API protocol (xbee) - compatible with all Maxstream modems including the 9XTend and Zigbee.  This protocol enables hardware addressing, allowing multiple aircraft to be managed from a single ground modem.&lt;br /&gt;
&lt;br /&gt;
Just specify the appropriate [[Subsystem/telemetry|telemetry subsystem]] in your firmware section. You can currently choose between the types ''transparent'', ''transparent_usb'' and ''xbee_api''.&lt;br /&gt;
&lt;br /&gt;
'''The default baudrate is 57600 baud, see the [[Subsystem/telemetry|telemetry subsystem]] page for more details and configuration options.'''&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;firmware name=&amp;quot;fixedwing or rotorcraft&amp;quot;&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
    &amp;lt;subsystem name=&amp;quot;telemetry&amp;quot;     type=&amp;quot;transparent&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;/firmware&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== GPS ===&lt;br /&gt;
The serial port settings must match that of the GPS and are configured here along with the necessary files to interpret the u-blox UBX binary protocol:&lt;br /&gt;
&lt;br /&gt;
Just specify the appropriate [[Subsystem/gps|gps subsystem]] in your firmware section. You can currently choose between the types '''ublox''' and '''ublox_utm''' for the older series 4 modules which still provide a UTM message.&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;firmware name=&amp;quot;fixedwing or rotorcraft&amp;quot;&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
    &amp;lt;subsystem name=&amp;quot;gps&amp;quot;               type=&amp;quot;ublox&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;/firmware&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
The correct UART is already defined by default according to your board.&lt;br /&gt;
The default GPS baudrate is 38400baud.&lt;br /&gt;
&lt;br /&gt;
If you need to set different baud rates or UART see the [[Subsystem/gps]] page for the options.&lt;br /&gt;
&lt;br /&gt;
'''Note:'''&lt;br /&gt;
* u-blox GPS modules are factory configured for 9600 baud, 38,400 baud is recommended along with the other required changes.  The GPS can be accessed directly through the [[tunnel|UART Tunnel]] and [[GPS#GPS_configuration_using_U-Center|Configured with u-center]]&lt;br /&gt;
&lt;br /&gt;
== XML Parameters ==&lt;br /&gt;
'''When defining parameters you can use [[Units|automatic unit conversion]] to conveniently set it in e.g. degrees.'''&lt;br /&gt;
&lt;br /&gt;
=== Commands ===&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;commands&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; lists the abstract commands you need to control the aircraft. In a simple fixed-wing example, we have only three:&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;commands&amp;gt;&lt;br /&gt;
  &amp;lt;axis name=&amp;quot;THROTTLE&amp;quot; failsafe_value=&amp;quot;0&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;axis name=&amp;quot;ROLL&amp;quot;     failsafe_value=&amp;quot;0&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;axis name=&amp;quot;PITCH&amp;quot;    failsafe_value=&amp;quot;0&amp;quot;/&amp;gt;&lt;br /&gt;
 &amp;lt;/commands&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
For rotorcraft, it is usually:&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;commands&amp;gt;&lt;br /&gt;
  &amp;lt;axis name=&amp;quot;PITCH&amp;quot;    failsafe_value=&amp;quot;0&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;axis name=&amp;quot;ROLL&amp;quot;     failsafe_value=&amp;quot;0&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;axis name=&amp;quot;YAW&amp;quot;      failsafe_value=&amp;quot;0&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;axis name=&amp;quot;THRUST&amp;quot;   failsafe_value=&amp;quot;0&amp;quot;/&amp;gt;&lt;br /&gt;
 &amp;lt;/commands&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Each command is also associated with a failsafe value which will be used if no controller is active, for example during initialization of the autopilot board. The range of these values is [-9600:9600]. For &amp;lt;tt&amp;gt;&amp;quot;THROTTLE&amp;quot;&amp;lt;/tt&amp;gt;, the range is [0, 9600] and in the corresponding &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;servo&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; definition the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;neutral&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; and &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;min&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; are usually the same for PWM based servos (see below). Note that these commands do not necessarily match the servo actuators. For example, the &amp;lt;tt&amp;gt;&amp;quot;ROLL&amp;quot;&amp;lt;/tt&amp;gt; command is typically linked to two aileron actuators.&lt;br /&gt;
&lt;br /&gt;
=== Servos ===&lt;br /&gt;
&lt;br /&gt;
The above commands get translated to the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;servos&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; here. In the example below we use two elevons and a motor. ([http://en.wikipedia.org/wiki/Elevon ''Elevons''] are surfaces used for both pitch and roll as on a flying wing.) These servos are listed in the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;servos&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; section:&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;servos&amp;gt;&lt;br /&gt;
  &amp;lt;servo name=&amp;quot;THROTTLE&amp;quot;         no=&amp;quot;0&amp;quot; min=&amp;quot;1000&amp;quot; neutral=&amp;quot;1000&amp;quot; max=&amp;quot;2000&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;servo name=&amp;quot;ELEVON_LEFTSIDE&amp;quot;  no=&amp;quot;1&amp;quot; min=&amp;quot;2000&amp;quot; neutral=&amp;quot;1500&amp;quot; max=&amp;quot;1000&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;servo name=&amp;quot;ELEVON_RIGHTSIDE&amp;quot; no=&amp;quot;2&amp;quot; min=&amp;quot;1000&amp;quot; neutral=&amp;quot;1500&amp;quot; max=&amp;quot;2000&amp;quot;/&amp;gt;&lt;br /&gt;
 &amp;lt;/servos&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
Names are associated to the corresponding '''real physical connector''' to which a servo is connected '''on the autopilot board'''. For example no=&amp;quot;2&amp;quot; means connector two on the board. Also the servo neutral value, total range and direction are defined.  Min/max/neutral values are expressed in milliseconds. The direction of travel can be reversed by exchanging min with max (as in &amp;lt;tt&amp;gt;&amp;quot;ELEVON_LEFTSIDE&amp;quot;&amp;lt;/tt&amp;gt;, above).  The ''standard'' travel for a hobby servo is 1000&amp;lt;math&amp;gt;\mu\text{s}&amp;lt;/math&amp;gt; - 2000&amp;lt;math&amp;gt;\mu\text{s}&amp;lt;/math&amp;gt; with a 1500&amp;lt;math&amp;gt;\mu\text{s}&amp;lt;/math&amp;gt; neutral. Trim can be added by changing this neutral value. Absolute servo travel limits can be increased or reduced with the min/max values.  The &amp;lt;tt&amp;gt;&amp;quot;THROTTLE&amp;quot;&amp;lt;/tt&amp;gt; servo typically has the same value for the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;neutral&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; and &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;min&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The attribute &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;driver&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; for &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;servos&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; node tells which actuators' driver is associated the the listed servos. After the version '''v4.9_devel-164-gdb0d004''', multiple servos sections can be defined and used together, if the correct [[Subsystem/actuators| actuators subsystems]] are loaded. Some boards are automatically loading a default driver, the one used when no &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;driver&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; attribute is specified.&lt;br /&gt;
&lt;br /&gt;
Note the following important tips:&lt;br /&gt;
* Reverse the servo direction by exchanging min/max&lt;br /&gt;
* Trim should always be adjusted mechanically if possible to avoid asymmetrical travel&lt;br /&gt;
* Any reduction of the total travel range should be done mechanically to maintain precision&lt;br /&gt;
* Many servos will respond well to values slightly outside the normal 1000-2000ms range but experiment carefully as the servo may not operate reliably outside this range and may even suffer permanent damage.&lt;br /&gt;
* Board connector numbering starts with &amp;lt;b&amp;gt;zero (0)&amp;lt;/b&amp;gt; not with one&lt;br /&gt;
* Servos are also known under the synonym &amp;lt;b&amp;gt;actuators&amp;lt;/b&amp;gt;&lt;br /&gt;
* (after version '''v4.9_devel-164-gdb0d004''') For I2C based motor speed control using the [[Rotorcraft_Configuration#Motor_Mixing|motor mixing]]:&lt;br /&gt;
** min: command to stop the motor&lt;br /&gt;
** neutral: motor idle command&lt;br /&gt;
** max: max thrust command&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;servos&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; are then linked to the commands in the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;command_laws&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; section:&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;command_laws&amp;gt;&lt;br /&gt;
  &amp;lt;let var=&amp;quot;aileron&amp;quot;            value=&amp;quot;@ROLL  * 0.3&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;let var=&amp;quot;elevator&amp;quot;           value=&amp;quot;@PITCH * 0.7&amp;quot;/&amp;gt;  &lt;br /&gt;
  &amp;lt;set servo=&amp;quot;THROTTLE&amp;quot;         value=&amp;quot;@THROTTLE&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;set servo=&amp;quot;ELEVON_LEFTSIDE&amp;quot;  value=&amp;quot;$elevator + $aileron&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;set servo=&amp;quot;ELEVON_RIGHTSIDE&amp;quot; value=&amp;quot;$elevator - $aileron&amp;quot;/&amp;gt;&lt;br /&gt;
 &amp;lt;/command_laws&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Image:airframe_sign_conventions.jpg|thumb|Sign conventions for flight dynamics]]&lt;br /&gt;
where the third line is the simplest: the throttle servo value equals throttle command value. The other lines define and control the pitch/roll mixing.  Elevon values are computed with a combination of two commands, '''ROLL''' and '''PITCH'''. This ''mixer'' is defined with two intermediate variables '''aileron''' and '''elevator''' introduced with the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;let&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; element.  The '''@''' symbol is used to reference a command value in the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;value&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; attribute of the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;set&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; and &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;let&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; elements.  In the above example, the servos are limited to +/- 70% of their full travel for pitch and 30% for roll, only in combination can the servos reach 100% deflection.  Note that these numbers ''should add up 100% or more, never less''.  For example, you may want 100% travel available for pitch - this means if a roll is commanded along with maximum pitch only one servo will respond to the roll command as the other has already reached its mechanical limit.  If you find after tuning that these numbers add to less than 100% consider reducing the surface travel mechanically.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Note that the signs used in the description follow the standard convention.&lt;br /&gt;
&lt;br /&gt;
After '''v4.9_devel-164-gdb0d004''', the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;command_laws&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; section is mandatory for both fixedwing and rotorcraft firmwares, only for fixedwing otherwise.&lt;br /&gt;
&lt;br /&gt;
=== Battery === &lt;br /&gt;
This section gives characteristics for monitoring the main power battery.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;MILLIAMP_AT_FULL_THROTTLE&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; represents the actual current (in mA) when full THROTTLE is applied. Note that when flying the current typically is significantly lower than in static tests at home on your workbench. &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;MILLIAMP_AT_FULL_THROTTLE&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; is used to compute the &amp;lt;tt&amp;gt;energy&amp;lt;/tt&amp;gt; value of the &amp;lt;tt&amp;gt;BAT&amp;lt;/tt&amp;gt; message when no [[Current_sensor|Current sensor]] is mounted in the airframe. This value can also be used in flight plans. For example, if at full throttle your motor consumes 10 Amps, use a value of 10000. You can &amp;quot;tweak&amp;quot; this number after a few flights to match the capacity of your battery. If upon landing your bat.energy messages says that you used 2500 mAh while the energy recharged into the battery is only 2000 mAh, you could reduce the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;MILLIAMP_AT_FULL_THROTTLE&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; value by 20% to match your in-flight current consumption. This tweaking is most precise if you fly full throttle only (respectively no throttle to glide down again).&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;CURRENT_ESTIMATION_NONLINEARITY&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; can be added to tweak the energy estimation for non full throttle cruise. As the current consumption is nonlinear, at 50% throttle it is likely to be substantially less than 50%. A superellipse is used to approximate this nonlinearity. The default setting is 1.2 and is used if the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;CURRENT_ESTIMATION_NONLINEARITY&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; is not defined in your airframe file. A value 1 corresponds to linear behaviour, 1.5 corresponds to strong nonlinearity. The tweaking is done same as decribed above for &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;MILLIAMP_AT_FULL_THROTTLE&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt;, but only partial throttle (cruise throttle) should be applied in flight.&lt;br /&gt;
&lt;br /&gt;
If both &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;MILLIAMP_AT_FULL_THROTTLE&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; and &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;CURRENT_ESTIMATION_NONLINEARITY&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; are tweaked well, you get precise energy estimations with less than 5% error independant of your flight pattern without even requiring a [[Current_sensor|current sensor]].&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;CATASTROPHIC_BAT_LEVEL&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; (was previously &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;LOW_BATTERY&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt;) value defines the voltage at which the autopilot will lock the throttle at 0% in autonomous mode (kill_throttle mode). This value is also used by the ground server to issue a '''CATASTROPHIC''' alarm message on the bus (this message will be displayed in the console of the GCS).  &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;CRITIC&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; and &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;LOW&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; values will also used as threshold for '''CRITIC''' and '''WARNING''' alarms. They are optional and the respective defaults are 10.0 and 10.5V.&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;MAX_BAT_LEVEL&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; may be specified to improve the display of the battery gauge in the strip or in &amp;quot;papgets&amp;quot;. Note that this definition is optional, with a default value of 12.5V.&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;section name=&amp;quot;BAT&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;MILLIAMP_AT_FULL_THROTTLE&amp;quot; value=&amp;quot;12000&amp;quot; unit=&amp;quot;mA&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;CATASTROPHIC_BAT_LEVEL&amp;quot; value=&amp;quot;6.0&amp;quot; unit=&amp;quot;V&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;CRITIC_BAT_LEVEL&amp;quot; value=&amp;quot;6.5&amp;quot; unit=&amp;quot;V&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;LOW_BAT_LEVEL&amp;quot; value=&amp;quot;7.0&amp;quot; unit=&amp;quot;V&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;MAX_BAT_LEVEL&amp;quot; value=&amp;quot;8.4&amp;quot; unit=&amp;quot;V&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;/section&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
The conversion of ADC measurements to Voltage is already defined for the different autopilot boards, if you need to override these defaults you can use the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;VoltageOfAdc(adc)&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; define and also specify offsets or anything else you might need, e.g.:&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;section name=&amp;quot;BAT&amp;quot;&amp;gt;&lt;br /&gt;
    ...&lt;br /&gt;
    &amp;lt;define name=&amp;quot;VOLTAGE_ADC_SCALE&amp;quot; value=&amp;quot;0.0177531&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;VOLTAGE_OFFSET&amp;quot; value=&amp;quot;0.5&amp;quot; unit=&amp;quot;V&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;VoltageOfAdc(adc)&amp;quot; value =&amp;quot;(VOLTAGE_ADC_SCALE * adc + VOLTAGE_OFFSET)&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;/section&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Modules ===&lt;br /&gt;
The [[Modules|modules]] allow to add new code in a flexible way with initialisation, periodic and event functions without modifying the main AP loop.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;modules main_freq=&amp;quot;60&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;load name=&amp;quot;demo_module.xml&amp;quot;/&amp;gt;&lt;br /&gt;
 &amp;lt;/modules&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* The main_freq parameter (in Hz) allows to specify the frequency of the main loop. Default is 60 Hz&lt;br /&gt;
&lt;br /&gt;
=== GCS ===&lt;br /&gt;
Use this &amp;lt;b&amp;gt;optional&amp;lt;/b&amp;gt; section to help customize parts of the GCS for a specific airframe:&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;section name=&amp;quot;GCS&amp;quot;&amp;gt;&lt;br /&gt;
    ...&lt;br /&gt;
    &amp;lt;define name=&amp;quot;ALT_SHIFT_PLUS_PLUS&amp;quot; value=&amp;quot;30&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;ALT_SHIFT_PLUS&amp;quot; value=&amp;quot;5&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;ALT_SHIFT_MINUS&amp;quot; value=&amp;quot;-5&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;SPEECH_NAME&amp;quot; value=&amp;quot;Quad&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;AC_ICON&amp;quot; value=&amp;quot;flyingwing&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;/section&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
[[Image:ac_icon_multi_uav.png|thumb|Various A/C icons demonstrated on a multi UAV simulation session]]&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;tt&amp;gt;ALT_SHIFT_PLUS_PLUS&amp;lt;/tt&amp;gt; sets the number of metres the target altitude will change when the double up arrow button is pressed on the [[GCS#Strips|strip]]&lt;br /&gt;
* &amp;lt;tt&amp;gt;ALT_SHIFT_PLUS&amp;lt;/tt&amp;gt; sets the number of metres the target altitude will change when the up arrow button is pressed on the [[GCS#Strips|strip]]&lt;br /&gt;
* &amp;lt;tt&amp;gt;ALT_SHIFT_MINUS&amp;lt;/tt&amp;gt; sets the number of metres the target altitude will change when the down arrow button is pressed on the [[GCS#Strips|strip]]&lt;br /&gt;
* &amp;lt;tt&amp;gt;SPEECH_NAME&amp;lt;/tt&amp;gt; a string ([a-zA-Z0-9_]) that will be used in place of the aircraft name specified in &amp;lt;tt&amp;gt;conf.xml&amp;lt;/tt&amp;gt; for the [[Speech|speech]] and [[GCS#Alarms|alarms]] functionality. Set this to &amp;quot;_&amp;quot; to prevent the speech function from saying the aircraft name. Useful if your aircraft name takes a long time to say (i.e. &amp;quot;UAV1-A_with_spektrum&amp;quot; can be shortened to &amp;quot;Plane&amp;quot;).&lt;br /&gt;
* &amp;lt;tt&amp;gt;AC_ICON&amp;lt;/tt&amp;gt; can be used to define the vehicle icon (or overwrite the default icon) that shows up on the 2D-map of the GCS. Available values are: &amp;lt;tt&amp;gt;flyingwing&amp;lt;/tt&amp;gt; , &amp;lt;tt&amp;gt;fixedwing&amp;lt;/tt&amp;gt; , &amp;lt;tt&amp;gt;rotorcraft&amp;lt;/tt&amp;gt; , &amp;lt;tt&amp;gt;home&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:User_Documentation]] [[Category:Airframe_Configuration]]&lt;/div&gt;</summary>
		<author><name>Garrosh</name></author>
	</entry>
	<entry>
		<id>http://wiki.paparazziuav.org/w/index.php?title=Airframe_Configuration&amp;diff=18244</id>
		<title>Airframe Configuration</title>
		<link rel="alternate" type="text/html" href="http://wiki.paparazziuav.org/w/index.php?title=Airframe_Configuration&amp;diff=18244"/>
		<updated>2014-02-13T17:25:00Z</updated>

		<summary type="html">&lt;p&gt;Garrosh: Changed miliseconds to microseconds on servo travel&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;categorytree style=&amp;quot;float:right; clear:right; margin-left:1ex; border: 1px solid gray; padding: 0.7ex;&amp;quot; mode=pages&amp;gt;Airframe_Configuration&amp;lt;/categorytree&amp;gt;&lt;br /&gt;
== About ==&lt;br /&gt;
The airframe file is the most important configuration file and contains all the hardware and software settings for your airframe. It describes what hardware you have and which firmware, sensors, algorithms, etc. you want to use and also holds your configuration parameters. All gains, trims, and behavior settings are defined with standard XML elements.&lt;br /&gt;
&lt;br /&gt;
The XML airframe configuration file is located in &amp;lt;tt&amp;gt;conf/airframes/&amp;lt;yourairframe&amp;gt;.xml&amp;lt;/tt&amp;gt; and always begins with a &amp;lt;!DOCTYPE airframe SYSTEM &amp;quot;airframe.dtd&amp;quot;&amp;gt; line and should look like this&lt;br /&gt;
{{Box Code|conf/airframes/&amp;lt;yourairframe&amp;gt;.xml|&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;!DOCTYPE airframe SYSTEM &amp;quot;airframe.dtd&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;airframe name=&amp;quot;yourairframe&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;!-- The airframe configuration goes here. --&amp;gt;&lt;br /&gt;
&amp;lt;/airframe&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;b&amp;gt;Also see the wiki pages for [[Fixedwing_Configuration|fixedwing specific configuration]] and [[Rotorcraft_Configuration|rotorcraft specific configuration]].&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Creating a new Aircraft ==&lt;br /&gt;
While the airframe file is where you configure most aspects of your aircraft, a fully specified aircraft needs several XML configuration files:&lt;br /&gt;
* Airframe (what this page is about)&lt;br /&gt;
* [[Flight_Plans|Flight Plan]]&lt;br /&gt;
* [[Settings]]&lt;br /&gt;
* [[Radio_Control|Radio]] (if you use a PPM based R/C system)&lt;br /&gt;
* [[Telemetry]]&lt;br /&gt;
Each aircraft is assigned a name, unique ID and the associated configuration files in [[Conf.xml|&amp;lt;tt&amp;gt;conf/conf.xml&amp;lt;/tt&amp;gt;]]. To create a new Aircraft, click new in the menu A/C in the [[Paparazzi_Center|Paparazzi Center]] and select your new airframe file, etc. (or specify it by hand in [[Conf.xml|&amp;lt;tt&amp;gt;conf/conf.xml&amp;lt;/tt&amp;gt;]]).&lt;br /&gt;
&lt;br /&gt;
== Firmware and Hardware definitions ==&lt;br /&gt;
First you should specify which firmware you want to use, that is if you have a &amp;lt;tt&amp;gt;[[Fixedwing_Configuration|fixedwing]]&amp;lt;/tt&amp;gt; aircraft or a &amp;lt;tt&amp;gt;[[Rotorcraft_Configuration|rotorcraft]]&amp;lt;/tt&amp;gt;:&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;firmware name=&amp;quot;fixedwing or rotorcraft&amp;quot;&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
  &amp;lt;/firmware&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
=== Select your Board ===&lt;br /&gt;
To specify autopilot hardware you are using and it's low-level settings you have to add a ''target''-tag.&lt;br /&gt;
Each ''target'' has two attributes, which are ''name'' and a corresponding ''board'' attribute.&lt;br /&gt;
The ''name'' attribute is either &amp;quot;ap&amp;quot; (autopilot) or &amp;quot;sim&amp;quot; (simulation).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;firmware name=&amp;quot;fixedwing or rotorcraft&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;target name=&amp;quot;sim&amp;quot; board=&amp;quot;pc&amp;quot;/&amp;gt; &amp;lt;!-- For simulation. --&amp;gt;&lt;br /&gt;
    &amp;lt;target name=&amp;quot;ap&amp;quot;  board=&amp;quot;lisa_m_1.0&amp;quot;/&amp;gt; &amp;lt;!-- Select your board here --&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
  &amp;lt;/firmware&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==== Simulation targets ====&lt;br /&gt;
target name=&amp;quot;sim&amp;quot;,&amp;quot;jsbsim&amp;quot;,&amp;quot;nps&amp;quot;&amp;lt;br/&amp;gt;&lt;br /&gt;
board=&amp;quot;pc&amp;quot;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
More Information at [[Simulation]].&lt;br /&gt;
&lt;br /&gt;
==== Board targets ====&lt;br /&gt;
target name=&amp;quot;ap&amp;quot;&amp;lt;br/&amp;gt;&lt;br /&gt;
board=&lt;br /&gt;
&amp;quot;apogee_0.99&amp;quot;,&lt;br /&gt;
&amp;quot;apogee_1.0&amp;quot;,&lt;br /&gt;
&amp;quot;ardrone2_raw&amp;quot;,&lt;br /&gt;
&amp;quot;ardrone2_sdk&amp;quot;,&lt;br /&gt;
&amp;quot;booz_1.0&amp;quot;,&lt;br /&gt;
&amp;quot;classix&amp;quot;,&lt;br /&gt;
&amp;quot;hb_1.1&amp;quot;,&lt;br /&gt;
&amp;quot;krooz_sd&amp;quot;,&lt;br /&gt;
&amp;quot;lisa_l_1.0&amp;quot;, &lt;br /&gt;
&amp;quot;lisa_l_1.1&amp;quot;, &lt;br /&gt;
&amp;quot;lisa_m_1.0&amp;quot;, &lt;br /&gt;
&amp;quot;lisa_m_2.0&amp;quot;,&lt;br /&gt;
&amp;quot;logom_2.6&amp;quot;,&lt;br /&gt;
&amp;quot;navgo_1.0&amp;quot;, &lt;br /&gt;
&amp;quot;sdlog_1.0&amp;quot;, &lt;br /&gt;
&amp;quot;stm32f4_discovery&amp;quot;,&lt;br /&gt;
&amp;quot;tiny_0.99&amp;quot;, &lt;br /&gt;
&amp;quot;tiny_1.1&amp;quot;, &lt;br /&gt;
&amp;quot;tiny_2.1&amp;quot;, &lt;br /&gt;
&amp;quot;tiny_2.11&amp;quot;, &lt;br /&gt;
&amp;quot;twog_1.0&amp;quot;, &lt;br /&gt;
&amp;quot;umarim_1.0&amp;quot;,&lt;br /&gt;
&amp;quot;umarim_lite_2.0&amp;quot;,&lt;br /&gt;
&amp;quot;yapa_2.0&amp;quot;,&lt;br /&gt;
&lt;br /&gt;
==== Direct Makefile ====&lt;br /&gt;
Optionally you can also add a raw [http://en.wikipedia.org/wiki/Makefile Makefile] section. This is only needed in very advanced setups. For example when testing newly developed hardware.&lt;br /&gt;
&lt;br /&gt;
=== LEDs ===&lt;br /&gt;
You can configure the LEDs on the autopilot to be used for different status indicators:&lt;br /&gt;
; ''SYS_TIME_LED'': blinks with 1Hz&lt;br /&gt;
; ''AHRS_ALIGNER_LED'': blinks until the AHRS is aligned (gyro bias initilalized) and then stays on&lt;br /&gt;
; ''GPS_LED'': blinking if trying to get a fix, on if 3D fix&lt;br /&gt;
; ''RADIO_CONTROL_LED'': on if RC signal is ok&lt;br /&gt;
; ''BARO_LED'' : only on booz and navgo boards: blinks until baro offset is initialized and then stays on&lt;br /&gt;
&lt;br /&gt;
Depending on your board some of the LEDs on it are already assigned to some indicators by default, check the appropriate autopilot board page for the defaults.&lt;br /&gt;
Use a configure node in the firmware section to assign an indicator to a LED number or disable that with ''none'':&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;firmware name=&amp;quot;fixedwing or rotorcraft&amp;quot;&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
     &amp;lt;configure name=&amp;quot;SYS_TIME_LED&amp;quot; value=&amp;quot;1&amp;quot;/&amp;gt;&lt;br /&gt;
     &amp;lt;configure name=&amp;quot;RADIO_CONTROL_LED&amp;quot; value=&amp;quot;2&amp;quot;/&amp;gt;&lt;br /&gt;
     &amp;lt;configure name=&amp;quot;GPS_LED&amp;quot; value=&amp;quot;none&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;/firmware&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
Beware that you can only assign '''one''' indicator to a LED number. So if the LED you want to use is already in use because another indicator is set to that number by default you have to disable that other indicator by setting it to ''none''.&lt;br /&gt;
&lt;br /&gt;
== Subsystems ==&lt;br /&gt;
&lt;br /&gt;
Each autopilot features certain [[Subsystems|subsystems]] which need to be configured properly.&lt;br /&gt;
The most important ones are described below.&lt;br /&gt;
&lt;br /&gt;
=== IMU ===&lt;br /&gt;
Add the [[Subsystem/imu|imu subsystem]] with the type you are using.&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;firmware name=&amp;quot;fixedwing or rotorcraft&amp;quot;&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
    &amp;lt;subsystem name=&amp;quot;imu&amp;quot;       type=&amp;quot;aspirin_v1.5&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;/firmware&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
See the [[Subsystem/imu|imu subsystem]] page for more details.&lt;br /&gt;
Also see the [[ImuCalibration|IMU calibration]] page.&lt;br /&gt;
&lt;br /&gt;
=== AHRS ===&lt;br /&gt;
The [[Subsystem/ahrs|AHRS subsystem]] specifies which attitude estimation filter you are using, e.g. for the complementary filter:&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;firmware name=&amp;quot;fixedwing or rotorcraft&amp;quot;&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
    &amp;lt;subsystem name=&amp;quot;ahrs&amp;quot; type=&amp;quot;int_cmpl_euler&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;/firmware&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
All AHRS algorithms depend on an imu subsystem, except for the ahrs_infrared which depends on the infrared module.&lt;br /&gt;
See the [[Subsystem/ahrs|AHRS subsystem page]] for more details.&lt;br /&gt;
&lt;br /&gt;
If the magnetometer should be used the [[Subsystem/ahrs#Local_Magnetic_Field|local magnetic field section]] must be filled in.&lt;br /&gt;
&lt;br /&gt;
=== Radio Control ===&lt;br /&gt;
&lt;br /&gt;
Supported types are:&lt;br /&gt;
* ''ppm''&lt;br /&gt;
* ''spektrum''&lt;br /&gt;
* ''datalink''&lt;br /&gt;
&lt;br /&gt;
Just specify the appropriate [[Subsystem/radio_control|radio control subsystem]] in your firmware section, e.g.:&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;firmware name=&amp;quot;fixedwing or rotorcraft&amp;quot;&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
    &amp;lt;subsystem name=&amp;quot;radio_control&amp;quot;     type=&amp;quot;ppm&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;/firmware&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Telemetry (Modem) ===&lt;br /&gt;
The modem protocol and baud rate must be set in both the airframe file and ground station.  Any standard baud rate can be used, with 9600 being adequate and 57600 recommended for most users to allow high speed telemetry for more detailed flight data analysis.  The actual data rate is determined by the number of messages being sent and the period of each message as defined in your [[Telemetry|telemetry file]], e.g. &amp;lt;tt&amp;gt;conf/telemetry/default.xml&amp;lt;/tt&amp;gt;.  Those wishing to experiment with &amp;quot;alternative&amp;quot; modems can reduce the number and period of each telemetry message to fit within most any bandwidth constraint.&lt;br /&gt;
&lt;br /&gt;
The [[Subsystem/telemetry|telemetry subsystem]] supports the following modem protocols:&lt;br /&gt;
* Standard transparent serial (pprz) - this is compatible with all modems and can be used to connect the autopilot directly to a PC for testing without a modem.&lt;br /&gt;
* Maxstream API protocol (xbee) - compatible with all Maxstream modems including the 9XTend and Zigbee.  This protocol enables hardware addressing, allowing multiple aircraft to be managed from a single ground modem.&lt;br /&gt;
&lt;br /&gt;
Just specify the appropriate [[Subsystem/telemetry|telemetry subsystem]] in your firmware section. You can currently choose between the types ''transparent'', ''transparent_usb'' and ''xbee_api''.&lt;br /&gt;
&lt;br /&gt;
'''The default baudrate is 57600 baud, see the [[Subsystem/telemetry|telemetry subsystem]] page for more details and configuration options.'''&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;firmware name=&amp;quot;fixedwing or rotorcraft&amp;quot;&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
    &amp;lt;subsystem name=&amp;quot;telemetry&amp;quot;     type=&amp;quot;transparent&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;/firmware&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== GPS ===&lt;br /&gt;
The serial port settings must match that of the GPS and are configured here along with the necessary files to interpret the u-blox UBX binary protocol:&lt;br /&gt;
&lt;br /&gt;
Just specify the appropriate [[Subsystem/gps|gps subsystem]] in your firmware section. You can currently choose between the types '''ublox''' and '''ublox_utm''' for the older series 4 modules which still provide a UTM message.&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;firmware name=&amp;quot;fixedwing or rotorcraft&amp;quot;&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
    &amp;lt;subsystem name=&amp;quot;gps&amp;quot;               type=&amp;quot;ublox&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;/firmware&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
The correct UART is already defined by default according to your board.&lt;br /&gt;
The default GPS baudrate is 38400baud.&lt;br /&gt;
&lt;br /&gt;
If you need to set different baud rates or UART see the [[Subsystem/gps]] page for the options.&lt;br /&gt;
&lt;br /&gt;
'''Note:'''&lt;br /&gt;
* u-blox GPS modules are factory configured for 9600 baud, 38,400 baud is recommended along with the other required changes.  The GPS can be accessed directly through the [[tunnel|UART Tunnel]] and [[GPS#GPS_configuration_using_U-Center|Configured with u-center]]&lt;br /&gt;
&lt;br /&gt;
== XML Parameters ==&lt;br /&gt;
'''When defining parameters you can use [[Units|automatic unit conversion]] to conveniently set it in e.g. degrees.'''&lt;br /&gt;
&lt;br /&gt;
=== Commands ===&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;commands&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; lists the abstract commands you need to control the aircraft. In a simple fixed-wing example, we have only three:&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;commands&amp;gt;&lt;br /&gt;
  &amp;lt;axis name=&amp;quot;THROTTLE&amp;quot; failsafe_value=&amp;quot;0&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;axis name=&amp;quot;ROLL&amp;quot;     failsafe_value=&amp;quot;0&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;axis name=&amp;quot;PITCH&amp;quot;    failsafe_value=&amp;quot;0&amp;quot;/&amp;gt;&lt;br /&gt;
 &amp;lt;/commands&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
For rotorcraft, it is usually:&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;commands&amp;gt;&lt;br /&gt;
  &amp;lt;axis name=&amp;quot;PITCH&amp;quot;    failsafe_value=&amp;quot;0&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;axis name=&amp;quot;ROLL&amp;quot;     failsafe_value=&amp;quot;0&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;axis name=&amp;quot;YAW&amp;quot;      failsafe_value=&amp;quot;0&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;axis name=&amp;quot;THRUST&amp;quot;   failsafe_value=&amp;quot;0&amp;quot;/&amp;gt;&lt;br /&gt;
 &amp;lt;/commands&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Each command is also associated with a failsafe value which will be used if no controller is active, for example during initialization of the autopilot board. The range of these values is [-9600:9600]. For &amp;lt;tt&amp;gt;&amp;quot;THROTTLE&amp;quot;&amp;lt;/tt&amp;gt;, the range is [0, 9600] and in the corresponding &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;servo&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; definition the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;neutral&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; and &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;min&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; are usually the same for PWM based servos (see below). Note that these commands do not necessarily match the servo actuators. For example, the &amp;lt;tt&amp;gt;&amp;quot;ROLL&amp;quot;&amp;lt;/tt&amp;gt; command is typically linked to two aileron actuators.&lt;br /&gt;
&lt;br /&gt;
=== Servos ===&lt;br /&gt;
&lt;br /&gt;
The above commands get translated to the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;servos&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; here. In the example below we use two elevons and a motor. ([http://en.wikipedia.org/wiki/Elevon ''Elevons''] are surfaces used for both pitch and roll as on a flying wing.) These servos are listed in the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;servos&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; section:&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;servos&amp;gt;&lt;br /&gt;
  &amp;lt;servo name=&amp;quot;THROTTLE&amp;quot;         no=&amp;quot;0&amp;quot; min=&amp;quot;1000&amp;quot; neutral=&amp;quot;1000&amp;quot; max=&amp;quot;2000&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;servo name=&amp;quot;ELEVON_LEFTSIDE&amp;quot;  no=&amp;quot;1&amp;quot; min=&amp;quot;2000&amp;quot; neutral=&amp;quot;1500&amp;quot; max=&amp;quot;1000&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;servo name=&amp;quot;ELEVON_RIGHTSIDE&amp;quot; no=&amp;quot;2&amp;quot; min=&amp;quot;1000&amp;quot; neutral=&amp;quot;1500&amp;quot; max=&amp;quot;2000&amp;quot;/&amp;gt;&lt;br /&gt;
 &amp;lt;/servos&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
Names are associated to the corresponding '''real physical connector''' to which a servo is connected '''on the autopilot board'''. For example no=&amp;quot;2&amp;quot; means connector two on the board. Also the servo neutral value, total range and direction are defined.  Min/max/neutral values are expressed in milliseconds. The direction of travel can be reversed by exchanging min with max (as in &amp;lt;tt&amp;gt;&amp;quot;ELEVON_LEFTSIDE&amp;quot;&amp;lt;/tt&amp;gt;, above).  The ''standard'' travel for a hobby servo is 1000~&amp;lt;math&amp;gt;\mu\text{s}&amp;lt;/math&amp;gt; - 2000~&amp;lt;math&amp;gt;\mu\text{s}&amp;lt;/math&amp;gt; with a 1500~&amp;lt;math&amp;gt;\mu\text{s}&amp;lt;/math&amp;gt; neutral. Trim can be added by changing this neutral value. Absolute servo travel limits can be increased or reduced with the min/max values.  The &amp;lt;tt&amp;gt;&amp;quot;THROTTLE&amp;quot;&amp;lt;/tt&amp;gt; servo typically has the same value for the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;neutral&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; and &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;min&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The attribute &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;driver&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; for &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;servos&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; node tells which actuators' driver is associated the the listed servos. After the version '''v4.9_devel-164-gdb0d004''', multiple servos sections can be defined and used together, if the correct [[Subsystem/actuators| actuators subsystems]] are loaded. Some boards are automatically loading a default driver, the one used when no &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;driver&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; attribute is specified.&lt;br /&gt;
&lt;br /&gt;
Note the following important tips:&lt;br /&gt;
* Reverse the servo direction by exchanging min/max&lt;br /&gt;
* Trim should always be adjusted mechanically if possible to avoid asymmetrical travel&lt;br /&gt;
* Any reduction of the total travel range should be done mechanically to maintain precision&lt;br /&gt;
* Many servos will respond well to values slightly outside the normal 1000-2000ms range but experiment carefully as the servo may not operate reliably outside this range and may even suffer permanent damage.&lt;br /&gt;
* Board connector numbering starts with &amp;lt;b&amp;gt;zero (0)&amp;lt;/b&amp;gt; not with one&lt;br /&gt;
* Servos are also known under the synonym &amp;lt;b&amp;gt;actuators&amp;lt;/b&amp;gt;&lt;br /&gt;
* (after version '''v4.9_devel-164-gdb0d004''') For I2C based motor speed control using the [[Rotorcraft_Configuration#Motor_Mixing|motor mixing]]:&lt;br /&gt;
** min: command to stop the motor&lt;br /&gt;
** neutral: motor idle command&lt;br /&gt;
** max: max thrust command&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;servos&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; are then linked to the commands in the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;command_laws&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; section:&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;command_laws&amp;gt;&lt;br /&gt;
  &amp;lt;let var=&amp;quot;aileron&amp;quot;            value=&amp;quot;@ROLL  * 0.3&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;let var=&amp;quot;elevator&amp;quot;           value=&amp;quot;@PITCH * 0.7&amp;quot;/&amp;gt;  &lt;br /&gt;
  &amp;lt;set servo=&amp;quot;THROTTLE&amp;quot;         value=&amp;quot;@THROTTLE&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;set servo=&amp;quot;ELEVON_LEFTSIDE&amp;quot;  value=&amp;quot;$elevator + $aileron&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;set servo=&amp;quot;ELEVON_RIGHTSIDE&amp;quot; value=&amp;quot;$elevator - $aileron&amp;quot;/&amp;gt;&lt;br /&gt;
 &amp;lt;/command_laws&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Image:airframe_sign_conventions.jpg|thumb|Sign conventions for flight dynamics]]&lt;br /&gt;
where the third line is the simplest: the throttle servo value equals throttle command value. The other lines define and control the pitch/roll mixing.  Elevon values are computed with a combination of two commands, '''ROLL''' and '''PITCH'''. This ''mixer'' is defined with two intermediate variables '''aileron''' and '''elevator''' introduced with the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;let&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; element.  The '''@''' symbol is used to reference a command value in the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;value&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; attribute of the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;set&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; and &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;let&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; elements.  In the above example, the servos are limited to +/- 70% of their full travel for pitch and 30% for roll, only in combination can the servos reach 100% deflection.  Note that these numbers ''should add up 100% or more, never less''.  For example, you may want 100% travel available for pitch - this means if a roll is commanded along with maximum pitch only one servo will respond to the roll command as the other has already reached its mechanical limit.  If you find after tuning that these numbers add to less than 100% consider reducing the surface travel mechanically.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Note that the signs used in the description follow the standard convention.&lt;br /&gt;
&lt;br /&gt;
After '''v4.9_devel-164-gdb0d004''', the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;command_laws&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; section is mandatory for both fixedwing and rotorcraft firmwares, only for fixedwing otherwise.&lt;br /&gt;
&lt;br /&gt;
=== Battery === &lt;br /&gt;
This section gives characteristics for monitoring the main power battery.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;MILLIAMP_AT_FULL_THROTTLE&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; represents the actual current (in mA) when full THROTTLE is applied. Note that when flying the current typically is significantly lower than in static tests at home on your workbench. &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;MILLIAMP_AT_FULL_THROTTLE&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; is used to compute the &amp;lt;tt&amp;gt;energy&amp;lt;/tt&amp;gt; value of the &amp;lt;tt&amp;gt;BAT&amp;lt;/tt&amp;gt; message when no [[Current_sensor|Current sensor]] is mounted in the airframe. This value can also be used in flight plans. For example, if at full throttle your motor consumes 10 Amps, use a value of 10000. You can &amp;quot;tweak&amp;quot; this number after a few flights to match the capacity of your battery. If upon landing your bat.energy messages says that you used 2500 mAh while the energy recharged into the battery is only 2000 mAh, you could reduce the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;MILLIAMP_AT_FULL_THROTTLE&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; value by 20% to match your in-flight current consumption. This tweaking is most precise if you fly full throttle only (respectively no throttle to glide down again).&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;CURRENT_ESTIMATION_NONLINEARITY&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; can be added to tweak the energy estimation for non full throttle cruise. As the current consumption is nonlinear, at 50% throttle it is likely to be substantially less than 50%. A superellipse is used to approximate this nonlinearity. The default setting is 1.2 and is used if the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;CURRENT_ESTIMATION_NONLINEARITY&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; is not defined in your airframe file. A value 1 corresponds to linear behaviour, 1.5 corresponds to strong nonlinearity. The tweaking is done same as decribed above for &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;MILLIAMP_AT_FULL_THROTTLE&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt;, but only partial throttle (cruise throttle) should be applied in flight.&lt;br /&gt;
&lt;br /&gt;
If both &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;MILLIAMP_AT_FULL_THROTTLE&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; and &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;CURRENT_ESTIMATION_NONLINEARITY&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; are tweaked well, you get precise energy estimations with less than 5% error independant of your flight pattern without even requiring a [[Current_sensor|current sensor]].&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;CATASTROPHIC_BAT_LEVEL&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; (was previously &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;LOW_BATTERY&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt;) value defines the voltage at which the autopilot will lock the throttle at 0% in autonomous mode (kill_throttle mode). This value is also used by the ground server to issue a '''CATASTROPHIC''' alarm message on the bus (this message will be displayed in the console of the GCS).  &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;CRITIC&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; and &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;LOW&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; values will also used as threshold for '''CRITIC''' and '''WARNING''' alarms. They are optional and the respective defaults are 10.0 and 10.5V.&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;MAX_BAT_LEVEL&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; may be specified to improve the display of the battery gauge in the strip or in &amp;quot;papgets&amp;quot;. Note that this definition is optional, with a default value of 12.5V.&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;section name=&amp;quot;BAT&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;MILLIAMP_AT_FULL_THROTTLE&amp;quot; value=&amp;quot;12000&amp;quot; unit=&amp;quot;mA&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;CATASTROPHIC_BAT_LEVEL&amp;quot; value=&amp;quot;6.0&amp;quot; unit=&amp;quot;V&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;CRITIC_BAT_LEVEL&amp;quot; value=&amp;quot;6.5&amp;quot; unit=&amp;quot;V&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;LOW_BAT_LEVEL&amp;quot; value=&amp;quot;7.0&amp;quot; unit=&amp;quot;V&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;MAX_BAT_LEVEL&amp;quot; value=&amp;quot;8.4&amp;quot; unit=&amp;quot;V&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;/section&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
The conversion of ADC measurements to Voltage is already defined for the different autopilot boards, if you need to override these defaults you can use the &amp;lt;b&amp;gt;&amp;lt;tt&amp;gt;VoltageOfAdc(adc)&amp;lt;/tt&amp;gt;&amp;lt;/b&amp;gt; define and also specify offsets or anything else you might need, e.g.:&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;section name=&amp;quot;BAT&amp;quot;&amp;gt;&lt;br /&gt;
    ...&lt;br /&gt;
    &amp;lt;define name=&amp;quot;VOLTAGE_ADC_SCALE&amp;quot; value=&amp;quot;0.0177531&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;VOLTAGE_OFFSET&amp;quot; value=&amp;quot;0.5&amp;quot; unit=&amp;quot;V&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;VoltageOfAdc(adc)&amp;quot; value =&amp;quot;(VOLTAGE_ADC_SCALE * adc + VOLTAGE_OFFSET)&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;/section&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Modules ===&lt;br /&gt;
The [[Modules|modules]] allow to add new code in a flexible way with initialisation, periodic and event functions without modifying the main AP loop.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;modules main_freq=&amp;quot;60&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;load name=&amp;quot;demo_module.xml&amp;quot;/&amp;gt;&lt;br /&gt;
 &amp;lt;/modules&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* The main_freq parameter (in Hz) allows to specify the frequency of the main loop. Default is 60 Hz&lt;br /&gt;
&lt;br /&gt;
=== GCS ===&lt;br /&gt;
Use this &amp;lt;b&amp;gt;optional&amp;lt;/b&amp;gt; section to help customize parts of the GCS for a specific airframe:&lt;br /&gt;
{{Box Code|conf/airframes/myplane.xml|&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;section name=&amp;quot;GCS&amp;quot;&amp;gt;&lt;br /&gt;
    ...&lt;br /&gt;
    &amp;lt;define name=&amp;quot;ALT_SHIFT_PLUS_PLUS&amp;quot; value=&amp;quot;30&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;ALT_SHIFT_PLUS&amp;quot; value=&amp;quot;5&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;ALT_SHIFT_MINUS&amp;quot; value=&amp;quot;-5&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;SPEECH_NAME&amp;quot; value=&amp;quot;Quad&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;define name=&amp;quot;AC_ICON&amp;quot; value=&amp;quot;flyingwing&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;/section&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
[[Image:ac_icon_multi_uav.png|thumb|Various A/C icons demonstrated on a multi UAV simulation session]]&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;tt&amp;gt;ALT_SHIFT_PLUS_PLUS&amp;lt;/tt&amp;gt; sets the number of metres the target altitude will change when the double up arrow button is pressed on the [[GCS#Strips|strip]]&lt;br /&gt;
* &amp;lt;tt&amp;gt;ALT_SHIFT_PLUS&amp;lt;/tt&amp;gt; sets the number of metres the target altitude will change when the up arrow button is pressed on the [[GCS#Strips|strip]]&lt;br /&gt;
* &amp;lt;tt&amp;gt;ALT_SHIFT_MINUS&amp;lt;/tt&amp;gt; sets the number of metres the target altitude will change when the down arrow button is pressed on the [[GCS#Strips|strip]]&lt;br /&gt;
* &amp;lt;tt&amp;gt;SPEECH_NAME&amp;lt;/tt&amp;gt; a string ([a-zA-Z0-9_]) that will be used in place of the aircraft name specified in &amp;lt;tt&amp;gt;conf.xml&amp;lt;/tt&amp;gt; for the [[Speech|speech]] and [[GCS#Alarms|alarms]] functionality. Set this to &amp;quot;_&amp;quot; to prevent the speech function from saying the aircraft name. Useful if your aircraft name takes a long time to say (i.e. &amp;quot;UAV1-A_with_spektrum&amp;quot; can be shortened to &amp;quot;Plane&amp;quot;).&lt;br /&gt;
* &amp;lt;tt&amp;gt;AC_ICON&amp;lt;/tt&amp;gt; can be used to define the vehicle icon (or overwrite the default icon) that shows up on the 2D-map of the GCS. Available values are: &amp;lt;tt&amp;gt;flyingwing&amp;lt;/tt&amp;gt; , &amp;lt;tt&amp;gt;fixedwing&amp;lt;/tt&amp;gt; , &amp;lt;tt&amp;gt;rotorcraft&amp;lt;/tt&amp;gt; , &amp;lt;tt&amp;gt;home&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:User_Documentation]] [[Category:Airframe_Configuration]]&lt;/div&gt;</summary>
		<author><name>Garrosh</name></author>
	</entry>
	<entry>
		<id>http://wiki.paparazziuav.org/w/index.php?title=Talk:Airframe_Configuration&amp;diff=18243</id>
		<title>Talk:Airframe Configuration</title>
		<link rel="alternate" type="text/html" href="http://wiki.paparazziuav.org/w/index.php?title=Talk:Airframe_Configuration&amp;diff=18243"/>
		<updated>2014-02-13T17:21:18Z</updated>

		<summary type="html">&lt;p&gt;Garrosh: Mistake about servo duty cycle&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;13 feb 2014 - According to wikipedia, [http://en.wikipedia.org/wiki/Servo_control] the duty cycle for most servos is in fact 2000 &amp;lt;math&amp;gt;\mu \text{s}&amp;lt;/math&amp;gt;, and not 2000 ms&lt;/div&gt;</summary>
		<author><name>Garrosh</name></author>
	</entry>
</feed>