<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.flightgear.org/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Onox</id>
	<title>FlightGear wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.flightgear.org/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Onox"/>
	<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/Special:Contributions/Onox"/>
	<updated>2026-04-10T21:49:35Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.39.6</generator>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=107567</id>
		<title>Multiplayer aerial refueling</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=107567"/>
		<updated>2017-04-03T02:24:36Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[File:F-14 aerial refueling.jpg|thumb|An F-14 has connected its probe with the left drogue of a 707-TT tanker.]]&lt;br /&gt;
[[File:EC-137D aerial refueling.jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D.]]&lt;br /&gt;
[[File:EC-137D aerial refueling (seen from boomer).jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D. The aircraft is seen from the boomer's view.]]&lt;br /&gt;
[[File:F-15C aerial refueling.jpg|thumb|An F-15C is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the F-15C.]]&lt;br /&gt;
[[File:SR-71 aerial refueling.jpg|thumb|An SR-71 is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the SR-71.]]&lt;br /&gt;
&lt;br /&gt;
User onox has created a modified [[Boeing 707-420|707-TT]] that can perform air-to-air refueling with a moving boom and drogues. When the receiving aircraft's receptacle or probe gets within a small distance of the boom or drogue, the boom or drogue will start 'tracking' that aircraft and move when the receiving aircraft moves. When the receiver disconnects, the tanker will publish in a text message the duration (in minutes and seconds) of contact.&lt;br /&gt;
&lt;br /&gt;
Part of this work can be found in the [https://github.com/JMaverick16/KC-137R/ KC-137R] advanced tanker project.&lt;br /&gt;
&lt;br /&gt;
== Compatible aircraft ==&lt;br /&gt;
&lt;br /&gt;
AAR can be performed with the 707-TT or the MV-22. The 707-TT provides a single flying boom at the end of the fuselage and two hose drum units that contain a hose and a drogue. The MV-22 can provide a single hose and drogue attached to its cargo door (Enable the drogue in the &amp;quot;Aircraft Options&amp;quot; dialog). Both aircraft require the ExpansionPack to allow the flying boom and drogues to move and follow aircraft. It is also needed to see the drogue and the hose. Download and install it in the usual $FG_AIRCRAFT folder (the folder where you normally install an aircraft).&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Tanker&lt;br /&gt;
|-&lt;br /&gt;
| 707&lt;br /&gt;
|-&lt;br /&gt;
| MV-22&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Aircraft&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/NikolaiVChr/fg-aircraft.git F-14] (Use the &amp;quot;ORF&amp;quot; branch)&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/NikolaiVChr/fg-aircraft.git F-15] (Use the &amp;quot;ORF&amp;quot; branch)&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/l0k1/A-10.git A-10]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/l0k1/B-1B B-1B]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/l0k1/SR71-BlackBird SR-71]&lt;br /&gt;
|-&lt;br /&gt;
| MV-22 / CV-22&lt;br /&gt;
|-&lt;br /&gt;
| EC-137D&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Both the tanker and the receiver need the ExpansionPack to see the drogues. The user flying the tanker needs to install the receiver aircraft as well in order to read the position of the receptacle/probe.&lt;br /&gt;
&lt;br /&gt;
== Lag settings ==&lt;br /&gt;
&lt;br /&gt;
It is very important to adjust the lag settings in Multiplayer &amp;gt; Lag Settings. Make sure you have FlightGear 2016.1 or higher. To determine the lag, you should ping one of the multiplayer server that both the tanker and the receiving aircraft are going to use. For example, to ping mpserver01, open a terminal and type &amp;quot;ping mpserver01.flightgear.org&amp;quot;. Determine the average ping in milliseconds and convert it to seconds. For example, a ping of 123 milliseconds becomes 0.123. Open Multiplayer &amp;gt; Lag Settings, enable &amp;quot;Master switch&amp;quot; and &amp;quot;Apply to close mp&amp;quot;. Then adjust the slider of &amp;quot;Lag adjustment&amp;quot; to the measured ping time to the server; in our example, 0.123. Alternatively, you can open the &amp;quot;Internal properties&amp;quot; window (ignore this if you don't know what it is) and set /sim/multiplay/lag/offset directly.&lt;br /&gt;
&lt;br /&gt;
Use an ethernet cable instead of wifi. Wifi may give you a very fluctuating ping time to the server.&lt;br /&gt;
&lt;br /&gt;
If you try to approach the tanker, the tanker will display the distance between your receptacle/drogue and the boom/drogue. If the tanker appears closer to you than the text suggests, then you might need to add a few milliseconds (5, 10, or 20) to the &amp;quot;Lag adjument&amp;quot;. Give FlightGear several seconds to adapt after moving the slider.&lt;br /&gt;
&lt;br /&gt;
With correct lag settings, the receiver aircraft should be able to stay connected for several minutes. In fact, one user, flying an EC-137D, managed to stay connected for 18 minutes and 23 seconds (with position guidance from the boomer).&lt;br /&gt;
&lt;br /&gt;
== Using the drogues ==&lt;br /&gt;
&lt;br /&gt;
Simply click on the Hose Drum Unit (HDU) to extend the hose and the drogue. The receiving aircraft needs to be within 3 meters of the drogue (this value might be lowered in the future) in order to connect with the drogue. The drogue will 'snap' to the probe and follow it, at least on the tanker's computer. On the receiving aircraft's computer it could look (visually) like it is not connected.&lt;br /&gt;
&lt;br /&gt;
== Using the flying boom ==&lt;br /&gt;
&lt;br /&gt;
Press the {{Key press|r}} key to move the flying boom to the ready position. Press {{Key press|d}} to disconnect. Press {{Key press|Shift}} + {{Key press|d}} to move to the off position or to perform an emergency disconnect. While the boom is ready and able to track a nearby aircraft, the &amp;quot;READY&amp;quot; light should be lit on the boomer's panel.&lt;br /&gt;
&lt;br /&gt;
To move the boom manually, hold {{Key press|Ctrl}} and then move the mouse. To extend/retract the telescope of the boom, release {{Key press|Ctrl}} and use the mouse scroll wheel.&lt;br /&gt;
&lt;br /&gt;
The receiving aircraft needs to be within 1 meter of the nozzle of the boom. Once connected, you have a few extra meters of margin. With correct lag settings several people have demonstrated to stay connected for several minutes, even while in different continents.&lt;br /&gt;
&lt;br /&gt;
== Pilot Director Lights ==&lt;br /&gt;
&lt;br /&gt;
[[File:Pilot Director Lights during aerial refueling.png|thumb|Pilot Directory Lights showing the fwd/aft and up/down status of the boom.]]&lt;br /&gt;
&lt;br /&gt;
The pilot director lights are visible in ALS and show to the receiving aircraft how close it is to the desired position. The left row with lights show the elevation of the boom (closest light means pilot has to go down (too close to tanker), farthest light means pilot must go up (get closer)). The right row shows how much the telescope has extended or retracted (closest light means pilot needs to get closer, farthest light means pilot is too close.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Left row !! Right row&lt;br /&gt;
|-&lt;br /&gt;
| Down and Up || Forward and Aft&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Modifying aircraft to be compatible with the flying boom or drogue ==&lt;br /&gt;
&lt;br /&gt;
In order for the tanker to be able to detect compatible aircraft, the multiplayer model XML file of the aircraft that wants to have fuel needs to be modified. This needs to happen on the computer on which the tanker is running. For example, the F-14B's Models/f-14b.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-7.1969&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;1.0409&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.0387&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;probe&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Aircraft that contain a receptacle, for connecting with the flying boom, should use the value &amp;quot;boom&amp;quot; instead of &amp;quot;probe&amp;quot;. For example, the F-15C's Models/f15c.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-0.3457&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;-1.6912&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.7946&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;boom&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Negotiating fuel flow ==&lt;br /&gt;
&lt;br /&gt;
Once it has been implemented, this section will contain instructions how to make the receiving aircraft only add fuel when connected to the boom or a drogue.&lt;br /&gt;
&lt;br /&gt;
== Missing features ==&lt;br /&gt;
&lt;br /&gt;
Aircraft are not able to negotiate a fuel flow with the tanker yet. Currently many aircraft use the generic aar.nas code which just adds fuel if the aircraft is within range of any tanker, even when the aircraft is not connected to the tanker. The maximum fuel flow depends on the type (boom, drogue, or drogue connected to boom), the specific maximum that the receiving aircraft can handle, and the state of the tanks of the tanker and receiving aircraft. Both the tanker and the receiving aircraft should publish this number (which might change continuously) in a property. Both aircraft then need to take the minimum and consider this to be the fuel flow that they can add/subtract from their tanks.&lt;br /&gt;
&lt;br /&gt;
The flying boom simply moves to a position indicated by the mouse. In reality (in the KC-135) the mouse should control the two flight control surfaces on the boom. It would be appreciated if someone creates a JSBSim system that computes the lift/drag depending on state of the flight control surfaces and the current position. &lt;br /&gt;
&lt;br /&gt;
{{air-to-air refueling}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Aircraft enhancement|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Howto|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Multiplayer]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=File:Pilot_Director_Lights_during_aerial_refueling.png&amp;diff=107566</id>
		<title>File:Pilot Director Lights during aerial refueling.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=File:Pilot_Director_Lights_during_aerial_refueling.png&amp;diff=107566"/>
		<updated>2017-04-03T02:10:28Z</updated>

		<summary type="html">&lt;p&gt;Onox: User created page with UploadWizard&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=={{int:filedesc}}==&lt;br /&gt;
{{Information&lt;br /&gt;
|description={{en|1=Pilot Directory Lights showing the fwd/aft and up/down status of the boom.}}&lt;br /&gt;
|date=2017-04-03&lt;br /&gt;
|source={{own}}&lt;br /&gt;
|author=[[User:Onox|Onox]]&lt;br /&gt;
|permission=&lt;br /&gt;
|other versions=&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=={{int:license-header}}==&lt;br /&gt;
{{self|cc-by-sa-4.0}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Multiplayer]]&lt;br /&gt;
[[Category:AAR]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=105674</id>
		<title>Multiplayer aerial refueling</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=105674"/>
		<updated>2016-11-06T19:35:14Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[File:F-14 aerial refueling.jpg|thumb|An F-14 has connected its probe with the left drogue of a 707-TT tanker.]]&lt;br /&gt;
[[File:EC-137D aerial refueling.jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D.]]&lt;br /&gt;
[[File:EC-137D aerial refueling (seen from boomer).jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D. The aircraft is seen from the boomer's view.]]&lt;br /&gt;
[[File:F-15C aerial refueling.jpg|thumb|An F-15C is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the F-15C.]]&lt;br /&gt;
[[File:SR-71 aerial refueling.jpg|thumb|An SR-71 is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the SR-71.]]&lt;br /&gt;
&lt;br /&gt;
User onox has created a modified 707-TT that can perform air-to-air refueling with a moving boom and drogues. When the receiving aircraft's receptacle or probe gets within a small distance of the boom or drogue, the boom or drogue will start 'tracking' that aircraft and move when the receiving aircraft moves. When the receiver disconnects, the tanker will publish in a text message the duration (in minutes and seconds) of contact.&lt;br /&gt;
&lt;br /&gt;
== Compatible aircraft ==&lt;br /&gt;
&lt;br /&gt;
AAR can be performed with the 707-TT or the MV-22. The 707-TT provides a single flying boom at the end of the fuselage and two hose drum units that contain a hose and a drogue. The MV-22 can provide a single hose and drogue attached to its cargo door (Enable the drogue in the &amp;quot;Aircraft Options&amp;quot; dialog). Both aircraft require the ExpansionPack to allow the flying boom and drogues to move and follow aircraft. It is also needed to see the drogue and the hose. Download and install it in the usual $FG_AIRCRAFT folder (the folder where you normally install an aircraft).&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Tanker&lt;br /&gt;
|-&lt;br /&gt;
| 707&lt;br /&gt;
|-&lt;br /&gt;
| MV-22&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Aircraft&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/NikolaiVChr/fg-aircraft.git F-14] (Use the &amp;quot;ORF&amp;quot; branch)&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/NikolaiVChr/fg-aircraft.git F-15] (Use the &amp;quot;ORF&amp;quot; branch)&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/l0k1/A-10.git A-10]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/l0k1/B-1B B-1B]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/l0k1/SR71-BlackBird SR-71]&lt;br /&gt;
|-&lt;br /&gt;
| MV-22 / CV-22&lt;br /&gt;
|-&lt;br /&gt;
| EC-137D&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Both the tanker and the receiver need the ExpansionPack to see the drogues. The user flying the tanker needs to install the receiver aircraft as well in order to read the position of the receptacle/probe.&lt;br /&gt;
&lt;br /&gt;
== Lag settings ==&lt;br /&gt;
&lt;br /&gt;
It is very important to adjust the lag settings in Multiplayer &amp;gt; Lag Settings. Make sure you have FlightGear 2016.1 or higher. To determine the lag, you should ping one of the multiplayer server that both the tanker and the receiving aircraft are going to use. For example, to ping mpserver01, open a terminal and type &amp;quot;ping mpserver01.flightgear.org&amp;quot;. Determine the average ping in milliseconds and convert it to seconds. For example, a ping of 123 milliseconds becomes 0.123. Open Multiplayer &amp;gt; Lag Settings, enable &amp;quot;Master switch&amp;quot; and &amp;quot;Apply to close mp&amp;quot;. Then adjust the slider of &amp;quot;Lag adjustment&amp;quot; to the measured ping time to the server; in our example, 0.123. Alternatively, you can open the &amp;quot;Internal properties&amp;quot; window (ignore this if you don't know what it is) and set /sim/multiplay/lag/offset directly.&lt;br /&gt;
&lt;br /&gt;
Use an ethernet cable instead of wifi. Wifi may give you a very fluctuating ping time to the server.&lt;br /&gt;
&lt;br /&gt;
If you try to approach the tanker, the tanker will display the distance between your receptacle/drogue and the boom/drogue. If the tanker appears closer to you than the text suggests, then you might need to add a few milliseconds (5, 10, or 20) to the &amp;quot;Lag adjument&amp;quot;. Give FlightGear several seconds to adapt after moving the slider.&lt;br /&gt;
&lt;br /&gt;
With correct lag settings, the receiver aircraft should be able to stay connected for several minutes. In fact, one user, flying an EC-137D, managed to stay connected for 18 minutes and 23 seconds (with position guidance from the boomer).&lt;br /&gt;
&lt;br /&gt;
== Using the drogues ==&lt;br /&gt;
&lt;br /&gt;
Simply click on the Hose Drum Unit (HDU) to extend the hose and the drogue. The receiving aircraft needs to be within 3 meters of the drogue (this value might be lowered in the future) in order to connect with the drogue. The drogue will 'snap' to the probe and follow it, at least on the tanker's computer. On the receiving aircraft's computer it could look (visually) like it is not connected.&lt;br /&gt;
&lt;br /&gt;
== Using the flying boom ==&lt;br /&gt;
&lt;br /&gt;
Press the {{Key press|r}} key to move the flying boom to the ready position. Press {{Key press|d}} to disconnect. Press {{Key press|Shift}} + {{Key press|d}} to move to the off position or to perform an emergency disconnect. While the boom is ready and able to track a nearby aircraft, the &amp;quot;READY&amp;quot; light should be lit on the boomer's panel.&lt;br /&gt;
&lt;br /&gt;
To move the boom manually, hold {{Key press|Ctrl}} and then move the mouse. To extend/retract the telescope of the boom, release {{Key press|Ctrl}} and use the mouse scroll wheel.&lt;br /&gt;
&lt;br /&gt;
The receiving aircraft needs to be within 1 meter of the nozzle of the boom. Once connected, you have a few extra meters of margin. With correct lag settings several people have demonstrated to stay connected for several minutes, even while in different continents.&lt;br /&gt;
&lt;br /&gt;
== Modifying aircraft to be compatible with the flying boom or drogue ==&lt;br /&gt;
&lt;br /&gt;
In order for the tanker to be able to detect compatible aircraft, the multiplayer model XML file of the aircraft that wants to have fuel needs to be modified. This needs to happen on the computer on which the tanker is running. For example, the F-14B's Models/f-14b.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-7.1969&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;1.0409&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.0387&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;probe&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Aircraft that contain a receptacle, for connecting with the flying boom, should use the value &amp;quot;boom&amp;quot; instead of &amp;quot;probe&amp;quot;. For example, the F-15C's Models/f15c.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-0.3457&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;-1.6912&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.7946&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;boom&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Negotiating fuel flow ==&lt;br /&gt;
&lt;br /&gt;
Once it has been implemented, this section will contain instructions how to make the receiving aircraft only add fuel when connected to the boom or a drogue.&lt;br /&gt;
&lt;br /&gt;
== Missing features ==&lt;br /&gt;
&lt;br /&gt;
Aircraft are not able to negotiate a fuel flow with the tanker yet. Currently many aircraft use the generic aar.nas code which just adds fuel if the aircraft is within range of any tanker, even when the aircraft is not connected to the tanker. The maximum fuel flow depends on the type (boom, drogue, or drogue connected to boom), the specific maximum that the receiving aircraft can handle, and the state of the tanks of the tanker and receiving aircraft. Both the tanker and the receiving aircraft should publish this number (which might change continuously) in a property. Both aircraft then need to take the minimum and consider this to be the fuel flow that they can add/subtract from their tanks.&lt;br /&gt;
&lt;br /&gt;
The flying boom simply moves to a position indicated by the mouse. In reality (in the KC-135) the mouse should control the two flight control surfaces on the boom. It would be appreciated if someone creates a JSBSim system that computes the lift/drag depending on state of the flight control surfaces and the current position. &lt;br /&gt;
&lt;br /&gt;
{{air-to-air refueling}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Aircraft enhancement|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Howto|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Multiplayer]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=101853</id>
		<title>Multiplayer aerial refueling</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=101853"/>
		<updated>2016-07-21T22:51:31Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[File:F-14 aerial refueling.jpg|thumb|An F-14 has connected its probe with the left drogue of a 707-TT tanker.]]&lt;br /&gt;
[[File:EC-137D aerial refueling.jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D.]]&lt;br /&gt;
[[File:EC-137D aerial refueling (seen from boomer).jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D. The aircraft is seen from the boomer's view.]]&lt;br /&gt;
[[File:F-15C aerial refueling.jpg|thumb|An F-15C is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the F-15C.]]&lt;br /&gt;
[[File:SR-71 aerial refueling.jpg|thumb|An SR-71 is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the SR-71.]]&lt;br /&gt;
&lt;br /&gt;
User onox has created a modified 707-TT that can perform air-to-air refueling with a moving boom and drogues. When the receiving aircraft's receptacle or probe gets within a small distance of the boom or drogue, the boom or drogue will start 'tracking' that aircraft and move when the receiving aircraft moves. When the receiver disconnects, the tanker will publish in a text message the duration (in minutes and seconds) of contact.&lt;br /&gt;
&lt;br /&gt;
== Compatible aircraft ==&lt;br /&gt;
&lt;br /&gt;
AAR can be performed with the 707-TT or the MV-22. The 707-TT provides a single flying boom at the end of the fuselage and two hose drum units that contain a hose and a drogue. The MV-22 can provide a single hose and drogue attached to its cargo door (Enable the drogue in the &amp;quot;Aircraft Options&amp;quot; dialog). Both aircraft require the [https://github.com/onox/ExpansionPack ExpansionPack] to allow the flying boom and drogues to move and follow aircraft. It is also needed to see the drogue and the hose. Download and install it in the usual $FG_AIRCRAFT folder (the folder where you normally install an aircraft).&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Tanker&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/onox/707 707]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/onox/V-22 MV-22]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Aircraft&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/NikolaiVChr/fg-aircraft.git F-14] (Use the &amp;quot;ORF&amp;quot; branch)&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/NikolaiVChr/fg-aircraft.git F-15] (Use the &amp;quot;ORF&amp;quot; branch)&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/l0k1/A-10.git A-10]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/l0k1/B-1B B-1B]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/l0k1/SR71-BlackBird SR-71]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/onox/V-22 MV-22 / CV-22]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/onox/707 EC-137D]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Both the tanker and the receiver need the ExpansionPack to see the drogues. The user flying the tanker needs to install the receiver aircraft as well in order to read the position of the receptacle/probe.&lt;br /&gt;
&lt;br /&gt;
== Lag settings ==&lt;br /&gt;
&lt;br /&gt;
It is very important to adjust the lag settings in Multiplayer &amp;gt; Lag Settings. Make sure you have FlightGear 2016.1 or higher. To determine the lag, you should ping one of the multiplayer server that both the tanker and the receiving aircraft are going to use. For example, to ping mpserver01, open a terminal and type &amp;quot;ping mpserver01.flightgear.org&amp;quot;. Determine the average ping in milliseconds and convert it to seconds. For example, a ping of 123 milliseconds becomes 0.123. Open Multiplayer &amp;gt; Lag Settings, enable &amp;quot;Master switch&amp;quot; and &amp;quot;Apply to close mp&amp;quot;. Then adjust the slider of &amp;quot;Lag adjustment&amp;quot; to the measured ping time to the server; in our example, 0.123. Alternatively, you can open the &amp;quot;Internal properties&amp;quot; window (ignore this if you don't know what it is) and set /sim/multiplay/lag/offset directly.&lt;br /&gt;
&lt;br /&gt;
Use an ethernet cable instead of wifi. Wifi may give you a very fluctuating ping time to the server.&lt;br /&gt;
&lt;br /&gt;
If you try to approach the tanker, the tanker will display the distance between your receptacle/drogue and the boom/drogue. If the tanker appears closer to you than the text suggests, then you might need to add a few milliseconds (5, 10, or 20) to the &amp;quot;Lag adjument&amp;quot;. Give FlightGear several seconds to adapt after moving the slider.&lt;br /&gt;
&lt;br /&gt;
With correct lag settings, the receiver aircraft should be able to stay connected for several minutes. In fact, one user, flying an EC-137D, managed to stay connected for 18 minutes and 23 seconds (with position guidance from the boomer).&lt;br /&gt;
&lt;br /&gt;
== Using the drogues ==&lt;br /&gt;
&lt;br /&gt;
Simply click on the Hose Drum Unit (HDU) to extend the hose and the drogue. The receiving aircraft needs to be within 3 meters of the drogue (this value might be lowered in the future) in order to connect with the drogue. The drogue will 'snap' to the probe and follow it, at least on the tanker's computer. On the receiving aircraft's computer it could look (visually) like it is not connected.&lt;br /&gt;
&lt;br /&gt;
== Using the flying boom ==&lt;br /&gt;
&lt;br /&gt;
Press the {{Key press|r}} key to move the flying boom to the ready position. Press {{Key press|d}} to disconnect. Press {{Key press|Shift}} + {{Key press|d}} to move to the off position or to perform an emergency disconnect. While the boom is ready and able to track a nearby aircraft, the &amp;quot;READY&amp;quot; light should be lit on the boomer's panel.&lt;br /&gt;
&lt;br /&gt;
To move the boom manually, hold {{Key press|Ctrl}} and then move the mouse. To extend/retract the telescope of the boom, release {{Key press|Ctrl}} and use the mouse scroll wheel.&lt;br /&gt;
&lt;br /&gt;
The receiving aircraft needs to be within 1 meter of the nozzle of the boom. Once connected, you have a few extra meters of margin. With correct lag settings several people have demonstrated to stay connected for several minutes, even while in different continents.&lt;br /&gt;
&lt;br /&gt;
== Modifying aircraft to be compatible with the flying boom or drogue ==&lt;br /&gt;
&lt;br /&gt;
In order for the tanker to be able to detect compatible aircraft, the multiplayer model XML file of the aircraft that wants to have fuel needs to be modified. This needs to happen on the computer on which the tanker is running. For example, the F-14B's Models/f-14b.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-7.1969&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;1.0409&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.0387&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;probe&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Aircraft that contain a receptacle, for connecting with the flying boom, should use the value &amp;quot;boom&amp;quot; instead of &amp;quot;probe&amp;quot;. For example, the F-15C's Models/f15c.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-0.3457&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;-1.6912&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.7946&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;boom&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Negotiating fuel flow ==&lt;br /&gt;
&lt;br /&gt;
Once it has been implemented, this section will contain instructions how to make the receiving aircraft only add fuel when connected to the boom or a drogue.&lt;br /&gt;
&lt;br /&gt;
== Missing features ==&lt;br /&gt;
&lt;br /&gt;
Aircraft are not able to negotiate a fuel flow with the tanker yet. Currently many aircraft use the generic aar.nas code which just adds fuel if the aircraft is within range of any tanker, even when the aircraft is not connected to the tanker. The maximum fuel flow depends on the type (boom, drogue, or drogue connected to boom), the specific maximum that the receiving aircraft can handle, and the state of the tanks of the tanker and receiving aircraft. Both the tanker and the receiving aircraft should publish this number (which might change continuously) in a property. Both aircraft then need to take the minimum and consider this to be the fuel flow that they can add/subtract from their tanks.&lt;br /&gt;
&lt;br /&gt;
There are no pilot director lights on the bottom of the tanker yet. See http://wiki.flightgear.org/Aerial_refueling_improvement_ideas_and_resources&lt;br /&gt;
&lt;br /&gt;
The flying boom simply moves to a position indicated by the mouse. In reality (in the KC-135) the mouse should control the two flight control surfaces on the boom. It would be appreciated if someone creates a JSBSim system that computes the lift/drag depending on state of the flight control surfaces and the current position. &lt;br /&gt;
&lt;br /&gt;
{{air-to-air refueling}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Aircraft enhancement|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Howto|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Multiplayer]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=File:SR-71_aerial_refueling.jpg&amp;diff=101852</id>
		<title>File:SR-71 aerial refueling.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=File:SR-71_aerial_refueling.jpg&amp;diff=101852"/>
		<updated>2016-07-21T22:50:58Z</updated>

		<summary type="html">&lt;p&gt;Onox: User created page with UploadWizard&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=={{int:filedesc}}==&lt;br /&gt;
{{Information&lt;br /&gt;
|description={{en|1=An SR-71 is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the SR-71.}}&lt;br /&gt;
|date=2016-07-22&lt;br /&gt;
|source={{own}}&lt;br /&gt;
|author=[[User:Onox|onox]]&lt;br /&gt;
|permission=&lt;br /&gt;
|other versions=&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=={{int:license-header}}==&lt;br /&gt;
{{self|cc-by-sa-4.0}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Multiplayer]]&lt;br /&gt;
[[Category:AAR]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=101851</id>
		<title>Multiplayer aerial refueling</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=101851"/>
		<updated>2016-07-21T22:48:36Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[File:F-14 aerial refueling.jpg|thumb|An F-14 has connected its probe with the left drogue of a 707-TT tanker.]]&lt;br /&gt;
[[File:EC-137D aerial refueling.jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D.]]&lt;br /&gt;
[[File:EC-137D aerial refueling (seen from boomer).jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D. The aircraft is seen from the boomer's view.]]&lt;br /&gt;
[[File:F-15C aerial refueling.jpg|thumb|An F-15C is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the F-15C.]]&lt;br /&gt;
&lt;br /&gt;
User onox has created a modified 707-TT that can perform air-to-air refueling with a moving boom and drogues. When the receiving aircraft's receptacle or probe gets within a small distance of the boom or drogue, the boom or drogue will start 'tracking' that aircraft and move when the receiving aircraft moves. When the receiver disconnects, the tanker will publish in a text message the duration (in minutes and seconds) of contact.&lt;br /&gt;
&lt;br /&gt;
== Compatible aircraft ==&lt;br /&gt;
&lt;br /&gt;
AAR can be performed with the 707-TT or the MV-22. The 707-TT provides a single flying boom at the end of the fuselage and two hose drum units that contain a hose and a drogue. The MV-22 can provide a single hose and drogue attached to its cargo door (Enable the drogue in the &amp;quot;Aircraft Options&amp;quot; dialog). Both aircraft require the [https://github.com/onox/ExpansionPack ExpansionPack] to allow the flying boom and drogues to move and follow aircraft. It is also needed to see the drogue and the hose. Download and install it in the usual $FG_AIRCRAFT folder (the folder where you normally install an aircraft).&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Tanker&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/onox/707 707]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/onox/V-22 MV-22]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Aircraft&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/NikolaiVChr/fg-aircraft.git F-14] (Use the &amp;quot;ORF&amp;quot; branch)&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/NikolaiVChr/fg-aircraft.git F-15] (Use the &amp;quot;ORF&amp;quot; branch)&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/l0k1/A-10.git A-10]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/l0k1/B-1B B-1B]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/l0k1/SR71-BlackBird SR-71]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/onox/V-22 MV-22 / CV-22]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/onox/707 EC-137D]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Both the tanker and the receiver need the ExpansionPack to see the drogues. The user flying the tanker needs to install the receiver aircraft as well in order to read the position of the receptacle/probe.&lt;br /&gt;
&lt;br /&gt;
== Lag settings ==&lt;br /&gt;
&lt;br /&gt;
It is very important to adjust the lag settings in Multiplayer &amp;gt; Lag Settings. Make sure you have FlightGear 2016.1 or higher. To determine the lag, you should ping one of the multiplayer server that both the tanker and the receiving aircraft are going to use. For example, to ping mpserver01, open a terminal and type &amp;quot;ping mpserver01.flightgear.org&amp;quot;. Determine the average ping in milliseconds and convert it to seconds. For example, a ping of 123 milliseconds becomes 0.123. Open Multiplayer &amp;gt; Lag Settings, enable &amp;quot;Master switch&amp;quot; and &amp;quot;Apply to close mp&amp;quot;. Then adjust the slider of &amp;quot;Lag adjustment&amp;quot; to the measured ping time to the server; in our example, 0.123. Alternatively, you can open the &amp;quot;Internal properties&amp;quot; window (ignore this if you don't know what it is) and set /sim/multiplay/lag/offset directly.&lt;br /&gt;
&lt;br /&gt;
Use an ethernet cable instead of wifi. Wifi may give you a very fluctuating ping time to the server.&lt;br /&gt;
&lt;br /&gt;
If you try to approach the tanker, the tanker will display the distance between your receptacle/drogue and the boom/drogue. If the tanker appears closer to you than the text suggests, then you might need to add a few milliseconds (5, 10, or 20) to the &amp;quot;Lag adjument&amp;quot;. Give FlightGear several seconds to adapt after moving the slider.&lt;br /&gt;
&lt;br /&gt;
With correct lag settings, the receiver aircraft should be able to stay connected for several minutes. In fact, one user, flying an EC-137D, managed to stay connected for 18 minutes and 23 seconds (with position guidance from the boomer).&lt;br /&gt;
&lt;br /&gt;
== Using the drogues ==&lt;br /&gt;
&lt;br /&gt;
Simply click on the Hose Drum Unit (HDU) to extend the hose and the drogue. The receiving aircraft needs to be within 3 meters of the drogue (this value might be lowered in the future) in order to connect with the drogue. The drogue will 'snap' to the probe and follow it, at least on the tanker's computer. On the receiving aircraft's computer it could look (visually) like it is not connected.&lt;br /&gt;
&lt;br /&gt;
== Using the flying boom ==&lt;br /&gt;
&lt;br /&gt;
Press the {{Key press|r}} key to move the flying boom to the ready position. Press {{Key press|d}} to disconnect. Press {{Key press|Shift}} + {{Key press|d}} to move to the off position or to perform an emergency disconnect. While the boom is ready and able to track a nearby aircraft, the &amp;quot;READY&amp;quot; light should be lit on the boomer's panel.&lt;br /&gt;
&lt;br /&gt;
To move the boom manually, hold {{Key press|Ctrl}} and then move the mouse. To extend/retract the telescope of the boom, release {{Key press|Ctrl}} and use the mouse scroll wheel.&lt;br /&gt;
&lt;br /&gt;
The receiving aircraft needs to be within 1 meter of the nozzle of the boom. Once connected, you have a few extra meters of margin. With correct lag settings several people have demonstrated to stay connected for several minutes, even while in different continents.&lt;br /&gt;
&lt;br /&gt;
== Modifying aircraft to be compatible with the flying boom or drogue ==&lt;br /&gt;
&lt;br /&gt;
In order for the tanker to be able to detect compatible aircraft, the multiplayer model XML file of the aircraft that wants to have fuel needs to be modified. This needs to happen on the computer on which the tanker is running. For example, the F-14B's Models/f-14b.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-7.1969&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;1.0409&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.0387&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;probe&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Aircraft that contain a receptacle, for connecting with the flying boom, should use the value &amp;quot;boom&amp;quot; instead of &amp;quot;probe&amp;quot;. For example, the F-15C's Models/f15c.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-0.3457&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;-1.6912&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.7946&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;boom&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Negotiating fuel flow ==&lt;br /&gt;
&lt;br /&gt;
Once it has been implemented, this section will contain instructions how to make the receiving aircraft only add fuel when connected to the boom or a drogue.&lt;br /&gt;
&lt;br /&gt;
== Missing features ==&lt;br /&gt;
&lt;br /&gt;
Aircraft are not able to negotiate a fuel flow with the tanker yet. Currently many aircraft use the generic aar.nas code which just adds fuel if the aircraft is within range of any tanker, even when the aircraft is not connected to the tanker. The maximum fuel flow depends on the type (boom, drogue, or drogue connected to boom), the specific maximum that the receiving aircraft can handle, and the state of the tanks of the tanker and receiving aircraft. Both the tanker and the receiving aircraft should publish this number (which might change continuously) in a property. Both aircraft then need to take the minimum and consider this to be the fuel flow that they can add/subtract from their tanks.&lt;br /&gt;
&lt;br /&gt;
There are no pilot director lights on the bottom of the tanker yet. See http://wiki.flightgear.org/Aerial_refueling_improvement_ideas_and_resources&lt;br /&gt;
&lt;br /&gt;
The flying boom simply moves to a position indicated by the mouse. In reality (in the KC-135) the mouse should control the two flight control surfaces on the boom. It would be appreciated if someone creates a JSBSim system that computes the lift/drag depending on state of the flight control surfaces and the current position. &lt;br /&gt;
&lt;br /&gt;
{{air-to-air refueling}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Aircraft enhancement|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Howto|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Multiplayer]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=101850</id>
		<title>Multiplayer aerial refueling</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=101850"/>
		<updated>2016-07-21T22:45:29Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[File:F-14 aerial refueling.jpg|thumb|An F-14 has connected its probe with the left drogue of a 707-TT tanker.]]&lt;br /&gt;
[[File:EC-137D aerial refueling.jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D.]]&lt;br /&gt;
[[File:EC-137D aerial refueling (seen from boomer).jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D. The aircraft is seen from the boomer's view.]]&lt;br /&gt;
[[File:F-15C aerial refueling.jpg|thumb|An F-15C is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the F-15C.]]&lt;br /&gt;
&lt;br /&gt;
User onox has created a modified 707-TT that can perform air-to-air refueling with a moving boom and drogues. When the receiving aircraft's receptacle or probe gets within a small distance of the boom or drogue, the boom or drogue will start 'tracking' that aircraft and move when the receiving aircraft moves. When the receiver disconnects, the tanker will publish in a text message the duration (in minutes and seconds) of contact.&lt;br /&gt;
&lt;br /&gt;
== Compatible aircraft ==&lt;br /&gt;
&lt;br /&gt;
AAR can be performed with the 707-TT or the MV-22. The 707-TT provides a single flying boom at the end of the fuselage and two hose drum units that contain a hose and a drogue. The MV-22 can provide a single hose and drogue attached to its cargo door (Enable the drogue in the &amp;quot;Aircraft Options&amp;quot; dialog). Both aircraft require the [https://github.com/onox/ExpansionPack ExpansionPack] to allow the flying boom and drogues to move and follow aircraft. It is also needed to see the drogue and the hose. Download and install it in the usual $FG_AIRCRAFT folder (the folder where you normally install an aircraft).&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Tanker&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/onox/707 707]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/onox/V-22 MV-22]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Aircraft&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/NikolaiVChr/fg-aircraft.git F-14] (Use the &amp;quot;ORF&amp;quot; branch)&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/NikolaiVChr/fg-aircraft.git F-15] (Use the &amp;quot;ORF&amp;quot; branch)&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/l0k1/A-10.git A-10]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/l0k1/B-1B B-1B]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/l0k1/SR71-BlackBird SR-71]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/onox/V-22 MV-22 / CV-22]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/onox/707 EC-137D]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Both the tanker and the receiver need the ExpansionPack to see the drogues. The user flying the tanker needs to install the receiver aircraft as well in order to read the position of the receptacle/probe.&lt;br /&gt;
&lt;br /&gt;
== Lag settings ==&lt;br /&gt;
&lt;br /&gt;
It is very important to adjust the lag settings in Multiplayer &amp;gt; Lag Settings. Make sure you have FlightGear 2016.1 or higher. To determine the lag, you should ping one of the multiplayer server that both the tanker and the receiving aircraft are going to use. For example, to ping mpserver01, open a terminal and type &amp;quot;ping mpserver01.flightgear.org&amp;quot;. Determine the average ping in milliseconds and convert it to seconds. For example, a ping of 123 milliseconds becomes 0.123. Open Multiplayer &amp;gt; Lag Settings, enable &amp;quot;Master switch&amp;quot; and &amp;quot;Apply to close mp&amp;quot;. Then adjust the slider of &amp;quot;Lag adjustment&amp;quot; to the measured ping time to the server; in our example, 0.123. Alternatively, you can open the &amp;quot;Internal properties&amp;quot; window (ignore this if you don't know what it is) and set /sim/multiplay/lag/offset directly.&lt;br /&gt;
&lt;br /&gt;
Use an ethernet cable instead of wifi. Wifi may give you a very fluctuating ping time to the server.&lt;br /&gt;
&lt;br /&gt;
If you try to approach the tanker, the tanker will display the distance between your receptacle/drogue and the boom/drogue. If the tanker appears closer to you than the text suggests, then you might need to add a few milliseconds (5, 10, or 20) to the &amp;quot;Lag adjument&amp;quot;. Give FlightGear several seconds to adapt after moving the slider.&lt;br /&gt;
&lt;br /&gt;
With correct lag settings, the receiver aircraft should be able to stay connected for several minutes. In fact, one user, flying an EC-137D, managed to stay connected for 18 minutes and 23 seconds.&lt;br /&gt;
&lt;br /&gt;
== Using the drogues ==&lt;br /&gt;
&lt;br /&gt;
Simply click on the Hose Drum Unit (HDU) to extend the hose and the drogue. The receiving aircraft needs to be within 3 meters of the drogue (this value might be lowered in the future) in order to connect with the drogue. The drogue will 'snap' to the probe and follow it, at least on the tanker's computer. On the receiving aircraft's computer it could look (visually) like it is not connected.&lt;br /&gt;
&lt;br /&gt;
== Using the flying boom ==&lt;br /&gt;
&lt;br /&gt;
Press the {{Key press|r}} key to move the flying boom to the ready position. Press {{Key press|d}} to disconnect. Press {{Key press|Shift}} + {{Key press|d}} to move to the off position or to perform an emergency disconnect. While the boom is ready and able to track a nearby aircraft, the &amp;quot;READY&amp;quot; light should be lit on the boomer's panel.&lt;br /&gt;
&lt;br /&gt;
To move the boom manually, hold {{Key press|Ctrl}} and then move the mouse. To extend/retract the telescope of the boom, release {{Key press|Ctrl}} and use the mouse scroll wheel.&lt;br /&gt;
&lt;br /&gt;
The receiving aircraft needs to be within 1 meter of the nozzle of the boom. Once connected, you have a few extra meters of margin. With correct lag settings several people have demonstrated to stay connected for several minutes, even while in different continents.&lt;br /&gt;
&lt;br /&gt;
== Modifying aircraft to be compatible with the flying boom or drogue ==&lt;br /&gt;
&lt;br /&gt;
In order for the tanker to be able to detect compatible aircraft, the multiplayer model XML file of the aircraft that wants to have fuel needs to be modified. This needs to happen on the computer on which the tanker is running. For example, the F-14B's Models/f-14b.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-7.1969&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;1.0409&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.0387&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;probe&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Aircraft that contain a receptacle, for connecting with the flying boom, should use the value &amp;quot;boom&amp;quot; instead of &amp;quot;probe&amp;quot;. For example, the F-15C's Models/f15c.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-0.3457&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;-1.6912&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.7946&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;boom&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Negotiating fuel flow ==&lt;br /&gt;
&lt;br /&gt;
Once it has been implemented, this section will contain instructions how to make the receiving aircraft only add fuel when connected to the boom or a drogue.&lt;br /&gt;
&lt;br /&gt;
== Missing features ==&lt;br /&gt;
&lt;br /&gt;
Aircraft are not able to negotiate a fuel flow with the tanker yet. Currently many aircraft use the generic aar.nas code which just adds fuel if the aircraft is within range of any tanker, even when the aircraft is not connected to the tanker. The maximum fuel flow depends on the type (boom, drogue, or drogue connected to boom), the specific maximum that the receiving aircraft can handle, and the state of the tanks of the tanker and receiving aircraft. Both the tanker and the receiving aircraft should publish this number (which might change continuously) in a property. Both aircraft then need to take the minimum and consider this to be the fuel flow that they can add/subtract from their tanks.&lt;br /&gt;
&lt;br /&gt;
There are no pilot director lights on the bottom of the tanker yet. See http://wiki.flightgear.org/Aerial_refueling_improvement_ideas_and_resources&lt;br /&gt;
&lt;br /&gt;
The flying boom simply moves to a position indicated by the mouse. In reality (in the KC-135) the mouse should control the two flight control surfaces on the boom. It would be appreciated if someone creates a JSBSim system that computes the lift/drag depending on state of the flight control surfaces and the current position. &lt;br /&gt;
&lt;br /&gt;
{{air-to-air refueling}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Aircraft enhancement|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Howto|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Multiplayer]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=101849</id>
		<title>Multiplayer aerial refueling</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=101849"/>
		<updated>2016-07-21T22:36:48Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[File:F-14 aerial refueling.jpg|thumb|An F-14 has connected its probe with the left drogue of a 707-TT tanker.]]&lt;br /&gt;
[[File:EC-137D aerial refueling.jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D.]]&lt;br /&gt;
[[File:EC-137D aerial refueling (seen from boomer).jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D. The aircraft is seen from the boomer's view.]]&lt;br /&gt;
[[File:F-15C aerial refueling.jpg|thumb|An F-15C is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the F-15C.]]&lt;br /&gt;
&lt;br /&gt;
User onox has created a modified 707-TT that can perform air-to-air refueling with a moving boom and drogues.&lt;br /&gt;
&lt;br /&gt;
== Compatible aircraft ==&lt;br /&gt;
&lt;br /&gt;
AAR can be performed with the 707-TT or the MV-22. The 707-TT provides a single flying boom at the end of the fuselage and two hose drum units that contain a hose and a drogue. The MV-22 can provide a single hose and drogue attached to its cargo door (Enable the drogue in the &amp;quot;Aircraft Options&amp;quot; dialog). Both aircraft require the [https://github.com/onox/ExpansionPack ExpansionPack] to allow the flying boom and drogues to move and follow aircraft. It is also needed to see the drogue and the hose. Download and install it in the usual $FG_AIRCRAFT folder (the folder where you normally install an aircraft).&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Tanker&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/onox/707 707]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/onox/V-22 MV-22]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Aircraft&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/NikolaiVChr/fg-aircraft.git F-14] (Use the &amp;quot;ORF&amp;quot; branch)&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/NikolaiVChr/fg-aircraft.git F-15] (Use the &amp;quot;ORF&amp;quot; branch)&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/l0k1/A-10.git A-10]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/l0k1/B-1B B-1B]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/l0k1/SR71-BlackBird SR-71]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/onox/V-22 MV-22 / CV-22]&lt;br /&gt;
|-&lt;br /&gt;
| [https://github.com/onox/707 EC-137D]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Both the tanker and the receiver need the ExpansionPack to see the drogues. The user flying the tanker needs to install the receiver aircraft as well in order to read the position of the receptacle/probe.&lt;br /&gt;
&lt;br /&gt;
== Lag settings ==&lt;br /&gt;
&lt;br /&gt;
It is very important to adjust the lag settings in Multiplayer &amp;gt; Lag Settings. Make sure you have FlightGear 2016.1 or higher. To determine the lag, you should ping one of the multiplayer server that both the tanker and the receiving aircraft are going to use. For example, to ping mpserver01, open a terminal and type &amp;quot;ping mpserver01.flightgear.org&amp;quot;. Determine the average ping in milliseconds and convert it to seconds. For example, a ping of 123 milliseconds becomes 0.123. Open Multiplayer &amp;gt; Lag Settings, enable &amp;quot;Master switch&amp;quot; and &amp;quot;Apply to close mp&amp;quot;. Then adjust the slider of &amp;quot;Lag adjustment&amp;quot; to the measured ping time to the server; in our example, 0.123. Alternatively, you can open the &amp;quot;Internal properties&amp;quot; window (ignore this if you don't know what it is) and set /sim/multiplay/lag/offset directly.&lt;br /&gt;
&lt;br /&gt;
Use an ethernet cable instead of wifi. Wifi may give you a very fluctuating ping time to the server.&lt;br /&gt;
&lt;br /&gt;
If you try to approach the tanker, the tanker will display the distance between your receptacle/drogue and the boom/drogue. If the tanker appears closer to you than the text suggests, then you might need to add a few milliseconds (5, 10, or 20) to the &amp;quot;Lag adjument&amp;quot;. Give FlightGear several seconds to adapt after moving the slider.&lt;br /&gt;
&lt;br /&gt;
== Using the drogues ==&lt;br /&gt;
&lt;br /&gt;
Simply click on the Hose Drum Unit (HDU) to extend the hose and the drogue. The receiving aircraft needs to be within 3 meters of the drogue (this value might be lowered in the future) in order to connect with the drogue. The drogue will 'snap' to the probe and follow it, at least on the tanker's computer. On the receiving aircraft's computer it could look (visually) like it is not connected.&lt;br /&gt;
&lt;br /&gt;
== Using the flying boom ==&lt;br /&gt;
&lt;br /&gt;
Press the {{Key press|r}} key to move the flying boom to the ready position. Press {{Key press|d}} to disconnect. Press {{Key press|Shift}} + {{Key press|d}} to move to the off position or to perform an emergency disconnect. While the boom is ready and able to track a nearby aircraft, the &amp;quot;READY&amp;quot; light should be lit on the boomer's panel.&lt;br /&gt;
&lt;br /&gt;
To move the boom manually, hold {{Key press|Ctrl}} and then move the mouse. To extend/retract the telescope of the boom, release {{Key press|Ctrl}} and use the mouse scroll wheel.&lt;br /&gt;
&lt;br /&gt;
The receiving aircraft needs to be within 1 meter of the nozzle of the boom. Once connected, you have a few extra meters of margin. With correct lag settings several people have demonstrated to stay connected for several minutes, even while in different continents.&lt;br /&gt;
&lt;br /&gt;
== Modifying aircraft to be compatible with the flying boom or drogue ==&lt;br /&gt;
&lt;br /&gt;
In order for the tanker to be able to detect compatible aircraft, the multiplayer model XML file of the aircraft that wants to have fuel needs to be modified. This needs to happen on the computer on which the tanker is running. For example, the F-14B's Models/f-14b.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-7.1969&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;1.0409&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.0387&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;probe&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Aircraft that contain a receptacle, for connecting with the flying boom, should use the value &amp;quot;boom&amp;quot; instead of &amp;quot;probe&amp;quot;. For example, the F-15C's Models/f15c.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-0.3457&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;-1.6912&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.7946&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;boom&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Negotiating fuel flow ==&lt;br /&gt;
&lt;br /&gt;
Once it has been implemented, this section will contain instructions how to make the receiving aircraft only add fuel when connected to the boom or a drogue.&lt;br /&gt;
&lt;br /&gt;
== Missing features ==&lt;br /&gt;
&lt;br /&gt;
Aircraft are not able to negotiate a fuel flow with the tanker yet. Currently many aircraft use the generic aar.nas code which just adds fuel if the aircraft is within range of any tanker, even when the aircraft is not connected to the tanker. The maximum fuel flow depends on the type (boom, drogue, or drogue connected to boom), the specific maximum that the receiving aircraft can handle, and the state of the tanks of the tanker and receiving aircraft. Both the tanker and the receiving aircraft should publish this number (which might change continuously) in a property. Both aircraft then need to take the minimum and consider this to be the fuel flow that they can add/subtract from their tanks.&lt;br /&gt;
&lt;br /&gt;
There are no pilot director lights on the bottom of the tanker yet. See http://wiki.flightgear.org/Aerial_refueling_improvement_ideas_and_resources&lt;br /&gt;
&lt;br /&gt;
The flying boom simply moves to a position indicated by the mouse. In reality (in the KC-135) the mouse should control the two flight control surfaces on the boom. It would be appreciated if someone creates a JSBSim system that computes the lift/drag depending on state of the flight control surfaces and the current position. &lt;br /&gt;
&lt;br /&gt;
{{air-to-air refueling}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Aircraft enhancement|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Howto|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Multiplayer]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Template:Air-to-air_refueling&amp;diff=101848</id>
		<title>Template:Air-to-air refueling</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Template:Air-to-air_refueling&amp;diff=101848"/>
		<updated>2016-07-21T22:13:59Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{navbox&lt;br /&gt;
|name      = Template:Air-to-air refueling&lt;br /&gt;
|title     = Air-to-air refueling&lt;br /&gt;
|image     = &lt;br /&gt;
|imageleft = &lt;br /&gt;
|state     = &lt;br /&gt;
|listclass = hlist&lt;br /&gt;
&lt;br /&gt;
|group1    = For pilots&lt;br /&gt;
|list1     = &lt;br /&gt;
* [[Howto:Aerial refueling]]&lt;br /&gt;
* [[Multiplayer_Aerial_refueling]]&lt;br /&gt;
&lt;br /&gt;
|group2    = For developers&lt;br /&gt;
|list2     = &lt;br /&gt;
* [[Howto:Implement aerial refueling capability]]&lt;br /&gt;
* [[Aerial refueling improvement ideas and resources]]&lt;br /&gt;
&lt;br /&gt;
|group3    = Tanker aircraft&lt;br /&gt;
|list3     = &lt;br /&gt;
* [[Boeing KC-135E]] (B)&lt;br /&gt;
* [[Boeing 707-420|Boeing 707/TT]] (B/P)&lt;br /&gt;
* [[Lockheed C-130 Hercules|Lockheed KC-130 Hercules]] (P)&lt;br /&gt;
* [[McDonnell Douglas DC-10-30|McDonnell Douglas KC-10A]] (B)&lt;br /&gt;
&lt;br /&gt;
|group4    = Receiver aircraft&lt;br /&gt;
|list4     =&lt;br /&gt;
* [[Boeing 707-420|Boeing EC-137D AWACS]] (B)&lt;br /&gt;
* [[British Aerospace Sea Harrier]] (P)&lt;br /&gt;
* [[Douglas A-4 Skyhawk]] (P)&lt;br /&gt;
* [[English Electric Lightning]] (P)&lt;br /&gt;
* [[Fairchild Republic A-10 Thunderbolt II]] (B)&lt;br /&gt;
* [[General Dynamics F-16]] (B)&lt;br /&gt;
* [[Grumman A-6E]] (P)&lt;br /&gt;
* [[Grumman F-14 Tomcat]] (P)&lt;br /&gt;
* [[Lockheed F-117 Nighthawk]] (B)&lt;br /&gt;
* [[Northrop T-38 Talon]] (?)&lt;br /&gt;
* [[Vought F-8 Crusader]] (P)&lt;br /&gt;
&lt;br /&gt;
|below     = B – Boom and receptacle refueling; P – Probe and drogue refueling&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- |below     = ''No One Kicks Ass Without Tanker Gas...Nobody'' --&amp;gt;&lt;br /&gt;
}}&amp;lt;noinclude&amp;gt;&lt;br /&gt;
{{Informative template|1=&lt;br /&gt;
__NOTOC__&lt;br /&gt;
== Goal ==&lt;br /&gt;
This template can be added to pages related to aerial refueling.&lt;br /&gt;
&lt;br /&gt;
Adding this template to a page will not automatically add a category to a page, as there several categories that would fit better, for example [[:Category:Military tanker aircraft]] and [[:Category:Air refueling ready]].&lt;br /&gt;
&lt;br /&gt;
== Usage ==&lt;br /&gt;
Add this to the bottom of the page, before the category links and language links.&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;{{&amp;lt;/nowiki&amp;gt;'''air-to-air refueling'''&amp;lt;nowiki&amp;gt;}}&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Navigation templates]]&lt;br /&gt;
[[Category:Air refueling ready| ]]&lt;br /&gt;
&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=101076</id>
		<title>Multiplayer aerial refueling</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=101076"/>
		<updated>2016-07-11T02:58:44Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[File:F-14 aerial refueling.jpg|thumb|An F-14 has connected its probe with the left drogue of a 707-TT tanker.]]&lt;br /&gt;
[[File:EC-137D aerial refueling.jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D.]]&lt;br /&gt;
[[File:EC-137D aerial refueling (seen from boomer).jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D. The aircraft is seen from the boomer's view.]]&lt;br /&gt;
[[File:F-15C aerial refueling.jpg|thumb|An F-15C is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the F-15C.]]&lt;br /&gt;
&lt;br /&gt;
User onox has created a modified 707-TT and EC-137D that allow air-to-air refueling with a moving boom and drogues.&lt;br /&gt;
&lt;br /&gt;
In order to perform AAR with this modified 707-TT you need to download the modified [https://github.com/onox/707 707] and the [https://github.com/onox/ExpansionPack ExpansionPack]. The ExpansionPack allows the flying boom and drogues to move and follow aircraft. It is also needed to see the drogue and the hose. People wishing to perform refueling with the F-15 or F-14 should use the &amp;quot;ORF&amp;quot; branch from [https://github.com/NikolaiVChr/fg-aircraft.git NikolaiVChr/fg-aircraft]. The [https://github.com/onox/V-22 MV-22] provides the ability to install one drogue on its cargo door.&lt;br /&gt;
&lt;br /&gt;
== Lag settings ==&lt;br /&gt;
&lt;br /&gt;
It is very important to adjust the lag settings in Multiplayer &amp;gt; Lag Settings. Make sure you have FlightGear 2016.1 or higher. To determine the lag, you should ping one of the multiplayer server that both the tanker and the receiving aircraft are going to use. For example, to ping mpserver01, open a terminal and type &amp;quot;ping mpserver01.flightgear.org&amp;quot;. Determine the average ping in milliseconds and convert it to seconds. For example, a ping of 123 milliseconds becomes 0.123. Open Multiplayer &amp;gt; Lag Settings, enable &amp;quot;Master switch&amp;quot; and &amp;quot;Apply to close mp&amp;quot;. Then adjust the slider of &amp;quot;Lag adjustment&amp;quot; to the measured ping time to the server; in our example, 0.123. Alternatively, you can open the &amp;quot;Internal properties&amp;quot; window (ignore this if you don't know what it is) and set /sim/multiplay/lag/offset directly.&lt;br /&gt;
&lt;br /&gt;
Use an ethernet cable instead of wifi. Wifi may give you a very fluctuating ping time to the server.&lt;br /&gt;
&lt;br /&gt;
If you try to approach the tanker, the tanker will display the distance between your receptacle/drogue and the boom/drogue. If the tanker appears closer to you than the text suggests, then you might need to add a few milliseconds (5, 10, or 20) to the &amp;quot;Lag adjument&amp;quot;. Give FlightGear several seconds to adapt after moving the slider.&lt;br /&gt;
&lt;br /&gt;
== Using the drogues ==&lt;br /&gt;
&lt;br /&gt;
Simply click on the Hose Drum Unit (HDU) to extend the hose and the drogue. The receiving aircraft needs to be within 3 meters of the drogue (this value might be lowered in the future) in order to connect with the drogue. The drogue will 'snap' to the probe and follow it, at least on the tanker's computer. On the receiving aircraft's computer it could look (visually) like it is not connected.&lt;br /&gt;
&lt;br /&gt;
== Using the flying boom ==&lt;br /&gt;
&lt;br /&gt;
Press the {{Key press|r}} key to move the flying boom to the ready position. Press {{Key press|d}} to disconnect. Press {{Key press|Shift}} + {{Key press|d}} to move to the off position or to perform an emergency disconnect. While the boom is ready and able to track a nearby aircraft, the &amp;quot;READY&amp;quot; light should be lit on the boomer's panel.&lt;br /&gt;
&lt;br /&gt;
To move the boom manually, hold {{Key press|Ctrl}} and then move the mouse. To extend/retract the telescope of the boom, release {{Key press|Ctrl}} and use the mouse scroll wheel.&lt;br /&gt;
&lt;br /&gt;
The receiving aircraft needs to be within 1 meter of the nozzle of the boom. Once connected, you have a few extra meters of margin. With correct lag settings several people have demonstrated to stay connected for several minutes, even while in different continents.&lt;br /&gt;
&lt;br /&gt;
== Modifying aircraft to be compatible with the flying boom or drogue ==&lt;br /&gt;
&lt;br /&gt;
In order for the tanker to be able to detect compatible aircraft, the multiplayer model XML file of the aircraft that wants to have fuel needs to be modified. This needs to happen on the computer on which the tanker is running. For example, the F-14B's Models/f-14b.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-7.1969&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;1.0409&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.0387&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;probe&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Aircraft that contain a receptacle, for connecting with the flying boom, should use the value &amp;quot;boom&amp;quot; instead of &amp;quot;probe&amp;quot;. For example, the F-15C's Models/f15c.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-0.3457&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;-1.6912&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.7946&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;boom&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Negotiating fuel flow ==&lt;br /&gt;
&lt;br /&gt;
Once it has been implemented, this section will contain instructions how to make the receiving aircraft only add fuel when connected to the boom or a drogue.&lt;br /&gt;
&lt;br /&gt;
== Missing features ==&lt;br /&gt;
&lt;br /&gt;
Aircraft are not able to negotiate a fuel flow with the tanker yet. Currently many aircraft use the generic aar.nas code which just adds fuel if the aircraft is within range of any tanker, even when the aircraft is not connected to the tanker. The maximum fuel flow depends on the type (boom, drogue, or drogue connected to boom), the specific maximum that the receiving aircraft can handle, and the state of the tanks of the tanker and receiving aircraft. Both the tanker and the receiving aircraft should publish this number (which might change continuously) in a property. Both aircraft then need to take the minimum and consider this to be the fuel flow that they can add/subtract from their tanks.&lt;br /&gt;
&lt;br /&gt;
There are no pilot director lights on the bottom of the tanker yet. See http://wiki.flightgear.org/Aerial_refueling_improvement_ideas_and_resources&lt;br /&gt;
&lt;br /&gt;
The flying boom simply moves to a position indicated by the mouse. In reality (in the KC-135) the mouse should control the two flight control surfaces on the boom. It would be appreciated if someone creates a JSBSim system that computes the lift/drag depending on state of the flight control surfaces and the current position. &lt;br /&gt;
&lt;br /&gt;
{{air-to-air refueling}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Aircraft enhancement|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Howto|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Multiplayer]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=101006</id>
		<title>Multiplayer aerial refueling</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=101006"/>
		<updated>2016-07-08T20:00:48Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[File:F-14 aerial refueling.jpg|thumb|An F-14 has connected its probe with the left drogue of a 707-TT tanker.]]&lt;br /&gt;
[[File:EC-137D aerial refueling.jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D.]]&lt;br /&gt;
[[File:EC-137D aerial refueling (seen from boomer).jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D. The aircraft is seen from the boomer's view.]]&lt;br /&gt;
[[File:F-15C aerial refueling.jpg|thumb|An F-15C is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the F-15C.]]&lt;br /&gt;
&lt;br /&gt;
User onox has created a modified 707-TT and EC-137D that allow air-to-air refueling with a moving boom and drogues.&lt;br /&gt;
&lt;br /&gt;
In order to perform AAR with this modified 707-TT you need to download the modified [https://github.com/onox/707 707] and the [https://github.com/onox/ExpansionPack ExpansionPack]. The ExpansionPack allows the flying boom and drogues to move and follow aircraft. It is also needed to see the drogue and the hose. People wishing to perform refueling with the F-15 or F-14 should use the &amp;quot;ORF&amp;quot; branch from [https://github.com/NikolaiVChr/fg-aircraft.git NikolaiVChr/fg-aircraft]. The [https://github.com/onox/V-22 MV-22] provides the ability to install one drogue on its cargo door.&lt;br /&gt;
&lt;br /&gt;
== Lag settings ==&lt;br /&gt;
&lt;br /&gt;
It is very important to adjust the lag settings in Multiplayer &amp;gt; Lag Settings. Make sure you have FlightGear 2016.1 or higher. To determine the lag, you should ping one of the multiplayer server that both the tanker and the receiving aircraft are going to use. For example, to ping mpserver01, open a terminal and type &amp;quot;ping mpserver01.flightgear.org&amp;quot;. Determine the average ping in milliseconds and convert it to seconds. For example, a ping of 123 milliseconds becomes 0.123. Open Multiplayer &amp;gt; Lag Settings, enable &amp;quot;Master switch&amp;quot; and &amp;quot;Apply to close mp&amp;quot;. Then adjust the slider of &amp;quot;Lag adjustment&amp;quot;. Most likely to be a positive number. Alternatively, you can open the &amp;quot;Internal properties&amp;quot; window (ignore this if you don't know what it is) and set /sim/multiplay/lag/offset directly.&lt;br /&gt;
&lt;br /&gt;
Use an ethernet cable instead of wifi. Wifi may give you a very fluctuating ping time to the server.&lt;br /&gt;
&lt;br /&gt;
== Using the drogues ==&lt;br /&gt;
&lt;br /&gt;
Simply click on the Hose Drum Unit (HDU) to extend the hose and the drogue. The receiving aircraft needs to be within 10 meters of the drogue (this value might be lowered in the future) in order to connect with the drogue. The drogue will 'snap' to the probe and follow it, at least on the tanker's computer. On the receiving aircraft's computer it could be (visually) look to be not connected.&lt;br /&gt;
&lt;br /&gt;
== Using the flying boom ==&lt;br /&gt;
&lt;br /&gt;
Press the {{Key press|r}} key to move the flying boom to the ready position. Press {{Key press|d}} to disconnect. Press {{Key press|Shift}} + {{Key press|d}} to move to the off position or to perform an emergency disconnect. While the boom is ready and able to track a nearby aircraft, the &amp;quot;READY&amp;quot; light should be lit on the boomer's panel.&lt;br /&gt;
&lt;br /&gt;
To move the boom manually, hold {{Key press|Ctrl}} and then move the mouse. To extend/retract the telescope of the boom, release {{Key press|Ctrl}} and use the mouse scroll wheel.&lt;br /&gt;
&lt;br /&gt;
The receiving aircraft needs to be within 1 meter of the nozzle of the boom. Once connected, you have a few extra meters of margin. With correct lag settings several people have demonstrated to stay connected, even while in different continents.&lt;br /&gt;
&lt;br /&gt;
== Modifying aircraft to be compatible with the flying boom or drogue ==&lt;br /&gt;
&lt;br /&gt;
In order for the tanker to be able to detect compatible aircraft, the multiplayer model XML file of the aircraft that wants to have fuel needs to be modified. For example, the F-14B's Models/f-14b.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-7.1969&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;1.0409&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.0387&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;probe&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Aircraft that contain a receptacle, for connecting with the flying boom, should use the value &amp;quot;boom&amp;quot; instead of &amp;quot;probe&amp;quot;. For example, the F-15C's Models/f15c.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-0.3457&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;-1.6912&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.7946&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;boom&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Negotiating fuel flow ==&lt;br /&gt;
&lt;br /&gt;
Once it has been implemented, this section will contain instructions how to make the receiving aircraft only add fuel when connected to the boom or a drogue.&lt;br /&gt;
&lt;br /&gt;
== Missing features ==&lt;br /&gt;
&lt;br /&gt;
Aircraft are not able to negotiate a fuel flow with the tanker yet. Currently many aircraft use the generic aar.nas code which just adds fuel if the aircraft is within range of any tanker, even when the aircraft is not connected to the tanker. The maximum fuel flow depends on the type (boom, drogue, or drogue connected to boom), the specific maximum that the receiving aircraft can handle, and the state of the tanks of the tanker and receiving aircraft. Both the tanker and the receiving aircraft should publish this number (which might change continuously) in a property. Both aircraft then need to take the minimum and consider this to be the fuel flow that they can add/subtract from their tanks.&lt;br /&gt;
&lt;br /&gt;
There are no pilot director lights on the bottom of the tanker yet. The 707-TT uses ALS procedural lights for the navigation lights. These could be used as well for the PDL. See http://wiki.flightgear.org/Aerial_refueling_improvement_ideas_and_resources&lt;br /&gt;
&lt;br /&gt;
The flying boom simply moves to a position indicated by the mouse. In reality (in the KC-135) the mouse should control the two flight control surfaces on the boom. It would be appreciated if someone creates a JSBSim system that computes the lift/drag depending on state of the flight control surfaces and the current position. &lt;br /&gt;
&lt;br /&gt;
{{air-to-air refueling}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Aircraft enhancement|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Howto|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Multiplayer]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=101005</id>
		<title>Multiplayer aerial refueling</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=101005"/>
		<updated>2016-07-08T19:59:38Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[File:F-14 aerial refueling.jpg|thumb|An F-14 has connected its probe with the left drogue of a 707-TT tanker.]]&lt;br /&gt;
[[File:EC-137D aerial refueling.jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D.]]&lt;br /&gt;
[[File:EC-137D aerial refueling (seen from boomer).jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D. The aircraft is seen from the boomer's view.]]&lt;br /&gt;
[[File:F-15C aerial refueling.jpg|thumb|An F-15C is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the F-15C.]]&lt;br /&gt;
&lt;br /&gt;
User onox has created a modified 707-TT and EC-137D that allow air-to-air refueling with a moving boom and drogues.&lt;br /&gt;
&lt;br /&gt;
In order to perform AAR with this modified 707-TT you need to download the modified [https://github.com/onox/707 707] and the [https://github.com/onox/ExpansionPack ExpansionPack]. The ExpansionPack allows the flying boom and drogues to move and follow aircraft. It is also needed to see the drogue and the hose. People wishing to perform refueling with the F-15 or F-14 should use the &amp;quot;ORF&amp;quot; branch from [https://github.com/NikolaiVChr/fg-aircraft.git NikolaiVChr/fg-aircraft]. The [https://github.com/onox/V-22 MV-22] provides the ability to install one drogue on its cargo door.&lt;br /&gt;
&lt;br /&gt;
== Lag settings ==&lt;br /&gt;
&lt;br /&gt;
It is very important to adjust the lag settings in Multiplayer &amp;gt; Lag Settings. Make sure you have FlightGear 2016.1 or higher. To determine the lag, you should ping one of the multiplayer server that both the tanker and the receiving aircraft are going to use. For example, to ping mpserver01, open a terminal and type &amp;quot;ping mpserver01.flightgear.org&amp;quot;. Determine the average ping in milliseconds and convert it to seconds. For example, a ping of 123 milliseconds becomes 0.123. Open Multiplayer &amp;gt; Lag Settings, enable &amp;quot;Master switch&amp;quot; and &amp;quot;Apply to close mp&amp;quot;. Then adjust the slider of &amp;quot;Lag adjustment&amp;quot;. Most likely to be a positive number. Alternatively, you can open the &amp;quot;Internal properties&amp;quot; window (ignore this if you don't know what it is) and set /sim/multiplay/lag/offset directly.&lt;br /&gt;
&lt;br /&gt;
Use an ethernet cable instead of wifi. Wifi may give you a very fluctuating ping time to the server.&lt;br /&gt;
&lt;br /&gt;
== Using the drogues ==&lt;br /&gt;
&lt;br /&gt;
Simply click on the Hose Drum Unit (HDU) to extend the hose and the drogue. The receiving aircraft needs to be within 10 meters of the drogue (this value might be lowered in the future) in order to connect with the drogue. The drogue will 'snap' to the probe and follow it, at least on the tanker's computer. On the receiving aircraft's computer it could be (visually) look to be not connected.&lt;br /&gt;
&lt;br /&gt;
== Using the flying boom ==&lt;br /&gt;
&lt;br /&gt;
Press the {{Key press|r}} key to move the flying boom to the ready position. Press {{Key press|d}} to disconnect. Press {{Key press|Shift}} + {{Key press|d}} to move to the off position or to perform an emergency disconnect. While the boom is ready and able to track a nearby aircraft, the &amp;quot;READY&amp;quot; light should be lit on the boomer's panel.&lt;br /&gt;
&lt;br /&gt;
To move the boom manually, hold {{Key press|Ctrl}} and then move the mouse. To extend/retract the telescope of the boom, release {{Key press|Ctrl}} and use the mouse scroll wheel.&lt;br /&gt;
&lt;br /&gt;
The receiving aircraft needs to be within 1 meter of the nozzle of the boom. Once connected, you have a few extra meters of margin. With correct lag settings several people have demonstrated to stay connected, even while in different continents.&lt;br /&gt;
&lt;br /&gt;
== Modifying aircraft to be compatible with the flying boom or drogue ==&lt;br /&gt;
&lt;br /&gt;
In order for the tanker to be able to detect compatible aircraft, the multiplayer model XML file of the aircraft that wants to have fuel needs to be modified. For example, the F-14B's Models/f-14b.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-7.1969&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;1.0409&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.0387&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;probe&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Aircraft that contain a receptacle, for connecting with the flying boom, should use the value &amp;quot;boom&amp;quot; instead of &amp;quot;probe&amp;quot;. For example, the F-15C's Models/f15c.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-0.3457&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;-1.6912&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.7946&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;boom&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Negotiating fuel flow ==&lt;br /&gt;
&lt;br /&gt;
Once it has been implemented, this section will contain instructions how to make the receiving aircraft only add fuel when connected to the boom or a drogue.&lt;br /&gt;
&lt;br /&gt;
== Missing features ==&lt;br /&gt;
&lt;br /&gt;
Aircraft are not able to negotiate a fuel flow with the tanker yet. Currently many aircraft use the generic aar.nas code which just adds fuel if the aircraft is within range of any tanker, even when the aircraft is not connected to the tanker. The maximum fuel flow depends on the type (boom, drogue, or drogue connected to boom), the specific maximum that the receiving aircraft can handle, and the state of the tanks of the tanker and receiving aircraft. Both the tanker and the receiving aircraft should publish this number (which might change continuously) in a property. Both aircraft then need to take the minimum and consider this to be the fuel flow that they can add/subtract from their tanks.&lt;br /&gt;
&lt;br /&gt;
There are no pilot director lights on the bottom of the tanker yet. The 707-TT uses ALS procedural lights for the navigation lights. These could be used as well for the PDL. See http://wiki.flightgear.org/Aerial_refueling_improvement_ideas_and_resources&lt;br /&gt;
&lt;br /&gt;
The flying boom simply moves to a position indicated by the mouse. In reality (in the KC-135) the mouse should control the two flight control surfaces on the boom. It would be appreciated if someone creates a JSBSim system that lift/drag depending on state of the flight control surfaces and the current position. &lt;br /&gt;
&lt;br /&gt;
{{air-to-air refueling}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Aircraft enhancement|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Howto|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Multiplayer]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=101004</id>
		<title>Multiplayer aerial refueling</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=101004"/>
		<updated>2016-07-08T19:52:37Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[File:F-14 aerial refueling.jpg|thumb|An F-14 has connected its probe with the left drogue of a 707-TT tanker.]]&lt;br /&gt;
[[File:EC-137D aerial refueling.jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D.]]&lt;br /&gt;
[[File:EC-137D aerial refueling (seen from boomer).jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D. The aircraft is seen from the boomer's view.]]&lt;br /&gt;
[[File:F-15C aerial refueling.jpg|thumb|An F-15C is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the F-15C.]]&lt;br /&gt;
&lt;br /&gt;
User onox has created a modified 707-TT and EC-137D that allow air-to-air refueling with a moving boom and drogues.&lt;br /&gt;
&lt;br /&gt;
In order to perform AAR with this modified 707-TT you need to download the modified [https://github.com/onox/707 707] and the [https://github.com/onox/ExpansionPack ExpansionPack]. The ExpansionPack allows the flying boom and drogues to move and follow aircraft. It is also needed to see the drogue and the hose. People wishing to perform refueling with the F-15 or F-14 should use the &amp;quot;ORF&amp;quot; branch from [https://github.com/NikolaiVChr/fg-aircraft.git NikolaiVChr/fg-aircraft]. The [https://github.com/onox/V-22 MV-22] provides the ability to install one drogue on its cargo door.&lt;br /&gt;
&lt;br /&gt;
== Lag settings ==&lt;br /&gt;
&lt;br /&gt;
It is very important to adjust the lag settings in Multiplayer &amp;gt; Lag Settings. Make sure you have FlightGear 2016.1 or higher. To determine the lag, you should ping one of the multiplayer server that both the tanker and the receiving aircraft are going to use. For example, to ping mpserver01, open a terminal and type &amp;quot;ping mpserver01.flightgear.org&amp;quot;. Determine the average ping in milliseconds and convert it to seconds. For example, a ping of 123 milliseconds becomes 0.123. Open Multiplayer &amp;gt; Lag Settings, enable &amp;quot;Master switch&amp;quot; and &amp;quot;Apply to close mp&amp;quot;. Then adjust the slider of &amp;quot;Lag adjustment&amp;quot;. Most likely to be a positive number. Alternatively, you can open the &amp;quot;Internal properties&amp;quot; window (ignore this if you don't know what it is) and set /sim/multiplay/lag/offset directly.&lt;br /&gt;
&lt;br /&gt;
== Using the drogues ==&lt;br /&gt;
&lt;br /&gt;
Simply click on the Hose Drum Unit (HDU) to extend the hose and the drogue.&lt;br /&gt;
&lt;br /&gt;
== Using the flying boom ==&lt;br /&gt;
&lt;br /&gt;
Press the {{Key press|r}} key to move the flying boom to the ready position. Press {{Key press|d}} to disconnect. Press {{Key press|Shift}} + {{Key press|d}} to move to the off position or to perform an emergency disconnect. While the boom is ready and able to track a nearby aircraft, the &amp;quot;READY&amp;quot; light should be lit on the boomer's panel.&lt;br /&gt;
&lt;br /&gt;
To move the boom manually, hold {{Key press|Ctrl}} and then move the mouse. To extend/retract the telescope of the boom, release {{Key press|Ctrl}} and use the mouse scroll wheel.&lt;br /&gt;
&lt;br /&gt;
== Modifying aircraft to be compatible with the flying boom or drogue ==&lt;br /&gt;
&lt;br /&gt;
In order for the tanker to be able to detect compatible aircraft, the multiplayer model XML file of the aircraft that wants to have fuel needs to be modified. For example, the F-14B's Models/f-14b.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-7.1969&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;1.0409&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.0387&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;probe&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Aircraft that contain a receptacle, for connecting with the flying boom, should use the value &amp;quot;boom&amp;quot; instead of &amp;quot;probe&amp;quot;. For example, the F-15C's Models/f15c.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-0.3457&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;-1.6912&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.7946&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;boom&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Negotiating fuel flow ==&lt;br /&gt;
&lt;br /&gt;
Once it has been implemented, this section will contain instructions how to make the receiving aircraft only add fuel when connected to the boom or a drogue.&lt;br /&gt;
&lt;br /&gt;
== Missing features ==&lt;br /&gt;
&lt;br /&gt;
Aircraft are not able to negotiate a fuel flow with the tanker yet. Currently many aircraft use the generic aar.nas code which just adds fuel if the aircraft is within range of any tanker, even when the aircraft is not connected to the tanker. The maximum fuel flow depends on the type (boom, drogue, or drogue connected to boom), the specific maximum that the receiving aircraft can handle, and the state of the tanks of the tanker and receiving aircraft. Both the tanker and the receiving aircraft should publish this number (which might change continuously) in a property. Both aircraft then need to take the minimum and consider this to be the fuel flow that they can add/subtract from their tanks.&lt;br /&gt;
&lt;br /&gt;
There are no pilot director lights on the bottom of the tanker yet. The 707-TT uses ALS procedural lights for the navigation lights. These could be used as well for the PDL. See http://wiki.flightgear.org/Aerial_refueling_improvement_ideas_and_resources&lt;br /&gt;
&lt;br /&gt;
The flying boom simply moves to a position indicated by the mouse. In reality (in the KC-135) the mouse should control the two flight control surfaces on the boom. It would be appreciated if someone creates a JSBSim system that lift/drag depending on state of the flight control surfaces and the current position. &lt;br /&gt;
&lt;br /&gt;
{{air-to-air refueling}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Aircraft enhancement|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Howto|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Multiplayer]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=101003</id>
		<title>Multiplayer aerial refueling</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=101003"/>
		<updated>2016-07-08T19:43:37Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[File:F-14 aerial refueling.jpg|thumb|An F-14 has connected its probe with the left drogue of a 707-TT tanker.]]&lt;br /&gt;
[[File:EC-137D aerial refueling.jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D.]]&lt;br /&gt;
[[File:EC-137D aerial refueling (seen from boomer).jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D. The aircraft is seen from the boomer's view.]]&lt;br /&gt;
[[File:F-15C aerial refueling.jpg|thumb|An F-15C is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the F-15C.]]&lt;br /&gt;
&lt;br /&gt;
User onox has created a modified 707-TT and EC-137D that allow air-to-air refueling with a moving boom and drogues.&lt;br /&gt;
&lt;br /&gt;
In order to perform AAR with this modified 707-TT you need to download the modified [https://github.com/onox/707 707] and the [https://github.com/onox/ExpansionPack ExpansionPack]. The ExpansionPack allows the flying boom and drogues to move and follow aircraft. It is also needed to see the drogue and the hose. People wishing to perform refueling with the F-15 or F-14 should use the &amp;quot;ORF&amp;quot; branch from [https://github.com/NikolaiVChr/fg-aircraft.git NikolaiVChr/fg-aircraft]. The [https://github.com/onox/V-22 MV-22] provides the ability to install one drogue on its cargo door.&lt;br /&gt;
&lt;br /&gt;
== Using the drogues ==&lt;br /&gt;
&lt;br /&gt;
Simply click on the Hose Drum Unit (HDU) to extend the hose and the drogue.&lt;br /&gt;
&lt;br /&gt;
== Using the flying boom ==&lt;br /&gt;
&lt;br /&gt;
Press the {{Key press|r}} key to move the flying boom to the ready position. Press {{Key press|d}} to disconnect. Press {{Key press|Shift}} + {{Key press|d}} to move to the off position or to perform an emergency disconnect. While the boom is ready and able to track a nearby aircraft, the &amp;quot;READY&amp;quot; light should be lit on the boomer's panel.&lt;br /&gt;
&lt;br /&gt;
To move the boom manually, hold {{Key press|Ctrl}} and then move the mouse. To extend/retract the telescope of the boom, release {{Key press|Ctrl}} and use the mouse scroll wheel.&lt;br /&gt;
&lt;br /&gt;
== Modifying aircraft to be compatible with the flying boom or drogue ==&lt;br /&gt;
&lt;br /&gt;
In order for the tanker to be able to detect compatible aircraft, the multiplayer model XML file of the aircraft that wants to have fuel needs to be modified. For example, the F-14B's Models/f-14b.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-7.1969&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;1.0409&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.0387&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;probe&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Aircraft that contain a receptacle, for connecting with the flying boom, should use the value &amp;quot;boom&amp;quot; instead of &amp;quot;probe&amp;quot;. For example, the F-15C's Models/f15c.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-0.3457&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;-1.6912&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.7946&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;boom&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Negotiating fuel flow ==&lt;br /&gt;
&lt;br /&gt;
Once it has been implemented, this section will contain instructions how to make the receiving aircraft only add fuel when connected to the boom or a drogue.&lt;br /&gt;
&lt;br /&gt;
== Missing features ==&lt;br /&gt;
&lt;br /&gt;
Aircraft are not able to negotiate a fuel flow with the tanker yet. Currently many aircraft use the generic aar.nas code which just adds fuel if the aircraft is within range of any tanker, even when the aircraft is not connected to the tanker. The maximum fuel flow depends on the type (boom, drogue, or drogue connected to boom), the specific maximum that the receiving aircraft can handle, and the state of the tanks of the tanker and receiving aircraft. Both the tanker and the receiving aircraft should publish this number (which might change continuously) in a property. Both aircraft then need to take the minimum and consider this to be the fuel flow that they can add/subtract from their tanks.&lt;br /&gt;
&lt;br /&gt;
There are no pilot director lights on the bottom of the tanker yet. The 707-TT uses ALS procedural lights for the navigation lights. These could be used as well for the PDL. See http://wiki.flightgear.org/Aerial_refueling_improvement_ideas_and_resources&lt;br /&gt;
&lt;br /&gt;
The flying boom simply moves to a position indicated by the mouse. In reality (in the KC-135) the mouse should control the two flight control surfaces on the boom. It would be appreciated if someone creates a JSBSim system that lift/drag depending on state of the flight control surfaces and the current position. &lt;br /&gt;
&lt;br /&gt;
{{air-to-air refueling}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Aircraft enhancement|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Howto|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Multiplayer]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=101002</id>
		<title>Multiplayer aerial refueling</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Multiplayer_aerial_refueling&amp;diff=101002"/>
		<updated>2016-07-08T19:41:23Z</updated>

		<summary type="html">&lt;p&gt;Onox: Created page with &amp;quot;An F-14 has connected its probe with the left drogue of a 707-TT tanker. File:EC-137D aerial refueling.jpg|thumb|An EC-137D is flyin...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[File:F-14 aerial refueling.jpg|thumb|An F-14 has connected its probe with the left drogue of a 707-TT tanker.]]&lt;br /&gt;
[[File:EC-137D aerial refueling.jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D.]]&lt;br /&gt;
[[File:EC-137D aerial refueling (seen from boomer).jpg|thumb|An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D. The aircraft is seen from the boomer's view.]]&lt;br /&gt;
[[File:F-15C aerial refueling.jpg|thumb|An F-15C is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the F-15C.]]&lt;br /&gt;
&lt;br /&gt;
User onox has created a modified 707-TT and EC-137D that allow air-to-air refueling with a moving boom and drogues.&lt;br /&gt;
&lt;br /&gt;
In order to perform AAR with this modified 707-TT you need to download the modified [https://github.com/onox/707 707] and the [https://github.com/onox/ExpansionPack ExpansionPack]. The ExpansionPack allows the flying boom and drogues to move and follow aircraft. It is also needed to see the drogue and the hose. People wishing to perform refueling with the F-15 or F-14 should use the &amp;quot;ORF&amp;quot; branch from [https://github.com/NikolaiVChr/fg-aircraft.git NikolaiVChr/fg-aircraft].&lt;br /&gt;
&lt;br /&gt;
== Using the drogues ==&lt;br /&gt;
&lt;br /&gt;
Simply click on the Hose Drum Unit (HDU) to extend the hose and the drogue.&lt;br /&gt;
&lt;br /&gt;
== Using the flying boom ==&lt;br /&gt;
&lt;br /&gt;
Press the {{Key press|r}} key to move the flying boom to the ready position. Press {{Key press|d}} to disconnect. Press {{Key press|Shift}} + {{Key press|d}} to move to the off position or to perform an emergency disconnect. While the boom is ready and able to track a nearby aircraft, the &amp;quot;READY&amp;quot; light should be lit on the boomer's panel.&lt;br /&gt;
&lt;br /&gt;
To move the boom manually, hold {{Key press|Ctrl}} and then move the mouse. To extend/retract the telescope of the boom, release {{Key press|Ctrl}} and use the mouse scroll wheel.&lt;br /&gt;
&lt;br /&gt;
== Modifying aircraft to be compatible with the flying boom or drogue ==&lt;br /&gt;
&lt;br /&gt;
In order for the tanker to be able to detect compatible aircraft, the multiplayer model XML file of the aircraft that wants to have fuel needs to be modified. For example, the F-14B's Models/f-14b.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-7.1969&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;1.0409&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.0387&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;probe&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Aircraft that contain a receptacle, for connecting with the flying boom, should use the value &amp;quot;boom&amp;quot; instead of &amp;quot;probe&amp;quot;. For example, the F-15C's Models/f15c.xml file contains:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;multiplay&amp;gt;&lt;br /&gt;
    &amp;lt;refuel&amp;gt;&lt;br /&gt;
        &amp;lt;offset-x-m type=&amp;quot;double&amp;quot;&amp;gt;-0.3457&amp;lt;/offset-x-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-y-m type=&amp;quot;double&amp;quot;&amp;gt;-1.6912&amp;lt;/offset-y-m&amp;gt;&lt;br /&gt;
        &amp;lt;offset-z-m type=&amp;quot;double&amp;quot;&amp;gt;0.7946&amp;lt;/offset-z-m&amp;gt;&lt;br /&gt;
        &amp;lt;type type=&amp;quot;string&amp;quot;&amp;gt;boom&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;/refuel&amp;gt;&lt;br /&gt;
&amp;lt;/multiplay&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Negotiating fuel flow ==&lt;br /&gt;
&lt;br /&gt;
Once it has been implemented, this section will contain instructions how to make the receiving aircraft only add fuel when connected to the boom or a drogue.&lt;br /&gt;
&lt;br /&gt;
== Missing features ==&lt;br /&gt;
&lt;br /&gt;
Aircraft are not able to negotiate a fuel flow with the tanker yet. Currently many aircraft use the generic aar.nas code which just adds fuel if the aircraft is within range of any tanker, even when the aircraft is not connected to the tanker. The maximum fuel flow depends on the type (boom, drogue, or drogue connected to boom), the specific maximum that the receiving aircraft can handle, and the state of the tanks of the tanker and receiving aircraft. Both the tanker and the receiving aircraft should publish this number (which might change continuously) in a property. Both aircraft then need to take the minimum and consider this to be the fuel flow that they can add/subtract from their tanks.&lt;br /&gt;
&lt;br /&gt;
There are no pilot director lights on the bottom of the tanker yet. The 707-TT uses ALS procedural lights for the navigation lights. These could be used as well for the PDL. See http://wiki.flightgear.org/Aerial_refueling_improvement_ideas_and_resources&lt;br /&gt;
&lt;br /&gt;
The flying boom simply moves to a position indicated by the mouse. In reality (in the KC-135) the mouse should control the two flight control surfaces on the boom. It would be appreciated if someone creates a JSBSim system that lift/drag depending on state of the flight control surfaces and the current position. &lt;br /&gt;
&lt;br /&gt;
{{air-to-air refueling}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Aircraft enhancement|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Howto|Implement aerial refueling capability]]&lt;br /&gt;
[[Category:Multiplayer]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=File:F-15C_aerial_refueling.jpg&amp;diff=101001</id>
		<title>File:F-15C aerial refueling.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=File:F-15C_aerial_refueling.jpg&amp;diff=101001"/>
		<updated>2016-07-08T18:57:57Z</updated>

		<summary type="html">&lt;p&gt;Onox: User created page with UploadWizard&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=={{int:filedesc}}==&lt;br /&gt;
{{Information&lt;br /&gt;
|description={{en|1=An F-15C is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the F-15C.}}&lt;br /&gt;
|date=2016-07-08&lt;br /&gt;
|source={{own}}&lt;br /&gt;
|author=[[User:Onox|onox]]&lt;br /&gt;
|permission=&lt;br /&gt;
|other versions=&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=={{int:license-header}}==&lt;br /&gt;
{{self|cc-by-sa-4.0}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Multiplayer]]&lt;br /&gt;
[[Category:AAR]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=File:EC-137D_aerial_refueling_(seen_from_boomer).jpg&amp;diff=101000</id>
		<title>File:EC-137D aerial refueling (seen from boomer).jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=File:EC-137D_aerial_refueling_(seen_from_boomer).jpg&amp;diff=101000"/>
		<updated>2016-07-08T18:57:56Z</updated>

		<summary type="html">&lt;p&gt;Onox: User created page with UploadWizard&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=={{int:filedesc}}==&lt;br /&gt;
{{Information&lt;br /&gt;
|description={{en|1=An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D. The aircraft is seen from the boomer's view.}}&lt;br /&gt;
|date=2016-07-08&lt;br /&gt;
|source={{own}}&lt;br /&gt;
|author=[[User:Onox|onox]]&lt;br /&gt;
|permission=&lt;br /&gt;
|other versions=&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=={{int:license-header}}==&lt;br /&gt;
{{self|cc-by-sa-4.0}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Multiplayer]]&lt;br /&gt;
[[Category:AAR]]&lt;br /&gt;
[[Category:AWACS aircraft]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=File:EC-137D_aerial_refueling.jpg&amp;diff=100999</id>
		<title>File:EC-137D aerial refueling.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=File:EC-137D_aerial_refueling.jpg&amp;diff=100999"/>
		<updated>2016-07-08T18:57:56Z</updated>

		<summary type="html">&lt;p&gt;Onox: User created page with UploadWizard&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=={{int:filedesc}}==&lt;br /&gt;
{{Information&lt;br /&gt;
|description={{en|1=An EC-137D is flying behind a 707-TT tanker while the flying boom of the tanker is connected to the receptacle of the EC-137D.}}&lt;br /&gt;
|date=2016-07-08&lt;br /&gt;
|source={{own}}&lt;br /&gt;
|author=[[User:Onox|onox]]&lt;br /&gt;
|permission=&lt;br /&gt;
|other versions=&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=={{int:license-header}}==&lt;br /&gt;
{{self|cc-by-sa-4.0}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Multiplayer]]&lt;br /&gt;
[[Category:AAR]]&lt;br /&gt;
[[Category:AWACS aircraft]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=File:F-14_aerial_refueling.jpg&amp;diff=100998</id>
		<title>File:F-14 aerial refueling.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=File:F-14_aerial_refueling.jpg&amp;diff=100998"/>
		<updated>2016-07-08T18:57:55Z</updated>

		<summary type="html">&lt;p&gt;Onox: User created page with UploadWizard&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=={{int:filedesc}}==&lt;br /&gt;
{{Information&lt;br /&gt;
|description={{en|1=An F-14 has connected its probe with the left drogue of a 707-TT tanker.}}&lt;br /&gt;
|date=2016-07-08&lt;br /&gt;
|source={{own}}&lt;br /&gt;
|author=[[User:Onox|onox]]&lt;br /&gt;
|permission=&lt;br /&gt;
|other versions=&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=={{int:license-header}}==&lt;br /&gt;
{{self|cc-by-sa-4.0}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Multiplayer]]&lt;br /&gt;
[[Category:AAR]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Cessna_172P&amp;diff=90435</id>
		<title>Cessna 172P</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Cessna_172P&amp;diff=90435"/>
		<updated>2015-12-07T19:30:30Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{infobox Aircraft&lt;br /&gt;
|ready = dualcontrol&lt;br /&gt;
|image		= c172p-thumbnail.jpg&lt;br /&gt;
|name 		= Cessna 172P&lt;br /&gt;
|type 		= Civilian aircraft&lt;br /&gt;
|fdm 		= JSBSim&lt;br /&gt;
|status-fdm	= 4&lt;br /&gt;
|status-systems	= 5&lt;br /&gt;
|status-cockpit	= 5&lt;br /&gt;
|status-model	= 4&lt;br /&gt;
|authors 	= David Megginson, gsagostinho (Gilberto Agostinho), wlbragg (Wayne Bragg), Juanvvc (Juan Vera del Campo), onox, thevirtualfer (Fernando Barbosa), Dany93 (Daniel Dubreuil), dg-505 (Jonathan Schellhase), IAHM-COL (Israel Hernandez), tigert (Tuomas Kuosmanen), AndersG (Anders Gidenstam), wkitty42 (Waldo Kitty), algefaen&lt;br /&gt;
|fgname 	= c172p&lt;br /&gt;
}}&lt;br /&gt;
The '''Cessna 172P ''Skyhawk''''' is a four-seat, single-engine, high-wing fixed-wing [[aircraft]]. First flown in 1955 and still in production, more Cessna 172s have been built than any other aircraft.&lt;br /&gt;
&lt;br /&gt;
A C172 has been the default aircraft in [[FlightGear]] since 2000, when it replaced the [[Navion]]. It has had a long development and includes a wide variety of simulation features. In 2015, it went through a complete refresh, including engine options, various tire sizes and floats, as well as a complete cockpit texture makeover. This new detailed version of the plane has become the default aircraft since [[Changelog_3.6|FlightGear 3.6]].&lt;br /&gt;
&lt;br /&gt;
== Features ==&lt;br /&gt;
&lt;br /&gt;
The new C172p has a much better 3D model and is now fully textured (including the interior). All the switches in the cockpit are clickable. It also has an improved FDM, more complex procedures and new realistic checklists, new sound effects, and damage modelling. The aircraft can get damaged if mishandled (e.g. gear collapse after a hard landing).&lt;br /&gt;
&lt;br /&gt;
[[File:C172p-bodensee-panorama.jpg|center|800px]]&lt;br /&gt;
&lt;br /&gt;
The aircraft currently has five variants, all available from the aircraft menu:&lt;br /&gt;
* regular wheels&lt;br /&gt;
* 26&amp;quot; bush tires&lt;br /&gt;
* 31&amp;quot; bush tires&lt;br /&gt;
* pontoons&lt;br /&gt;
* amphibian&lt;br /&gt;
* snow skis&lt;br /&gt;
&lt;br /&gt;
Also, from the same menu, the user can select two different engines:&lt;br /&gt;
* 160 HP&lt;br /&gt;
* 180 HP (recommended when using pontoons, amphibian and skis variants)&lt;br /&gt;
&lt;br /&gt;
The aircraft now can get damaged from collisions, crashes, hard landings or overload while in-flight, and the modelling includes wheel collapse, wings breaking, etc. The damage can be turned off in the aircraft menu, which also contains an option for repairing the aircraft.&lt;br /&gt;
&lt;br /&gt;
The windows now can get foggy or frosty, depending on the combination of interior and exterior temperatures. The pilot must then use the Cabin Heat and Cabin Air levers (on the right of the flaps) to control it. Alternatively, it's possible to disable the effect in the &amp;quot;Aircraft Options&amp;quot; in the &amp;quot;Cessna 172P&amp;quot; menu. This effect depends on the new ALS effects found in 3.5 and above, and will also have the side effect of producing grey windows in versions prior to 3.5.&lt;br /&gt;
&lt;br /&gt;
The FDM has also been modified. The aircraft may enter into a spin in case of an asymmetric stall (a particularly dangerous situation when turning to final, in which case the aircraft is at low speed and low height). The FDM has also been tweaked to include hydrodynamics effects while taking off or landing on water, as well as adding a new 180 HP engine.&lt;br /&gt;
&lt;br /&gt;
There are several liveries available, some of which have higher resolution than others, which are marked as HD in the liveries menu. Each of the HD liveries also has unique cockpit and interior textures.&lt;br /&gt;
&lt;br /&gt;
The aircraft has a simulation of the [[Bendix/King KAP140 Autopilot]].&lt;br /&gt;
&lt;br /&gt;
Also, if the user has enabled ALS (Atmospheric light scattering) in the Rendering Options, then it's possible to activate the flashlight by clicking on the &amp;quot;Cessna 172P&amp;quot; menu and selecting &amp;quot;Flashlight&amp;quot;. Select it once for the white flashlight, select it again for a red one and select it one more time to turn it off.&lt;br /&gt;
&lt;br /&gt;
The aircraft can now go through a pre-flight: wheel chocks, tie-downs and the pitot tube cover can now be added or removed, oil management and fuel contamination by water have been implemented (both of which are not activated by default, but are available in the aircraft menu).&lt;br /&gt;
[[File:c172p-ALS-flashlight2.jpg|500px|center|Cessna 172P's flashlight in the cockpit]]&lt;br /&gt;
&lt;br /&gt;
== Handling The Aircraft ==&lt;br /&gt;
&lt;br /&gt;
=== Pre-Flight Inspection ===&lt;br /&gt;
[[File:C172p-secured-Aosta.jpg|270px||thumb|Cessna 172P secured at Aosta Airport]]&lt;br /&gt;
It's recommended to use any exterior view or activate the walker for these procedures.&lt;br /&gt;
* Fuel quantity: add by clicking on the fuel tank caps above each wing&lt;br /&gt;
* Right wing: remove tie-downs&lt;br /&gt;
* Right wing: check for fuel contamination by clicking under the wing and take a fuel sample. If the sample is light blue, the fuel is not contaminated and can be returned to the tank. If the sample is transparent or partially transparent, you must discard it and take new samples until they are completely light blue&lt;br /&gt;
* Nose: check for oil quantity by clicking on the oil door in the nose. Critical oil level for either engine is 5.0 quarts.&lt;br /&gt;
* Nose: remove wheel chocks&lt;br /&gt;
* Left wing: remove tie-downs&lt;br /&gt;
* Left wing: remove pitot tube cover&lt;br /&gt;
* Left wing: check for fuel contamination&lt;br /&gt;
&lt;br /&gt;
=== Engine Start (manual and complex startup) ===&lt;br /&gt;
* Priming: prime the engine at least 3 times&lt;br /&gt;
* Mixture: Rich (Red all the way in)&lt;br /&gt;
* Throttle: Open 1/8 (Black almost all the way out)&lt;br /&gt;
* Parking Brake: Applied ({{Key press|Shift|B}})&lt;br /&gt;
* Prop Area: Clear&lt;br /&gt;
* Master switch: Both on&lt;br /&gt;
* Magnetos: Both (Press {{Key press|&amp;lt;nowiki&amp;gt;}&amp;lt;/nowiki&amp;gt;}} three times)&lt;br /&gt;
* Ignition: Start ({{Key press|S}})&lt;br /&gt;
&lt;br /&gt;
=== Engine Start (automatically with Autostart) ===&lt;br /&gt;
* Click on the menu &amp;quot;Cessna C172P&amp;quot;, select &amp;quot;Autostart&amp;quot; and then simply hold the key {{Key press|S}} in order to start the plane.&lt;br /&gt;
&lt;br /&gt;
=== Takeoff ===&lt;br /&gt;
[[File:c172p-cockpit.jpg|270px||thumb|Cessna 172P ready for take off]]&lt;br /&gt;
* no flaps&lt;br /&gt;
* full throttle&lt;br /&gt;
* rotate at 55 KIAS&lt;br /&gt;
&lt;br /&gt;
=== Climbout ===&lt;br /&gt;
* no flaps&lt;br /&gt;
* full throttle&lt;br /&gt;
* 75 KIAS&lt;br /&gt;
&lt;br /&gt;
=== Cruise ===&lt;br /&gt;
* throttle 65%&lt;br /&gt;
* mixture rich of peak&lt;br /&gt;
* speed around 100 knots&lt;br /&gt;
&lt;br /&gt;
=== Landing ===&lt;br /&gt;
[[File:c172p-landing2.jpg|270px||thumb|Cessna 172P about to touchdown]]&lt;br /&gt;
* full flaps&lt;br /&gt;
* 60 KIAS&lt;br /&gt;
&lt;br /&gt;
=== Airspeeds ===&lt;br /&gt;
: ''See also [[Aircraft speed#V speeds]]''&lt;br /&gt;
&lt;br /&gt;
The information in this section is based on external resources.&amp;lt;ref&amp;gt;[http://www.triangleaviation.com/1982_172r.html Triangle Aviation]{{dead link|2015-10}}&amp;lt;/ref&amp;gt;&amp;lt;ref&amp;gt;[http://www.otisair.com/c172info.html OtisAir's Airborne Observations]{{dead link|2015-10}}&amp;lt;/ref&amp;gt;&amp;lt;ref&amp;gt;{{cite web |url=http://www.airweb.faa.gov/Regulatory_and_Guidance_Library/rgMakeModel.nsf/0/724e90061c5bf3b1862576260063e599/$FILE/3A12.pdf |title=Type Certificate No. 3A12, Revision 79 |date=27 August 2009 |work= |publisher=FAA |format=pdf |accessdate=9 October 2015}}&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Airspeed !! CAS&lt;br /&gt;
|-&lt;br /&gt;
| Stall speed, landing configuration, V&amp;lt;sub&amp;gt;S&amp;lt;sub&amp;gt;0&amp;lt;/sub&amp;gt;&amp;lt;/sub&amp;gt; || 33 kt&lt;br /&gt;
|-&lt;br /&gt;
| Stall speed, clean, V&amp;lt;sub&amp;gt;S&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/sub&amp;gt; || 44 kt&lt;br /&gt;
|-&lt;br /&gt;
| Rotation speed, V&amp;lt;sub&amp;gt;R&amp;lt;/sub&amp;gt; || 55 kt&lt;br /&gt;
|-&lt;br /&gt;
| Best angle of climb speed, V&amp;lt;sub&amp;gt;X&amp;lt;/sub&amp;gt; || 59 kt&lt;br /&gt;
|-&lt;br /&gt;
| Best rate of climb speed, V&amp;lt;sub&amp;gt;Y&amp;lt;/sub&amp;gt; || 76 kt&lt;br /&gt;
|-&lt;br /&gt;
| Maximum flap extended speed, V&amp;lt;sub&amp;gt;FE&amp;lt;/sub&amp;gt; || 85 kt&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;2&amp;quot; valign=&amp;quot;top&amp;quot; | Maneuvering speed, V&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt; || 96 kt (floatplane)&lt;br /&gt;
|-&lt;br /&gt;
| 99 kt (landplane)&lt;br /&gt;
|-&lt;br /&gt;
| Maximum structural cruising speed, V&amp;lt;sub&amp;gt;NO&amp;lt;/sub&amp;gt; || 127 kt&lt;br /&gt;
|-&lt;br /&gt;
| Never exceed speed, V&amp;lt;sub&amp;gt;NE&amp;lt;/sub&amp;gt; || 158 kt&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== FAQ ==&lt;br /&gt;
&lt;br /&gt;
Here are some of the frequently asked questions about this aircraft:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Q:''' I am experiencing grey windows, what is happening?&lt;br /&gt;
&lt;br /&gt;
'''A:''' If you experience grey windows, you do not have the correct FlightGear version. This aircraft requires 3.5 or above.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Q:''' Why does the aircraft keep turning left?&lt;br /&gt;
&lt;br /&gt;
'''A:''' Please see [[understanding Propeller Torque and P-Factor]]. If using the amphibian model on a solid runway, note that at the taxiing is done by differential braking (the rudder becomes more and more effective as the plane gains speed).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Q:''' Why will the engine not start?&lt;br /&gt;
&lt;br /&gt;
'''A:''' You can start the engine automatically by clicking on the menu &amp;quot;Cessna C172P&amp;quot;, selecting &amp;quot;Autostart&amp;quot; and then simply holding the key {{Key press|S}}. For a manual start, please follow the checklists available by clicking on the menu &amp;quot;Help&amp;quot; followed by &amp;quot;Aircraft Checklists&amp;quot;. As seen above, the engine must by &amp;quot;primed&amp;quot; before starting. If oil management is activated, you must have enough oil for the engine to work (more than 5.0 quarts). If fuel contamination is activated, the fuel must be light blue in order for the engine to properly work.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Q:''' Why does the engine die immediately after startup?&lt;br /&gt;
&lt;br /&gt;
'''A:''' Probably because the throttle is being incremented too fast after startup as the engine needs a few seconds to stabilize itself.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Q:''' Why can't I start the sim with the engine running?&lt;br /&gt;
&lt;br /&gt;
'''A:''' You can! Go to the menu &amp;quot;Cessna C172P&amp;quot;, select &amp;quot;Aircraft Options&amp;quot; and tick the option &amp;quot;Start with engine running&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Q:''' Why the aircraft doesn't move?&lt;br /&gt;
&lt;br /&gt;
'''A:''' The aircraft won't move if you have the parking brakes set, or if either of the wing tie-downs, the tail tie-down or wheel chocks are in place (if the option &amp;quot;allow securing aircraft&amp;quot; is enabled in the aircraft menu).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Q:''' Why the airspeed indicator doesn't work?&lt;br /&gt;
&lt;br /&gt;
'''A:''' If the option &amp;quot;allow securing aircraft&amp;quot; is enabled in the aircraft menu, then very likely you forgot to remove the pitot tube cover.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Q:''' How can I switch to the bush tires/pontoons/amphibian?&lt;br /&gt;
&lt;br /&gt;
'''A:''' By clicking in menu &amp;quot;Cessna 172P&amp;quot;, selecting &amp;quot;Aircraft Options&amp;quot; and then selecting the other landing gear options.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Q:''' How can I switch to the 180 HP engine?&lt;br /&gt;
&lt;br /&gt;
'''A:''' This is also done by clicking in menu &amp;quot;Cessna 172P&amp;quot;, selecting &amp;quot;Aircraft Options&amp;quot; and then selecting the engine power option.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Q:''' Why can't I take off from the water without crashing the plane?&lt;br /&gt;
&lt;br /&gt;
'''A:''' Taking off and landing on water can be quite tricky. Try applying a little bit of back pressure on the yoke while accelerating to 55 KIAS. It's also recommended to use the 180 HP engine instead of the default 160 HP, as the extra weight of the pontoons make it really hard to climb with the default engine.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Q:''' Why is the simulator lagging so much?&lt;br /&gt;
&lt;br /&gt;
'''A:''' As with any complex 3D model, this new version of the c172p is a bit more demanding on the computers than the older one. If you are having troubles with performance, try using non-HD liveries which use textures with lower resolutions, as well as other solutions that can improve performance (disabling certain graphical options in the Rendering Options, lowering the resolution of FlightGear, etc.).&lt;br /&gt;
&lt;br /&gt;
Some tricks that help to increase fps is by disabling all GUI windows, including the menu bar and the orange fps counters at the bottom of the screen. You can display an alternative fps counter in the top left corner via the &amp;quot;Debug&amp;quot; menu and then selecting &amp;quot;Cycle On-Screen Statistics&amp;quot;. Make sure to hide the menu bar by pressing F10 to see the counter.&lt;br /&gt;
&lt;br /&gt;
A second trick is to simply disable the rendering of all clouds if you don't mind. Start FlightGear with &amp;quot;--prop:/sim/rendering/draw-mask/clouds=0&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
If you notice heavy slowdowns when flying over certain scenery and you see FlightGear generating many &amp;quot;Warning:: Picked up error in TriangleIntersect&amp;quot; messages in the terminal or log file, you can disable this by starting FlightGear with &amp;quot;--prop:/sim/rendering/osg-notify-level=fatal&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Q:''' Why are the windows getting foggy/frosty?&lt;br /&gt;
&lt;br /&gt;
'''A:''' If the dew point of the cabin air temperature is higher than the surface temperature of the windshield, the windows will get either foggy or frosty. Use the Cabin Heat and Cabin Air levers (on the right of the flaps) to control it. The dew point rises with the temperature in the cabin, and it rises faster than the windshield temperature can adjust, resulting in temporary fog. If the air is very humid, the dew point is going to be very close to the cabin temperature, which makes it likely that it will be higher than the windshield temperature. Extra passengers will create a more humid atmosphere in the cabin. Try to increase air flow using the Cabin Air lever or overhead air vents in order to decrease the humidity or temperature. Alternatively, disable the effect by going to the menu &amp;quot;Cessna 172P&amp;quot;, selecting &amp;quot;Aircraft Options&amp;quot; and disable the option &amp;quot;Enable frost and fog&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Q:''' How do I increase the cabin air temperature?&lt;br /&gt;
&lt;br /&gt;
'''A:''' Increase the cabin air temperature by opening the Cabin Heat lever. In order to actually get a heated air flow, you need a medium or high EGT (Exhaust Gas Temperature -- the instrument between the yoke and the ADF instrument), and airspeed and/or sufficient propeller RPM.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Q:''' How can I click on a switch which is being covered by the yoke?&lt;br /&gt;
&lt;br /&gt;
'''A:''' You can hide the yokes by clicking on them or by going to the menu &amp;quot;Cessna 172P&amp;quot;, selecting &amp;quot;Hide/Show Yokes&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
== Development status/Issues/TODO ==&lt;br /&gt;
&lt;br /&gt;
This aircraft is undergoing a constant development, which can be followed on its [https://github.com/Juanvvc/c172p-detailed repository], where a [https://github.com/Juanvvc/c172p-detailed/issues list of issues and future enhancements] can also be found.&lt;br /&gt;
&lt;br /&gt;
== Gallery ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;gallery mode=&amp;quot;packed&amp;quot;&amp;gt;&lt;br /&gt;
c172p-plane5.jpg|Cessna 172P above Chapada Diamantina in Brazil&lt;br /&gt;
c172p-plane4.jpg|Taking off from Compiegne Margny (LFAD)&lt;br /&gt;
c172p-cockpit2.jpg|About to land, showing the new ALS shadow effects in the cockpit&lt;br /&gt;
c172p-floats.jpg|Float variant in San Francisco&lt;br /&gt;
c172p-plane3.jpg|Cessna 172P at high altitude flying over Lago di Garda in Italy&lt;br /&gt;
c172p-landing.jpg|On final at Aosta Airport (LIMW)&lt;br /&gt;
c172p-cockpit3.jpg|The fully textured interiors of the new c172p&lt;br /&gt;
c172p-night.jpg|A night flight, showing the instrument illumination&lt;br /&gt;
c172p-particles.jpg|Taking off on water, showing the particle system&lt;br /&gt;
c172p-plane1.jpg|Above Serra do Mar in Brazil&lt;br /&gt;
c172p-plane2.jpg|Flying at sunset&lt;br /&gt;
c172p-winter.jpg|European winter&lt;br /&gt;
c172p-damage.jpg|Gear collapse due to heavy landing&lt;br /&gt;
c172p-frost.jpg|If the conditions are just right, frost or fog will appear in the windows&lt;br /&gt;
c172p-taubate.jpg|Flying above Taubate, Brazil&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== External links ==&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Cessna_172 Wikipedia article]&lt;br /&gt;
* [http://www.atlasaviation.com/checklists/cessna-172/cessna_172_checklist.htm Cessna 172 checklists at AtlasAviation.com]&lt;br /&gt;
&lt;br /&gt;
{{Appendix}}&lt;br /&gt;
&lt;br /&gt;
{{Cessna}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Civil utility aircraft]]&lt;br /&gt;
[[Category:High wing aircraft]]&lt;br /&gt;
[[Category:Propeller aircraft]]&lt;br /&gt;
[[Category:Single-engine aircraft]]&lt;br /&gt;
[[Category:Interactive Tutorial Support]]&lt;br /&gt;
[[Category:Aircraft with a cockpit-only autopilot]]&lt;br /&gt;
[[Category:Aircraft with Checklists]]&lt;br /&gt;
[[fr:Cessna 172]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=FlightGear_Newsletter_June_2015&amp;diff=85328</id>
		<title>FlightGear Newsletter June 2015</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=FlightGear_Newsletter_June_2015&amp;diff=85328"/>
		<updated>2015-06-02T13:27:17Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{draft|newsletter|Please feel free to add content you think will be of interest to the FlightGear community. You can read the latest newsletter at [[FlightGear Newsletter May 2015]].}}&lt;br /&gt;
&lt;br /&gt;
{{Newsletter-header|June 2015}}&lt;br /&gt;
&amp;lt;div style=&amp;quot;border-bottom:3px double #BBB;&amp;quot;&amp;gt;&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; |&lt;br /&gt;
 | valign=&amp;quot;top&amp;quot; width=&amp;quot;33%&amp;quot; |&lt;br /&gt;
{{Newsletter-cover-header|Development news}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Random splash screens|Random splash screens]]&amp;lt;br/&amp;gt;&lt;br /&gt;
 | valign=&amp;quot;top&amp;quot; width=&amp;quot;33%&amp;quot; |&lt;br /&gt;
{{Newsletter-cover-header|In the hangar}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Space Shuttle|Space Shuttle developement]]&amp;lt;br/&amp;gt;&lt;br /&gt;
{{Newsletter-cover-header|Scenery Corner}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Großenhain Airfield|Großenhain Airfield]]&amp;lt;br/&amp;gt;&lt;br /&gt;
{{Newsletter-cover-header|Community News}}&amp;lt;br/&amp;gt;&lt;br /&gt;
 | valign=&amp;quot;top&amp;quot; width=&amp;quot;33%&amp;quot; |&lt;br /&gt;
{{Newsletter-cover-header|Contributing}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Translators required|Translators required]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#FlightGear logos|FlightGear logos]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Screenshots|Screenshots]]&lt;br /&gt;
|}&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Development News ==&lt;br /&gt;
&lt;br /&gt;
=== Random splash screens ===&lt;br /&gt;
&lt;br /&gt;
It is now possible to add multiple splash screens for an aircraft. When starting FlightGear, one of the splash screens is randomly chosen and shown on the screen. To add multiple splash screen, simply add multiple &amp;lt;splash-texture&amp;gt; tags. For example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;startup&amp;gt;&lt;br /&gt;
    &amp;lt;splash-texture&amp;gt;Aircraft/c172p/splash1.png&amp;lt;/splash-texture&amp;gt;&lt;br /&gt;
    &amp;lt;splash-texture&amp;gt;Aircraft/c172p/splash2.png&amp;lt;/splash-texture&amp;gt;&lt;br /&gt;
    &amp;lt;splash-texture&amp;gt;Aircraft/c172p/splash3.png&amp;lt;/splash-texture&amp;gt;&lt;br /&gt;
    &amp;lt;splash-texture&amp;gt;Aircraft/c172p/splash4.png&amp;lt;/splash-texture&amp;gt;&lt;br /&gt;
&amp;lt;/startup&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can add as many splash screens as you want.&lt;br /&gt;
&lt;br /&gt;
== In the Hangar ==&lt;br /&gt;
=== Space Shuttle ===&lt;br /&gt;
Jajpreja is now modelling the landing gear for the Shuttle.&lt;br /&gt;
[[File:Spaceshuttlegear.png|200px|center]]&lt;br /&gt;
&lt;br /&gt;
== Scenery Corner ==&lt;br /&gt;
&lt;br /&gt;
=== Großenhain Airfield ===&lt;br /&gt;
[[File:FGFS_EDAK_APRON_2015.jpg|600px|Apron of [[Grossenhain_Airfield|Großenhain Airfield]]]]&amp;lt;br /&amp;gt;&lt;br /&gt;
Custom [http://www.mediafire.com/download/d0rb8ko7864t4cu/FGscenery_Saxony.zip FGscenery_Saxony] package has new content. For [[Grossenhain Airfield]] (EDAK) the package contains a custom airport layout (scenery tile), static buildings and airport data. You can download this custom scenery file from the [[Grossenhain_Airfield#Scenery_Add-on|Grossenhain Airfield]] wiki page.&amp;lt;br /&amp;gt;&lt;br /&gt;
We wish you happy flying!&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== New Regional Textures ===&lt;br /&gt;
This project aims to create new regional textures, particularly for the Southern Hemisphere. Currently, the whole Africa (desert, savanna, rainforest and Mediterranean regions) as well as parts of South America (rainforest) and Southeast Asia (rainforest) have new textures and materials (including new urban textures). Repository link: https://github.com/gilbertohasnofb/new-regional-textures and development thread: http://forum.flightgear.org/viewtopic.php?f=5&amp;amp;t=26031&lt;br /&gt;
[[File:New_Regional_Textures.jpg|900px|center]]&lt;br /&gt;
&lt;br /&gt;
== Community News ==&lt;br /&gt;
&lt;br /&gt;
== Contributing ==&lt;br /&gt;
=== Translators required ===&lt;br /&gt;
{|&lt;br /&gt;
| [[File:en.gif]]&lt;br /&gt;
| The FlightGear Wiki still needs help for translating it into various languages. If you are interested in making the FlightGear Wiki multi-language then start at [[Help:Translate]].&lt;br /&gt;
|-&lt;br /&gt;
| [[File:de.gif]]&lt;br /&gt;
| Das FlightGear Wiki benötigt immer noch Hilfe bei der Übersetzung in verschiedene Sprachen. Wenn Du Interesse daran hast, das FlightGear Wiki Mehrsprachig zu machen, dann fang doch mit [[:de:Help:Übersetzen|Help:Übersetzen]] an.&lt;br /&gt;
|-&lt;br /&gt;
| [[File:nl.gif]]&lt;br /&gt;
| De FlightGear Wiki kan nog steed hulp gebruiken bij het vertalen van artikelen. Als je interesse hebt om de wiki meertalig te maken, raden we je aan om een kijkje te nemen bij [[:nl:Help:Vertalen|Help:Vertalen]].&lt;br /&gt;
|-&lt;br /&gt;
| [[File:es.gif]]&lt;br /&gt;
| La wiki de FlightGear todavía necesita ayuda para traducirla a varios lenguajes. Si estás interesado en hacer la FlightGear wiki multilingüe, entonces comienza en [[:es:Help:Traducir|Help:Traducir]].&lt;br /&gt;
|-&lt;br /&gt;
| [[File:cat.gif]]&lt;br /&gt;
| La wiki de FlightGear encara necessita ajuda per traduir-la a diverses llengües. Si esteu interessat en fer la wiki de FlightGear multilingüe, llavors comenceu a [[:ca:Help:Traduir|Help:Traduir]].&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== FlightGear logos ===&lt;br /&gt;
If you want some graphic elements for your FlightGear-related site (such as a hangar or YouTube channel), please feel free to visit [[FlightGear logos]] for a repository of logos.  And if you have some art skills, please don't hesitate to contribute with your own design creations.&lt;br /&gt;
&lt;br /&gt;
=== Screenshots ===&lt;br /&gt;
The FlightGear project always needs screenshots, which show features that were added since the last release.  These should be of good quality, especially in content and technical image properties.  It is therefore recommended to use the best viable filter settings ([[anti-aliasing]], texture sharpening, etc.).  More info at [[Howto:Make nice screenshots]].&lt;br /&gt;
&lt;br /&gt;
[[Category:FlightGear Newsletter|2015 05]]&lt;br /&gt;
[[Category:Changes after 3.4]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=FlightGear_Newsletter_May_2015&amp;diff=85213</id>
		<title>FlightGear Newsletter May 2015</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=FlightGear_Newsletter_May_2015&amp;diff=85213"/>
		<updated>2015-05-30T18:50:24Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{draft|newsletter|Please feel free to add content you think will be of interest to the FlightGear community. You can read the latest newsletter at [[FlightGear Newsletter March 2015]].}}&lt;br /&gt;
&lt;br /&gt;
{{Newsletter-header|May 2015}}&lt;br /&gt;
&amp;lt;div style=&amp;quot;border-bottom:3px double #BBB;&amp;quot;&amp;gt;&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; |&lt;br /&gt;
 | valign=&amp;quot;top&amp;quot; width=&amp;quot;33%&amp;quot; |&lt;br /&gt;
{{Newsletter-cover-header|Development news}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Exhaust flames|Exhaust flames]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Automated checklist execution|Automated checklist execution]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Submodel enhancements|Submodel enhancements]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Sound position fixes|Sound position fixes]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Nasal/Canvas: A simple tiled map|Nasal/Canvas: A simple tiled map]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#New (4th!) ATC-pie release|New ATC-pie release]]&lt;br /&gt;
 | valign=&amp;quot;top&amp;quot; width=&amp;quot;33%&amp;quot; |&lt;br /&gt;
{{Newsletter-cover-header|In the hanger}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Amphibious variant of the C172p|Amphibious variant of the C172p]]&amp;lt;br/&amp;gt;&lt;br /&gt;
{{Newsletter-cover-header|Scenery Corner}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Scenery Project Elba|Scenery Project Elba]]&amp;lt;br/&amp;gt;&lt;br /&gt;
{{Newsletter-cover-header|Community News}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#The Festival of FlightGear 2015 (1/2) - 2 &amp;amp; 3 May|The Festival of FlightGear 2015 (1/2) - 2 &amp;amp; 3 May]]&amp;lt;br/&amp;gt;&lt;br /&gt;
 | valign=&amp;quot;top&amp;quot; width=&amp;quot;33%&amp;quot; |&lt;br /&gt;
{{Newsletter-cover-header|Contributing}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Translators required|Translators required]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#FlightGear logos|FlightGear logos]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Screenshots|Screenshots]]&lt;br /&gt;
|}&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Development News ==&lt;br /&gt;
=== Exhaust flames ===&lt;br /&gt;
The latest addition to the Atmospheric Light Scattering framework is  a procedural shader effect to render thruster and afterburner exhaust flames. This effect integrates over a 3d-distribution of glowing emitters in a bounding box, which means that it doesn't generate sharp edges in the visuals.&lt;br /&gt;
&lt;br /&gt;
Flame color, density, distribution of shock diamonds and widening in thin atmosphere are all runtime configurable, allowing to account realistically for changed thrust or ambient pressure.&lt;br /&gt;
&lt;br /&gt;
Here's an example application for the [[SpaceShuttle - Project Overview|Space Shuttle]] main engine - note how the exhaust plume is narrow early on and shows pronounced shock diamonds while it widens in the thin upper atmosphere:&lt;br /&gt;
&lt;br /&gt;
[[File:Shuttle flame05.jpg|400px|Space Shuttle main engine flames during early ascent]]&lt;br /&gt;
[[File:Shuttle flame06.jpg|400px|Space Shuttle main engine flames during late ascent]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
See the [[ALS technical notes#The exhaust flame effect|ALS exhaust flame effect]] for details.&lt;br /&gt;
&lt;br /&gt;
=== Automated checklist execution ===&lt;br /&gt;
{{FGCquote&lt;br /&gt;
  |As part of the development of the Lockheed 1049h Constellation, I created a comprehensive set of checklists based on the crew operating manual with other items added sufficient to take the aircraft through all stages of flight. Rather than hand-code an autostart script I wrote a more generic script to run checklist bindings in sequence. This script is now available in FGDATA and can be used on other aircraft:&amp;lt;br/&amp;gt;&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
[[Aircraft_Checklists#Automated_checklist_execution|Wiki: Automated Checklist Execution]]&amp;lt;br/&amp;gt;&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
If you are thinking about writing an autostart menu, you might want to consider using this script and driving the autostart from the checklists. It's not restricted to autostart, you can essentially run any sequence of checklists from any piece of Nasal code.&amp;lt;br/&amp;gt;&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
You can see the script in action in the latest [https://sourceforge.net/p/flightgear/fgaddon/HEAD/tree/trunk/Aircraft/Lockheed1049h/ Lockheed 1049h]. Note that you need a recent copy of [https://sourceforge.net/p/flightgear/fgdata/ci/next/tree/ FGDATA] for this to work. The autostart in this case is intelligent enough to run different checklist sequences depending on whether you are starting on a runway, at the terminal or in the air and also uses automated checklist execution to run an &amp;quot;After Landing&amp;quot; checklist from a keyboard shortcut during that busy time of rollout and taxi.&lt;br /&gt;
  |{{cite web |url=http://forum.flightgear.org/viewtopic.php?p=241203&amp;amp;sid=4bad6d92dab1d411ea46e6efb1b8850c#p241203&lt;br /&gt;
     |title=&amp;lt;nowiki&amp;gt;Automated Checklist Execution&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
     |author=&amp;lt;nowiki&amp;gt;sanhozay&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
     |date=&amp;lt;nowiki&amp;gt;Fri May 01&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
   }}&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Submodel enhancements ===&lt;br /&gt;
&lt;br /&gt;
It is now possible to adjust various offsets, including heading and pitch, during runtime. Furthermore, the x, y, and z offsets can be defined in metric units. Finally, the randomness of the azimuth (heading), elevation (pitch), Cd, and life can be defined. See http://wiki.flightgear.org/Howto:Add_submodels#Step_2_of_6:_Define_the_position_and_orientation&lt;br /&gt;
&lt;br /&gt;
[[File:Submodel-offset.png|800px|A Phalanx CIWS shooting at an extraterrestrial weather balloon. The orange tracer bullets are submodels. The red line is a scaled model representing the aiming orientation of the Phalanx. ]]&lt;br /&gt;
&lt;br /&gt;
=== Sound position fixes ===&lt;br /&gt;
&lt;br /&gt;
The sound subsystem has been given some fixes so that the distance between the position of the current view and the sound's position is correctly computed.&lt;br /&gt;
&lt;br /&gt;
=== Nasal/Canvas: A simple tiled map ===&lt;br /&gt;
Using the [[Canvas GUI]], you can make a simple tiled map using images downloaded on the fly  You can view the code behind the map at [[Canvas Snippets#A simple tile map]].&lt;br /&gt;
&lt;br /&gt;
[[File:Canvas - Tile map demo.png|A simple, canvas based tile map which is centered around the aircraft.]]&lt;br /&gt;
&lt;br /&gt;
=== New (4th!) ATC-pie release ===&lt;br /&gt;
[[File:ATC-pie-logo.png|200px|left|ATC-pie logo.]]&lt;br /&gt;
[[ATC-pie]] now provides a '''solo training mode''' for ATCs. Using the same interface as the multi-player game mode and an additional instruction pane, you can choose to play offline and control virtual aircraft as Tower, Approach, Departure, or any combination of those positions. As MP traffic still can be scarce in many occasions on our network, this new game mode can be a solution for you not to give up on a planned session and give yourself some challenge. Also, you may learn from it enough to make your own MP sessions more popular over the network!&lt;br /&gt;
&lt;br /&gt;
The main features are:&lt;br /&gt;
* Free combination choice of APP, TWR and DEP control positions for custom training&lt;br /&gt;
* Handovers to/from virtual ATCs&lt;br /&gt;
* Instruction interface and pilot read back&lt;br /&gt;
* Adjustable difficulty (traffic density)&lt;br /&gt;
* Departure–arrival and ILS–visual balance options&lt;br /&gt;
* Configurable runways in use, entry and exit points&lt;br /&gt;
&lt;br /&gt;
See the [[ATC-pie|wiki page]] for more!&lt;br /&gt;
&lt;br /&gt;
== In the Hangar ==&lt;br /&gt;
&lt;br /&gt;
=== Amphibious variant of the C172p ===&lt;br /&gt;
&lt;br /&gt;
The c172p-detailed aircraft has been given a variant with pontoons (optionally with wheels) so that it can land on water. The aircraft will replace the old c172p in FlightGear 3.6.&lt;br /&gt;
&lt;br /&gt;
[[File:C172p-amphibious.jpg|800px|An amphibious variant of the C172p.]]&lt;br /&gt;
&lt;br /&gt;
== Scenery Corner ==&lt;br /&gt;
=== Scenery Project Elba ===&lt;br /&gt;
The Scenery Project Elba has been started, aiming to improve the scenery of Elba, an island west of Italy. More information can be found on the wiki page: [[Scenery Project Elba]]. Contributions welcome! Development thread: http://forum.flightgear.org/viewtopic.php?f=5&amp;amp;t=26138&amp;lt;br/&amp;gt;&lt;br /&gt;
[[File:Elba.jpg|900px|center]]&lt;br /&gt;
&lt;br /&gt;
== Community News ==&lt;br /&gt;
=== The Festival of FlightGear 2015 (1/2) - 2 &amp;amp; 3 May ===&lt;br /&gt;
Time: All weekend Sat 00:00-Sun 23:59&lt;br /&gt;
Location: Argentina/Brazil (SBRJ/SBGL and south)&lt;br /&gt;
&lt;br /&gt;
== Contributing ==&lt;br /&gt;
=== Translators required ===&lt;br /&gt;
{|&lt;br /&gt;
| [[File:en.gif]]&lt;br /&gt;
| The FlightGear Wiki still needs help for translating it into various languages. If you are interested in making the FlightGear Wiki multi-language then start at [[Help:Translate]].&lt;br /&gt;
|-&lt;br /&gt;
| [[File:de.gif]]&lt;br /&gt;
| Das FlightGear Wiki benötigt immer noch Hilfe bei der Übersetzung in verschiedene Sprachen. Wenn Du Interesse daran hast, das FlightGear Wiki Mehrsprachig zu machen, dann fang doch mit [[:de:Help:Übersetzen|Help:Übersetzen]] an.&lt;br /&gt;
|-&lt;br /&gt;
| [[File:nl.gif]]&lt;br /&gt;
| De FlightGear Wiki kan nog steed hulp gebruiken bij het vertalen van artikelen. Als je interesse hebt om de wiki meertalig te maken, raden we je aan om een kijkje te nemen bij [[:nl:Help:Vertalen|Help:Vertalen]].&lt;br /&gt;
|-&lt;br /&gt;
| [[File:es.gif]]&lt;br /&gt;
| La wiki de FlightGear todavía necesita ayuda para traducirla a varios lenguajes. Si estás interesado en hacer la FlightGear wiki multilingüe, entonces comienza en [[:es:Help:Traducir|Help:Traducir]].&lt;br /&gt;
|-&lt;br /&gt;
| [[File:cat.gif]]&lt;br /&gt;
| La wiki de FlightGear encara necessita ajuda per traduir-la a diverses llengües. Si esteu interessat en fer la wiki de FlightGear multilingüe, llavors comenceu a [[:ca:Help:Traduir|Help:Traduir]].&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== FlightGear logos ===&lt;br /&gt;
If you want some graphic elements for your FlightGear-related site (such as a hangar or YouTube channel), please feel free to visit [[FlightGear logos]] for a repository of logos.  And if you have some art skills, please don't hesitate to contribute with your own design creations.&lt;br /&gt;
&lt;br /&gt;
=== Screenshots ===&lt;br /&gt;
The FlightGear project always needs screenshots, which show features that were added since the last release.  These should be of good quality, especially in content and technical image properties.  It is therefore recommended to use the best viable filter settings ([[anti-aliasing]], texture sharpening, etc.).  More info at [[Howto:Make nice screenshots]].&lt;br /&gt;
&lt;br /&gt;
[[Category:FlightGear Newsletter|2015 05]]&lt;br /&gt;
[[Category:Changes after 3.4]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=File:C172p-amphibious.jpg&amp;diff=85212</id>
		<title>File:C172p-amphibious.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=File:C172p-amphibious.jpg&amp;diff=85212"/>
		<updated>2015-05-30T18:43:44Z</updated>

		<summary type="html">&lt;p&gt;Onox: An amphibious version of the C172p.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Summary ==&lt;br /&gt;
An amphibious version of the C172p.&lt;br /&gt;
== Licensing ==&lt;br /&gt;
{{self|cc-by-sa-3.0}}&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=FlightGear_Newsletter_May_2015&amp;diff=85209</id>
		<title>FlightGear Newsletter May 2015</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=FlightGear_Newsletter_May_2015&amp;diff=85209"/>
		<updated>2015-05-30T18:31:29Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{draft|newsletter|Please feel free to add content you think will be of interest to the FlightGear community. You can read the latest newsletter at [[FlightGear Newsletter March 2015]].}}&lt;br /&gt;
&lt;br /&gt;
{{Newsletter-header|May 2015}}&lt;br /&gt;
&amp;lt;div style=&amp;quot;border-bottom:3px double #BBB;&amp;quot;&amp;gt;&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; |&lt;br /&gt;
 | valign=&amp;quot;top&amp;quot; width=&amp;quot;33%&amp;quot; |&lt;br /&gt;
{{Newsletter-cover-header|Development news}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Exhaust flames|Exhaust flames]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Automated checklist execution|Automated checklist execution]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Submodel enhancements|Submodel enhancements]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Sound position fixes|Sound position fixes]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Nasal/Canvas: A simple tiled map|Nasal/Canvas: A simple tiled map]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#New (4th!) ATC-pie release|New ATC-pie release]]&lt;br /&gt;
 | valign=&amp;quot;top&amp;quot; width=&amp;quot;33%&amp;quot; |&lt;br /&gt;
{{Newsletter-cover-header|In the hanger}}&amp;lt;br/&amp;gt;&lt;br /&gt;
{{Newsletter-cover-header|Scenery Corner}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Scenery Project Elba|Scenery Project Elba]]&amp;lt;br/&amp;gt;&lt;br /&gt;
{{Newsletter-cover-header|Community News}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#The Festival of FlightGear 2015 (1/2) - 2 &amp;amp; 3 May|The Festival of FlightGear 2015 (1/2) - 2 &amp;amp; 3 May]]&amp;lt;br/&amp;gt;&lt;br /&gt;
 | valign=&amp;quot;top&amp;quot; width=&amp;quot;33%&amp;quot; |&lt;br /&gt;
{{Newsletter-cover-header|Contributing}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Translators required|Translators required]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#FlightGear logos|FlightGear logos]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Screenshots|Screenshots]]&lt;br /&gt;
|}&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Development News ==&lt;br /&gt;
=== Exhaust flames ===&lt;br /&gt;
The latest addition to the Atmospheric Light Scattering framework is  a procedural shader effect to render thruster and afterburner exhaust flames. This effect integrates over a 3d-distribution of glowing emitters in a bounding box, which means that it doesn't generate sharp edges in the visuals.&lt;br /&gt;
&lt;br /&gt;
Flame color, density, distribution of shock diamonds and widening in thin atmosphere are all runtime configurable, allowing to account realistically for changed thrust or ambient pressure.&lt;br /&gt;
&lt;br /&gt;
Here's an example application for the [[SpaceShuttle - Project Overview|Space Shuttle]] main engine - note how the exhaust plume is narrow early on and shows pronounced shock diamonds while it widens in the thin upper atmosphere:&lt;br /&gt;
&lt;br /&gt;
[[File:Shuttle flame05.jpg|400px|Space Shuttle main engine flames during early ascent]]&lt;br /&gt;
[[File:Shuttle flame06.jpg|400px|Space Shuttle main engine flames during late ascent]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
See the [[ALS technical notes#The exhaust flame effect|ALS exhaust flame effect]] for details.&lt;br /&gt;
&lt;br /&gt;
=== Automated checklist execution ===&lt;br /&gt;
{{FGCquote&lt;br /&gt;
  |As part of the development of the Lockheed 1049h Constellation, I created a comprehensive set of checklists based on the crew operating manual with other items added sufficient to take the aircraft through all stages of flight. Rather than hand-code an autostart script I wrote a more generic script to run checklist bindings in sequence. This script is now available in FGDATA and can be used on other aircraft:&amp;lt;br/&amp;gt;&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
[[Aircraft_Checklists#Automated_checklist_execution|Wiki: Automated Checklist Execution]]&amp;lt;br/&amp;gt;&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
If you are thinking about writing an autostart menu, you might want to consider using this script and driving the autostart from the checklists. It's not restricted to autostart, you can essentially run any sequence of checklists from any piece of Nasal code.&amp;lt;br/&amp;gt;&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
You can see the script in action in the latest [https://sourceforge.net/p/flightgear/fgaddon/HEAD/tree/trunk/Aircraft/Lockheed1049h/ Lockheed 1049h]. Note that you need a recent copy of [https://sourceforge.net/p/flightgear/fgdata/ci/next/tree/ FGDATA] for this to work. The autostart in this case is intelligent enough to run different checklist sequences depending on whether you are starting on a runway, at the terminal or in the air and also uses automated checklist execution to run an &amp;quot;After Landing&amp;quot; checklist from a keyboard shortcut during that busy time of rollout and taxi.&lt;br /&gt;
  |{{cite web |url=http://forum.flightgear.org/viewtopic.php?p=241203&amp;amp;sid=4bad6d92dab1d411ea46e6efb1b8850c#p241203&lt;br /&gt;
     |title=&amp;lt;nowiki&amp;gt;Automated Checklist Execution&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
     |author=&amp;lt;nowiki&amp;gt;sanhozay&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
     |date=&amp;lt;nowiki&amp;gt;Fri May 01&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
   }}&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Submodel enhancements ===&lt;br /&gt;
&lt;br /&gt;
It is now possible to adjust various offsets, including heading and pitch, during runtime. Furthermore, the x, y, and z offsets can be defined in metric units. Finally, the randomness of the azimuth (heading), elevation (pitch), Cd, and life can be defined. See http://wiki.flightgear.org/Howto:Add_submodels#Step_2_of_6:_Define_the_position_and_orientation&lt;br /&gt;
&lt;br /&gt;
[[File:Submodel-offset.png|800px|A Phalanx CIWS shooting at an extraterrestrial weather balloon. The orange tracer bullets are submodels. The red line is a scaled model representing the aiming orientation of the Phalanx. ]]&lt;br /&gt;
&lt;br /&gt;
=== Sound position fixes ===&lt;br /&gt;
&lt;br /&gt;
The sound subsystem has been given some fixes so that the distance between the position of the current view and the sound's position is correctly computed.&lt;br /&gt;
&lt;br /&gt;
=== Nasal/Canvas: A simple tiled map ===&lt;br /&gt;
Using the [[Canvas GUI]], you can make a simple tiled map using images downloaded on the fly  You can view the code behind the map at [[Canvas Snippets#A simple tile map]].&lt;br /&gt;
&lt;br /&gt;
[[File:Canvas - Tile map demo.png|A simple, canvas based tile map which is centered around the aircraft.]]&lt;br /&gt;
&lt;br /&gt;
=== New (4th!) ATC-pie release ===&lt;br /&gt;
[[File:ATC-pie-logo.png|200px|left|ATC-pie logo.]]&lt;br /&gt;
[[ATC-pie]] now provides a '''solo training mode''' for ATCs. Using the same interface as the multi-player game mode and an additional instruction pane, you can choose to play offline and control virtual aircraft as Tower, Approach, Departure, or any combination of those positions. As MP traffic still can be scarce in many occasions on our network, this new game mode can be a solution for you not to give up on a planned session and give yourself some challenge. Also, you may learn from it enough to make your own MP sessions more popular over the network!&lt;br /&gt;
&lt;br /&gt;
The main features are:&lt;br /&gt;
* Free combination choice of APP, TWR and DEP control positions for custom training&lt;br /&gt;
* Handovers to/from virtual ATCs&lt;br /&gt;
* Instruction interface and pilot read back&lt;br /&gt;
* Adjustable difficulty (traffic density)&lt;br /&gt;
* Departure–arrival and ILS–visual balance options&lt;br /&gt;
* Configurable runways in use, entry and exit points&lt;br /&gt;
&lt;br /&gt;
See the [[ATC-pie|wiki page]] for more!&lt;br /&gt;
&lt;br /&gt;
== Scenery Corner ==&lt;br /&gt;
=== Scenery Project Elba ===&lt;br /&gt;
The Scenery Project Elba has been started, aiming to improve the scenery of Elba, an island west of Italy. More information can be found on the wiki page: [[Scenery Project Elba]]. Contributions welcome! Development thread: http://forum.flightgear.org/viewtopic.php?f=5&amp;amp;t=26138&amp;lt;br/&amp;gt;&lt;br /&gt;
[[File:Elba.jpg|900px|center]]&lt;br /&gt;
&lt;br /&gt;
== Community News ==&lt;br /&gt;
=== The Festival of FlightGear 2015 (1/2) - 2 &amp;amp; 3 May ===&lt;br /&gt;
Time: All weekend Sat 00:00-Sun 23:59&lt;br /&gt;
Location: Argentina/Brazil (SBRJ/SBGL and south)&lt;br /&gt;
&lt;br /&gt;
== Contributing ==&lt;br /&gt;
=== Translators required ===&lt;br /&gt;
{|&lt;br /&gt;
| [[File:en.gif]]&lt;br /&gt;
| The FlightGear Wiki still needs help for translating it into various languages. If you are interested in making the FlightGear Wiki multi-language then start at [[Help:Translate]].&lt;br /&gt;
|-&lt;br /&gt;
| [[File:de.gif]]&lt;br /&gt;
| Das FlightGear Wiki benötigt immer noch Hilfe bei der Übersetzung in verschiedene Sprachen. Wenn Du Interesse daran hast, das FlightGear Wiki Mehrsprachig zu machen, dann fang doch mit [[:de:Help:Übersetzen|Help:Übersetzen]] an.&lt;br /&gt;
|-&lt;br /&gt;
| [[File:nl.gif]]&lt;br /&gt;
| De FlightGear Wiki kan nog steed hulp gebruiken bij het vertalen van artikelen. Als je interesse hebt om de wiki meertalig te maken, raden we je aan om een kijkje te nemen bij [[:nl:Help:Vertalen|Help:Vertalen]].&lt;br /&gt;
|-&lt;br /&gt;
| [[File:es.gif]]&lt;br /&gt;
| La wiki de FlightGear todavía necesita ayuda para traducirla a varios lenguajes. Si estás interesado en hacer la FlightGear wiki multilingüe, entonces comienza en [[:es:Help:Traducir|Help:Traducir]].&lt;br /&gt;
|-&lt;br /&gt;
| [[File:cat.gif]]&lt;br /&gt;
| La wiki de FlightGear encara necessita ajuda per traduir-la a diverses llengües. Si esteu interessat en fer la wiki de FlightGear multilingüe, llavors comenceu a [[:ca:Help:Traduir|Help:Traduir]].&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== FlightGear logos ===&lt;br /&gt;
If you want some graphic elements for your FlightGear-related site (such as a hangar or YouTube channel), please feel free to visit [[FlightGear logos]] for a repository of logos.  And if you have some art skills, please don't hesitate to contribute with your own design creations.&lt;br /&gt;
&lt;br /&gt;
=== Screenshots ===&lt;br /&gt;
The FlightGear project always needs screenshots, which show features that were added since the last release.  These should be of good quality, especially in content and technical image properties.  It is therefore recommended to use the best viable filter settings ([[anti-aliasing]], texture sharpening, etc.).  More info at [[Howto:Make nice screenshots]].&lt;br /&gt;
&lt;br /&gt;
[[Category:FlightGear Newsletter|2015 05]]&lt;br /&gt;
[[Category:Changes after 3.4]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=File:Submodel-offset.png&amp;diff=85206</id>
		<title>File:Submodel-offset.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=File:Submodel-offset.png&amp;diff=85206"/>
		<updated>2015-05-30T18:26:46Z</updated>

		<summary type="html">&lt;p&gt;Onox: A Phalanx CIWS shooting at an extraterrestrial weather balloon. The orange tracer bullets are submodels. The red line is a scaled model representing the aiming orientation of the Phalanx.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Summary ==&lt;br /&gt;
A Phalanx CIWS shooting at an extraterrestrial weather balloon. The orange tracer bullets are submodels. The red line is a scaled model representing the aiming orientation of the Phalanx. &lt;br /&gt;
== Licensing ==&lt;br /&gt;
{{self|cc-by-sa-3.0}}&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=FlightGear_Newsletter_May_2015&amp;diff=85205</id>
		<title>FlightGear Newsletter May 2015</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=FlightGear_Newsletter_May_2015&amp;diff=85205"/>
		<updated>2015-05-30T18:00:19Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{draft|newsletter|Please feel free to add content you think will be of interest to the FlightGear community. You can read the latest newsletter at [[FlightGear Newsletter March 2015]].}}&lt;br /&gt;
&lt;br /&gt;
{{Newsletter-header|May 2015}}&lt;br /&gt;
&amp;lt;div style=&amp;quot;border-bottom:3px double #BBB;&amp;quot;&amp;gt;&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; |&lt;br /&gt;
 | valign=&amp;quot;top&amp;quot; width=&amp;quot;33%&amp;quot; |&lt;br /&gt;
{{Newsletter-cover-header|Development news}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Exhaust flames|Exhaust flames]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Automated checklist execution|Automated checklist execution]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Submodel enhancements|Submodel enhancements]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Sound position fixes|Sound position fixes]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Nasal/Canvas: A simple tiled map|Nasal/Canvas: A simple tiled map]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#New (4th!) ATC-pie release|New ATC-pie release]]&lt;br /&gt;
 | valign=&amp;quot;top&amp;quot; width=&amp;quot;33%&amp;quot; |&lt;br /&gt;
{{Newsletter-cover-header|In the hanger}}&amp;lt;br/&amp;gt;&lt;br /&gt;
{{Newsletter-cover-header|Scenery Corner}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Scenery Project Elba|Scenery Project Elba]]&amp;lt;br/&amp;gt;&lt;br /&gt;
{{Newsletter-cover-header|Community News}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#The Festival of FlightGear 2015 (1/2) - 2 &amp;amp; 3 May|The Festival of FlightGear 2015 (1/2) - 2 &amp;amp; 3 May]]&amp;lt;br/&amp;gt;&lt;br /&gt;
 | valign=&amp;quot;top&amp;quot; width=&amp;quot;33%&amp;quot; |&lt;br /&gt;
{{Newsletter-cover-header|Contributing}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Translators required|Translators required]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#FlightGear logos|FlightGear logos]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Screenshots|Screenshots]]&lt;br /&gt;
|}&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Development News ==&lt;br /&gt;
=== Exhaust flames ===&lt;br /&gt;
The latest addition to the Atmospheric Light Scattering framework is  a procedural shader effect to render thruster and afterburner exhaust flames. This effect integrates over a 3d-distribution of glowing emitters in a bounding box, which means that it doesn't generate sharp edges in the visuals.&lt;br /&gt;
&lt;br /&gt;
Flame color, density, distribution of shock diamonds and widening in thin atmosphere are all runtime configurable, allowing to account realistically for changed thrust or ambient pressure.&lt;br /&gt;
&lt;br /&gt;
Here's an example application for the [[SpaceShuttle - Project Overview|Space Shuttle]] main engine - note how the exhaust plume is narrow early on and shows pronounced shock diamonds while it widens in the thin upper atmosphere:&lt;br /&gt;
&lt;br /&gt;
[[File:Shuttle flame05.jpg|400px|Space Shuttle main engine flames during early ascent]]&lt;br /&gt;
[[File:Shuttle flame06.jpg|400px|Space Shuttle main engine flames during late ascent]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
See the [[ALS technical notes#The exhaust flame effect|ALS exhaust flame effect]] for details.&lt;br /&gt;
&lt;br /&gt;
=== Automated checklist execution ===&lt;br /&gt;
{{FGCquote&lt;br /&gt;
  |As part of the development of the Lockheed 1049h Constellation, I created a comprehensive set of checklists based on the crew operating manual with other items added sufficient to take the aircraft through all stages of flight. Rather than hand-code an autostart script I wrote a more generic script to run checklist bindings in sequence. This script is now available in FGDATA and can be used on other aircraft:&amp;lt;br/&amp;gt;&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
[[Aircraft_Checklists#Automated_checklist_execution|Wiki: Automated Checklist Execution]]&amp;lt;br/&amp;gt;&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
If you are thinking about writing an autostart menu, you might want to consider using this script and driving the autostart from the checklists. It's not restricted to autostart, you can essentially run any sequence of checklists from any piece of Nasal code.&amp;lt;br/&amp;gt;&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
You can see the script in action in the latest [https://sourceforge.net/p/flightgear/fgaddon/HEAD/tree/trunk/Aircraft/Lockheed1049h/ Lockheed 1049h]. Note that you need a recent copy of [https://sourceforge.net/p/flightgear/fgdata/ci/next/tree/ FGDATA] for this to work. The autostart in this case is intelligent enough to run different checklist sequences depending on whether you are starting on a runway, at the terminal or in the air and also uses automated checklist execution to run an &amp;quot;After Landing&amp;quot; checklist from a keyboard shortcut during that busy time of rollout and taxi.&lt;br /&gt;
  |{{cite web |url=http://forum.flightgear.org/viewtopic.php?p=241203&amp;amp;sid=4bad6d92dab1d411ea46e6efb1b8850c#p241203&lt;br /&gt;
     |title=&amp;lt;nowiki&amp;gt;Automated Checklist Execution&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
     |author=&amp;lt;nowiki&amp;gt;sanhozay&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
     |date=&amp;lt;nowiki&amp;gt;Fri May 01&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
   }}&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Submodel enhancements ===&lt;br /&gt;
&lt;br /&gt;
It is now possible to adjust various offsets, including heading and pitch, during runtime. Furthermore, the x, y, and z offsets can be defined in metric units. Finally, the randomness of the azimuth (heading), elevation (pitch), Cd, and life can be defined. See http://wiki.flightgear.org/Howto:Add_submodels#Step_2_of_6:_Define_the_position_and_orientation&lt;br /&gt;
&lt;br /&gt;
=== Sound position fixes ===&lt;br /&gt;
&lt;br /&gt;
The sound subsystem has been given some fixes so that the distance between the position of the current view and the sound's position is correctly computed.&lt;br /&gt;
&lt;br /&gt;
=== Nasal/Canvas: A simple tiled map ===&lt;br /&gt;
Using the [[Canvas GUI]], you can make a simple tiled map using images downloaded on the fly  You can view the code behind the map at [[Canvas Snippets#A simple tile map]].&lt;br /&gt;
&lt;br /&gt;
[[File:Canvas - Tile map demo.png|A simple, canvas based tile map which is centered around the aircraft.]]&lt;br /&gt;
&lt;br /&gt;
=== New (4th!) ATC-pie release ===&lt;br /&gt;
[[File:ATC-pie-logo.png|200px|left|ATC-pie logo.]]&lt;br /&gt;
[[ATC-pie]] now provides a '''solo training mode''' for ATCs. Using the same interface as the multi-player game mode and an additional instruction pane, you can choose to play offline and control virtual aircraft as Tower, Approach, Departure, or any combination of those positions. As MP traffic still can be scarce in many occasions on our network, this new game mode can be a solution for you not to give up on a planned session and give yourself some challenge. Also, you may learn from it enough to make your own MP sessions more popular over the network!&lt;br /&gt;
&lt;br /&gt;
The main features are:&lt;br /&gt;
* Free combination choice of APP, TWR and DEP control positions for custom training&lt;br /&gt;
* Handovers to/from virtual ATCs&lt;br /&gt;
* Instruction interface and pilot read back&lt;br /&gt;
* Adjustable difficulty (traffic density)&lt;br /&gt;
* Departure–arrival and ILS–visual balance options&lt;br /&gt;
* Configurable runways in use, entry and exit points&lt;br /&gt;
&lt;br /&gt;
See the [[ATC-pie|wiki page]] for more!&lt;br /&gt;
&lt;br /&gt;
== Scenery Corner ==&lt;br /&gt;
=== Scenery Project Elba ===&lt;br /&gt;
The Scenery Project Elba has been started, aiming to improve the scenery of Elba, an island west of Italy. More information can be found on the wiki page: [[Scenery Project Elba]]. Contributions welcome! Development thread: http://forum.flightgear.org/viewtopic.php?f=5&amp;amp;t=26138&amp;lt;br/&amp;gt;&lt;br /&gt;
[[File:Elba.jpg|900px|center]]&lt;br /&gt;
&lt;br /&gt;
== Community News ==&lt;br /&gt;
=== The Festival of FlightGear 2015 (1/2) - 2 &amp;amp; 3 May ===&lt;br /&gt;
Time: All weekend Sat 00:00-Sun 23:59&lt;br /&gt;
Location: Argentina/Brazil (SBRJ/SBGL and south)&lt;br /&gt;
&lt;br /&gt;
== Contributing ==&lt;br /&gt;
=== Translators required ===&lt;br /&gt;
{|&lt;br /&gt;
| [[File:en.gif]]&lt;br /&gt;
| The FlightGear Wiki still needs help for translating it into various languages. If you are interested in making the FlightGear Wiki multi-language then start at [[Help:Translate]].&lt;br /&gt;
|-&lt;br /&gt;
| [[File:de.gif]]&lt;br /&gt;
| Das FlightGear Wiki benötigt immer noch Hilfe bei der Übersetzung in verschiedene Sprachen. Wenn Du Interesse daran hast, das FlightGear Wiki Mehrsprachig zu machen, dann fang doch mit [[:de:Help:Übersetzen|Help:Übersetzen]] an.&lt;br /&gt;
|-&lt;br /&gt;
| [[File:nl.gif]]&lt;br /&gt;
| De FlightGear Wiki kan nog steed hulp gebruiken bij het vertalen van artikelen. Als je interesse hebt om de wiki meertalig te maken, raden we je aan om een kijkje te nemen bij [[:nl:Help:Vertalen|Help:Vertalen]].&lt;br /&gt;
|-&lt;br /&gt;
| [[File:es.gif]]&lt;br /&gt;
| La wiki de FlightGear todavía necesita ayuda para traducirla a varios lenguajes. Si estás interesado en hacer la FlightGear wiki multilingüe, entonces comienza en [[:es:Help:Traducir|Help:Traducir]].&lt;br /&gt;
|-&lt;br /&gt;
| [[File:cat.gif]]&lt;br /&gt;
| La wiki de FlightGear encara necessita ajuda per traduir-la a diverses llengües. Si esteu interessat en fer la wiki de FlightGear multilingüe, llavors comenceu a [[:ca:Help:Traduir|Help:Traduir]].&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== FlightGear logos ===&lt;br /&gt;
If you want some graphic elements for your FlightGear-related site (such as a hangar or YouTube channel), please feel free to visit [[FlightGear logos]] for a repository of logos.  And if you have some art skills, please don't hesitate to contribute with your own design creations.&lt;br /&gt;
&lt;br /&gt;
=== Screenshots ===&lt;br /&gt;
The FlightGear project always needs screenshots, which show features that were added since the last release.  These should be of good quality, especially in content and technical image properties.  It is therefore recommended to use the best viable filter settings ([[anti-aliasing]], texture sharpening, etc.).  More info at [[Howto:Make nice screenshots]].&lt;br /&gt;
&lt;br /&gt;
[[Category:FlightGear Newsletter|2015 05]]&lt;br /&gt;
[[Category:Changes after 3.4]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=FlightGear_Newsletter_May_2015&amp;diff=85204</id>
		<title>FlightGear Newsletter May 2015</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=FlightGear_Newsletter_May_2015&amp;diff=85204"/>
		<updated>2015-05-30T17:58:07Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{draft|newsletter|Please feel free to add content you think will be of interest to the FlightGear community. You can read the latest newsletter at [[FlightGear Newsletter March 2015]].}}&lt;br /&gt;
&lt;br /&gt;
{{Newsletter-header|May 2015}}&lt;br /&gt;
&amp;lt;div style=&amp;quot;border-bottom:3px double #BBB;&amp;quot;&amp;gt;&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; |&lt;br /&gt;
 | valign=&amp;quot;top&amp;quot; width=&amp;quot;33%&amp;quot; |&lt;br /&gt;
{{Newsletter-cover-header|Development news}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Exhaust flames|Exhaust flames]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Automated checklist execution|Automated checklist execution]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Submodel enhancements|Submodel enhancements]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Nasal/Canvas: A simple tiled map|Nasal/Canvas: A simple tiled map]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#New (4th!) ATC-pie release|New ATC-pie release]]&lt;br /&gt;
 | valign=&amp;quot;top&amp;quot; width=&amp;quot;33%&amp;quot; |&lt;br /&gt;
{{Newsletter-cover-header|In the hanger}}&amp;lt;br/&amp;gt;&lt;br /&gt;
{{Newsletter-cover-header|Scenery Corner}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Scenery Project Elba|Scenery Project Elba]]&amp;lt;br/&amp;gt;&lt;br /&gt;
{{Newsletter-cover-header|Community News}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#The Festival of FlightGear 2015 (1/2) - 2 &amp;amp; 3 May|The Festival of FlightGear 2015 (1/2) - 2 &amp;amp; 3 May]]&amp;lt;br/&amp;gt;&lt;br /&gt;
 | valign=&amp;quot;top&amp;quot; width=&amp;quot;33%&amp;quot; |&lt;br /&gt;
{{Newsletter-cover-header|Contributing}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Translators required|Translators required]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#FlightGear logos|FlightGear logos]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Screenshots|Screenshots]]&lt;br /&gt;
|}&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Development News ==&lt;br /&gt;
=== Exhaust flames ===&lt;br /&gt;
The latest addition to the Atmospheric Light Scattering framework is  a procedural shader effect to render thruster and afterburner exhaust flames. This effect integrates over a 3d-distribution of glowing emitters in a bounding box, which means that it doesn't generate sharp edges in the visuals.&lt;br /&gt;
&lt;br /&gt;
Flame color, density, distribution of shock diamonds and widening in thin atmosphere are all runtime configurable, allowing to account realistically for changed thrust or ambient pressure.&lt;br /&gt;
&lt;br /&gt;
Here's an example application for the [[SpaceShuttle - Project Overview|Space Shuttle]] main engine - note how the exhaust plume is narrow early on and shows pronounced shock diamonds while it widens in the thin upper atmosphere:&lt;br /&gt;
&lt;br /&gt;
[[File:Shuttle flame05.jpg|400px|Space Shuttle main engine flames during early ascent]]&lt;br /&gt;
[[File:Shuttle flame06.jpg|400px|Space Shuttle main engine flames during late ascent]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
See the [[ALS technical notes#The exhaust flame effect|ALS exhaust flame effect]] for details.&lt;br /&gt;
&lt;br /&gt;
=== Automated checklist execution ===&lt;br /&gt;
{{FGCquote&lt;br /&gt;
  |As part of the development of the Lockheed 1049h Constellation, I created a comprehensive set of checklists based on the crew operating manual with other items added sufficient to take the aircraft through all stages of flight. Rather than hand-code an autostart script I wrote a more generic script to run checklist bindings in sequence. This script is now available in FGDATA and can be used on other aircraft:&amp;lt;br/&amp;gt;&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
[[Aircraft_Checklists#Automated_checklist_execution|Wiki: Automated Checklist Execution]]&amp;lt;br/&amp;gt;&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
If you are thinking about writing an autostart menu, you might want to consider using this script and driving the autostart from the checklists. It's not restricted to autostart, you can essentially run any sequence of checklists from any piece of Nasal code.&amp;lt;br/&amp;gt;&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
You can see the script in action in the latest [https://sourceforge.net/p/flightgear/fgaddon/HEAD/tree/trunk/Aircraft/Lockheed1049h/ Lockheed 1049h]. Note that you need a recent copy of [https://sourceforge.net/p/flightgear/fgdata/ci/next/tree/ FGDATA] for this to work. The autostart in this case is intelligent enough to run different checklist sequences depending on whether you are starting on a runway, at the terminal or in the air and also uses automated checklist execution to run an &amp;quot;After Landing&amp;quot; checklist from a keyboard shortcut during that busy time of rollout and taxi.&lt;br /&gt;
  |{{cite web |url=http://forum.flightgear.org/viewtopic.php?p=241203&amp;amp;sid=4bad6d92dab1d411ea46e6efb1b8850c#p241203&lt;br /&gt;
     |title=&amp;lt;nowiki&amp;gt;Automated Checklist Execution&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
     |author=&amp;lt;nowiki&amp;gt;sanhozay&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
     |date=&amp;lt;nowiki&amp;gt;Fri May 01&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
   }}&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Submodel enhancements ===&lt;br /&gt;
&lt;br /&gt;
It is now possible to adjust various offsets, including heading and pitch, during runtime. Furthermore, the x, y, and z offsets can be defined in metric units. Finally, the randomness of the azimuth (heading), elevation (pitch), Cd, and life can be defined. See http://wiki.flightgear.org/Howto:Add_submodels#Step_2_of_6:_Define_the_position_and_orientation&lt;br /&gt;
&lt;br /&gt;
=== Nasal/Canvas: A simple tiled map ===&lt;br /&gt;
Using the [[Canvas GUI]], you can make a simple tiled map using images downloaded on the fly  You can view the code behind the map at [[Canvas Snippets#A simple tile map]].&lt;br /&gt;
&lt;br /&gt;
[[File:Canvas - Tile map demo.png|A simple, canvas based tile map which is centered around the aircraft.]]&lt;br /&gt;
&lt;br /&gt;
=== New (4th!) ATC-pie release ===&lt;br /&gt;
[[File:ATC-pie-logo.png|200px|left|ATC-pie logo.]]&lt;br /&gt;
[[ATC-pie]] now provides a '''solo training mode''' for ATCs. Using the same interface as the multi-player game mode and an additional instruction pane, you can choose to play offline and control virtual aircraft as Tower, Approach, Departure, or any combination of those positions. As MP traffic still can be scarce in many occasions on our network, this new game mode can be a solution for you not to give up on a planned session and give yourself some challenge. Also, you may learn from it enough to make your own MP sessions more popular over the network!&lt;br /&gt;
&lt;br /&gt;
The main features are:&lt;br /&gt;
* Free combination choice of APP, TWR and DEP control positions for custom training&lt;br /&gt;
* Handovers to/from virtual ATCs&lt;br /&gt;
* Instruction interface and pilot read back&lt;br /&gt;
* Adjustable difficulty (traffic density)&lt;br /&gt;
* Departure–arrival and ILS–visual balance options&lt;br /&gt;
* Configurable runways in use, entry and exit points&lt;br /&gt;
&lt;br /&gt;
See the [[ATC-pie|wiki page]] for more!&lt;br /&gt;
&lt;br /&gt;
== Scenery Corner ==&lt;br /&gt;
=== Scenery Project Elba ===&lt;br /&gt;
The Scenery Project Elba has been started, aiming to improve the scenery of Elba, an island west of Italy. More information can be found on the wiki page: [[Scenery Project Elba]]. Contributions welcome! Development thread: http://forum.flightgear.org/viewtopic.php?f=5&amp;amp;t=26138&amp;lt;br/&amp;gt;&lt;br /&gt;
[[File:Elba.jpg|900px|center]]&lt;br /&gt;
&lt;br /&gt;
== Community News ==&lt;br /&gt;
=== The Festival of FlightGear 2015 (1/2) - 2 &amp;amp; 3 May ===&lt;br /&gt;
Time: All weekend Sat 00:00-Sun 23:59&lt;br /&gt;
Location: Argentina/Brazil (SBRJ/SBGL and south)&lt;br /&gt;
&lt;br /&gt;
== Contributing ==&lt;br /&gt;
=== Translators required ===&lt;br /&gt;
{|&lt;br /&gt;
| [[File:en.gif]]&lt;br /&gt;
| The FlightGear Wiki still needs help for translating it into various languages. If you are interested in making the FlightGear Wiki multi-language then start at [[Help:Translate]].&lt;br /&gt;
|-&lt;br /&gt;
| [[File:de.gif]]&lt;br /&gt;
| Das FlightGear Wiki benötigt immer noch Hilfe bei der Übersetzung in verschiedene Sprachen. Wenn Du Interesse daran hast, das FlightGear Wiki Mehrsprachig zu machen, dann fang doch mit [[:de:Help:Übersetzen|Help:Übersetzen]] an.&lt;br /&gt;
|-&lt;br /&gt;
| [[File:nl.gif]]&lt;br /&gt;
| De FlightGear Wiki kan nog steed hulp gebruiken bij het vertalen van artikelen. Als je interesse hebt om de wiki meertalig te maken, raden we je aan om een kijkje te nemen bij [[:nl:Help:Vertalen|Help:Vertalen]].&lt;br /&gt;
|-&lt;br /&gt;
| [[File:es.gif]]&lt;br /&gt;
| La wiki de FlightGear todavía necesita ayuda para traducirla a varios lenguajes. Si estás interesado en hacer la FlightGear wiki multilingüe, entonces comienza en [[:es:Help:Traducir|Help:Traducir]].&lt;br /&gt;
|-&lt;br /&gt;
| [[File:cat.gif]]&lt;br /&gt;
| La wiki de FlightGear encara necessita ajuda per traduir-la a diverses llengües. Si esteu interessat en fer la wiki de FlightGear multilingüe, llavors comenceu a [[:ca:Help:Traduir|Help:Traduir]].&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== FlightGear logos ===&lt;br /&gt;
If you want some graphic elements for your FlightGear-related site (such as a hangar or YouTube channel), please feel free to visit [[FlightGear logos]] for a repository of logos.  And if you have some art skills, please don't hesitate to contribute with your own design creations.&lt;br /&gt;
&lt;br /&gt;
=== Screenshots ===&lt;br /&gt;
The FlightGear project always needs screenshots, which show features that were added since the last release.  These should be of good quality, especially in content and technical image properties.  It is therefore recommended to use the best viable filter settings ([[anti-aliasing]], texture sharpening, etc.).  More info at [[Howto:Make nice screenshots]].&lt;br /&gt;
&lt;br /&gt;
[[Category:FlightGear Newsletter|2015 05]]&lt;br /&gt;
[[Category:Changes after 3.4]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Howto:Add_submodels&amp;diff=85198</id>
		<title>Howto:Add submodels</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Howto:Add_submodels&amp;diff=85198"/>
		<updated>2015-05-30T17:41:19Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[File:b29s-bombs.jpg|thumb|270px|[[Boeing B-29 Superfortress|B-29s]] dropping their load.]]&lt;br /&gt;
Submodels are the means in [[FlightGear]] whereby we can represent anything which is dropped, fired, or launched from an [[aircraft]] or indeed any model... the possibilies are endless. Some examples which can be found in FlightGear: guns, flares, bombs, droptanks, smoke, contrails. These last to date from a time before particles were implemented in FlightGear. While they still exist in older models, they are probably nowadays best done with particles.&lt;br /&gt;
&lt;br /&gt;
In general, AI Models are instantiated at startup. Submodels, which use only AIBallistic objects, are pre-loaded at startup, but only instantiated when required.&lt;br /&gt;
&lt;br /&gt;
This [[:Category:Howto|howto]] will explain '''how to add submodels''' to your model&lt;br /&gt;
&lt;br /&gt;
=== Step 1 of 6: Create the submodel ===&lt;br /&gt;
&lt;br /&gt;
First, create the file Models/submodels.xml containing a &amp;lt;submodel&amp;gt; inside a &amp;lt;PropertyList tag&amp;gt;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-8&amp;quot;?&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;PropertyList&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;submodel&amp;gt;&lt;br /&gt;
        &amp;lt;name&amp;gt;M-17.001-submodel&amp;lt;/name&amp;gt;&lt;br /&gt;
        &amp;lt;model&amp;gt;/Aircraft/b29/Models/M17.xml&amp;lt;/model&amp;gt;&lt;br /&gt;
        &amp;lt;trigger&amp;gt;/sim/weapons/loadout[1]/bomb[0]/dropped&amp;lt;/trigger&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;repeat&amp;gt;false&amp;lt;/repeat&amp;gt;&lt;br /&gt;
        &amp;lt;count&amp;gt;1&amp;lt;/count&amp;gt;&lt;br /&gt;
        &amp;lt;delay&amp;gt;0&amp;lt;/delay&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;speed&amp;gt;0&amp;lt;/speed&amp;gt;&lt;br /&gt;
        &amp;lt;wind&amp;gt;false&amp;lt;/wind&amp;gt;&lt;br /&gt;
        &amp;lt;aero-stabilised&amp;gt;true&amp;lt;/aero-stabilised&amp;gt;&lt;br /&gt;
        &amp;lt;eda&amp;gt;1.42&amp;lt;/eda&amp;gt;&lt;br /&gt;
        &amp;lt;cd&amp;gt;0.75&amp;lt;/cd&amp;gt;&lt;br /&gt;
        &amp;lt;weight&amp;gt;500&amp;lt;/weight&amp;gt;&lt;br /&gt;
        &amp;lt;life&amp;gt;900&amp;lt;/life&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;impact&amp;gt;true&amp;lt;/impact&amp;gt;&lt;br /&gt;
        &amp;lt;impact-reports&amp;gt;sim/ai/aircraft/impact/bomb&amp;lt;/impact-reports&amp;gt;&lt;br /&gt;
    &amp;lt;/submodel&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/PropertyList&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Measurements (except those in &amp;lt;offsets&amp;gt;, see below) are in Imperial Measure: Feet, Inches, Pounds. This is because the original author(s) were American.&lt;br /&gt;
&lt;br /&gt;
The trigger is a boolean property, which you define, which when &amp;quot;true&amp;quot; causes the submodel to be released/launched. For bombs you want &amp;lt;repeat&amp;gt; to be set to &amp;quot;false&amp;quot;, &amp;lt;count&amp;gt; to 1, and &amp;lt;delay&amp;gt; to 0. For bullets you want to set &amp;lt;repeat&amp;gt; to &amp;quot;true&amp;quot;, &amp;lt;count&amp;gt; to -1, and &amp;lt;delay&amp;gt; to a number greater than zero. If the weapon system has a limited capacity (limited number of bullets) then you should use Nasal or XML (&amp;lt;autopilot&amp;gt; or &amp;lt;property-rule&amp;gt;) to control whether the submodel should be triggered or not.&lt;br /&gt;
&lt;br /&gt;
=== Step 2 of 6: Define the position and orientation ===&lt;br /&gt;
&lt;br /&gt;
Second, define the offset of the submodel with respect to the center of the model. For example, the forward left Phalanx CIWS of the CVN-70 supercarrier uses:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;submodel&amp;gt;&lt;br /&gt;
        ...&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;offsets&amp;gt;&lt;br /&gt;
            &amp;lt;x-m&amp;gt;-121.2666&amp;lt;/x-m&amp;gt;&lt;br /&gt;
            &amp;lt;y-m&amp;gt;-21.1147&amp;lt;/y-m&amp;gt;&lt;br /&gt;
            &amp;lt;z-m&amp;gt;16.8345&amp;lt;/z-m&amp;gt;&lt;br /&gt;
            &amp;lt;heading-deg&amp;gt;&lt;br /&gt;
                &amp;lt;property&amp;gt;/carrier/phalanx/output/forward-left/yaw-deg&amp;lt;/property&amp;gt;&lt;br /&gt;
                &amp;lt;offset&amp;gt;-90.0&amp;lt;/offset&amp;gt;&lt;br /&gt;
            &amp;lt;/heading-deg&amp;gt;&lt;br /&gt;
            &amp;lt;pitch-deg&amp;gt;&lt;br /&gt;
                &amp;lt;property&amp;gt;/carrier/phalanx/output/forward-left/pitch-deg&amp;lt;/property&amp;gt;&lt;br /&gt;
            &amp;lt;/pitch-deg&amp;gt;&lt;br /&gt;
        &amp;lt;/offsets&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        ...&lt;br /&gt;
    &amp;lt;/submodel&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The various tags inside the &amp;lt;offsets&amp;gt; tag support certain tags also seen in &amp;lt;autopilot&amp;gt; files: &amp;lt;property&amp;gt;, &amp;lt;expression&amp;gt;, &amp;lt;value&amp;gt;, &amp;lt;scale&amp;gt;, &amp;lt;offset&amp;gt;, &amp;lt;min&amp;gt;, &amp;lt;max&amp;gt;, &amp;lt;abs&amp;gt;, and &amp;lt;period&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{tip|Use these to control the submodel's initial position and orientation during runtime. For example, to control the pitch and heading of a Phalanx CIWS (Close-In Weapon System).&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
{{note|The &amp;lt;x-m&amp;gt;, &amp;lt;y-m&amp;gt;, and &amp;lt;z-m&amp;gt; use metric units and have the same coordinate system as the main model. This is unlike the old &amp;lt;x-offset&amp;gt;, &amp;lt;y-offset&amp;gt;, and &amp;lt;z-offset&amp;gt; tags which use imperial units and have the x-axis reversed.}}&lt;br /&gt;
&lt;br /&gt;
=== Step 3 of 6: Re-use configuration values (optional) ===&lt;br /&gt;
&lt;br /&gt;
If you want to create multiple instances of the same kind of submodel, for example, multiple guns of the same type, then you should alias tags that you want to re-use:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;phalanx&amp;gt;&lt;br /&gt;
        &amp;lt;model&amp;gt;Aircraft/CVN-70/Models/M61A1/apibullet-tracer.xml&amp;lt;/model&amp;gt;&lt;br /&gt;
        &amp;lt;speed&amp;gt;3650.0&amp;lt;/speed&amp;gt;&lt;br /&gt;
        ...&lt;br /&gt;
    &amp;lt;/phalanx&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;submodel&amp;gt;&lt;br /&gt;
        &amp;lt;name&amp;gt;Phalanx Forward Left M61A1 Bullet Tracer Round&amp;lt;/name&amp;gt;&lt;br /&gt;
        &amp;lt;trigger&amp;gt;/sim/multiplay/generic/int[3]&amp;lt;/trigger&amp;gt;&lt;br /&gt;
        &amp;lt;model alias=&amp;quot;/phalanx/model&amp;quot;/&amp;gt;&lt;br /&gt;
        &amp;lt;speed alias=&amp;quot;/phalanx/speed&amp;quot;/&amp;gt;&lt;br /&gt;
        ...&lt;br /&gt;
    &amp;lt;/submodel&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;submodel&amp;gt;&lt;br /&gt;
        &amp;lt;name&amp;gt;Phalanx Forward Right M61A1 Bullet Tracer Round&amp;lt;/name&amp;gt;&lt;br /&gt;
        &amp;lt;trigger&amp;gt;/sim/multiplay/generic/int[2]&amp;lt;/trigger&amp;gt;&lt;br /&gt;
        &amp;lt;model alias=&amp;quot;/phalanx/model&amp;quot;/&amp;gt;&lt;br /&gt;
        &amp;lt;speed alias=&amp;quot;/phalanx/speed&amp;quot;/&amp;gt;&lt;br /&gt;
        ...&lt;br /&gt;
    &amp;lt;/submodel&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
As you can see, the speed is defined in just one place instead of two. If you ever need to adjust the speed of all the submodels, you only have to adjust one number.&lt;br /&gt;
&lt;br /&gt;
=== Step 4 of 6: Add the submodel to your model ===&lt;br /&gt;
&lt;br /&gt;
This is very simple. First, add these lines to your model ~-set.xml file within the &amp;lt;sim&amp;gt;&amp;lt;/sim&amp;gt; tag:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;submodels&amp;gt;&lt;br /&gt;
        &amp;lt;serviceable type=&amp;quot;bool&amp;quot;&amp;gt;true&amp;lt;/serviceable&amp;gt;&lt;br /&gt;
        &amp;lt;path&amp;gt;Aircraft/seahawk/Models/seahawk-submodels3.xml&amp;lt;/path&amp;gt;&lt;br /&gt;
    &amp;lt;/submodels&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Where &amp;lt;path&amp;gt; is the path to the file you created at Step 1 above. If you want to add submodels to an AI Object, add the same lines within the &amp;lt;scenario&amp;gt;&amp;lt;/scenario&amp;gt; tag in the scenario file which instantiates the AI Object. &lt;br /&gt;
&lt;br /&gt;
=== Step 5 of 6: Control the release of the submodel ===&lt;br /&gt;
&lt;br /&gt;
There is no built-in way of setting/toggling the trigger property so you will need to add some mechanism to do this. A suitable key binding might be:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;key n=&amp;quot;10&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;name&amp;gt;Ctrl-J&amp;lt;/name&amp;gt;&lt;br /&gt;
    &amp;lt;desc&amp;gt;Jettison Port and Stbd Pylon Stores.&amp;lt;/desc&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;!-- port inner --&amp;gt;&lt;br /&gt;
    &amp;lt;binding&amp;gt;&lt;br /&gt;
        &amp;lt;command&amp;gt;property-assign&amp;lt;/command&amp;gt;&lt;br /&gt;
        &amp;lt;property&amp;gt;controls/armament/station[0]/jettison-all&amp;lt;/property&amp;gt;&lt;br /&gt;
        &amp;lt;value type=&amp;quot;bool&amp;quot;&amp;gt;1&amp;lt;/value&amp;gt;&lt;br /&gt;
    &amp;lt;/binding&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;!-- stbd inner --&amp;gt;&lt;br /&gt;
    &amp;lt;binding&amp;gt;&lt;br /&gt;
        &amp;lt;command&amp;gt;property-assign&amp;lt;/command&amp;gt;&lt;br /&gt;
        &amp;lt;property&amp;gt;controls/armament/station[1]/jettison-all&amp;lt;/property&amp;gt;&lt;br /&gt;
        &amp;lt;value type=&amp;quot;bool&amp;quot;&amp;gt;1&amp;lt;/value&amp;gt;&lt;br /&gt;
    &amp;lt;/binding&amp;gt;&lt;br /&gt;
&amp;lt;/key&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Step 6 of 6: Terminate the submodel ===&lt;br /&gt;
&lt;br /&gt;
There are 3 ways to terminate your submodel:&lt;br /&gt;
&lt;br /&gt;
# Do nothing: the submodel will die when its life expires or its altitude &amp;lt;= -1000, whichever occurs first.&lt;br /&gt;
# Instantiate a subsquent submodel: &amp;lt;submodel-path&amp;gt; contains the path to the file containing the submodel to be instantiated. Activated if one or more of &amp;lt;collision&amp;gt;, &amp;lt;impact&amp;gt;, or &amp;lt;expiry&amp;gt; are set to true.&lt;br /&gt;
# Instantiate a static model: for this you will need a Nasal fuction:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var droptank_node = props.globals.getNode(&amp;quot;sim/ai/aircraft/impact/droptank&amp;quot;, 1);&lt;br /&gt;
                               &lt;br /&gt;
var droptanks = func(n) {&lt;br /&gt;
    var droptank = droptank_node.getValue();&lt;br /&gt;
    var node = props.globals.getNode(n.getValue(), 1);&lt;br /&gt;
&lt;br /&gt;
    geo.put_model(&amp;quot;Aircraft/seahawk/Models/droptank-hot.xml&amp;quot;,&lt;br /&gt;
        node.getNode(&amp;quot;impact/latitude-deg&amp;quot;).getValue(),&lt;br /&gt;
        node.getNode(&amp;quot;impact/longitude-deg&amp;quot;).getValue(),&lt;br /&gt;
        node.getNode(&amp;quot;impact/elevation-m&amp;quot;).getValue() + 0.25, # +0.25 to ensure the droptank isn't buried&lt;br /&gt;
        node.getNode(&amp;quot;impact/heading-deg&amp;quot;).getValue(),&lt;br /&gt;
    0, 0);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
setlistener(&amp;quot;sim/ai/aircraft/impact/droptank&amp;quot;, droptanks);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The path &amp;lt;tt&amp;gt;sim/ai/aircraft/impact/droptank&amp;lt;/tt&amp;gt; is the one you specified in the tag &amp;lt;submodel-path&amp;gt;. Options 2 and 3 are NOT mutually exclusive. Thus you can both instantiate a static model AND instantiate a subsequent submodel.&lt;br /&gt;
As above, this is activated if one or more of &amp;lt;collision&amp;gt;, &amp;lt;impact&amp;gt;, or &amp;lt;expiry&amp;gt; are set to true.&lt;br /&gt;
&lt;br /&gt;
=== Notes ===&lt;br /&gt;
 &lt;br /&gt;
# A submodel will create an AIBallistic object which will follow a ballistic path. By default one submodel will be released when the corresponding trigger is &amp;quot;true&amp;quot;. The initial conditions (IC) define the object's starting point (relative to the user model's current position), and its initial speed and direction (relative to that of the user model aircraft). If you want to release many similar objects with the same IC, then you may use the &amp;lt;repeat&amp;gt;, &amp;lt;delay&amp;gt; and &amp;lt;count&amp;gt; properties to define this.&lt;br /&gt;
# There is a long list of allowable tags. The allowed properties are:&lt;br /&gt;
&lt;br /&gt;
      &amp;lt;name&amp;gt;         The name of the submodel.&lt;br /&gt;
      &amp;lt;model&amp;gt;        The path to the visual model. Any model in any location is allowed. All the normal&lt;br /&gt;
                     animations are available.&lt;br /&gt;
      &amp;lt;trigger&amp;gt;      The property which will act as the trigger. &lt;br /&gt;
      &amp;lt;speed&amp;gt;        Initial speed, in feet/sec, relative to user aircraft.&lt;br /&gt;
      &amp;lt;repeat&amp;gt;       Set &amp;quot;true&amp;quot; if you want multiple releases of this submodel. Defaults&lt;br /&gt;
                     to false&lt;br /&gt;
      &amp;lt;delay&amp;gt;        Time, in seconds, between repeated releases.&lt;br /&gt;
      &amp;lt;count&amp;gt;        Number of submodels available for multiple release.&lt;br /&gt;
      &amp;lt;buoyancy&amp;gt;     Submodel's upward acceleration (fps) due to buoyancy in air. 32 is &lt;br /&gt;
                     neutral (contrails),  &amp;gt; 32 exhaust gas, smoke. &lt;br /&gt;
      &amp;lt;wind&amp;gt;	     If true, the Submodel is affected by local wind. Defaults to false. This&lt;br /&gt;
                     tag was added to cater for smoke, contrails and the like. The effect of &lt;br /&gt;
                     wind on ballistic objects is not well modelled. For bombs, bulllets etc. &lt;br /&gt;
                     this is best left at the default setting.&lt;br /&gt;
      &amp;lt;cd&amp;gt;           The Coeffient of Drag. Varies with submodel shape - 0.295 for a bullet, &lt;br /&gt;
                     0.045 for an airfoil. Enter an appropriate value. Defaults to 0.295.&lt;br /&gt;
      &amp;lt;eda&amp;gt;          Effective drag area (sq ft). Usually the cross-sectional area of the &lt;br /&gt;
                     submodel normal to the airflow.&lt;br /&gt;
      &amp;lt;weight&amp;gt;       The weight of the submodel (lbs). Defaults to 0.25	&lt;br /&gt;
      &amp;lt;aero-stabilised&amp;gt; If true, the submodel aligns with the local airflow. Defaults to true.&lt;br /&gt;
      &amp;lt;external-force&amp;gt; If true the submodel is subjected to an external force.&lt;br /&gt;
      &amp;lt;force-path&amp;gt;   A string describing the property where the magnitude, azimuth and elevation&lt;br /&gt;
                     of the external force is to be found. The following child properties are&lt;br /&gt;
                     instantiated:&lt;br /&gt;
                        ~/force-lb&lt;br /&gt;
                        ~/force-azimuth-deg&lt;br /&gt;
                        ~/force-elevation-deg&lt;br /&gt;
                     You need to manipulate these properties with some Nasal to apply an external&lt;br /&gt;
                     force to the submodel.&lt;br /&gt;
      &amp;lt;force-stabilised&amp;gt; If true, the submodel aligns with the external force. Defaults to false.&lt;br /&gt;
                     If both this and &amp;lt;aero-stabilised&amp;gt; are true this takes priority.&lt;br /&gt;
      &amp;lt;no-roll&amp;gt;      If true, the submodel does not bank in turns. Defaults to false.&lt;br /&gt;
      &amp;lt;collision&amp;gt;    If true, the position of collisions (or hits) with other non-ballistic &lt;br /&gt;
                     AI models are reported. Defaults to false.&lt;br /&gt;
      &amp;lt;impact&amp;gt;       If this is true the position of impact on the terrain is reported. Defaults to&lt;br /&gt;
                     false.&lt;br /&gt;
      &amp;lt;expiry&amp;gt;       If true, the postion of the Submodel when its life expires is reported. Defaults&lt;br /&gt;
                     to false. Collision, Impact, and Expiry are handled in that order.&lt;br /&gt;
      &amp;lt;impact-reports&amp;gt; A string descibing the location of Collision, Impact, or Expiry position.&lt;br /&gt;
                     Defaults to &amp;quot;/ai/models/model-impact&amp;quot;.&lt;br /&gt;
      &amp;lt;fuse-range&amp;gt;   Range (ft) added to Collision and Impact calculations. Defaults to 0.0.&lt;br /&gt;
      &amp;lt;contents&amp;gt;     A string describing the property where the contents (lbs) of a Submodel are located.&lt;br /&gt;
                     Used with droptanks. Set to zero on release. Defaults to &amp;quot;none&amp;quot;.&lt;br /&gt;
      &amp;lt;speed-prop&amp;gt;   A string describing the property where the initial speed of the Submodel is located.&lt;br /&gt;
                     Defaults to &amp;quot;none&amp;quot;.&lt;br /&gt;
      &amp;lt;submodel-path&amp;gt; A string describing the path to the .xml file where the next submodel Initial &lt;br /&gt;
                     Conditions are located. This submodel will be instantiated when any of Collision&lt;br /&gt;
                     Impact or Expiry are true. Submodels can be linked to any depth using this tag.&lt;br /&gt;
                     Defaults to &amp;quot;&amp;quot;.&lt;br /&gt;
      &amp;lt;slaved&amp;gt;       If true the Submodel is slaved to its parent model on release. For a subsequent &lt;br /&gt;
                     release, the property &amp;quot;controls/slave-to-ac&amp;quot; must be set to false.      &lt;br /&gt;
&lt;br /&gt;
      &amp;lt;random&amp;gt;       If true, initial cd is varied by +- 10 %, and life between 50 % and 100 %.&lt;br /&gt;
                     Define &amp;lt;randomness&amp;gt; to control the randomness of the azimuth, elevation,&lt;br /&gt;
                     cd, and life. Defaults to false.&lt;br /&gt;
      &amp;lt;randomness&amp;gt;   Contains the &amp;lt;azimuth&amp;gt;, &amp;lt;elevation&amp;gt;, &amp;lt;cd&amp;gt;, and &amp;lt;life. tags:&lt;br /&gt;
            &amp;lt;azimuth&amp;gt;       Define the variation in degrees around the default azimuth.&lt;br /&gt;
                            By default +- 0 %.&lt;br /&gt;
            &amp;lt;elevation&amp;gt;     Define the variation in degrees around the default elevation.&lt;br /&gt;
                            By default +- 0 %.&lt;br /&gt;
            &amp;lt;cd&amp;gt;            Controls how much the Cd is varied. The default is 0.1, which is +- 10%.&lt;br /&gt;
            &amp;lt;life&amp;gt;          Varies the randomness of the submodel's life between 0.0 (0 %) and 1.0 (100 %).&lt;br /&gt;
                            Defaults to 0.5 (50 %). Note this is the minimum life, not the variation&lt;br /&gt;
                            around the submodel's default life.&lt;br /&gt;
&lt;br /&gt;
      &amp;lt;offsets&amp;gt;      Contains the &amp;lt;x-m&amp;gt;, &amp;lt;y-m&amp;gt;, &amp;lt;z-m&amp;gt;, &amp;lt;heading-deg&amp;gt;, and &amp;lt;pitch-deg&amp;gt; tags:&lt;br /&gt;
            &amp;lt;x-m&amp;gt;           Submodel's initial fore/aft position relative to user aircraft.&lt;br /&gt;
                            Aft is positive. (m)&lt;br /&gt;
            &amp;lt;y-m&amp;gt;           Submodel's initial left/right position relative to user aircraft.  &lt;br /&gt;
                            Right is positive. (m)&lt;br /&gt;
            &amp;lt;z-m&amp;gt;           Submodel's initial up/down position relative to user aircraft.  &lt;br /&gt;
                            Up is positive. (m)&lt;br /&gt;
            &amp;lt;heading-deg&amp;gt;   Submodel's initial azimuth, in degrees, relative to user aircraft's&lt;br /&gt;
                            nose.  Right is positive.&lt;br /&gt;
            &amp;lt;pitch-deg&amp;gt;     Submodel's initial elevation, in degrees, relative to user aircraft's&lt;br /&gt;
                            pitch.  Up is positive.&lt;br /&gt;
&lt;br /&gt;
The following tags are deprecated:&lt;br /&gt;
      &amp;lt;x-offset&amp;gt;     Submodel's initial fore/aft position relative to user aircraft.  &lt;br /&gt;
                     Fore is positive. (ft)&lt;br /&gt;
      &amp;lt;y-offset&amp;gt;     Submodel's initial left/right position relative to user aircraft.  &lt;br /&gt;
                     Right is positive. (ft)&lt;br /&gt;
      &amp;lt;z-offset&amp;gt;     Submodel's initial up/down position relative to user aircraft.  &lt;br /&gt;
                     Up is positive. (ft)&lt;br /&gt;
      &amp;lt;yaw-offset&amp;gt;   Submodel's initial azimuth, in degrees, relative to user aircraft's&lt;br /&gt;
                     nose.  Right is positive.&lt;br /&gt;
      &amp;lt;pitch-offset&amp;gt; Submodel's initial elevation, in degrees, relative to user aircraft's&lt;br /&gt;
                     pitch.  Up is positive.&lt;br /&gt;
&lt;br /&gt;
=== Technical stuff ===&lt;br /&gt;
# '''Slaved Objects.''' Slaved objects follow exactly the movements of their parent object. They can be released, when they then become normal Ballistic objects. They are designed for use as underwing stores, such as droptanks, as they give a realistic appearance on release. On the other hand, there is a small framerate cost. Where the stores are carried in a bombbay, this technique is not required. Here, an acceptable appearance can be achieved by adding models of the stores in the bombbay which are hidden on instantiation of the submodel.&lt;br /&gt;
# '''Formations.''' Wingmen are not AI Aircraft. In the interest of framerate they are in fact a sub-class of slaved objects, with added sinusoidal noise and some simple AI rules. They cannot be released to act independently. The formation can be changed by the use of a Nasal script. There is no collision detection or avoidance, so you must avoid flying the wingmen into each other during a formation change. Thare is a significant framerate cost involved. The wingmen can be as simple or complicated as you wish. The ones currently implemented tend to be fully detailed, and can be &amp;quot;ridden&amp;quot;. This is uneccesary, but gives a fun viewpoint of the formation. In due course I will produce a Howto for Wingmen.&lt;br /&gt;
# '''Multiplayer.''' Submodels, indeed all AI objects are not visible over MP. This is in part deliberate (to prevent people trying to shoot at airliners), and in part technical (due to lag on the network the submodels would be nowhere near their actual position). On the other hand, it would be nice to include wingmen and perhaps droptanks in the overall scene. At the moment I cannot come up with a design which works at acceptable framerate cost.&lt;br /&gt;
&lt;br /&gt;
[[Category:Aircraft enhancement|Add submodels]]&lt;br /&gt;
[[Category:Howto|Add submodels]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Howto:Add_submodels&amp;diff=85192</id>
		<title>Howto:Add submodels</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Howto:Add_submodels&amp;diff=85192"/>
		<updated>2015-05-30T17:25:56Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[File:b29s-bombs.jpg|thumb|270px|[[Boeing B-29 Superfortress|B-29s]] dropping their load.]]&lt;br /&gt;
Submodels are the means in [[FlightGear]] whereby we can represent anything which is dropped, fired, or launched from an [[aircraft]] or indeed any model... the possibilies are endless. Some examples which can be found in FlightGear: guns, flares, bombs, droptanks, smoke, contrails. These last to date from a time before particles were implemented in FlightGear. While they still exist in older models, they are probably nowadays best done with particles.&lt;br /&gt;
&lt;br /&gt;
In general, AI Models are instantiated at startup. Submodels, which use only AIBallistic objects, are pre-loaded at startup, but only instantiated when required.&lt;br /&gt;
&lt;br /&gt;
This [[:Category:Howto|howto]] will explain '''how to add submodels''' to your model&lt;br /&gt;
&lt;br /&gt;
=== Step 1 of 6: Create the submodel ===&lt;br /&gt;
&lt;br /&gt;
First, create the file Models/submodels.xml containing a &amp;lt;submodel&amp;gt; inside a &amp;lt;PropertyList tag&amp;gt;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-8&amp;quot;?&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;PropertyList&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;submodel&amp;gt;&lt;br /&gt;
        &amp;lt;name&amp;gt;M-17.001-submodel&amp;lt;/name&amp;gt;&lt;br /&gt;
        &amp;lt;model&amp;gt;/Aircraft/b29/Models/M17.xml&amp;lt;/model&amp;gt;&lt;br /&gt;
        &amp;lt;trigger&amp;gt;/sim/weapons/loadout[1]/bomb[0]/dropped&amp;lt;/trigger&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;repeat&amp;gt;false&amp;lt;/repeat&amp;gt;&lt;br /&gt;
        &amp;lt;count&amp;gt;1&amp;lt;/count&amp;gt;&lt;br /&gt;
        &amp;lt;delay&amp;gt;0&amp;lt;/delay&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;speed&amp;gt;0&amp;lt;/speed&amp;gt;&lt;br /&gt;
        &amp;lt;wind&amp;gt;false&amp;lt;/wind&amp;gt;&lt;br /&gt;
        &amp;lt;aero-stabilised&amp;gt;true&amp;lt;/aero-stabilised&amp;gt;&lt;br /&gt;
        &amp;lt;eda&amp;gt;1.42&amp;lt;/eda&amp;gt;&lt;br /&gt;
        &amp;lt;cd&amp;gt;0.75&amp;lt;/cd&amp;gt;&lt;br /&gt;
        &amp;lt;weight&amp;gt;500&amp;lt;/weight&amp;gt;&lt;br /&gt;
        &amp;lt;life&amp;gt;900&amp;lt;/life&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;impact&amp;gt;true&amp;lt;/impact&amp;gt;&lt;br /&gt;
        &amp;lt;impact-reports&amp;gt;sim/ai/aircraft/impact/bomb&amp;lt;/impact-reports&amp;gt;&lt;br /&gt;
    &amp;lt;/submodel&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/PropertyList&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Measurements (except those in &amp;lt;offsets&amp;gt;, see below) are in Imperial Measure: Feet, Inches, Pounds. This is because the original author(s) were American.&lt;br /&gt;
&lt;br /&gt;
The trigger is a boolean property, which you define, which when &amp;quot;true&amp;quot; causes the submodel to be released/launched. For bombs you want &amp;lt;repeat&amp;gt; to be set to &amp;quot;false&amp;quot;, &amp;lt;count&amp;gt; to 1, and &amp;lt;delay&amp;gt; to 0. For bullets you want to set &amp;lt;repeat&amp;gt; to &amp;quot;true&amp;quot;, &amp;lt;count&amp;gt; to -1, and &amp;lt;delay&amp;gt; to a number greater than zero. If the weapon system has a limited capacity (limited number of bullets) then you should use Nasal or XML (&amp;lt;autopilot&amp;gt; or &amp;lt;property-rule&amp;gt;) to control whether the submodel should be triggered or not.&lt;br /&gt;
&lt;br /&gt;
=== Step 2 of 6: Define the position and orientation ===&lt;br /&gt;
&lt;br /&gt;
Second, define the offset of the submodel with respect to the center of the model. For example, the forward left Phalanx CIWS of the CVN-70 supercarrier uses:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;submodel&amp;gt;&lt;br /&gt;
        ...&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;offsets&amp;gt;&lt;br /&gt;
            &amp;lt;x-m&amp;gt;-121.2666&amp;lt;/x-m&amp;gt;&lt;br /&gt;
            &amp;lt;y-m&amp;gt;-21.1147&amp;lt;/y-m&amp;gt;&lt;br /&gt;
            &amp;lt;z-m&amp;gt;16.8345&amp;lt;/z-m&amp;gt;&lt;br /&gt;
            &amp;lt;heading-deg&amp;gt;&lt;br /&gt;
                &amp;lt;property&amp;gt;/carrier/phalanx/output/forward-left/yaw-deg&amp;lt;/property&amp;gt;&lt;br /&gt;
                &amp;lt;offset&amp;gt;-90.0&amp;lt;/offset&amp;gt;&lt;br /&gt;
            &amp;lt;/heading-deg&amp;gt;&lt;br /&gt;
            &amp;lt;pitch-deg&amp;gt;&lt;br /&gt;
                &amp;lt;property&amp;gt;/carrier/phalanx/output/forward-left/pitch-deg&amp;lt;/property&amp;gt;&lt;br /&gt;
            &amp;lt;/pitch-deg&amp;gt;&lt;br /&gt;
        &amp;lt;/offsets&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        ...&lt;br /&gt;
    &amp;lt;/submodel&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The various tags inside the &amp;lt;offsets&amp;gt; tag support certain tags also seen in &amp;lt;autopilot&amp;gt; files: &amp;lt;property&amp;gt;, &amp;lt;expression&amp;gt;, &amp;lt;value&amp;gt;, &amp;lt;scale&amp;gt;, &amp;lt;offset&amp;gt;, &amp;lt;min&amp;gt;, &amp;lt;max&amp;gt;, &amp;lt;abs&amp;gt;, and &amp;lt;period&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{tip|Use these to control the submodel's initial position and orientation during runtime. For example, to control the pitch and heading of a Phalanx CIWS (Close-In Weapon System).&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
{{note|The &amp;lt;x-m&amp;gt;, &amp;lt;y-m&amp;gt;, and &amp;lt;z-m&amp;gt; use metric units and have the same coordinate system as the main model. This is unlike the old &amp;lt;x-offset&amp;gt;, &amp;lt;y-offset&amp;gt;, and &amp;lt;z-offset&amp;gt; tags which use imperial units and have the x-axis reversed.}}&lt;br /&gt;
&lt;br /&gt;
=== Step 3 of 6: Re-use configuration values (optional) ===&lt;br /&gt;
&lt;br /&gt;
If you want to create multiple instances of the same kind of submodel, for example, multiple guns of the same type, then you should alias tags that you want to re-use:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;phalanx&amp;gt;&lt;br /&gt;
        &amp;lt;model&amp;gt;Aircraft/CVN-70/Models/M61A1/apibullet-tracer.xml&amp;lt;/model&amp;gt;&lt;br /&gt;
        &amp;lt;speed&amp;gt;3650.0&amp;lt;/speed&amp;gt;&lt;br /&gt;
        ...&lt;br /&gt;
    &amp;lt;/phalanx&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;submodel&amp;gt;&lt;br /&gt;
        &amp;lt;name&amp;gt;Phalanx Forward Left M61A1 Bullet Tracer Round&amp;lt;/name&amp;gt;&lt;br /&gt;
        &amp;lt;trigger&amp;gt;/sim/multiplay/generic/int[3]&amp;lt;/trigger&amp;gt;&lt;br /&gt;
        &amp;lt;model alias=&amp;quot;/phalanx/model&amp;quot;/&amp;gt;&lt;br /&gt;
        &amp;lt;speed alias=&amp;quot;/phalanx/speed&amp;quot;/&amp;gt;&lt;br /&gt;
        ...&lt;br /&gt;
    &amp;lt;/submodel&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;submodel&amp;gt;&lt;br /&gt;
        &amp;lt;name&amp;gt;Phalanx Forward Right M61A1 Bullet Tracer Round&amp;lt;/name&amp;gt;&lt;br /&gt;
        &amp;lt;trigger&amp;gt;/sim/multiplay/generic/int[2]&amp;lt;/trigger&amp;gt;&lt;br /&gt;
        &amp;lt;model alias=&amp;quot;/phalanx/model&amp;quot;/&amp;gt;&lt;br /&gt;
        &amp;lt;speed alias=&amp;quot;/phalanx/speed&amp;quot;/&amp;gt;&lt;br /&gt;
        ...&lt;br /&gt;
    &amp;lt;/submodel&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
As you can see, the speed is defined in just one place instead of two. If you ever need to adjust the speed of all the submodels, you only have to adjust one number.&lt;br /&gt;
&lt;br /&gt;
=== Step 4 of 6: Add the submodel to your model ===&lt;br /&gt;
&lt;br /&gt;
This is very simple. First, add these lines to your model ~-set.xml file within the &amp;lt;sim&amp;gt;&amp;lt;/sim&amp;gt; tag:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;submodels&amp;gt;&lt;br /&gt;
        &amp;lt;serviceable type=&amp;quot;bool&amp;quot;&amp;gt;true&amp;lt;/serviceable&amp;gt;&lt;br /&gt;
        &amp;lt;path&amp;gt;Aircraft/seahawk/Models/seahawk-submodels3.xml&amp;lt;/path&amp;gt;&lt;br /&gt;
    &amp;lt;/submodels&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Where &amp;lt;path&amp;gt; is the path to the file you created at Step 1 above. If you want to add submodels to an AI Object, add the same lines within the &amp;lt;scenario&amp;gt;&amp;lt;/scenario&amp;gt; tag in the scenario file which instantiates the AI Object. &lt;br /&gt;
&lt;br /&gt;
=== Step 5 of 6: Control the release of the submodel ===&lt;br /&gt;
&lt;br /&gt;
There is no built-in way of setting/toggling the trigger property so you will need to add some mechanism to do this. A suitable key binding might be:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;key n=&amp;quot;10&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;name&amp;gt;Ctrl-J&amp;lt;/name&amp;gt;&lt;br /&gt;
    &amp;lt;desc&amp;gt;Jettison Port and Stbd Pylon Stores.&amp;lt;/desc&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;!-- port inner --&amp;gt;&lt;br /&gt;
    &amp;lt;binding&amp;gt;&lt;br /&gt;
        &amp;lt;command&amp;gt;property-assign&amp;lt;/command&amp;gt;&lt;br /&gt;
        &amp;lt;property&amp;gt;controls/armament/station[0]/jettison-all&amp;lt;/property&amp;gt;&lt;br /&gt;
        &amp;lt;value type=&amp;quot;bool&amp;quot;&amp;gt;1&amp;lt;/value&amp;gt;&lt;br /&gt;
    &amp;lt;/binding&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;!-- stbd inner --&amp;gt;&lt;br /&gt;
    &amp;lt;binding&amp;gt;&lt;br /&gt;
        &amp;lt;command&amp;gt;property-assign&amp;lt;/command&amp;gt;&lt;br /&gt;
        &amp;lt;property&amp;gt;controls/armament/station[1]/jettison-all&amp;lt;/property&amp;gt;&lt;br /&gt;
        &amp;lt;value type=&amp;quot;bool&amp;quot;&amp;gt;1&amp;lt;/value&amp;gt;&lt;br /&gt;
    &amp;lt;/binding&amp;gt;&lt;br /&gt;
&amp;lt;/key&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Step 6 of 6: Terminate the submodel ===&lt;br /&gt;
&lt;br /&gt;
There are 3 ways to terminate your submodel:&lt;br /&gt;
&lt;br /&gt;
# Do nothing: the submodel will die when its life expires or its altitude &amp;lt;= -1000, whichever occurs first.&lt;br /&gt;
# Instantiate a subsquent submodel: &amp;lt;submodel-path&amp;gt; contains the path to the file containing the submodel to be instantiated. Activated if one or more of &amp;lt;collision&amp;gt;, &amp;lt;impact&amp;gt;, or &amp;lt;expiry&amp;gt; are set to true.&lt;br /&gt;
# Instantiate a static model: for this you will need a Nasal fuction:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var droptank_node = props.globals.getNode(&amp;quot;sim/ai/aircraft/impact/droptank&amp;quot;, 1);&lt;br /&gt;
                               &lt;br /&gt;
var droptanks = func(n) {&lt;br /&gt;
    var droptank = droptank_node.getValue();&lt;br /&gt;
    var node = props.globals.getNode(n.getValue(), 1);&lt;br /&gt;
&lt;br /&gt;
    geo.put_model(&amp;quot;Aircraft/seahawk/Models/droptank-hot.xml&amp;quot;,&lt;br /&gt;
        node.getNode(&amp;quot;impact/latitude-deg&amp;quot;).getValue(),&lt;br /&gt;
        node.getNode(&amp;quot;impact/longitude-deg&amp;quot;).getValue(),&lt;br /&gt;
        node.getNode(&amp;quot;impact/elevation-m&amp;quot;).getValue() + 0.25, # +0.25 to ensure the droptank isn't buried&lt;br /&gt;
        node.getNode(&amp;quot;impact/heading-deg&amp;quot;).getValue(),&lt;br /&gt;
    0, 0);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
setlistener(&amp;quot;sim/ai/aircraft/impact/droptank&amp;quot;, droptanks);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The path &amp;lt;tt&amp;gt;sim/ai/aircraft/impact/droptank&amp;lt;/tt&amp;gt; is the one you specified in the tag &amp;lt;submodel-path&amp;gt;. Options 2 and 3 are NOT mutually exclusive. Thus you can both instantiate a static model AND instantiate a subsequent submodel.&lt;br /&gt;
As above, this is activated if one or more of &amp;lt;collision&amp;gt;, &amp;lt;impact&amp;gt;, or &amp;lt;expiry&amp;gt; are set to true.&lt;br /&gt;
&lt;br /&gt;
=== Notes ===&lt;br /&gt;
 &lt;br /&gt;
# A submodel will create an AIBallistic object which will follow a ballistic path. By default one submodel will be released when the corresponding trigger is &amp;quot;true&amp;quot;. The initial conditions (IC) define the object's starting point (relative to the user model's current position), and its initial speed and direction (relative to that of the user model aircraft). If you want to release many similar objects with the same IC, then you may use the &amp;lt;repeat&amp;gt;, &amp;lt;delay&amp;gt; and &amp;lt;count&amp;gt; properties to define this.&lt;br /&gt;
# There is a long list of allowable tags. The allowed properties are:&lt;br /&gt;
&lt;br /&gt;
      &amp;lt;name&amp;gt;         The name of the submodel.&lt;br /&gt;
      &amp;lt;model&amp;gt;        The path to the visual model. Any model in any location is allowed. All the normal&lt;br /&gt;
                     animations are available.&lt;br /&gt;
      &amp;lt;trigger&amp;gt;      The property which will act as the trigger. &lt;br /&gt;
      &amp;lt;speed&amp;gt;        Initial speed, in feet/sec, relative to user aircraft.&lt;br /&gt;
      &amp;lt;repeat&amp;gt;       Set &amp;quot;true&amp;quot; if you want multiple releases of this submodel. Defaults&lt;br /&gt;
                     to false&lt;br /&gt;
      &amp;lt;delay&amp;gt;        Time, in seconds, between repeated releases.&lt;br /&gt;
      &amp;lt;count&amp;gt;        Number of submodels available for multiple release.&lt;br /&gt;
      &amp;lt;x-offset&amp;gt;     Submodel's initial fore/aft position relative to user aircraft.  &lt;br /&gt;
                     Fore is positive. (ft)&lt;br /&gt;
      &amp;lt;y-offset&amp;gt;     Submodel's initial left/right position relative to user aircraft.  &lt;br /&gt;
                     Right is positive. (ft)&lt;br /&gt;
      &amp;lt;z-offset&amp;gt;     Submodel's initial up/down position relative to user aircraft.  &lt;br /&gt;
                     Up is positive. (ft)&lt;br /&gt;
      &amp;lt;yaw-offset&amp;gt;   Submodel's initial azimuth, in degrees, relative to user aircraft's&lt;br /&gt;
                     nose.  Right is positive.&lt;br /&gt;
      &amp;lt;pitch-offset&amp;gt; Submodel's initial elevation, in degrees, relative to user aircraft's&lt;br /&gt;
                     pitch.  Up is positive.&lt;br /&gt;
      &amp;lt;buoyancy&amp;gt;     Submodel's upward acceleration (fps) due to buoyancy in air. 32 is &lt;br /&gt;
                     neutral (contrails),  &amp;gt; 32 exhaust gas, smoke. &lt;br /&gt;
      &amp;lt;wind&amp;gt;	     If true, the Submodel is affected by local wind. Defaults to false. This&lt;br /&gt;
                     tag was added to cater for smoke, contrails and the like. The effect of &lt;br /&gt;
                     wind on ballistic objects is not well modelled. For bombs, bulllets etc. &lt;br /&gt;
                     this is best left at the default setting.&lt;br /&gt;
      &amp;lt;cd&amp;gt;           The Coeffient of Drag. Varies with submodel shape - 0.295 for a bullet, &lt;br /&gt;
                     0.045 for an airfoil. Enter an appropriate value. Defaults to 0.295.&lt;br /&gt;
      &amp;lt;eda&amp;gt;          Effective drag area (sq ft). Usually the cross-sectional area of the &lt;br /&gt;
                     submodel normal to the airflow.&lt;br /&gt;
      &amp;lt;weight&amp;gt;       The weight of the submodel (lbs). Defaults to 0.25	&lt;br /&gt;
      &amp;lt;aero-stabilised&amp;gt; If true, the submodel aligns with the local airflow. Defaults to true.&lt;br /&gt;
      &amp;lt;external-force&amp;gt; If true the submodel is subjected to an external force.&lt;br /&gt;
      &amp;lt;force-path&amp;gt;   A string describing the property where the magnitude, azimuth and elevation&lt;br /&gt;
                     of the external force is to be found. The following child properties are&lt;br /&gt;
                     instantiated:&lt;br /&gt;
                        ~/force-lb&lt;br /&gt;
                        ~/force-azimuth-deg&lt;br /&gt;
                        ~/force-elevation-deg&lt;br /&gt;
                     You need to manipulate these properties with some Nasal to apply an external&lt;br /&gt;
                     force to the submodel.&lt;br /&gt;
      &amp;lt;force-stabilised&amp;gt; If true, the submodel aligns with the external force. Defaults to false.&lt;br /&gt;
                     If both this and &amp;lt;aero-stabilised&amp;gt; are true this takes priority.&lt;br /&gt;
      &amp;lt;no-roll&amp;gt;      If true, the submodel does not bank in turns. Defaults to false.&lt;br /&gt;
      &amp;lt;collision&amp;gt;    If true, the position of collisions (or hits) with other non-ballistic &lt;br /&gt;
                     AI models are reported. Defaults to false.&lt;br /&gt;
      &amp;lt;impact&amp;gt;       If this is true the position of impact on the terrain is reported. Defaults to&lt;br /&gt;
                     false.&lt;br /&gt;
      &amp;lt;expiry&amp;gt;       If true, the postion of the Submodel when its life expires is reported. Defaults&lt;br /&gt;
                     to false. Collision, Impact, and Expiry are handled in that order.&lt;br /&gt;
      &amp;lt;impact-reports&amp;gt; A string descibing the location of Collision, Impact, or Expiry position.&lt;br /&gt;
                     Defaults to &amp;quot;/ai/models/model-impact&amp;quot;.&lt;br /&gt;
      &amp;lt;fuse-range&amp;gt;   Range (ft) added to Collision and Impact calculations. Defaults to 0.0.&lt;br /&gt;
      &amp;lt;contents&amp;gt;     A string describing the property where the contents (lbs) of a Submodel are located.&lt;br /&gt;
                     Used with droptanks. Set to zero on release. Defaults to &amp;quot;none&amp;quot;.&lt;br /&gt;
      &amp;lt;speed-prop&amp;gt;   A string describing the property where the initial speed of the Submodel is located.&lt;br /&gt;
                     Defaults to &amp;quot;none&amp;quot;.&lt;br /&gt;
      &amp;lt;submodel-path&amp;gt; A string describing the path to the .xml file where the next submodel Initial &lt;br /&gt;
                     Conditions are located. This submodel will be instantiated when any of Collision&lt;br /&gt;
                     Impact or Expiry are true. Submodels can be linked to any depth using this tag.&lt;br /&gt;
                     Defaults to &amp;quot;&amp;quot;.&lt;br /&gt;
      &amp;lt;random&amp;gt;       If true, initial Azimuth is varied by +- 10 degrees, cd by 10%, and Life by the&lt;br /&gt;
                     value Randomness. Defaults to false.&lt;br /&gt;
      &amp;lt;randomness&amp;gt;   Varies the randomness of Life between 0.0(0%) and 1.0(100%). Defaults to 0.5 (50%).&lt;br /&gt;
      &amp;lt;slaved&amp;gt;       If true the Submodel is slaved to its parent model on release. For a subsequent release &lt;br /&gt;
                     the property &amp;quot;controls/slave-to-ac&amp;quot; must be set to false.&lt;br /&gt;
&lt;br /&gt;
=== Technical stuff ===&lt;br /&gt;
# '''Slaved Objects.''' Slaved objects follow exactly the movements of their parent object. They can be released, when they then become normal Ballistic objects. They are designed for use as underwing stores, such as droptanks, as they give a realistic appearance on release. On the other hand, there is a small framerate cost. Where the stores are carried in a bombbay, this technique is not required. Here, an acceptable appearance can be achieved by adding models of the stores in the bombbay which are hidden on instantiation of the submodel.&lt;br /&gt;
# '''Formations.''' Wingmen are not AI Aircraft. In the interest of framerate they are in fact a sub-class of slaved objects, with added sinusoidal noise and some simple AI rules. They cannot be released to act independently. The formation can be changed by the use of a Nasal script. There is no collision detection or avoidance, so you must avoid flying the wingmen into each other during a formation change. Thare is a significant framerate cost involved. The wingmen can be as simple or complicated as you wish. The ones currently implemented tend to be fully detailed, and can be &amp;quot;ridden&amp;quot;. This is uneccesary, but gives a fun viewpoint of the formation. In due course I will produce a Howto for Wingmen.&lt;br /&gt;
# '''Multiplayer.''' Submodels, indeed all AI objects are not visible over MP. This is in part deliberate (to prevent people trying to shoot at airliners), and in part technical (due to lag on the network the submodels would be nowhere near their actual position). On the other hand, it would be nice to include wingmen and perhaps droptanks in the overall scene. At the moment I cannot come up with a design which works at acceptable framerate cost.&lt;br /&gt;
&lt;br /&gt;
[[Category:Aircraft enhancement|Add submodels]]&lt;br /&gt;
[[Category:Howto|Add submodels]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Howto:Add_submodels&amp;diff=85190</id>
		<title>Howto:Add submodels</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Howto:Add_submodels&amp;diff=85190"/>
		<updated>2015-05-30T17:22:34Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[File:b29s-bombs.jpg|thumb|270px|[[Boeing B-29 Superfortress|B-29s]] dropping their load.]]&lt;br /&gt;
Submodels are the means in [[FlightGear]] whereby we can represent anything which is dropped, fired, or launched from an [[aircraft]] or indeed any model... the possibilies are endless. Some examples which can be found in FlightGear: guns, flares, bombs, droptanks, smoke, contrails. These last to date from a time before particles were implemented in FlightGear. While they still exist in older models, they are probably nowadays best done with particles.&lt;br /&gt;
&lt;br /&gt;
In general, AI Models are instantiated at startup. Submodels, which use only AIBallistic objects, are pre-loaded at startup, but only instantiated when required.&lt;br /&gt;
&lt;br /&gt;
This [[:Category:Howto|howto]] will explain '''how to add submodels''' to your model&lt;br /&gt;
&lt;br /&gt;
=== Step 1 of 6: Create the submodel ===&lt;br /&gt;
&lt;br /&gt;
First, create the file Models/submodels.xml containing a &amp;lt;submodel&amp;gt; inside a &amp;lt;PropertyList tag&amp;gt;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-8&amp;quot;?&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;PropertyList&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;submodel&amp;gt;&lt;br /&gt;
        &amp;lt;name&amp;gt;M-17.001-submodel&amp;lt;/name&amp;gt;&lt;br /&gt;
        &amp;lt;model&amp;gt;/Aircraft/b29/Models/M17.xml&amp;lt;/model&amp;gt;&lt;br /&gt;
        &amp;lt;trigger&amp;gt;/sim/weapons/loadout[1]/bomb[0]/dropped&amp;lt;/trigger&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;repeat&amp;gt;false&amp;lt;/repeat&amp;gt;&lt;br /&gt;
        &amp;lt;count&amp;gt;1&amp;lt;/count&amp;gt;&lt;br /&gt;
        &amp;lt;delay&amp;gt;0&amp;lt;/delay&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;speed&amp;gt;0&amp;lt;/speed&amp;gt;&lt;br /&gt;
        &amp;lt;wind&amp;gt;false&amp;lt;/wind&amp;gt;&lt;br /&gt;
        &amp;lt;aero-stabilised&amp;gt;true&amp;lt;/aero-stabilised&amp;gt;&lt;br /&gt;
        &amp;lt;eda&amp;gt;1.42&amp;lt;/eda&amp;gt;&lt;br /&gt;
        &amp;lt;cd&amp;gt;0.75&amp;lt;/cd&amp;gt;&lt;br /&gt;
        &amp;lt;weight&amp;gt;500&amp;lt;/weight&amp;gt;&lt;br /&gt;
        &amp;lt;life&amp;gt;900&amp;lt;/life&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;impact&amp;gt;true&amp;lt;/impact&amp;gt;&lt;br /&gt;
        &amp;lt;impact-reports&amp;gt;sim/ai/aircraft/impact/bomb&amp;lt;/impact-reports&amp;gt;&lt;br /&gt;
    &amp;lt;/submodel&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/PropertyList&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Measurements (except those in &amp;lt;offsets&amp;gt;, see below) are in Imperial Measure: Feet, Inches, Pounds. This is because the original author(s) were American.&lt;br /&gt;
&lt;br /&gt;
The trigger is a boolean property, which you define, which when &amp;quot;true&amp;quot; causes the submodel to be released/launched. For bombs you want &amp;lt;repeat&amp;gt; to be set to &amp;quot;false&amp;quot;, &amp;lt;count&amp;gt; to 1, and &amp;lt;delay&amp;gt; to 0. For bullets you want to set &amp;lt;repeat&amp;gt; to &amp;quot;true&amp;quot;, &amp;lt;count&amp;gt; to -1, and &amp;lt;delay&amp;gt; to a number greater than zero. If the weapon system has a limited capacity (limited number of bullets) then you should use Nasal or XML (&amp;lt;autopilot&amp;gt; or &amp;lt;property-rule&amp;gt;) to control whether the submodel should be triggered or not.&lt;br /&gt;
&lt;br /&gt;
=== Step 2 of 6: Define the position and orientation ===&lt;br /&gt;
&lt;br /&gt;
Second, define the offset of the submodel with respect to the center of the model. For example, the forward left Phalanx CIWS of the CVN-70 supercarrier uses:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;submodel&amp;gt;&lt;br /&gt;
        ...&lt;br /&gt;
&lt;br /&gt;
        &amp;lt;offsets&amp;gt;&lt;br /&gt;
            &amp;lt;x-m&amp;gt;-121.2666&amp;lt;/x-m&amp;gt;&lt;br /&gt;
            &amp;lt;y-m&amp;gt;-21.1147&amp;lt;/y-m&amp;gt;&lt;br /&gt;
            &amp;lt;z-m&amp;gt;16.8345&amp;lt;/z-m&amp;gt;&lt;br /&gt;
            &amp;lt;heading-deg&amp;gt;&lt;br /&gt;
                &amp;lt;property&amp;gt;/carrier/phalanx/output/forward-left/yaw-deg&amp;lt;/property&amp;gt;&lt;br /&gt;
                &amp;lt;offset&amp;gt;-90.0&amp;lt;/offset&amp;gt;&lt;br /&gt;
            &amp;lt;/heading-deg&amp;gt;&lt;br /&gt;
            &amp;lt;pitch-deg&amp;gt;&lt;br /&gt;
                &amp;lt;property&amp;gt;/carrier/phalanx/output/forward-left/pitch-deg&amp;lt;/property&amp;gt;&lt;br /&gt;
            &amp;lt;/pitch-deg&amp;gt;&lt;br /&gt;
        &amp;lt;/offsets&amp;gt;&lt;br /&gt;
&lt;br /&gt;
        ...&lt;br /&gt;
    &amp;lt;/submodel&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The various tags inside the &amp;lt;offsets&amp;gt; tag support certain tags also seen in &amp;lt;autopilot&amp;gt; files: &amp;lt;property&amp;gt;, &amp;lt;expression&amp;gt;, &amp;lt;value&amp;gt;, &amp;lt;scale&amp;gt;, &amp;lt;offset&amp;gt;, &amp;lt;min&amp;gt;, &amp;lt;max&amp;gt;, &amp;lt;abs&amp;gt;, and &amp;lt;period&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{tip|Use these to control the submodel's initial position and orientation during runtime. For example, to control the pitch and heading of a Phalanx CIWS (Close-In Weapon System).&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
{{note|The &amp;lt;x-m&amp;gt;, &amp;lt;y-m&amp;gt;, and &amp;lt;z-m&amp;gt; use metric units and have the same coordinate system as the main model. This is unlike the old &amp;lt;x-offset&amp;gt;, &amp;lt;y-offset&amp;gt;, and &amp;lt;z-offset&amp;gt; tags which use imperial units and have the x-axis reversed.}}&lt;br /&gt;
&lt;br /&gt;
=== Step 3 of 6: Re-use configuration values (optional) ===&lt;br /&gt;
&lt;br /&gt;
If you want to create multiple instances of the same kind of submodel, for example, multiple guns of the same type, then you should alias tags that you want to re-use:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;phalanx&amp;gt;&lt;br /&gt;
        &amp;lt;model&amp;gt;Aircraft/CVN-70/Models/M61A1/apibullet-tracer.xml&amp;lt;/model&amp;gt;&lt;br /&gt;
        &amp;lt;speed&amp;gt;3650.0&amp;lt;/speed&amp;gt;&lt;br /&gt;
        ...&lt;br /&gt;
    &amp;lt;/phalanx&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;submodel&amp;gt;&lt;br /&gt;
        &amp;lt;name&amp;gt;Phalanx Forward Left M61A1 Bullet Tracer Round&amp;lt;/name&amp;gt;&lt;br /&gt;
        &amp;lt;trigger&amp;gt;/sim/multiplay/generic/int[3]&amp;lt;/trigger&amp;gt;&lt;br /&gt;
        &amp;lt;model alias=&amp;quot;/phalanx/model&amp;quot;/&amp;gt;&lt;br /&gt;
        &amp;lt;speed alias=&amp;quot;/phalanx/speed&amp;quot;/&amp;gt;&lt;br /&gt;
        ...&lt;br /&gt;
    &amp;lt;/submodel&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;submodel&amp;gt;&lt;br /&gt;
        &amp;lt;name&amp;gt;Phalanx Forward Right M61A1 Bullet Tracer Round&amp;lt;/name&amp;gt;&lt;br /&gt;
        &amp;lt;trigger&amp;gt;/sim/multiplay/generic/int[2]&amp;lt;/trigger&amp;gt;&lt;br /&gt;
        &amp;lt;model alias=&amp;quot;/phalanx/model&amp;quot;/&amp;gt;&lt;br /&gt;
        &amp;lt;speed alias=&amp;quot;/phalanx/speed&amp;quot;/&amp;gt;&lt;br /&gt;
        ...&lt;br /&gt;
    &amp;lt;/submodel&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
As you can see, the speed is defined in just one place instead of two. If you ever need to adjust the speed of all the submodels, you only have to adjust one number.&lt;br /&gt;
&lt;br /&gt;
=== Step 4 of 6: Add the submodel to your model ===&lt;br /&gt;
&lt;br /&gt;
This is very simple. First, add these lines to your model ~-set.xml file within the &amp;lt;sim&amp;gt;&amp;lt;/sim&amp;gt; tag:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;submodels&amp;gt;&lt;br /&gt;
     &amp;lt;serviceable type=&amp;quot;bool&amp;quot;&amp;gt;true&amp;lt;/serviceable&amp;gt;&lt;br /&gt;
     &amp;lt;path&amp;gt;Aircraft/seahawk/Models/seahawk-submodels3.xml&amp;lt;/path&amp;gt;&lt;br /&gt;
   &amp;lt;/submodels&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Where &amp;lt;path&amp;gt; is the path to the file you created at Step 1 above. If you want to add submodels to an AI Object, add the same lines within the &amp;lt;scenario&amp;gt;&amp;lt;/scenario&amp;gt; tag in the scenario file which instantiates the AI Object. &lt;br /&gt;
&lt;br /&gt;
=== Step 5 of 6: Control the release of the submodel ===&lt;br /&gt;
&lt;br /&gt;
There is no built-in way of setting/toggling the trigger property so you will need to add some mechanism to do this. A suitable key binding might be:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;key n=&amp;quot;10&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;name&amp;gt;Ctrl-J&amp;lt;/name&amp;gt;&lt;br /&gt;
    &amp;lt;desc&amp;gt;Jettison Port and Stbd Pylon Stores.&amp;lt;/desc&amp;gt;&lt;br /&gt;
    &amp;lt;!-- port inner --&amp;gt;&lt;br /&gt;
    &amp;lt;binding&amp;gt;&lt;br /&gt;
      &amp;lt;command&amp;gt;property-assign&amp;lt;/command&amp;gt;&lt;br /&gt;
      &amp;lt;property&amp;gt;controls/armament/station[0]/jettison-all&amp;lt;/property&amp;gt;&lt;br /&gt;
      &amp;lt;value type=&amp;quot;bool&amp;quot;&amp;gt;1&amp;lt;/value&amp;gt;&lt;br /&gt;
    &amp;lt;/binding&amp;gt;&lt;br /&gt;
    &amp;lt;!-- stbd inner --&amp;gt;&lt;br /&gt;
    &amp;lt;binding&amp;gt;&lt;br /&gt;
      &amp;lt;command&amp;gt;property-assign&amp;lt;/command&amp;gt;&lt;br /&gt;
      &amp;lt;property&amp;gt;controls/armament/station[1]/jettison-all&amp;lt;/property&amp;gt;&lt;br /&gt;
      &amp;lt;value type=&amp;quot;bool&amp;quot;&amp;gt;1&amp;lt;/value&amp;gt;&lt;br /&gt;
    &amp;lt;/binding&amp;gt;&lt;br /&gt;
  &amp;lt;/key&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Step 6 of 6: Terminate the submodel ===&lt;br /&gt;
&lt;br /&gt;
There are 3 ways to terminate your submodel:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
# Do nothing: the submodel will die when its life expires or its altitude &amp;lt;= -1000, whichever occurs first.&lt;br /&gt;
# Instantiate a subsquent submodel: &amp;lt;submodel-path&amp;gt; contains the path to the file containing the submodel to be instantiated. Activated if one or more of &amp;lt;collision&amp;gt;, &amp;lt;impact&amp;gt;, or &amp;lt;expiry&amp;gt; are set to true.&lt;br /&gt;
# Instantiate a static model: for this you will need a Nasal fuction:&lt;br /&gt;
&lt;br /&gt;
  var droptank_node = props.globals.getNode(&amp;quot;sim/ai/aircraft/impact/droptank&amp;quot;,1);&lt;br /&gt;
                                   &lt;br /&gt;
  var droptanks = func(n) {&lt;br /&gt;
    var droptank = droptank_node.getValue();&lt;br /&gt;
    var node = props.globals.getNode(n.getValue(), 1);&lt;br /&gt;
    geo.put_model(&amp;quot;Aircraft/seahawk/Models/droptank-hot.xml&amp;quot;,&lt;br /&gt;
                node.getNode(&amp;quot;impact/latitude-deg&amp;quot;).getValue(),&lt;br /&gt;
                node.getNode(&amp;quot;impact/longitude-deg&amp;quot;).getValue(),&lt;br /&gt;
                node.getNode(&amp;quot;impact/elevation-m&amp;quot;).getValue()+ 0.25, #+0.25 to ensure the droptank isn't buried&lt;br /&gt;
                node.getNode(&amp;quot;impact/heading-deg&amp;quot;).getValue(),&lt;br /&gt;
                0,&lt;br /&gt;
                0&lt;br /&gt;
                );&lt;br /&gt;
  }&lt;br /&gt;
  &lt;br /&gt;
  setlistener(&amp;quot;sim/ai/aircraft/impact/droptank&amp;quot;, droptanks);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The path &amp;lt;tt&amp;gt;sim/ai/aircraft/impact/droptank&amp;lt;/tt&amp;gt; is the one you specified in the tag &amp;lt;submodel-path&amp;gt;. Options 2 and 3 are NOT mutually exclusive. Thus you can both instantiate a static model AND instantiate a subsequent submodel.&lt;br /&gt;
As above, this is activated if one or more of &amp;lt;collision&amp;gt;, &amp;lt;impact&amp;gt;, or &amp;lt;expiry&amp;gt; are set to true.&lt;br /&gt;
&lt;br /&gt;
=== Notes ===&lt;br /&gt;
 &lt;br /&gt;
# A submodel will create an AIBallistic object which will follow a ballistic path. By default one submodel will be released when the corresponding trigger is &amp;quot;true&amp;quot;. The initial conditions (IC) define the object's starting point (relative to the user model's current position), and its initial speed and direction (relative to that of the user model aircraft). If you want to release many similar objects with the same IC, then you may use the &amp;lt;repeat&amp;gt;, &amp;lt;delay&amp;gt; and &amp;lt;count&amp;gt; properties to define this.&lt;br /&gt;
# There is a long list of allowable tags. The allowed properties are:&lt;br /&gt;
&lt;br /&gt;
      &amp;lt;name&amp;gt;         The name of the submodel.&lt;br /&gt;
      &amp;lt;model&amp;gt;        The path to the visual model. Any model in any location is allowed. All the normal&lt;br /&gt;
                     animations are available.&lt;br /&gt;
      &amp;lt;trigger&amp;gt;      The property which will act as the trigger. &lt;br /&gt;
      &amp;lt;speed&amp;gt;        Initial speed, in feet/sec, relative to user aircraft.&lt;br /&gt;
      &amp;lt;repeat&amp;gt;       Set &amp;quot;true&amp;quot; if you want multiple releases of this submodel. Defaults&lt;br /&gt;
                     to false&lt;br /&gt;
      &amp;lt;delay&amp;gt;        Time, in seconds, between repeated releases.&lt;br /&gt;
      &amp;lt;count&amp;gt;        Number of submodels available for multiple release.&lt;br /&gt;
      &amp;lt;x-offset&amp;gt;     Submodel's initial fore/aft position relative to user aircraft.  &lt;br /&gt;
                     Fore is positive. (ft)&lt;br /&gt;
      &amp;lt;y-offset&amp;gt;     Submodel's initial left/right position relative to user aircraft.  &lt;br /&gt;
                     Right is positive. (ft)&lt;br /&gt;
      &amp;lt;z-offset&amp;gt;     Submodel's initial up/down position relative to user aircraft.  &lt;br /&gt;
                     Up is positive. (ft)&lt;br /&gt;
      &amp;lt;yaw-offset&amp;gt;   Submodel's initial azimuth, in degrees, relative to user aircraft's&lt;br /&gt;
                     nose.  Right is positive.&lt;br /&gt;
      &amp;lt;pitch-offset&amp;gt; Submodel's initial elevation, in degrees, relative to user aircraft's&lt;br /&gt;
                     pitch.  Up is positive.&lt;br /&gt;
      &amp;lt;buoyancy&amp;gt;     Submodel's upward acceleration (fps) due to buoyancy in air. 32 is &lt;br /&gt;
                     neutral (contrails),  &amp;gt; 32 exhaust gas, smoke. &lt;br /&gt;
      &amp;lt;wind&amp;gt;	     If true, the Submodel is affected by local wind. Defaults to false. This&lt;br /&gt;
                     tag was added to cater for smoke, contrails and the like. The effect of &lt;br /&gt;
                     wind on ballistic objects is not well modelled. For bombs, bulllets etc. &lt;br /&gt;
                     this is best left at the default setting.&lt;br /&gt;
      &amp;lt;cd&amp;gt;           The Coeffient of Drag. Varies with submodel shape - 0.295 for a bullet, &lt;br /&gt;
                     0.045 for an airfoil. Enter an appropriate value. Defaults to 0.295.&lt;br /&gt;
      &amp;lt;eda&amp;gt;          Effective drag area (sq ft). Usually the cross-sectional area of the &lt;br /&gt;
                     submodel normal to the airflow.&lt;br /&gt;
      &amp;lt;weight&amp;gt;       The weight of the submodel (lbs). Defaults to 0.25	&lt;br /&gt;
      &amp;lt;aero-stabilised&amp;gt; If true, the submodel aligns with the local airflow. Defaults to true.&lt;br /&gt;
      &amp;lt;external-force&amp;gt; If true the submodel is subjected to an external force.&lt;br /&gt;
      &amp;lt;force-path&amp;gt;   A string describing the property where the magnitude, azimuth and elevation&lt;br /&gt;
                     of the external force is to be found. The following child properties are&lt;br /&gt;
                     instantiated:&lt;br /&gt;
                        ~/force-lb&lt;br /&gt;
                        ~/force-azimuth-deg&lt;br /&gt;
                        ~/force-elevation-deg&lt;br /&gt;
                     You need to manipulate these properties with some Nasal to apply an external&lt;br /&gt;
                     force to the submodel.&lt;br /&gt;
      &amp;lt;force-stabilised&amp;gt; If true, the submodel aligns with the external force. Defaults to false.&lt;br /&gt;
                     If both this and &amp;lt;aero-stabilised&amp;gt; are true this takes priority.&lt;br /&gt;
      &amp;lt;no-roll&amp;gt;      If true, the submodel does not bank in turns. Defaults to false.&lt;br /&gt;
      &amp;lt;collision&amp;gt;    If true, the position of collisions (or hits) with other non-ballistic &lt;br /&gt;
                     AI models are reported. Defaults to false.&lt;br /&gt;
      &amp;lt;impact&amp;gt;       If this is true the position of impact on the terrain is reported. Defaults to&lt;br /&gt;
                     false.&lt;br /&gt;
      &amp;lt;expiry&amp;gt;       If true, the postion of the Submodel when its life expires is reported. Defaults&lt;br /&gt;
                     to false. Collision, Impact, and Expiry are handled in that order.&lt;br /&gt;
      &amp;lt;impact-reports&amp;gt; A string descibing the location of Collision, Impact, or Expiry position.&lt;br /&gt;
                     Defaults to &amp;quot;/ai/models/model-impact&amp;quot;.&lt;br /&gt;
      &amp;lt;fuse-range&amp;gt;   Range (ft) added to Collision and Impact calculations. Defaults to 0.0.&lt;br /&gt;
      &amp;lt;contents&amp;gt;     A string describing the property where the contents (lbs) of a Submodel are located.&lt;br /&gt;
                     Used with droptanks. Set to zero on release. Defaults to &amp;quot;none&amp;quot;.&lt;br /&gt;
      &amp;lt;speed-prop&amp;gt;   A string describing the property where the initial speed of the Submodel is located.&lt;br /&gt;
                     Defaults to &amp;quot;none&amp;quot;.&lt;br /&gt;
      &amp;lt;submodel-path&amp;gt; A string describing the path to the .xml file where the next submodel Initial &lt;br /&gt;
                     Conditions are located. This submodel will be instantiated when any of Collision&lt;br /&gt;
                     Impact or Expiry are true. Submodels can be linked to any depth using this tag.&lt;br /&gt;
                     Defaults to &amp;quot;&amp;quot;.&lt;br /&gt;
      &amp;lt;random&amp;gt;       If true, initial Azimuth is varied by +- 10 degrees, cd by 10%, and Life by the&lt;br /&gt;
                     value Randomness. Defaults to false.&lt;br /&gt;
      &amp;lt;randomness&amp;gt;   Varies the randomness of Life between 0.0(0%) and 1.0(100%). Defaults to 0.5 (50%).&lt;br /&gt;
      &amp;lt;slaved&amp;gt;       If true the Submodel is slaved to its parent model on release. For a subsequent release &lt;br /&gt;
                     the property &amp;quot;controls/slave-to-ac&amp;quot; must be set to false.&lt;br /&gt;
&lt;br /&gt;
=== Technical stuff ===&lt;br /&gt;
# '''Slaved Objects.''' Slaved objects follow exactly the movements of their parent object. They can be released, when they then become normal Ballistic objects. They are designed for use as underwing stores, such as droptanks, as they give a realistic appearance on release. On the other hand, there is a small framerate cost. Where the stores are carried in a bombbay, this technique is not required. Here, an acceptable appearance can be achieved by adding models of the stores in the bombbay which are hidden on instantiation of the submodel.&lt;br /&gt;
# '''Formations.''' Wingmen are not AI Aircraft. In the interest of framerate they are in fact a sub-class of slaved objects, with added sinusoidal noise and some simple AI rules. They cannot be released to act independently. The formation can be changed by the use of a Nasal script. There is no collision detection or avoidance, so you must avoid flying the wingmen into each other during a formation change. Thare is a significant framerate cost involved. The wingmen can be as simple or complicated as you wish. The ones currently implemented tend to be fully detailed, and can be &amp;quot;ridden&amp;quot;. This is uneccesary, but gives a fun viewpoint of the formation. In due course I will produce a Howto for Wingmen.&lt;br /&gt;
# '''Multiplayer.''' Submodels, indeed all AI objects are not visible over MP. This is in part deliberate (to prevent people trying to shoot at airliners), and in part technical (due to lag on the network the submodels would be nowhere near their actual position). On the other hand, it would be nice to include wingmen and perhaps droptanks in the overall scene. At the moment I cannot come up with a design which works at acceptable framerate cost.&lt;br /&gt;
&lt;br /&gt;
[[Category:Aircraft enhancement|Add submodels]]&lt;br /&gt;
[[Category:Howto|Add submodels]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=FlightGear_Newsletter_April_2015&amp;diff=83717</id>
		<title>FlightGear Newsletter April 2015</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=FlightGear_Newsletter_April_2015&amp;diff=83717"/>
		<updated>2015-04-22T08:31:05Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{draft|newsletter|Please feel free to add content you think will be of interest to the FlightGear community. Read the latest newsletter at [[FlightGear Newsletter March 2015]].}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{Newsletter-header|April 2015}}&lt;br /&gt;
&amp;lt;div style=&amp;quot;border-bottom:3px double #BBB;&amp;quot;&amp;gt;&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; |&lt;br /&gt;
 | valign=&amp;quot;top&amp;quot; width=&amp;quot;33%&amp;quot; |&lt;br /&gt;
{{Newsletter-cover-header|Development news}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#FlightGear now lives at SourceForge|FlightGear now lives at SourceForge]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#OpenRTI move|OpenRTI move]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Spaceflight|Spaceflight]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Understanding Rembrandt and Vsync|Understanding Rembrandt and Vsync]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#SVG transparency|SVG transparency]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Optional collision detection in multiplayer|Optional collision detection in multiplayer]]&amp;lt;br/&amp;gt;&lt;br /&gt;
 | valign=&amp;quot;top&amp;quot; width=&amp;quot;33%&amp;quot; |&lt;br /&gt;
{{Newsletter-cover-header|In the hanger}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Boeing 707 liveries|Boeing 707 liveries]]&amp;lt;br/&amp;gt;&lt;br /&gt;
{{Newsletter-cover-header|Scenery Corner}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Belgium airports|Belgium airports]]&amp;lt;br/&amp;gt;&lt;br /&gt;
{{Newsletter-cover-header|Community News}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#FlightGear: featured project at SourceForge|FlightGear: featured project at SourceForge]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#FG Flights blog|FG Flights blog]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#New FGCom server maintainer|New FGCom server maintainer]]&amp;lt;br/&amp;gt;&lt;br /&gt;
 | valign=&amp;quot;top&amp;quot; width=&amp;quot;33%&amp;quot; |&lt;br /&gt;
{{Newsletter-cover-header|Contributing}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Better accessibility for FlightGear|Better accessibility for FlightGear]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Translators required|Translators required]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#FlightGear logos|FlightGear logos]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Screenshots|Screenshots]]&lt;br /&gt;
|}&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Development news ==&lt;br /&gt;
=== OSG Support ===&lt;br /&gt;
{{FGCquote&lt;br /&gt;
  |I made a commit to SimGear that fixes compilation with current OSG sources.&amp;lt;br/&amp;gt;&lt;br /&gt;
Unfortunately, FlightGear doesn't actually work with this OSG due to a bug&amp;lt;br/&amp;gt;&lt;br /&gt;
in the mesh optimizer. If you want to use current OSG, check the&amp;lt;br/&amp;gt;&lt;br /&gt;
osg-submissions mailing list for my fix.&lt;br /&gt;
  |{{cite web |url=http://sourceforge.net/p/flightgear/mailman/message/33913629/&lt;br /&gt;
     |title=&amp;lt;nowiki&amp;gt;[Flightgear-devel] OSG 3.3.8 heads up&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
     |author=&amp;lt;nowiki&amp;gt;Tim Moore&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
     |date=&amp;lt;nowiki&amp;gt;2015-04-19&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
   }}&lt;br /&gt;
}}&lt;br /&gt;
=== FlightGear now lives at SourceForge ===&lt;br /&gt;
The move from Gitorious to SourceForge is now complete.  A historical read-only record will remain at [http://gitorious.org Gitorious.org], as well as other public locations.&amp;lt;ref&amp;gt;http://sourceforge.net/p/flightgear/mailman/message/33832698/&amp;lt;/ref&amp;gt;  In addition, hooks have been added so that every commit to either the [http://sourceforge.net/p/flightgear/flightgear/ FlightGear], [http://sourceforge.net/p/flightgear/simgear/ SimGear] or [http://sourceforge.net/p/flightgear/fgdata/ FGData] repositories will (hopefully) send a message to the [http://sourceforge.net/p/flightgear/mailman/flightgear-commitlogs/ flightgear-commitlogs mailing list].&amp;lt;ref&amp;gt;http://sourceforge.net/p/flightgear/mailman/message/33827961/&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{FGCquote&lt;br /&gt;
  |One additional thing to keep in mind is that our flightgear-commitlogs&amp;lt;br/&amp;gt;&lt;br /&gt;
mailing list has a maximum message size configured to 160Kb.  Messages&amp;lt;br/&amp;gt;&lt;br /&gt;
larger than this get sent over to the list moderator.  That may be why some&amp;lt;br/&amp;gt;&lt;br /&gt;
of these messages are delayed.  I mentioned this to Torsten offline and it&amp;lt;br/&amp;gt;&lt;br /&gt;
sounded like he had some ideas for ensuring that extra long diffs get&amp;lt;br/&amp;gt;&lt;br /&gt;
trimmed to a reasonable size for a mailing list.&lt;br /&gt;
  |{{cite web |url=http://sourceforge.net/p/flightgear/mailman/message/33913347/&lt;br /&gt;
     |title=&amp;lt;nowiki&amp;gt;Re: [Flightgear-devel] [Flightgear-commitlogs] [FGData] FlightGear&lt;br /&gt;
 data - next generation branch next updated.&lt;br /&gt;
 7b595eca19e1bfb83ae330c02f2eeec5e9c9da58&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
     |author=&amp;lt;nowiki&amp;gt;Curtis Olson&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
     |date=&amp;lt;nowiki&amp;gt;2015-04-19&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
   }}&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== OpenRTI move ===&lt;br /&gt;
The OpenRTI project, maintained by Mathias Fröhlich, has been moved from Gitorious to [http://sourceforge.net/projects/openrti/?source=directory SourceForge].&amp;lt;ref&amp;gt;{{cite web&lt;br /&gt;
|url    = http://sourceforge.net/p/flightgear/mailman/message/33852792/&lt;br /&gt;
|title  = &amp;lt;nowiki&amp;gt;[Flightgear-devel] OpenRTI gitorious git repository deleted&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
|author = &amp;lt;nowiki&amp;gt;Mathias Fröhlich&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
|date   = April 16, 2015&lt;br /&gt;
}}&amp;lt;/ref&amp;gt;  OpenRTI is an open-source {{Abbr|HLA|High-level architecture}}/{{Abbr|RTI|Run-time infrastructure}} implementation, used by FlightGear.  To move your local clone over to the Sourceforge repository, you can just set the URL of your remote repository to the new URL. Below is an example for the usual clone (where the default remote repository is called '''origin'''):&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;bash&amp;quot;&amp;gt;&lt;br /&gt;
git remote set-url origin git://git.code.sf.net/p/openrti/OpenRTI&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== State Machine Support ===&lt;br /&gt;
{{FGCquote&lt;br /&gt;
  |I have just added a the relevant documentation to the wiki:&amp;lt;br/&amp;gt;&lt;br /&gt;
http://wiki.flightgear.org/Autopilot_configuration_reference#State_Machine_.3Cstate-machine.3E&amp;lt;br/&amp;gt;&lt;br /&gt;
I have also fixed a related bug in SimGear, so make sure you have pulled up&amp;lt;br/&amp;gt;&lt;br /&gt;
to this patch:&amp;lt;br/&amp;gt;&lt;br /&gt;
http://sourceforge.net/p/flightgear/simgear/ci/fd740959391ac4c54012fe101bf872eddb9ee303/&amp;lt;br/&amp;gt;&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
If someone with a better wiki-fu can beautify my addition, that'd be great.&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  |{{cite web |url=http://sourceforge.net/p/flightgear/mailman/message/33941746/&lt;br /&gt;
     |title=&amp;lt;nowiki&amp;gt;Re: [Flightgear-devel] Automated Checklist Execution&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
     |author=&amp;lt;nowiki&amp;gt;Torsten Dreyer&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
     |date=&amp;lt;nowiki&amp;gt;2015-04-21&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
   }}&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Spaceflight ===&lt;br /&gt;
Development and test of spaceflight in FlightGear continues. Based on information in the official crew manual, the Space Shuttle has received various digital autopilot (DAP) modes for maneuvering in orbit and an improved control logic for thrust vectoring during ascent. A guidance computer for re-entry has been added to aid trajectory management during this rather challenging part of the mission. The spacecraft has now been tested for a successful de-orbit maneuver aimed at a pre-selected landing site.&lt;br /&gt;
&lt;br /&gt;
Work on simulating the aerodynamic, thermal and structural limits of the orbiter, as well as damage, is currently in progress.&lt;br /&gt;
&lt;br /&gt;
[[File:Shuttle Cockpit.jpg|400px|Cockpit of the Space Shuttle as of April 2015]]&lt;br /&gt;
[[File:Shuttle map.jpg|400px|Ground track map for spaceflight]]&lt;br /&gt;
&lt;br /&gt;
The addition of a 3D cockpit has also begun; currently, most instruments are simply static textures, but several displays should be functional soon. Other developments are more generally useful beyond the Shuttle, such as a ground track map and improvements to the Earthview rendering engine using procedural overlay texturing, making textures appear at higher resolution than they actually are.&lt;br /&gt;
&lt;br /&gt;
Test flights using a [[Nasal]]-controlled object on an analytically-computed Kepler orbiter suggest that docking to an AI space station or interactions with satellites should in fact be quite possible to implement.&lt;br /&gt;
&lt;br /&gt;
Modelers interested in realistic spaceflight are very welcome to come aboard and help taking FlightGear to the limits.&lt;br /&gt;
&lt;br /&gt;
=== Understanding Rembrandt and Vsync ===&lt;br /&gt;
Richard Harrison has been looking into Rembrandt to find the cause of unreasonably low frame rate.&amp;lt;ref&amp;gt;{{cite web&lt;br /&gt;
|url = http://sourceforge.net/p/flightgear/mailman/message/33671091/&lt;br /&gt;
|title = &amp;lt;nowiki&amp;gt;[Flightgear-devel] Deferred rendering (Rembrandt) performance&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
|author = Richard Harrison&lt;br /&gt;
|date = March 29, 2015&lt;br /&gt;
}}&amp;lt;/ref&amp;gt;  To cut a long story short, he has found that {{Abbr|Vsync|Vertical synchronization}} is causing the problems.  After making some changes to the code so that he could turn Vsync on or off, he found that the following command line options provide a great increase in performance:&lt;br /&gt;
{{note|The first flag sets a custom property created during his tests; it isn't available in normal FlightGear.}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;bash&amp;quot;&amp;gt;&lt;br /&gt;
--prop:/sim/rendering/vsync-enable=false&lt;br /&gt;
--prop:/sim/frame-rate-throttle-hz=60&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
These flags increased his frame rate from 30 fps to 60 fps (when drawing nothing).&lt;br /&gt;
&lt;br /&gt;
You can read the full report at http://chateau-logic.com/content/deferred-rendering-rembrandt-performance.&lt;br /&gt;
&lt;br /&gt;
See also [[FlightGear I/O Considerations#Understanding VSync|Understanding Vsync]].&lt;br /&gt;
&lt;br /&gt;
=== SVG transparency ===&lt;br /&gt;
A small patch has enabled Canvas to display transparency in an SVG file.&lt;br /&gt;
&lt;br /&gt;
Currently, there is only support for the {{Func link|fill-opacity|ext=https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/fill-opacity}} and {{Func link|stroke-opacity|ext=https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/stroke-opacity}} properties, but there is a small bug if the value is 0.0.&lt;br /&gt;
&lt;br /&gt;
See commits [http://sourceforge.net/u/userid-1550991/flightgear/ci/7b71a8f361ce735372ed1cbacd7a2b66226d4e73/] and [http://sourceforge.net/u/userid-1550991/flightgear/ci/acb88337f2f31104752230cdc755143211a46ec5/].&lt;br /&gt;
&lt;br /&gt;
{| align=&amp;quot;center&amp;quot;&lt;br /&gt;
! Before !! After&lt;br /&gt;
|-&lt;br /&gt;
| [[File:Be for SVG Transparent.png|400px|Before patches]] || [[File:After SVG Transparent.png|400px|After patches]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Nasal &amp;amp; Canvas 101: Loading SVG Images ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Screenshot !! Code&lt;br /&gt;
|-&lt;br /&gt;
| [[File:Canvas-svg-support.png|thumb|screen shot demonstrating how the scripted Nasal-based SVG parser can be used to dynamically turn SVG files into OpenVG instructions understood by Canvas]] &lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot; enclose=&amp;quot;div&amp;quot;&amp;gt;&lt;br /&gt;
var (width,height) = (320,160);&lt;br /&gt;
var title = 'My new Window';&lt;br /&gt;
&lt;br /&gt;
# create a new window, dimensions are WIDTH x HEIGHT, using the dialog decoration (i.e. titlebar)&lt;br /&gt;
var window = canvas.Window.new([width,height],&amp;quot;dialog&amp;quot;)&lt;br /&gt;
 .set('title',title);&lt;br /&gt;
&lt;br /&gt;
# adding a canvas to the new window and setting up background colors/transparency&lt;br /&gt;
var myCanvas = window.createCanvas().set(&amp;quot;background&amp;quot;, canvas.style.getColor(&amp;quot;bg_color&amp;quot;));&lt;br /&gt;
&lt;br /&gt;
# Using specific css colors would also be possible:&lt;br /&gt;
# myCanvas.set(&amp;quot;background&amp;quot;, &amp;quot;#ffaac0&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
# creating the top-level/root group which will contain all other elements/group&lt;br /&gt;
var root = myCanvas.createGroup();&lt;br /&gt;
&lt;br /&gt;
# change the background color &lt;br /&gt;
myCanvas.set(&amp;quot;background&amp;quot;, &amp;quot;#ffaac0&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
# creating the top-level/root group which will contain all other elements/group&lt;br /&gt;
var root = myCanvas.createGroup();&lt;br /&gt;
&lt;br /&gt;
var filename = &amp;quot;/Nasal/canvas/map/Images/boeingAirplane.svg&amp;quot;;&lt;br /&gt;
var svg_symbol = root.createChild('group');&lt;br /&gt;
canvas.parsesvg(svg_symbol, filename);&lt;br /&gt;
&lt;br /&gt;
svg_symbol.setTranslation(width/2,height/2);&lt;br /&gt;
&lt;br /&gt;
#svg_symbol.setScale(0.2);&lt;br /&gt;
#svg_symbol.setRotation(radians)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Optional collision detection in multiplayer ===&lt;br /&gt;
&lt;br /&gt;
A patch has been added to FlightGear to allow optional collision detection in multiplayer. To enable collision detection, start FlightGear with:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
--prop:bool:/sim/multiplay/hot=true&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Alternatively, those who are able to patch FGData themselves, can download [http://sourceforge.net/p/flightgear/mailman/attachment/CAHs0wcrEwYZvXTddcUaH0ZMfmVNvEWRap8MXOrEoKybUDO58sQ%40mail.gmail.com/3/ mp-hot-fgdata.patch], which adds a checkbox to the Multiplayer Settings dialog to enable or disable the collision detection.&lt;br /&gt;
&lt;br /&gt;
== In the hangar ==&lt;br /&gt;
=== Boeing 707 liveries ===&lt;br /&gt;
Seven new liveries are now available for [[Boeing 707]].  &lt;br /&gt;
* British Airways&lt;br /&gt;
* British Airways cargo&lt;br /&gt;
* British Caledonian&lt;br /&gt;
* China Airlines&lt;br /&gt;
* Pakistan International Airlines&lt;br /&gt;
* Trans European Airways&lt;br /&gt;
* Belize Airways Ltd. (Nick Reimer, others by sanhozay). &lt;br /&gt;
See this [http://forum.flightgear.org/viewtopic.php?f=13&amp;amp;t=24144 forum post] for more information. You can download the liveries [http://liveries.flightgear.org/aircraft.php?id=4 here].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;gallery mode=&amp;quot;packed&amp;quot;&amp;gt;&lt;br /&gt;
BAW.jpg|British Airways livery&lt;br /&gt;
BAWC.jpg|British Airways Cargo livery&lt;br /&gt;
BCC.jpg|British Caledonian livery&lt;br /&gt;
CCA.jpg|China Airlines livery&lt;br /&gt;
PIA.jpg|Pakistan International airlines livery&lt;br /&gt;
TEA.jpg|Trans European Airways livery&lt;br /&gt;
BAL.jpg|Belize Airways limited livery&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Scenery corner ==&lt;br /&gt;
=== Belgium airports ===&lt;br /&gt;
This month, various airports in Belgium are being populated with 3D buildings and shared models.  The source for most of the models is the Belgium Custom Scenery Project by [http://dvanmosselbeen.be David van Mosselbeen].&lt;br /&gt;
&lt;br /&gt;
Project link: https://gitlab.com/dvanmosselbeen/belgium-custom-scenery/tree/master.&lt;br /&gt;
&lt;br /&gt;
== Community news ==&lt;br /&gt;
=== FlightGear: featured project at SourceForge ===&lt;br /&gt;
{{FGCquote&lt;br /&gt;
  |I just wanted to post a quick message letting everyone know that next week&amp;lt;br/&amp;gt;&lt;br /&gt;
FlightGear will be a featured project of the week on SourceForge's front&amp;lt;br/&amp;gt;&lt;br /&gt;
page.  There are a variety of inputs into the selection process and it&amp;lt;br/&amp;gt;&lt;br /&gt;
should be some nice exposure for our little project.&amp;lt;br/&amp;gt;&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
Congratulations and thanks everyone! :-)&amp;lt;br/&amp;gt;&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
We should expect some increased traffic and a few new visitors taking a&amp;lt;br/&amp;gt;&lt;br /&gt;
look at FlightGear for the first time.  Please keep this in mind if we see&amp;lt;br/&amp;gt;&lt;br /&gt;
more new questions on this list or on the forum than usual.&amp;lt;br/&amp;gt;&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
Fly on!&amp;lt;br/&amp;gt;&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
Curt.&lt;br /&gt;
  |{{cite web |url=http://sourceforge.net/p/flightgear/mailman/message/33767341/&lt;br /&gt;
     |title=&amp;lt;nowiki&amp;gt;[Flightgear-devel] FlightGear will be one of SourceForge's projects&lt;br /&gt;
	of the week&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
     |author=&amp;lt;nowiki&amp;gt;Curtis Olson&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
     |date=&amp;lt;nowiki&amp;gt;2015-04-10&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
   }}&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== FG Flights blog ===&lt;br /&gt;
A new blog by [http://forum.flightgear.org/memberlist.php?mode=viewprofile&amp;amp;u=17464 gsagostinho] focused on sharing screenshots of short flights, particularly with GA aircraft. The link is http://fgflights.blogspot.cz/?view=sidebar.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;gallery mode=&amp;quot;packed&amp;quot;&amp;gt;&lt;br /&gt;
FGflights-blog-1.png|[[C172p]] over Bodensee (Lake Constance)&lt;br /&gt;
FGflights-blog-2.png|C172p over Feldberg&lt;br /&gt;
FGflights-blog-3.png|C172p landing at SBEG&lt;br /&gt;
FGflights-blog-4.png|Socata-ST10 in Sicily&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== New FGCom server maintainer ===&lt;br /&gt;
The FGCom server was previously provided through generous donation of and maintained by a contributor who has since quietly left the project.&amp;lt;ref&amp;gt;http://sourceforge.net/p/flightgear/mailman/message/33723747/&amp;lt;/ref&amp;gt;&amp;lt;ref&amp;gt;http://sourceforge.net/p/flightgear/mailman/message/33734219/&amp;lt;/ref&amp;gt;  A new maintainer has now appeared and the server is again available.&amp;lt;ref&amp;gt;http://sourceforge.net/p/flightgear/mailman/message/33831481/&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contributing ==&lt;br /&gt;
=== Better accessibility for FlightGear ===&lt;br /&gt;
{{FGCquote&lt;br /&gt;
  | I'd like to set up a dedicated web site for those of us with any disability to have ways to get around Flight Gear.  I was also thinking even maybe we could find some developers who are disabled who would be interested in helping us set up Flight Gear for all disabilities?  I think we can do some of this on Source Forge.  If we have some developers here on the FlightGear list who would like to help if I could get names that would be helpful so then I have a list.  I would be happy to help develop some as well.  I am unfortunately not a Java programmer but can do html type stuff and the Nasal stuff doesn't look to terribly bad to learn.  I’d also like to see if we can make packs for speech like in our turns so we know what direction one is going as they turn.  There are many more things.  I have to be honest Flight Gear is a platform for me to become familiar with what I will also need for actual flight.  I plan to attack flight lessons myself and FG gives me a good foundation to handle some of these concerns for a bigger project I may have later.  I’d like to personally thank everyone who answers and would be willing to help.&lt;br /&gt;
&lt;br /&gt;
  |{{cite web |url=http://sourceforge.net/p/flightgear/mailman/message/33735816/&lt;br /&gt;
     |title=&amp;lt;nowiki&amp;gt;Re: [Flightgear-devel] New fgcom server needed&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
     |author=&amp;lt;nowiki&amp;gt;Scott Berry&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
     |date=&amp;lt;nowiki&amp;gt;2015-04-06&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
   }}&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Translators required ===&lt;br /&gt;
{|&lt;br /&gt;
| [[File:en.gif]]&lt;br /&gt;
| The FlightGear Wiki still needs help for translating it into various languages. If you are interested in making the FlightGear Wiki multi-language then start at [[Help:Translate]].&lt;br /&gt;
|-&lt;br /&gt;
| [[File:de.gif]]&lt;br /&gt;
| Das FlightGear Wiki benötigt immer noch Hilfe bei der Übersetzung in verschiedene Sprachen. Wenn Du Interesse daran hast, das FlightGear Wiki Mehrsprachig zu machen, dann fang doch mit [[:de:Help:Übersetzen|Help:Übersetzen]] an.&lt;br /&gt;
|-&lt;br /&gt;
| [[File:nl.gif]]&lt;br /&gt;
| De FlightGear Wiki kan nog steed hulp gebruiken bij het vertalen van artikelen. Als je interesse hebt om de wiki meertalig te maken, raden we je aan om een kijkje te nemen bij [[:nl:Help:Vertalen|Help:Vertalen]].&lt;br /&gt;
|-&lt;br /&gt;
| [[File:es.gif]]&lt;br /&gt;
| La wiki de FlightGear todavía necesita ayuda para traducirla a varios lenguajes. Si estás interesado en hacer la FlightGear wiki multilingüe, entonces comienza en [[:es:Help:Traducir|Help:Traducir]].&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== FlightGear logos ===&lt;br /&gt;
If you want some graphic elements for your FlightGear-related site (such as a hangar or YouTube channel), please feel free to visit [[FlightGear logos]] for a repository of logos.  And if you have some art skills, please don't hesitate to contribute with your own design creations.&lt;br /&gt;
&lt;br /&gt;
=== Screenshots ===&lt;br /&gt;
The FlightGear project always needs screenshots, which show features that were added since the last release.  These should be of good quality, especially in content and technical image properties.  It is therefore recommended to use the best viable filter settings ([[anti-aliasing]], texture sharpening, etc.).  More info at [[Howto:Make nice screenshots]].&lt;br /&gt;
&lt;br /&gt;
{{Appendix}}&lt;br /&gt;
&lt;br /&gt;
[[Category:FlightGear Newsletter|2015 04]]&lt;br /&gt;
[[Category:Changes after 3.4]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=FlightGear_Newsletter_March_2015&amp;diff=82676</id>
		<title>FlightGear Newsletter March 2015</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=FlightGear_Newsletter_March_2015&amp;diff=82676"/>
		<updated>2015-03-20T19:53:49Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{draft|newsletter|Please feel free to add content you think will be of interest to the FlightGear community.}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{Newsletter-header|March 2015}}&lt;br /&gt;
&amp;lt;div style=&amp;quot;border-bottom:3px double #BBB;&amp;quot;&amp;gt;&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; |&lt;br /&gt;
 | valign=&amp;quot;top&amp;quot; width=&amp;quot;33%&amp;quot; |&lt;br /&gt;
[[#Project restructuring|Project restructuring]]&amp;lt;br/&amp;gt;&lt;br /&gt;
{{Newsletter-cover-header|Development news}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Upcoming built-in GUI|Upcoming built-in GUI]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Environment-responsive glass|Environment-responsive glass]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Cockpit interior light and shadow|Cockpit interior light and shadow]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#New ATC-pie release|New ATC-pie release]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Variant-of tag added|Variant-of tag added]]&amp;lt;br/&amp;gt;&lt;br /&gt;
 | valign=&amp;quot;top&amp;quot; width=&amp;quot;33%&amp;quot; |&lt;br /&gt;
{{Newsletter-cover-header|In the hanger}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#c172p-detailed project|c172p-detailed project]]&amp;lt;br/&amp;gt;&lt;br /&gt;
{{Newsletter-cover-header|Scenery Corner}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Verona Villafranca 2D layout released|Verona Villafranca 2D layout released]]&amp;lt;br/&amp;gt;&lt;br /&gt;
{{Newsletter-cover-header|Community News}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#FlightGear Space Program|FlightGear Space Program]]&amp;lt;br/&amp;gt;&lt;br /&gt;
 | valign=&amp;quot;top&amp;quot; width=&amp;quot;33%&amp;quot; |&lt;br /&gt;
{{Newsletter-cover-header|Contributing}}&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Translators required|Translators required]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#FlightGear logos|FlightGear logos]]&amp;lt;br/&amp;gt;&lt;br /&gt;
[[#Screenshots|Screenshots]]&amp;lt;br/&amp;gt;&lt;br /&gt;
|}&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Project restructuring ==&lt;br /&gt;
Due to two recent developments, large parts of the FlightGear project are going to be moving.  The first is the announcement that Gitorious.org will shut down in May this year ([https://about.gitlab.com/2015/03/03/gitlab-acquires-gitorious/ read more]) and that Google Code will shut down in 2016 ([http://google-opensource.blogspot.co.uk/2015/03/farewell-to-google-code.html read more]).  This means that all the source code (SimGear and FlightGear), the bug tracker, and [[TerraSync]]{{clarify}} are moving.  In addition, just previous to these developments, [[fgdata]] was split, see [[#fgdata split|below]] for details.&lt;br /&gt;
&lt;br /&gt;
All repositories of the FlightGear project have been synchronized to [http://sourceforge.net/p/flightgear/_list/git SourceForge.net]&amp;lt;ref&amp;gt;{{cite web&lt;br /&gt;
|url    = http://sourceforge.net/p/flightgear/mailman/message/33588398/&lt;br /&gt;
|title  = &amp;lt;nowiki&amp;gt;[Flightgear-devel] [MasterCaution] (ding!) FlightGear is now at SourceForge&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
|author = Torsten Dreyer&lt;br /&gt;
|authorlink-wiki = User:T3r&lt;br /&gt;
|date   = 2015-03-12&lt;br /&gt;
}}&amp;lt;/ref&amp;gt;.  '''No more work should be pushed to Gitorious any more.'''  Except for fgdata, all others are mirrors of the original and a new clone is not necessary.  All you have to do is update the URL(s) of your remote(s) and pull as usual.&lt;br /&gt;
&lt;br /&gt;
Example for SimGear with read-only access:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;bash&amp;quot;&amp;gt;&lt;br /&gt;
git remote set-url origin git://git.code.sf.net/p/flightgear/simgear &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Example for FlightGear source with read/write access:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;bash&amp;quot;&amp;gt;&lt;br /&gt;
git remote set-url origin http://git.code.sf.net/p/flightgear/flightgear&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Note|HTTPS access is no longer supported; you will have to change the relevant URLs.}}&lt;br /&gt;
&lt;br /&gt;
The bug tracker has moved to http://sourceforge.net/p/flightgear/codetickets/&amp;lt;ref&amp;gt;{{cite web&lt;br /&gt;
|url    = http://sourceforge.net/p/flightgear/mailman/message/33600886&lt;br /&gt;
|title  = &amp;lt;nowiki&amp;gt;[Flightgear-devel] Bugtracker moving to sourceforge&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
|author = Torsten Dreyer&lt;br /&gt;
|date   = 2015-03-16&lt;br /&gt;
}}&amp;lt;/ref&amp;gt;. All old issues/feature requests have been preserved.  The wiki template {{tl|Issue}} has been updated ([http://wiki.flightgear.org/index.php?title=Template:Issue&amp;amp;diff=82555&amp;amp;oldid=72743 diff]).&lt;br /&gt;
&lt;br /&gt;
TerraSync is yet to be moved as of March 18.&lt;br /&gt;
&lt;br /&gt;
Several (but not all) of the [[:Category:Git|Git related articles]] on the wiki have been updated, including [[FlightGear Git: data developers]].&lt;br /&gt;
&lt;br /&gt;
To get re-added as a contributor to the FlightGear repositories, you will have to do the following steps&amp;lt;ref name=&amp;quot;a&amp;quot;&amp;gt;{{cite web&lt;br /&gt;
|url    = http://sourceforge.net/p/flightgear/mailman/message/33562106/&lt;br /&gt;
|title  = &amp;lt;nowiki&amp;gt;[Flightgear-devel] FGData - The Next Generation is ready.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
|author = Torsten Dreyer&lt;br /&gt;
|date   = 2015-03-07&lt;br /&gt;
}}&amp;lt;/ref&amp;gt;:&lt;br /&gt;
# [https://sourceforge.net/user/registration Register] a SourceForge.net&lt;br /&gt;
# Upload your public key.&lt;br /&gt;
# Send your SourceForge username to Curt, Clément, James, or Torsten D, stating which repo(s) you want to be re-added to.&lt;br /&gt;
&lt;br /&gt;
=== FGData split ===&lt;br /&gt;
After lots of hard work by Torsten D, a new, more compact [[fgdata]] repository ([[base package]]) has now been created. Located at http://sourceforge.net/p/flightgear/fgdata/, this new fgdata has had all aircraft (except for the [[C172p]] and [[UFO]]) stripped from it, as well as the histories of the Scenery, AI, and Models directories&amp;lt;ref name=&amp;quot;a&amp;quot;&amp;gt;{{cite web&lt;br /&gt;
|url    = http://sourceforge.net/p/flightgear/mailman/message/33562106/&lt;br /&gt;
|title  = &amp;lt;nowiki&amp;gt;[Flightgear-devel] FGData - The Next Generation is ready.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
|author = Torsten Dreyer&lt;br /&gt;
|date   = 2015-03-07&lt;br /&gt;
}}&amp;lt;/ref&amp;gt;.  This has reduced its size to about 1.3 GB&amp;lt;ref&amp;gt;{{cite web&lt;br /&gt;
|url    = http://sourceforge.net/p/flightgear/mailman/message/33562630/&lt;br /&gt;
|title  = &amp;lt;nowiki&amp;gt;Re: [Flightgear-devel] FGData - The Next Generation is ready.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
|author = Anders Gidenstam&lt;br /&gt;
|authorlink-wiki = User:AndersG&lt;br /&gt;
|date   = 2015-03-07&lt;br /&gt;
}}&amp;lt;/ref&amp;gt;.  As almost all commit IDs have changed, you will have to get a fresh clone of this new fgdata&amp;lt;ref name=&amp;quot;a&amp;quot;&amp;gt;{{cite web&lt;br /&gt;
|url    = http://sourceforge.net/p/flightgear/mailman/message/33562106/&lt;br /&gt;
|title  = &amp;lt;nowiki&amp;gt;[Flightgear-devel] FGData - The Next Generation is ready.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
|author = Torsten Dreyer&lt;br /&gt;
|date   = 2015-03-07&lt;br /&gt;
}}&amp;lt;/ref&amp;gt;.  See above for information on getting re-added as a contributor.&lt;br /&gt;
&lt;br /&gt;
{{note|For consistency reasons, fgdata development should now happen on the &amp;quot;next&amp;quot; branch and no longer in &amp;quot;master&amp;quot;.  &amp;quot;next&amp;quot; should be the default branch&amp;lt;ref&amp;gt;{{cite web&lt;br /&gt;
|url    = http://sourceforge.net/p/flightgear/mailman/message/33562259/&lt;br /&gt;
|title  = &amp;lt;nowiki&amp;gt;Re: [Flightgear-devel] FGData - The Next Generation is ready.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
|author = Torsten Dreyer&lt;br /&gt;
|date   = 2015-03-07&lt;br /&gt;
}}&amp;lt;/ref&amp;gt;.}}&lt;br /&gt;
&lt;br /&gt;
{{note|IAHM-COL has preserved the history of all aircraft at https://github.com/FGMEMBERS&amp;lt;ref&amp;gt;{{cite web&lt;br /&gt;
|url    = http://sourceforge.net/p/flightgear/mailman/message/33562691/&lt;br /&gt;
|title  = &amp;lt;nowiki&amp;gt;Re: [Flightgear-devel] FGData - The Next Generation is ready.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
|author = IAHM-COL&lt;br /&gt;
|date   = 2015-03-07&lt;br /&gt;
}}&amp;lt;/ref&amp;gt;.}}&lt;br /&gt;
&lt;br /&gt;
{{note|See [[FGAddon]] for obtaining aircraft other than the C172p and UFO.}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Development news ==&lt;br /&gt;
=== Upcoming built-in GUI ===&lt;br /&gt;
[[File:Qt launcher for FlightGear 3.5 on Windows 7.jpg|thumb|The aircraft page of the Qt launcher for FlightGear 3.5 as rendered on Windows 7.]]&lt;br /&gt;
Development of a new GUI frontend for FlightGear has started, with the aim to replace [[FGRun]] and eventually the PLIB PUI.  James Turner is currently prototyping this new launcher, based on [http://www.qt.io/qt-quick/ Qt Quick], at the suggestion and encouragement of Curt, Torsten D &amp;amp; others&amp;lt;ref&amp;gt;{{cite web&lt;br /&gt;
|url    = http://sourceforge.net/p/flightgear/mailman/message/33245028&lt;br /&gt;
|title  = &amp;lt;nowiki&amp;gt;[Flightgear-devel] Gui technologies&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
|author = James Turner&lt;br /&gt;
|authorlink-wiki = User:Zakalawe&lt;br /&gt;
|date   = 2015-01-20&lt;br /&gt;
}}&amp;lt;/ref&amp;gt;.  There will also be the HTML5-based GUI called [[Phi]], which is being developed by Torsten D.&lt;br /&gt;
&lt;br /&gt;
The reason for the announcement is that this would overlap some areas other developers are working on.  This will hopefully avoid others unnecessarily expending energy on areas that might be affected.&lt;br /&gt;
&lt;br /&gt;
{{inote|The parallel development of HTML and Qt-based UIs is happening by intention and is not the result of discoordination&amp;lt;ref&amp;gt;{{cite web&lt;br /&gt;
|url    = http://forum.flightgear.org/viewtopic.php?p=229445#p229445&lt;br /&gt;
|title  = Re: New Canvas GUI&lt;br /&gt;
|author = Torsten Dreyer&lt;br /&gt;
|authorlink-wiki = User:T3r&lt;br /&gt;
|date   = Jan 10, 2015&lt;br /&gt;
}}&amp;lt;/ref&amp;gt;.  It is likely both will use a common service layer to provide necessary data&amp;lt;ref&amp;gt;{{cite web&lt;br /&gt;
|url    = http://forum.flightgear.org/viewtopic.php?p=229303#p229303&lt;br /&gt;
|title  = Re: New Canvas GUI&lt;br /&gt;
|author = Torsten Dreyer&lt;br /&gt;
|date   = Jan 08, 2015&lt;br /&gt;
}}&amp;lt;/ref&amp;gt;.}}&lt;br /&gt;
&lt;br /&gt;
To learn more, see [[Integrated Qt5 Launcher]].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Atmospheric light scattering ===&lt;br /&gt;
Two new cockpit interior effects have been added to the ALS rendering framework.&lt;br /&gt;
&lt;br /&gt;
==== Environment-responsive glass ====&lt;br /&gt;
A new '''glass effect''' for the cockpit interior brings dynamical rendering of raindrop splashes as well as frost.  In future, the effect will also include fogging and windshield wiper support with aircraft-supplied texture masks, all with a realistic interaction with the sunlight, including the enhanced visibility of dirt on glass when looking into the sun due to Mie scattering.&lt;br /&gt;
&lt;br /&gt;
[[File:Glass01.jpg|400px|Frost effect]]&lt;br /&gt;
[[File:Glass07.jpg|400px|Raindrop splashes]]&lt;br /&gt;
&lt;br /&gt;
Both frost and the correct splash dynamics of the raindrops need to be modeled by the aircraft developer, as the shader cannot have get the required information. See [[ALS technical notes#ALS glass effect]] for details.&lt;br /&gt;
&lt;br /&gt;
==== Cockpit interior light and shadow ====&lt;br /&gt;
Do you like the way shadow and light move across the panel in flight when using [[Rembrandt]]? ALS is now able to do the same and more using the new '''model-interior''' effect which utilizes a cubemap representing the cockpit layout – at hardly any framerate cost. The effect is able to draw very sharp shadows without flickering, semi-shadows, dirty or tinted glass, and even render caustics from light refracted on curved glass surfaces.&lt;br /&gt;
&lt;br /&gt;
[[File:Interior01.jpg|400px|Colored glass]]&lt;br /&gt;
[[File:Opacity04.jpg|400px|Caustics]]&lt;br /&gt;
&lt;br /&gt;
All that's needed from aircraft modellers is a pre-computed cube map representing the cockpit.  See [[ALS technical notes#Internal cockpit reflection]] for more details.&lt;br /&gt;
&lt;br /&gt;
=== New ATC-pie release ===&lt;br /&gt;
Announced as beta in January and released as stable early February, [[ATC-pie]] has happily served a few [[ATC]] sessions in its first month of existance. In particular, it seems to have found comfortable homes for adoption in EKCH and LFOK already. Meanwhile, progress was made on its development to reach the important milestone of general and continuous ATC coordination on Flightgear with the '''handover feature''', released this month.&lt;br /&gt;
&lt;br /&gt;
Beginning to populate the network with a new program without dividing the MP network (especially controllers) was a challenge as interesting as necessary. Collaborative work made this possible, enabling both [[OpenRadar]] and ATC-pie users to exchange strips in a transparent way, regardless of their software choice.&lt;br /&gt;
&lt;br /&gt;
''See also [http://forum.flightgear.org/viewtopic.php?f=83&amp;amp;t=25573#p234276 the forum announcement] …''&lt;br /&gt;
&lt;br /&gt;
=== Variant-of tag added ===&lt;br /&gt;
Aircraft developers can make use of a new tag in the [[Aircraft-set.xml]] file.  Added to the &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;sim&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;, the &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;variant-of&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; tag states to the launcher the aircraft type that your aircraft is a variant of.  For example, the [[British Aerospace Sea Harrier|BAe Sea Harrier FA2]] is a variant of the BAe Sea Harrier, and the ''Cessna 172P - Canvas Demo'' is a variant of the [[Cessna C172P|C172P]].&lt;br /&gt;
&lt;br /&gt;
Syntax:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;sim&amp;gt;&lt;br /&gt;
    ...&lt;br /&gt;
    &amp;lt;variant-of&amp;gt;[aircraft]&amp;lt;/variant-of&amp;gt;&lt;br /&gt;
    ...&lt;br /&gt;
&amp;lt;/sim&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Example from the {{repo link|site=sf|path=Aircraft/777/777-200ER-set.xml|lines=11|text=Boeing 777-200ER}}:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;variant-of&amp;gt;777-200&amp;lt;/variant-of&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== In the hangar ==&lt;br /&gt;
=== c172p-detailed project ===&lt;br /&gt;
A new, more detailed version of the [[C172p]] is currently being worked on by wlbragg, gsagostinho, thevirtualfer, ludomotico, onox and others. It brings amazing new textures, controls, switches, and systems!  Below are some of the results of their work:&lt;br /&gt;
&lt;br /&gt;
[[File:Screenshots of the project c172p-detailed.jpg|800px|Some screenshots of the c172p-detailed project]]&lt;br /&gt;
&lt;br /&gt;
''Find out more at [http://forum.flightgear.org/viewtopic.php?f=4&amp;amp;t=25157 Cessna 172P detailed] …''&lt;br /&gt;
&lt;br /&gt;
== Scenery Corner ==&lt;br /&gt;
=== Verona Villafranca 2D layout released ===&lt;br /&gt;
[[User:Elgaton|elgaton]] has released the complete 2D layout for [[LIPX]]; the work is going to be submitted to the Airport Scenery Gateway at the end of March for inclusion in X-Plane and FlightGear. A scenery build can be downloaded from the [http://forum.flightgear.org/viewtopic.php?f=5&amp;amp;t=21576 official development thread on the forum]. 3D buildings will be added in the coming months.&lt;br /&gt;
&amp;lt;gallery mode=&amp;quot;packed&amp;quot;&amp;gt;&lt;br /&gt;
File:LIPX-RC2-panorama.png|The airport and the surrounding area.&lt;br /&gt;
File:LIPX-RC2-top.png|Top view.&lt;br /&gt;
File:LIPX-RC2-apron.png|The apron now features up-to-date stands.&lt;br /&gt;
File:LIPX-B-CRJ700.png|Holding short at B in a CRJ-700 (at night).&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Community News ==&lt;br /&gt;
=== FlightGear Space Program ===&lt;br /&gt;
&lt;br /&gt;
[[File:Fgspbadge.png|thumb|FGSP Cosmonaut Badge &amp;quot;The Owl&amp;quot;]]&lt;br /&gt;
[[File:spacetripready.png|link=FlightGear space program]]&lt;br /&gt;
&lt;br /&gt;
Now is your time to become official cosmonaut of The FlightGear Space Program. Just downloading the famous '''[[Space Shuttle]]'''  that has been largely reworked, and select any of the available [[FlightGear_space_program_missions|missions]]. Report your succesfull orbit flight tracker screenie and you'll receive a custom badge of The FlightGear Space Program.&lt;br /&gt;
&lt;br /&gt;
The Space Shuttle can be downloaded from {{repo link|site=gith|proj=herbyw/antonov-aircrafts|view=tree|text=the GitHub repository}} in either a ZIP file or by cloning.&lt;br /&gt;
&lt;br /&gt;
As an add-on also you can fly our Special Cargo Transport Missions with the heavily updated [[Antonov_An-12|An-12]], [[Antonov_An-22|An-22]], and [[An-225]] (mission transport variants).&lt;br /&gt;
&lt;br /&gt;
''Find out more about space flight in FlightGear at [[FlightGear space program]] …''&lt;br /&gt;
&lt;br /&gt;
== Contributing ==&lt;br /&gt;
=== Translators required ===&lt;br /&gt;
{|&lt;br /&gt;
|[[File:en.gif]]&lt;br /&gt;
|The FlightGear Wiki still needs help for translating it into various languages. If you are interested in making the FlightGear Wiki multi-language then start at [[Help:Translate]].&lt;br /&gt;
|-&lt;br /&gt;
|[[File:de.gif]]&lt;br /&gt;
|Das FlightGear Wiki benötigt immer noch Hilfe bei der Übersetzung in verschiedene Sprachen. Wenn Du Interesse daran hast, das FlightGear Wiki Mehrsprachig zu machen, dann fang doch mit [[:de:Help:Übersetzen|Help:Übersetzen]] an.&lt;br /&gt;
|-&lt;br /&gt;
|[[File:nl.gif]]&lt;br /&gt;
|De FlightGear Wiki kan nog steed hulp gebruiken bij het vertalen van artikelen. Als je interesse hebt om de wiki meertalig te maken, raden we je aan om een kijkje te nemen bij [[:nl:Help:Vertalen|Help:Vertalen]].&lt;br /&gt;
|-&lt;br /&gt;
|[[File:es.gif]]&lt;br /&gt;
|La FlightGear wiki todavía necesita ayuda para traducirla a varios lenguajes. Si estás interesado en hacer la FlightGear wiki multilingüe, entonces comienza en [[:es:Help:Traducir|Help:Traducir]].&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== FlightGear logos ===&lt;br /&gt;
If you want some graphic elements for your FlightGear-related site (for example hangar or YouTube channel), please feel free to visit [[FlightGear logos]] for a repository of logos.  And if you have some art skills, please don't hesitate to contribute with your own design creations.&lt;br /&gt;
&lt;br /&gt;
=== Screenshots ===&lt;br /&gt;
The FlightGear project always needs screenshots for the website, which show features that were added since the last release.  These shots should be of good quality, especially in content and technical image properties.  It is therefore recommended to use the best viable filter settings ([[antialiasing]], texture sharpening, etc.).  More info at [[Howto:Make nice screenshots]].&lt;br /&gt;
&lt;br /&gt;
[[Category:FlightGear Newsletter|2015 03]]&lt;br /&gt;
[[Category:Changes after 3.4]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=RAAS&amp;diff=78986</id>
		<title>RAAS</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=RAAS&amp;diff=78986"/>
		<updated>2015-01-08T14:49:41Z</updated>

		<summary type="html">&lt;p&gt;Onox: Redirected page to Runway Awareness and Advisory System&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Runway_Awareness_and_Advisory_System]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Nasal_Variables&amp;diff=78985</id>
		<title>Nasal Variables</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Nasal_Variables&amp;diff=78985"/>
		<updated>2015-01-08T14:48:17Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:Nasal Navigation}}&lt;br /&gt;
&lt;br /&gt;
A '''variable''' is a combination of a name/namespace (e.g. foo in the local namespace or setprop in the global namespace) and a value (from simple scalars, like &amp;lt;tt&amp;gt;1&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;&amp;quot;hello!&amp;quot;&amp;lt;/tt&amp;gt;, to more complex data types, like hashes and vectors). Here we will explain some of how the various types of variables work.&lt;br /&gt;
&lt;br /&gt;
== Variables ==&lt;br /&gt;
Nasal scripts should make use of the var keyword when declaring variables. The &amp;quot;var&amp;quot; keyword makes a variable guaranteed to be local. Nasal natively provides support for scalars (numbers, strings), lists (arrays, vectors) and hashes (objects or dictionaries); more complex data structures (such as trees) can be built using vectors or hashes. &lt;br /&gt;
&lt;br /&gt;
'''vectors''' and '''hashes''' can be understood as &amp;quot;containers&amp;quot; for your data; in the case of vectors, you end up with a container that has sequentially-numbered places for each element - whereas a hash can also used named keys for its values. Storing happens in a  key/value fashion. Data look-up is usually done via square brackets:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
# create an empty vector&lt;br /&gt;
var myVector = [];&lt;br /&gt;
&lt;br /&gt;
# append a value to it&lt;br /&gt;
append(myVector, 10);&lt;br /&gt;
&lt;br /&gt;
# get out the first element (starting at 0)&lt;br /&gt;
var firstElement = myVector[0];&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Equally, a hash is easy to set up to serve as container for your values:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var myHash = {};&lt;br /&gt;
myHash.field = 10;&lt;br /&gt;
var myField = myHash.field;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
And of course, Nasal also has functions: bits of code which take inputs and can return values and that can be &amp;quot;called&amp;quot; again and again. Rounding out the types are &amp;quot;nil&amp;quot; (aka NULL pointer) and &amp;quot;ghost&amp;quot; (Garbage-collected Handle to OutSide Thingy – a virtual type that represents a C or C++ object).  For more see the [[Nasal Variables#Table of types|table of types]]. Here's an example of a few of these types, being assigned to symbols:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
 var w=100;     # w is a local numerical variable&lt;br /&gt;
 var x=&amp;quot;hello&amp;quot;; # x is a local string variable&lt;br /&gt;
 var y=[];      # y is a local vector (array)&lt;br /&gt;
 var z={};      # z is a local hash (dictionary or table) - also used for OOP&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
What is the difference between a vector and a hash? The difference is, elements in a vector are sequentially numbered, i.e. each element has a numeric index:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var my_vector = ['A','B','C'];&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This initializes a vector with three elements: A, B and C. To access each element of the vector, you would need to use the element's numerical index:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var my_vector = ['A','B','C'];&lt;br /&gt;
print (my_vector[0] ); #prints A&lt;br /&gt;
print (my_vector[1] ); #prints B&lt;br /&gt;
print (my_vector[2] ); #prints C&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
As can be seen, indexing starts at zero.&lt;br /&gt;
&lt;br /&gt;
Compared to vectors, hashes don't use square brackets but curly  braces instead: &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var my_hash = {};&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Hashes may not just have numerical indexes, but also symbolic indexes as lookup keys:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var my_hash = {first:'A',second:'B',third:'C'};&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will create a hash (imagine it like a storage container for a bunch of related variables) and initialize it with three values (A,B and C) which are assigned to three different lookup keys: first, second, third.&lt;br /&gt;
&lt;br /&gt;
In other words, you can access each element in the hash by using its lookup key:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var my_hash = {first:'A',second:'B',third:'C'};&lt;br /&gt;
print ( my_hash.first ); # will print A&lt;br /&gt;
print ( my_hash.second ); # will print B&lt;br /&gt;
print ( my_hash.third ); # will print C&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Insert new pairs (or change existing):&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var hash = {};&lt;br /&gt;
hash.field1 = 1;&lt;br /&gt;
hash['field2']= 2;&lt;br /&gt;
hash[&amp;quot;field3&amp;quot;] = 3&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Nasal supports a &amp;quot;nil&amp;quot; value for use as a null pointer equivalent:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
 var foo=nil; &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Also, note that Nasal symbols are case-sensitive, these are all different variables:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
 var show = func(what) {print(what,&amp;quot;\n&amp;quot;);}&lt;br /&gt;
 var abc=1; # these are all different symbols&lt;br /&gt;
 var ABC=2; # different from abc &lt;br /&gt;
 var aBc=3; # different from abc and ABC&lt;br /&gt;
 &lt;br /&gt;
 show(abc);&lt;br /&gt;
 show(ABC);&lt;br /&gt;
 show(aBc);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Please note that functions assigned to variables are no exception. If you write code without using &amp;quot;var&amp;quot; on variables, then you risk (often hard to debug) breakage at a later time because you may be overwriting symbols in another namespace. &lt;br /&gt;
&lt;br /&gt;
So functions bound to variables should use the &amp;quot;var&amp;quot; keyword as well:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
 var hello = func { &lt;br /&gt;
   print(&amp;quot;hello\n&amp;quot;); &lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
There's another reason why &amp;quot;var&amp;quot; should be used consequently, even if a variable is safe enough from later side effects, because it has a relatively specific or unique name: The &amp;quot;var&amp;quot; keyword makes reading code for others (and for the author after some time) easier, as it makes clear: &amp;quot;this variable starts its life *HERE*&amp;quot;. No need to search around to see whether assigning a value to it means something to other code outside or not. Also, with an editor offering proper syntax highlighting reading such code is actually easier, despite the &amp;quot;noise&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
The problem with nasal code that does not make use of the var keyword is, that it can break other code, and with it the whole system, but no Nasal error message will point you there, as it's syntactically and semantically correct code. Just doing things that it wasn't supposed to do.&lt;br /&gt;
For a more in-depth discussion, please see [http://www.mail-archive.com/flightgear-devel@lists.sourceforge.net/msg13557.html Nasal &amp;amp; &amp;quot;var&amp;quot;].&lt;br /&gt;
&lt;br /&gt;
Nasal scripts that are loaded from [[$FG_ROOT]]/Nasal are automatically placed inside a namespace that is based on the script's name.&lt;br /&gt;
&lt;br /&gt;
For example, referring to our earlier &amp;quot;Hello World&amp;quot; example, global variables defined in the hello.nas script would be accessible by using &amp;quot;hello&amp;quot; as prefix from other modules:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
 # hello.nas&lt;br /&gt;
 var greeting=&amp;quot;Hello World&amp;quot;; # define a greeting symbol inside the hello namespace&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you were now to read out the value from the greeting variable from another Nasal module, you would have to use the hello prefix:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
 # greetme.nas&lt;br /&gt;
 print(hello.greeting); # the hello prefix is referring to the hello namespace (or module).&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Variables - Advanced Uses ==&lt;br /&gt;
&lt;br /&gt;
Nasal also supports Multi-assignment expressions. You can assign more than one variable (or lvalue) at a time by putting them in a parenthesized list:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
   (var a, var b) = (1, 2);&lt;br /&gt;
   var (a, b) = (1, 2);               # Shorthand for (var a, var b)&lt;br /&gt;
   (var a, v[0], obj.field) = (1,2,3) # Any assignable lvalue works&lt;br /&gt;
   var color = [1, 1, 0.5];&lt;br /&gt;
   var (r, g, b) = color;  # works with runtime vectors too&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Vectors (lists or arrays) can be created from others using an ordered list of indexes and ranges. &lt;br /&gt;
This is usually called &amp;quot;vector slicing&amp;quot;.&lt;br /&gt;
For example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
   var v1 = [&amp;quot;a&amp;quot;,&amp;quot;b&amp;quot;,&amp;quot;c&amp;quot;,&amp;quot;d&amp;quot;,&amp;quot;e&amp;quot;]&lt;br /&gt;
   var v2 = v1[3,2];   # == [&amp;quot;d&amp;quot;,&amp;quot;c&amp;quot;];&lt;br /&gt;
   var v3 = v1[1:3];   # i.e. range from 1 to 3: [&amp;quot;b&amp;quot;,&amp;quot;c&amp;quot;,&amp;quot;d&amp;quot;];&lt;br /&gt;
   var v4 = v1[1:];    # no value means &amp;quot;to the end&amp;quot;: [&amp;quot;b&amp;quot;,&amp;quot;c&amp;quot;,&amp;quot;d&amp;quot;,&amp;quot;e&amp;quot;]&lt;br /&gt;
   var i = 2;&lt;br /&gt;
   var v5 = v1[i];     # runtime expressions are fine: [&amp;quot;c&amp;quot;]&lt;br /&gt;
   var v6 = v1[-2,-1]; # negative indexes are relative to end: [&amp;quot;d&amp;quot;,&amp;quot;e&amp;quot;]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The range values can be computed at runtime (e.g. i=1; v5=v1[i:]). Negative indices work the same way they do with the vector functions (-1 is the last element, -2 is 2nd to last, etc...).&lt;br /&gt;
&lt;br /&gt;
== Vector slicing ==&lt;br /&gt;
&lt;br /&gt;
In Nasal, like many other scripting languages, one can &amp;quot;slice&amp;quot; vectors, that is, make a new vector gathering from indices of a previous vector. (Note that slicing strings is currently not supported but is possible.) The basic syntax for slicing is this:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
vec[n:m];&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
This makes a new vector who's contents are taken from vec starting at index n and going until index m – including both indices. This contrasts with Python, who considers index m a &amp;quot;one-past-end&amp;quot; index, i.e. it does not include it in the final result. Let's take an easy example to illustrate this:&lt;br /&gt;
&lt;br /&gt;
Start with a vector, call it vec like above, and have it of size o. We will fill each index with the number of that index, like so:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var vec = setsize([], o);&lt;br /&gt;
forindex (var v; vec)&lt;br /&gt;
    vec[v] = v;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
Thus a vector of size 5 would be [0,1,2,3,4]. Let's look at slicing with that vector. Using the notation above, let's take a slice of the whole vector. We of course have to start at the first index – 0 – and we go to the last valid index – which is not o, but o-1. Thus we have:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
vec[0:o-1];&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
In Python, this would actually go to o not o-1, but using subvec notation, we get the same as Python:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
subvec(vec, 0, o);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
(Be warned that subvec takes a starting index and ''length'' and thus is not equivalent!). There are several other ways to notate this as well:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
vec[0:-1];&lt;br /&gt;
vec[:-1];&lt;br /&gt;
vec[0:];&lt;br /&gt;
vec[:];&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
Note the last three, they show that we can leave out an index to designate the start or end of the vector (or we can equivalently put 0 for the start and -1 for the end). If we do an arbitrary slice from n to m, we will get a vector like this (due to the way we filled our indices):&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
vec[n:m] == [n, n+1, n+2, ..., m-1, m];&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
A degenerate vector slice becomes a simple subscript inside a new vector:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
vec[n:n] == [vec[n]];&lt;br /&gt;
vec[-1:] == [vec[-1]];&lt;br /&gt;
vec[:0] == [vec[0]];&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
You can think of vector slicing as designating the two end-caps of the result, with the result including those indices.&lt;br /&gt;
&lt;br /&gt;
Another feature of Nasal's slices is that one can pick individual indices to &amp;quot;cherry-pick&amp;quot; out of the original vector using commas:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
vec[0,5,7] #pull indices 0, 5, and 7&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
This can also be combined with the other form of slices like so:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
vec[0,5:7] #0, 5, 6, and 7&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now let's make a range() function.&lt;br /&gt;
&lt;br /&gt;
== Making a Range Function ==&lt;br /&gt;
In Python, the range function returns what is essentially a vector slice of an &amp;quot;infinite&amp;quot; vector who's indices are filled like we did above. That is, it returns a vector like this:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
[arg[0], arg[0]+1, arg[0]+2, ..., arg[1]-2, arg[1]-1]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
This turns out to be incredibly useful for iterating over the size of a vector (for i in range(0,len(vec)):) and also has other applications. Since we are doing this in Nasal, we need to be careful with the last index. While in Python it's a equivalent to a simple slice, but in Nasal we need to subtract 1 from the top index. Here's an example of how to do it:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var _range = []; #gets filled like [0, 1, 2, 3, ... ]&lt;br /&gt;
var range = func(start, end) { #one-past-end, actually&lt;br /&gt;
    # We need to make sure our index end-1 exists,&lt;br /&gt;
    # which will happen when the size is equal to end,&lt;br /&gt;
    # (since size-1 is always the last valid index)&lt;br /&gt;
    while(size(_range) &amp;lt; end) {&lt;br /&gt;
        append(_range, size(_range));&lt;br /&gt;
    }&lt;br /&gt;
    return _range[start:end-1];&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Storage: property tree vs. Nasal ==&lt;br /&gt;
With FlightGear's built-in property tree and Nasal's support for it, there are two obvious, and two somewhat competing, ways for storing scalar data: native Nasal variables and FlightGear properties, both of which can be easily accessed and managed from Nasal.&lt;br /&gt;
&lt;br /&gt;
The advantage to native Nasal-space data is that it's fast and simple.  If the only thing that will care about the value is your script, they are good choices.&lt;br /&gt;
&lt;br /&gt;
The property tree is an inter-subsystem communication thing.  This is what you want if you want to share data with the C++ world (for example, YASim &amp;lt;control-output&amp;gt; tags write to properties -- they don't understand Nasal), or read in via configuration files.&lt;br /&gt;
&lt;br /&gt;
Also, native Nasal data structures are usually far faster than their equivalent in property tree space.  This is because there are several layers of indirection in retrieving a property tree value. &lt;br /&gt;
&lt;br /&gt;
In general, this means that you shouldn't make overly excessive use of the property tree for storing state that isn't otherwise relevant to FlightGear or any of its subsystems. Doing that would in fact have adverse effects on the performance of your code. In general, you should favor Nasal variables and data structures and should only make use of properties to interface with the rest of FlightGear, or to easily provide debugging information at run time.&lt;br /&gt;
&lt;br /&gt;
As of FG 2.4.0, retrieving a value from the property tree via getprop is about 50% slower than accessing a native Nasal variable, and accessing the value via node.getValue() is 10-20% slower yet. This is an insignificant amount of time if you are retrieving and storing a few individual values from the property tree, but adds up fast if you are storing or retrieving hashes or large amounts of data.  (You can easily benchmark times on your own code using systime() or debug.benchmark.)&lt;br /&gt;
&lt;br /&gt;
This is a case where your original Nasal code was the better algorithm:  it &amp;quot;ought&amp;quot; to be better to hold the property tree nodes and index them explicitly using getChild() than to create a property tree path string for each child. However, the code that parses property tree paths has been optimized, especially to allocate as little heap storage as possible, so its speed outclasses the Nasal parser [http://www.mail-archive.com/flightgear-devel@lists.sourceforge.net/msg28835.html].&lt;br /&gt;
&lt;br /&gt;
For FlightGear version &amp;lt;= 2.10 the following applies: If there is even a slight performance concern, the only justification for not using getprop() / setprop() directly is if you explicitly require to set a variable type. &lt;br /&gt;
&lt;br /&gt;
Assembling a property path by string manipulation may be in theory less appealing, but it is in practice 3 to 10 times faster than using the props module - I have made several benchmark tests, all leading to the same result. Large-scale property manipulation from Nasal is performance hungry and should &lt;br /&gt;
be avoided if possible by using Nasal-internal variables instead, and if it needs to be done, getprop() /setprop() offer significantly superior performance[http://www.mail-archive.com/flightgear-devel@lists.sourceforge.net/msg39844.html].&lt;br /&gt;
&lt;br /&gt;
Yes, setprop/getprop is definitely faster, because there's less work to do. Evaluating the expression &amp;quot;temp1&amp;quot; requires pushing the symbol value (a&lt;br /&gt;
string) onto the stack, and executing OP_LOCAL which does a hash table lookup to find the value in the namespace list and leave it on the stack for the next bit of code to use.&lt;br /&gt;
&lt;br /&gt;
Evaluating &amp;quot;node.getValue()&amp;quot; requires:&lt;br /&gt;
&lt;br /&gt;
*  Pushing the symbol &amp;quot;node&amp;quot; onto the stack&lt;br /&gt;
*  Executing OP_LOCAL to look it up&lt;br /&gt;
*  Pushing the symbol &amp;quot;getValue&amp;quot; onto the stack&lt;br /&gt;
*  Executing OP_MEMBER to look it up in the object&lt;br /&gt;
*  Executing OP_CALL to call it as a function&lt;br /&gt;
*  Inside the member function:&lt;br /&gt;
*    Finding the values of me._g and the arg vector: 2 OP_LOCALS and 1 OP_MEMBER (not that expensive, dealing with small hashes)&lt;br /&gt;
*    Looking up the C++/raw variant: another OP_LOCAL and into a densely populated namespace&lt;br /&gt;
*    Finally (!) calling the C++ property node function&lt;br /&gt;
*  Turn the output node into a Nasal object and leave it on the stack.&lt;br /&gt;
&lt;br /&gt;
That said, you really don't want to be designing your scripts around raw, low-level performance issues.  Write your code to be readable, not blazingly fast.  In general &amp;quot;altitude&amp;quot; is more readable than &amp;quot;altNode.getValue()&amp;quot; [http://www.mail-archive.com/flightgear-devel@lists.sourceforge.net/msg12222.html].&lt;br /&gt;
&lt;br /&gt;
Note that for FlightGear versions &amp;gt; 2.10 (possibly in 3.0) there's a plan to eventually re-implement/modernize the property tree wrappers using Tom's new cppbind framework[http://www.mail-archive.com/flightgear-devel@lists.sourceforge.net/msg39840.html].&lt;br /&gt;
&lt;br /&gt;
In addition, it is worth noting that the Nasal/FlightGear APIs cannot currently be considered to be thread safe, this mean that -at least for now- the explicit use of pure Nasal space variables is the only way to exploit possible parallelism in your code by making use of threads.&lt;br /&gt;
&lt;br /&gt;
== std.Vector ==&lt;br /&gt;
&lt;br /&gt;
In FlightGear 3.3 or higher you can manipulate vectors using an object-oriented API by using [[Vector|std.Vector]].&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Nasal_Variables&amp;diff=78984</id>
		<title>Nasal Variables</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Nasal_Variables&amp;diff=78984"/>
		<updated>2015-01-08T14:47:35Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:Nasal Navigation}}&lt;br /&gt;
&lt;br /&gt;
A '''variable''' is a combination of a name/namespace (e.g. foo in the local namespace or setprop in the global namespace) and a value (from simple scalars, like &amp;lt;tt&amp;gt;1&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;&amp;quot;hello!&amp;quot;&amp;lt;/tt&amp;gt;, to more complex data types, like hashes and vectors). Here we will explain some of how the various types of variables work.&lt;br /&gt;
&lt;br /&gt;
== Variables ==&lt;br /&gt;
Nasal scripts should make use of the var keyword when declaring variables. The &amp;quot;var&amp;quot; keyword makes a variable guaranteed to be local. Nasal natively provides support for scalars (numbers, strings), lists (arrays, vectors) and hashes (objects or dictionaries); more complex data structures (such as trees) can be built using vectors or hashes. &lt;br /&gt;
&lt;br /&gt;
'''vectors''' and '''hashes''' can be understood as &amp;quot;containers&amp;quot; for your data; in the case of vectors, you end up with a container that has sequentially-numbered places for each element - whereas a hash can also used named keys for its values. Storing happens in a  key/value fashion. Data look-up is usually done via square brackets:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
# create an empty vector&lt;br /&gt;
var myVector = [];&lt;br /&gt;
&lt;br /&gt;
# append a value to it&lt;br /&gt;
append(myVector, 10);&lt;br /&gt;
&lt;br /&gt;
# get out the first element (starting at 0)&lt;br /&gt;
var firstElement = myVector[0];&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Equally, a hash is easy to set up to serve as container for your values:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var myHash = {};&lt;br /&gt;
myHash.field = 10;&lt;br /&gt;
var myField = myHash.field;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
And of course, Nasal also has functions: bits of code which take inputs and can return values and that can be &amp;quot;called&amp;quot; again and again. Rounding out the types are &amp;quot;nil&amp;quot; (aka NULL pointer) and &amp;quot;ghost&amp;quot; (Garbage-collected Handle to OutSide Thingy – a virtual type that represents a C or C++ object).  For more see the [[Nasal Variables#Table of types|table of types]]. Here's an example of a few of these types, being assigned to symbols:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
 var w=100;     # w is a local numerical variable&lt;br /&gt;
 var x=&amp;quot;hello&amp;quot;; # x is a local string variable&lt;br /&gt;
 var y=[];      # y is a local vector (array)&lt;br /&gt;
 var z={};      # z is a local hash (dictionary or table) - also used for OOP&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
What is the difference between a vector and a hash? The difference is, elements in a vector are sequentially numbered, i.e. each element has a numeric index:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var my_vector = ['A','B','C'];&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This initializes a vector with three elements: A, B and C. To access each element of the vector, you would need to use the element's numerical index:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var my_vector = ['A','B','C'];&lt;br /&gt;
print (my_vector[0] ); #prints A&lt;br /&gt;
print (my_vector[1] ); #prints B&lt;br /&gt;
print (my_vector[2] ); #prints C&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
As can be seen, indexing starts at zero.&lt;br /&gt;
&lt;br /&gt;
Compared to vectors, hashes don't use square brackets but curly  braces instead: &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var my_hash = {};&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Hashes may not just have numerical indexes, but also symbolic indexes as lookup keys:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var my_hash = {first:'A',second:'B',third:'C'};&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will create a hash (imagine it like a storage container for a bunch of related variables) and initialize it with three values (A,B and C) which are assigned to three different lookup keys: first, second, third.&lt;br /&gt;
&lt;br /&gt;
In other words, you can access each element in the hash by using its lookup key:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var my_hash = {first:'A',second:'B',third:'C'};&lt;br /&gt;
print ( my_hash.first ); # will print A&lt;br /&gt;
print ( my_hash.second ); # will print B&lt;br /&gt;
print ( my_hash.third ); # will print C&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Insert new pairs (or change existing):&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var hash = {};&lt;br /&gt;
hash.field1 = 1;&lt;br /&gt;
hash['field2']= 2;&lt;br /&gt;
hash[&amp;quot;field3&amp;quot;] = 3&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Nasal supports a &amp;quot;nil&amp;quot; value for use as a null pointer equivalent:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
 var foo=nil; &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Also, note that Nasal symbols are case-sensitive, these are all different variables:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
 var show = func(what) {print(what,&amp;quot;\n&amp;quot;);}&lt;br /&gt;
 var abc=1; # these are all different symbols&lt;br /&gt;
 var ABC=2; # different from abc &lt;br /&gt;
 var aBc=3; # different from abc and ABC&lt;br /&gt;
 &lt;br /&gt;
 show(abc);&lt;br /&gt;
 show(ABC);&lt;br /&gt;
 show(aBc);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Please note that functions assigned to variables are no exception. If you write code without using &amp;quot;var&amp;quot; on variables, then you risk (often hard to debug) breakage at a later time because you may be overwriting symbols in another namespace. &lt;br /&gt;
&lt;br /&gt;
So functions bound to variables should use the &amp;quot;var&amp;quot; keyword as well:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
 var hello = func { &lt;br /&gt;
   print(&amp;quot;hello\n&amp;quot;); &lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
There's another reason why &amp;quot;var&amp;quot; should be used consequently, even if a variable is safe enough from later side effects, because it has a relatively specific or unique name: The &amp;quot;var&amp;quot; keyword makes reading code for others (and for the author after some time) easier, as it makes clear: &amp;quot;this variable starts its life *HERE*&amp;quot;. No need to search around to see whether assigning a value to it means something to other code outside or not. Also, with an editor offering proper syntax highlighting reading such code is actually easier, despite the &amp;quot;noise&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
The problem with nasal code that does not make use of the var keyword is, that it can break other code, and with it the whole system, but no Nasal error message will point you there, as it's syntactically and semantically correct code. Just doing things that it wasn't supposed to do.&lt;br /&gt;
For a more in-depth discussion, please see [http://www.mail-archive.com/flightgear-devel@lists.sourceforge.net/msg13557.html Nasal &amp;amp; &amp;quot;var&amp;quot;].&lt;br /&gt;
&lt;br /&gt;
Nasal scripts that are loaded from [[$FG_ROOT]]/Nasal are automatically placed inside a namespace that is based on the script's name.&lt;br /&gt;
&lt;br /&gt;
For example, referring to our earlier &amp;quot;Hello World&amp;quot; example, global variables defined in the hello.nas script would be accessible by using &amp;quot;hello&amp;quot; as prefix from other modules:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
 # hello.nas&lt;br /&gt;
 var greeting=&amp;quot;Hello World&amp;quot;; # define a greeting symbol inside the hello namespace&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you were now to read out the value from the greeting variable from another Nasal module, you would have to use the hello prefix:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
 # greetme.nas&lt;br /&gt;
 print(hello.greeting); # the hello prefix is referring to the hello namespace (or module).&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Variables - Advanced Uses ==&lt;br /&gt;
&lt;br /&gt;
Nasal also supports Multi-assignment expressions. You can assign more than one variable (or lvalue) at a time by putting them in a parenthesized list:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
   (var a, var b) = (1, 2);&lt;br /&gt;
   var (a, b) = (1, 2);               # Shorthand for (var a, var b)&lt;br /&gt;
   (var a, v[0], obj.field) = (1,2,3) # Any assignable lvalue works&lt;br /&gt;
   var color = [1, 1, 0.5];&lt;br /&gt;
   var (r, g, b) = color;  # works with runtime vectors too&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Vectors (lists or arrays) can be created from others using an ordered list of indexes and ranges. &lt;br /&gt;
This is usually called &amp;quot;vector slicing&amp;quot;.&lt;br /&gt;
For example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
   var v1 = [&amp;quot;a&amp;quot;,&amp;quot;b&amp;quot;,&amp;quot;c&amp;quot;,&amp;quot;d&amp;quot;,&amp;quot;e&amp;quot;]&lt;br /&gt;
   var v2 = v1[3,2];   # == [&amp;quot;d&amp;quot;,&amp;quot;c&amp;quot;];&lt;br /&gt;
   var v3 = v1[1:3];   # i.e. range from 1 to 3: [&amp;quot;b&amp;quot;,&amp;quot;c&amp;quot;,&amp;quot;d&amp;quot;];&lt;br /&gt;
   var v4 = v1[1:];    # no value means &amp;quot;to the end&amp;quot;: [&amp;quot;b&amp;quot;,&amp;quot;c&amp;quot;,&amp;quot;d&amp;quot;,&amp;quot;e&amp;quot;]&lt;br /&gt;
   var i = 2;&lt;br /&gt;
   var v5 = v1[i];     # runtime expressions are fine: [&amp;quot;c&amp;quot;]&lt;br /&gt;
   var v6 = v1[-2,-1]; # negative indexes are relative to end: [&amp;quot;d&amp;quot;,&amp;quot;e&amp;quot;]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The range values can be computed at runtime (e.g. i=1; v5=v1[i:]). Negative indices work the same way they do with the vector functions (-1 is the last element, -2 is 2nd to last, etc...).&lt;br /&gt;
&lt;br /&gt;
== Vector slicing ==&lt;br /&gt;
&lt;br /&gt;
In Nasal, like many other scripting languages, one can &amp;quot;slice&amp;quot; vectors, that is, make a new vector gathering from indices of a previous vector. (Note that slicing strings is currently not supported but is possible.) The basic syntax for slicing is this:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
vec[n:m];&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
This makes a new vector who's contents are taken from vec starting at index n and going until index m – including both indices. This contrasts with Python, who considers index m a &amp;quot;one-past-end&amp;quot; index, i.e. it does not include it in the final result. Let's take an easy example to illustrate this:&lt;br /&gt;
&lt;br /&gt;
Start with a vector, call it vec like above, and have it of size o. We will fill each index with the number of that index, like so:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var vec = setsize([], o);&lt;br /&gt;
forindex (var v; vec)&lt;br /&gt;
    vec[v] = v;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
Thus a vector of size 5 would be [0,1,2,3,4]. Let's look at slicing with that vector. Using the notation above, let's take a slice of the whole vector. We of course have to start at the first index – 0 – and we go to the last valid index – which is not o, but o-1. Thus we have:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
vec[0:o-1];&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
In Python, this would actually go to o not o-1, but using subvec notation, we get the same as Python:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
subvec(vec, 0, o);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
(Be warned that subvec takes a starting index and ''length'' and thus is not equivalent!). There are several other ways to notate this as well:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
vec[0:-1];&lt;br /&gt;
vec[:-1];&lt;br /&gt;
vec[0:];&lt;br /&gt;
vec[:];&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
Note the last three, they show that we can leave out an index to designate the start or end of the vector (or we can equivalently put 0 for the start and -1 for the end). If we do an arbitrary slice from n to m, we will get a vector like this (due to the way we filled our indices):&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
vec[n:m] == [n, n+1, n+2, ..., m-1, m];&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
A degenerate vector slice becomes a simple subscript inside a new vector:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
vec[n:n] == [vec[n]];&lt;br /&gt;
vec[-1:] == [vec[-1]];&lt;br /&gt;
vec[:0] == [vec[0]];&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
You can think of vector slicing as designating the two end-caps of the result, with the result including those indices.&lt;br /&gt;
&lt;br /&gt;
Another feature of Nasal's slices is that one can pick individual indices to &amp;quot;cherry-pick&amp;quot; out of the original vector using commas:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
vec[0,5,7] #pull indices 0, 5, and 7&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
This can also be combined with the other form of slices like so:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
vec[0,5:7] #0, 5, 6, and 7&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now let's make a range() function.&lt;br /&gt;
&lt;br /&gt;
== Making a Range Function ==&lt;br /&gt;
In Python, the range function returns what is essentially a vector slice of an &amp;quot;infinite&amp;quot; vector who's indices are filled like we did above. That is, it returns a vector like this:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
[arg[0], arg[0]+1, arg[0]+2, ..., arg[1]-2, arg[1]-1]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
This turns out to be incredibly useful for iterating over the size of a vector (for i in range(0,len(vec)):) and also has other applications. Since we are doing this in Nasal, we need to be careful with the last index. While in Python it's a equivalent to a simple slice, but in Nasal we need to subtract 1 from the top index. Here's an example of how to do it:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var _range = []; #gets filled like [0, 1, 2, 3, ... ]&lt;br /&gt;
var range = func(start, end) { #one-past-end, actually&lt;br /&gt;
    # We need to make sure our index end-1 exists,&lt;br /&gt;
    # which will happen when the size is equal to end,&lt;br /&gt;
    # (since size-1 is always the last valid index)&lt;br /&gt;
    while(size(_range) &amp;lt; end) {&lt;br /&gt;
        append(_range, size(_range));&lt;br /&gt;
    }&lt;br /&gt;
    return _range[start:end-1];&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Storage: property tree vs. Nasal ==&lt;br /&gt;
With FlightGear's built-in property tree and Nasal's support for it, there are two obvious, and two somewhat competing, ways for storing scalar data: native Nasal variables and FlightGear properties, both of which can be easily accessed and managed from Nasal.&lt;br /&gt;
&lt;br /&gt;
The advantage to native Nasal-space data is that it's fast and simple.  If the only thing that will care about the value is your script, they are good choices.&lt;br /&gt;
&lt;br /&gt;
The property tree is an inter-subsystem communication thing.  This is what you want if you want to share data with the C++ world (for example, YASim &amp;lt;control-output&amp;gt; tags write to properties -- they don't understand Nasal), or read in via configuration files.&lt;br /&gt;
&lt;br /&gt;
Also, native Nasal data structures are usually far faster than their equivalent in property tree space.  This is because there are several layers of indirection in retrieving a property tree value. &lt;br /&gt;
&lt;br /&gt;
In general, this means that you shouldn't make overly excessive use of the property tree for storing state that isn't otherwise relevant to FlightGear or any of its subsystems. Doing that would in fact have adverse effects on the performance of your code. In general, you should favor Nasal variables and data structures and should only make use of properties to interface with the rest of FlightGear, or to easily provide debugging information at run time.&lt;br /&gt;
&lt;br /&gt;
As of FG 2.4.0, retrieving a value from the property tree via getprop is about 50% slower than accessing a native Nasal variable, and accessing the value via node.getValue() is 10-20% slower yet. This is an insignificant amount of time if you are retrieving and storing a few individual values from the property tree, but adds up fast if you are storing or retrieving hashes or large amounts of data.  (You can easily benchmark times on your own code using systime() or debug.benchmark.)&lt;br /&gt;
&lt;br /&gt;
This is a case where your original Nasal code was the better algorithm:  it &amp;quot;ought&amp;quot; to be better to hold the property tree nodes and index them explicitly using getChild() than to create a property tree path string for each child. However, the code that parses property tree paths has been optimized, especially to allocate as little heap storage as possible, so its speed outclasses the Nasal parser [http://www.mail-archive.com/flightgear-devel@lists.sourceforge.net/msg28835.html].&lt;br /&gt;
&lt;br /&gt;
For FlightGear version &amp;lt;= 2.10 the following applies: If there is even a slight performance concern, the only justification for not using getprop() / setprop() directly is if you explicitly require to set a variable type. &lt;br /&gt;
&lt;br /&gt;
Assembling a property path by string manipulation may be in theory less appealing, but it is in practice 3 to 10 times faster than using the props module - I have made several benchmark tests, all leading to the same result. Large-scale property manipulation from Nasal is performance hungry and should &lt;br /&gt;
be avoided if possible by using Nasal-internal variables instead, and if it needs to be done, getprop() /setprop() offer significantly superior performance[http://www.mail-archive.com/flightgear-devel@lists.sourceforge.net/msg39844.html].&lt;br /&gt;
&lt;br /&gt;
Yes, setprop/getprop is definitely faster, because there's less work to do. Evaluating the expression &amp;quot;temp1&amp;quot; requires pushing the symbol value (a&lt;br /&gt;
string) onto the stack, and executing OP_LOCAL which does a hash table lookup to find the value in the namespace list and leave it on the stack for the next bit of code to use.&lt;br /&gt;
&lt;br /&gt;
Evaluating &amp;quot;node.getValue()&amp;quot; requires:&lt;br /&gt;
&lt;br /&gt;
*  Pushing the symbol &amp;quot;node&amp;quot; onto the stack&lt;br /&gt;
*  Executing OP_LOCAL to look it up&lt;br /&gt;
*  Pushing the symbol &amp;quot;getValue&amp;quot; onto the stack&lt;br /&gt;
*  Executing OP_MEMBER to look it up in the object&lt;br /&gt;
*  Executing OP_CALL to call it as a function&lt;br /&gt;
*  Inside the member function:&lt;br /&gt;
*    Finding the values of me._g and the arg vector: 2 OP_LOCALS and 1 OP_MEMBER (not that expensive, dealing with small hashes)&lt;br /&gt;
*    Looking up the C++/raw variant: another OP_LOCAL and into a densely populated namespace&lt;br /&gt;
*    Finally (!) calling the C++ property node function&lt;br /&gt;
*  Turn the output node into a Nasal object and leave it on the stack.&lt;br /&gt;
&lt;br /&gt;
That said, you really don't want to be designing your scripts around raw, low-level performance issues.  Write your code to be readable, not blazingly fast.  In general &amp;quot;altitude&amp;quot; is more readable than &amp;quot;altNode.getValue()&amp;quot; [http://www.mail-archive.com/flightgear-devel@lists.sourceforge.net/msg12222.html].&lt;br /&gt;
&lt;br /&gt;
Note that for FlightGear versions &amp;gt; 2.10 (possibly in 3.0) there's a plan to eventually re-implement/modernize the property tree wrappers using Tom's new cppbind framework[http://www.mail-archive.com/flightgear-devel@lists.sourceforge.net/msg39840.html].&lt;br /&gt;
&lt;br /&gt;
In addition, it is worth noting that the Nasal/FlightGear APIs cannot currently be considered to be thread safe, this mean that -at least for now- the explicit use of pure Nasal space variables is the only way to exploit possible parallelism in your code by making use of threads.&lt;br /&gt;
&lt;br /&gt;
== std.Vector ==&lt;br /&gt;
&lt;br /&gt;
In FlightGear 3.3 you can manipulate vectors using an object-oriented API by using [[Vector|std.Vector]].&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Vector&amp;diff=78983</id>
		<title>Vector</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Vector&amp;diff=78983"/>
		<updated>2015-01-08T14:44:26Z</updated>

		<summary type="html">&lt;p&gt;Onox: Document API of of std.Vector&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:Nasal Navigation}}&lt;br /&gt;
&lt;br /&gt;
std.Vector provides an object-oriented way to use vectors in Nasal in FlightGear 3.3 or higher.&lt;br /&gt;
&lt;br /&gt;
=== Creating a new vector ===&lt;br /&gt;
&lt;br /&gt;
A new empty Vector can be created as follows:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var v = std.Vector.new();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can also wrap a standard Nasal vector in an instance of Vector by adding the Nasal vector as a parameter to new():&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var v = std.Vector.new(['a', 'b', 'c']);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Adding items ===&lt;br /&gt;
&lt;br /&gt;
A single item can be added using append():&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
v.append('x');&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To insert an item on a specific position, use insert(). The index is zero-based. The previous item on the given index will be shifted one position to the right:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var v = std.Vector.new(['a', 'c', 'd']);&lt;br /&gt;
&lt;br /&gt;
v.insert(1, 'b');&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To insert items to the front of the vector, use index 0. If a Vector has n items, then you can use indices 0 to n. Using index n will append the item to the Vector. It is also possible to use negative indices in order to insert items at a position relative to the end of the Vector:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var v = std.Vector.new(['a', 'b', 'd']);&lt;br /&gt;
&lt;br /&gt;
v.insert(-1, 'c');&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This example inserts 'c' at the old position of 'd'. 'd' will be shifted to the right. To insert an item at the front of the Vector with currently n items using a negative index, use index -n:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var v = std.Vector.new(['b', 'c', 'd']);&lt;br /&gt;
&lt;br /&gt;
v.insert(-3, 'a');&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Adding vectors ===&lt;br /&gt;
&lt;br /&gt;
The Vector can be extended with a Nasal vector using extend():&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
v.extend(['x', 'y', 'z']);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Removing items ===&lt;br /&gt;
&lt;br /&gt;
To remove the first occurence of an item, use remove():&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
v.remove('x');&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you try to remove a non-existing item, a ValueError will be raised. Use Nasal's call() function to catch this error. To remove and return an item at a given index, use pop():&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var v = std.Vector.new(['a', 'b', 'd', 'c']);&lt;br /&gt;
&lt;br /&gt;
var result = v.pop(2);&lt;br /&gt;
assert(result == 'd');&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Just like with insert(), the index given to pop() can be negative. If you try to call pop() using an invalid index, then an IndexError will be raised.&lt;br /&gt;
&lt;br /&gt;
To remove all items from the Vector, use clear():&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
v.clear();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Querying the vector ===&lt;br /&gt;
&lt;br /&gt;
To query the size of the Vector, use size():&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var v = std.Vector.new(['a', 'b', 'c']);&lt;br /&gt;
&lt;br /&gt;
var result = v.size();&lt;br /&gt;
assert(result == 3);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To query the index of the first occurence of an item, use index():&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var v = std.Vector.new(['a', 'b', 'c']);&lt;br /&gt;
&lt;br /&gt;
var result = v.index('c');&lt;br /&gt;
assert(result == 2);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
contains() can be used to determine if the Vector contains the given item:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var v = std.Vector.new(['a', 'b', 'c']);&lt;br /&gt;
&lt;br /&gt;
var result = v.contains('c');&lt;br /&gt;
assert(result);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Iteration ===&lt;br /&gt;
&lt;br /&gt;
In order to iterate over the items, you need to iterate over the wrapped Nasal vector itself:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var v = std.Vector.new(['a', 'b', 'c']);&lt;br /&gt;
&lt;br /&gt;
foreach (var item; v.vector) {&lt;br /&gt;
    print(item);&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=FlightGear_Git:_data_developers&amp;diff=78321</id>
		<title>FlightGear Git: data developers</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=FlightGear_Git:_data_developers&amp;diff=78321"/>
		<updated>2014-12-16T14:48:45Z</updated>

		<summary type="html">&lt;p&gt;Onox: The git clone command is already explained. No need to create a Gitorious account.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Git}}&lt;br /&gt;
Anyone contributing data to FlightGear, like aircraft models, dialogs or textures, is a '''data developer'''. This article helps those in setting up a correct workflow, to ease the inclusion of their work into the simulator.&lt;br /&gt;
&lt;br /&gt;
== Note about aircraft ==&lt;br /&gt;
As of September 2014, all aircraft but those in the base package (that is shipped with a FlightGear release) have been copied over to a new [https://sourceforge.net/p/flightgear/fgaddon/ SVN repository]. Changes to those aircraft should be made there instead of in the Git fgdata repository discussed in this article. For the moment all aircraft are still present in the Git repository, but only base package aircraft are maintained in the Git repository. Before the release of FlightGear 3.4 in February 2014, all non-base package aircraft will be removed from Git.&lt;br /&gt;
&lt;br /&gt;
== Preparations ==&lt;br /&gt;
The steps described in this section are only required once, at the initialization of your development environment.&lt;br /&gt;
&lt;br /&gt;
=== Cloning the repository ===&lt;br /&gt;
The first thing to do as a prospective developer is to [https://gitorious.org/users/new register at Gitorious] if you haven't already done so. This will enable you to publish your edits and have them incorporated into the main project.&lt;br /&gt;
&lt;br /&gt;
After logging in, you can create a personal &amp;quot;clone&amp;quot; of the data repository. This clone is where you will be working in, without touching the main repository. To create a clone, navigate to the fgdata repository on https://gitorious.org/fg/ and click the [http://gitorious.org/fg/fgdata/clone Clone repository] button. In general the default name is fine, but you can change it to whatever you like. Gitorious will now clone the data repository. Due to the size of our repository, this can take some time.&lt;br /&gt;
&lt;br /&gt;
=== Obtaining the data ===&lt;br /&gt;
Before you can start editing, you first need to retrieve the data to your computer. There are two ways to do this. At the time of writing the data repository is over 5 GB. Continuing an interrupted cloning of a repository is not supported within Git. Therefore, if you have a slow or unstable connection to the internet, it is recommended to [[#Bundle|download the bundle]].&lt;br /&gt;
&lt;br /&gt;
For both approaches, Git must be installed. There is a lot of software available, but the following are often used:&lt;br /&gt;
* '''Mac:''' [http://code.google.com/p/git-osx-installer/ Git for OS X]&lt;br /&gt;
* '''Windows:''' [http://msysgit.github.io/ msysGit]&lt;br /&gt;
&lt;br /&gt;
==== Single clone ====&lt;br /&gt;
# Create a directory on your computer where you'll be storing the data.&lt;br /&gt;
# Change into that folder.&lt;br /&gt;
# Clone the repository with the following command. This will create a &amp;lt;tt&amp;gt;/fgdata&amp;lt;/tt&amp;gt; subfolder and put all the contents of the repository in there.&lt;br /&gt;
#:&amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;git clone git://gitorious.org/fg/fgdata.git&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== Bundle ====&lt;br /&gt;
For the FlightGear-data there is a [http://www.kernel.org/pub/software/scm/git/docs/git-bundle.html git-bundle] (snapshot) [http://mxchange.org:23456/file?info_hash=%BF%FF%AB%0C%16%BF%8Eg%B8%A0%CFw%01%0A%5D%8F%3F%81%96y torrent] ([http://mxchange.org:23456/ tracker]; [http://flightgear.mxchange.org/pub/fgfs/fgdata.bundle.md5 md5]|[http://flightgear.mxchange.org/pub/fgfs/fgdata.bundle.sha1 sha1]|[http://flightgear.mxchange.org/pub/fgfs/fgdata.bundle.sha512 sha512]) available. This way you can resume interrupted downloads. After unpacking it only a comparatively small amount of data has to be transferred from the git server to synchronize your repository. Also download the fgdata-update-*.bundle updates linked in the [http://mxchange.org:23456/ tracker]. See also the Develop sections in [[FlightGear Git on Windows]].&lt;br /&gt;
&lt;br /&gt;
# Create a directory on your computer where you'll be storing the data.&lt;br /&gt;
# Change into that folder.&lt;br /&gt;
# Do the following steps to extract the bundle and bring the repository up to date:&lt;br /&gt;
#:&amp;lt;code&amp;gt;git clone fgdata.bundle fgdata&amp;lt;/code&amp;gt;&lt;br /&gt;
#:&amp;lt;code&amp;gt;cd fgdata&amp;lt;/code&amp;gt;&lt;br /&gt;
#:&amp;lt;code&amp;gt;git checkout -b master-tmp&amp;lt;/code&amp;gt;&lt;br /&gt;
#:&amp;lt;code&amp;gt;for N in 01 02 03 04 05 06 07 08 09 10 11; do git pull ../fgdata-update-0$N.bundle master; done&amp;lt;/code&amp;gt;&lt;br /&gt;
#:&amp;lt;code&amp;gt;git remote rm origin&amp;lt;/code&amp;gt;&lt;br /&gt;
#:&amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;git remote add origin git://gitorious.org/fg/fgdata.git&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
#:&amp;lt;code&amp;gt;git fetch origin&amp;lt;/code&amp;gt;&lt;br /&gt;
#:&amp;lt;code&amp;gt;git branch --track master origin/master&amp;lt;/code&amp;gt;&lt;br /&gt;
#:&amp;lt;code&amp;gt;git checkout master&amp;lt;/code&amp;gt;&lt;br /&gt;
#:&amp;lt;code&amp;gt;git branch -D master-tmp&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You should be suspicious if based on the printed progress during the &amp;lt;code&amp;gt;git fetch origin&amp;lt;/code&amp;gt; phase you estimate the data download during the fetch will exceed 1GB (assuming the bundle is not terribly outdated).&lt;br /&gt;
&lt;br /&gt;
=== Authentication ===&lt;br /&gt;
In order to publish edits on Gitorious, you need to generate a secret key so you can be correctly identified.&lt;br /&gt;
&lt;br /&gt;
# Navigate to your newly created fgdata directory and run:&lt;br /&gt;
#: &amp;lt;code&amp;gt;ssh-keygen&amp;lt;/code&amp;gt;&lt;br /&gt;
# Enter the name of the file in which you prefer to save the key and press Enter.&lt;br /&gt;
# Enter your password/passphrase and press Enter. You'll have to do this twice.&lt;br /&gt;
# Your key is now being generated. Open the .pub file with an editor and copy the content.&lt;br /&gt;
# Visit your dashboard at Gitorious and navigate to &amp;quot;Manage SSH keys&amp;quot;.&lt;br /&gt;
# Click the &amp;quot;Add SSH key&amp;quot; button and paste the content of the .pub file. Follow the instructions on the screen.&lt;br /&gt;
# Now run the following, again in your fgdata directory, with ''&amp;lt;url&amp;gt;'' as the line that you get by clicking SSH on your fgdata clone page at Gitorious (something like ''git@gitorious.org:~your/fg/yours-fgdata.git''):&lt;br /&gt;
#: &amp;lt;code&amp;gt;git remote set-url origin &amp;lt;url&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Obtaining the simulator ===&lt;br /&gt;
In order to test your work, you'll need the FlightGear version that matches the data. Since FlightGear is under constant development, data from Git does not work with previous releases. Fortunately obtaining the latest development version of the simulator is fairly straightforward for most operating systems.&lt;br /&gt;
&lt;br /&gt;
* '''Mac:''' Download [http://flightgear.simpits.org:8080/job/FlightGear-mac/ the .dmg]&lt;br /&gt;
* '''Windows:''' Download the [http://flightgear.simpits.org:8080/job/Win32-installer-Cmake 32-bits] or [http://flightgear.simpits.org:8080/job/Win64-installer-Cmake 64-bits] installer and follow its instructions. Let it install the binary into a clean directory.&lt;br /&gt;
&lt;br /&gt;
Point [[$FG_ROOT]] to your freshly obtained fgdata directory. When using [[FlightGear Launch Control|the launcher]], this can be done on the first page, previous from the aircraft selection.&lt;br /&gt;
&lt;br /&gt;
== Making edits ==&lt;br /&gt;
It is recommended to split your new fgdata clone into separate local branches for your work. For instance, if you're working on the Boeing 747-400 and the aircraft reflection shader, you might create 2 branches named &amp;quot;747-400&amp;quot; and &amp;quot;reflect-shader&amp;quot;. To do this, run the following commands:&lt;br /&gt;
:&amp;lt;code&amp;gt;git checkout master&amp;lt;/code&amp;gt;&lt;br /&gt;
:&amp;lt;code&amp;gt;git checkout -b &amp;lt;branch name&amp;gt;&amp;lt;/code&amp;gt; &lt;br /&gt;
Then you can make your changes to the new local branch(es), which will make merge requests easier for both yourself and committers. To switch in between branches, simply use&lt;br /&gt;
:&amp;lt;code&amp;gt;git checkout &amp;lt;branch name&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Publishing edits ==&lt;br /&gt;
To push local updates to your fgdata clone on Gitorious, perform the following steps:&lt;br /&gt;
# Switch to the branch that contains your edits:&lt;br /&gt;
#:&amp;lt;code&amp;gt;git checkout &amp;lt;branch name&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
# List all the changed files:&lt;br /&gt;
#:&amp;lt;code&amp;gt;git status -- .&amp;lt;/code&amp;gt;&lt;br /&gt;
# Now it's time to commit the changed files.&lt;br /&gt;
#* If you want to commit all changed files, run the following and type your commit message.&lt;br /&gt;
#*: &amp;lt;code&amp;gt;git commit -a&amp;lt;/code&amp;gt;&lt;br /&gt;
#* If you only want to commit a selection of files, run the following:&lt;br /&gt;
#*: &amp;lt;code&amp;gt;git add &amp;lt;path/to/file&amp;gt;&amp;lt;/code&amp;gt; (for single files)&lt;br /&gt;
#*: &amp;lt;code&amp;gt;git add --all &amp;lt;path/to/folder&amp;gt;&amp;lt;/code&amp;gt; (to add all files within a certain folder)&lt;br /&gt;
#*: &amp;lt;code&amp;gt;git rm &amp;lt;path/to/file&amp;gt;&amp;lt;/code&amp;gt; (to remove files that you've removed)&lt;br /&gt;
#: Followed by&lt;br /&gt;
#:: &amp;lt;code&amp;gt;git commit -m &amp;quot;&amp;lt;commit message&amp;gt;&amp;quot;&amp;lt;/code&amp;gt;&lt;br /&gt;
# Check if everything went fine, by loading Gitk:&lt;br /&gt;
#: &amp;lt;code&amp;gt;gitk&amp;lt;/code&amp;gt;&lt;br /&gt;
# Finally, push the commit to your fgdata clone Gitorious with the following command. Replace &amp;lt;code&amp;gt;YourUID&amp;lt;/code&amp;gt; with your Gitorious account:&lt;br /&gt;
#: &amp;lt;code&amp;gt;git push git@gitorious.org:~YourUID/fg/YourUIDs-fgdata.git&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Requesting edits to be merged ==&lt;br /&gt;
[[File:Create merge request at Gitorious.png|thumb|270px|Creating a merge request at Gitorious.]]&lt;br /&gt;
# Click the &amp;quot;Request merge&amp;quot; button on your fgdata clone page. Loading the next page can take a while, as it will list all commits of the past years!&lt;br /&gt;
# Once again write a short summary (could be the same as used with git commit), but this time, also write an explanation of your merge request (what does it do?). Make sure you set the target repository to fgdata, target branch to master and source branch to the local branch with your updates.&lt;br /&gt;
# Tick the box in front of your commit and click the &amp;quot;Create merge request&amp;quot; button.&lt;br /&gt;
# Everyone can see the pending request, but in order to make sure that your request gets looked at, you may contact a contributor. You can find a list of people on the right side of the [https://gitorious.org/fg/fgdata repository page].&lt;br /&gt;
&lt;br /&gt;
Creating merge requests using this method literally means merging an entire branch into fgdata; this may not be desirable for some situations, such as small changes that only require one little commit. There's a neat method to only push certain commits to a merge request discussed by Anders Gidenstam [http://forum.flightgear.org/viewtopic.php?f=4&amp;amp;t=10392&amp;amp;start=45#p115747 on the FlightGear Forums].&lt;br /&gt;
&lt;br /&gt;
[[Category:Git]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Template:POTW/2014-50&amp;diff=78202</id>
		<title>Template:POTW/2014-50</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Template:POTW/2014-50&amp;diff=78202"/>
		<updated>2014-12-07T20:39:50Z</updated>

		<summary type="html">&lt;p&gt;Onox: Created page with &amp;quot;{{POTW |image       = ASW20_summerday1.jpg |description = ASW20 on a nice summer day. |article     = Schleicher_ASW_20 }}&amp;lt;noinclude&amp;gt;Category:Picture of the week 2014&amp;lt;/noin...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{POTW&lt;br /&gt;
|image       = ASW20_summerday1.jpg&lt;br /&gt;
|description = ASW20 on a nice summer day.&lt;br /&gt;
|article     = Schleicher_ASW_20&lt;br /&gt;
}}&amp;lt;noinclude&amp;gt;[[Category:Picture of the week 2014]]&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Autopilot_configuration_reference&amp;diff=78102</id>
		<title>Autopilot configuration reference</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Autopilot_configuration_reference&amp;diff=78102"/>
		<updated>2014-11-30T13:42:27Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[File:FgPlot.jpg|400px|thumb|[[FGPlot]] can be used to plot the value properties while tuning an autopilot.]]&lt;br /&gt;
&lt;br /&gt;
{{forum|46|Autopilot &amp;amp; Route Manager}}&lt;br /&gt;
{{Autoflight Navigation}}&lt;br /&gt;
&lt;br /&gt;
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 [[Git]] sources. Some of the elements may not be available in the current release version of FlightGear.&lt;br /&gt;
&lt;br /&gt;
The flightgear xml based autopilot system can run at FDM rate or at frame rate. Using a &amp;lt;autopilot&amp;gt; tag in your aircraft's -set.xml &lt;br /&gt;
adds the autopilot at fdm rate, using a &amp;lt;property-rule&amp;gt; runs the same config at frame rate.&lt;br /&gt;
&lt;br /&gt;
{{Systems_Modeling_Disclaimer}}&lt;br /&gt;
&lt;br /&gt;
Refer to [[Howto:Design an autopilot]] as a guide how to use these elements. &lt;br /&gt;
&lt;br /&gt;
For built-in runtime plotting of FlightGear properties (including FDM/Autopilot properties), check out [[FGPlot]] (available in FlightGear 2.11+).&lt;br /&gt;
&lt;br /&gt;
== Structure Of a Configuration File ==&lt;br /&gt;
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:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;PropertyList&amp;gt;&lt;br /&gt;
   &amp;lt;params&amp;gt;&lt;br /&gt;
     &amp;lt;controls&amp;gt;&lt;br /&gt;
       &amp;lt;aileron&amp;gt;controls/flight/aileron&amp;lt;/aileron&amp;gt;&lt;br /&gt;
       &amp;lt;rudder&amp;gt;controls/flight/rudder&amp;lt;/rudder&amp;gt;&lt;br /&gt;
       &amp;lt;elevator&amp;gt;controls/flight/elevator&amp;lt;/elevator&amp;gt;&lt;br /&gt;
     &amp;lt;/controls&amp;gt;&lt;br /&gt;
   &amp;lt;/params&amp;gt;&lt;br /&gt;
   &amp;lt;!-- Place your components here --&amp;gt;&lt;br /&gt;
   &amp;lt;!--&lt;br /&gt;
   &amp;lt;filter&amp;gt;&lt;br /&gt;
     &amp;lt;name&amp;gt;Myfilter&amp;lt;/name&amp;gt;&lt;br /&gt;
     &amp;lt;input&amp;gt;/foo&amp;lt;/input&amp;gt;&lt;br /&gt;
     &amp;lt;output&amp;gt;/bar&amp;lt;/output&amp;gt;&lt;br /&gt;
   &amp;lt;/filter&amp;gt;&lt;br /&gt;
   --&amp;gt;&lt;br /&gt;
 &amp;lt;/PropertyList&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{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 external file using &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;params include=&amp;quot;my-params.xml&amp;quot;/&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/tt&amp;gt; to avoid duplication of code.}}&lt;br /&gt;
&lt;br /&gt;
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 developers put these files into the Systems folder of the aircraft.&lt;br /&gt;
&lt;br /&gt;
== Adding an Autopilot Configuration to Aircraft ==&lt;br /&gt;
Autopilot configuration files are added to the aircraft by adding &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;autopilot&amp;gt;&lt;br /&gt;
    &amp;lt;path&amp;gt;Aircraft/MyAircraft/Systems/my-autopilot.xml&amp;lt;/path&amp;gt;&lt;br /&gt;
  &amp;lt;/autopilot&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
to the &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;sim&amp;gt;&lt;br /&gt;
   &amp;lt;systems&amp;gt;&lt;br /&gt;
     &amp;lt;!-- many other elements live here --&amp;gt;&lt;br /&gt;
     &amp;lt;autopilot&amp;gt;&lt;br /&gt;
       &amp;lt;path&amp;gt;Aircraft/MyAircraft/Systems/my-autopilot.xml&amp;lt;/path&amp;gt;&lt;br /&gt;
     &amp;lt;/autopilot&amp;gt;&lt;br /&gt;
   &amp;lt;/systems&amp;gt;&lt;br /&gt;
  &amp;lt;/sim&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
node of your aircraft-set.xml file. Note, that more than one &amp;lt;autopilot&amp;gt; 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 &amp;lt;systems&amp;gt;. For example, lateral and vertical autopilot modes could live in separate files, as could a yaw-damper system.&lt;br /&gt;
&lt;br /&gt;
== Adding a Property-rule Configuration to Aircraft ==&lt;br /&gt;
Property-rules can also be used in which case they will run at frame rate. You can use these to process properties so their values can be used by other systems outside of the autopilot scope (for example to create smooth animations for switches that normally have discrete values)&lt;br /&gt;
&lt;br /&gt;
To achieve this load your filters configuration by adding:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;property-rule n=&amp;quot;100&amp;quot;&amp;gt;  &amp;lt;!-- &amp;quot;n&amp;quot; needs to be &amp;gt;= 100 to avoid overwriting other predefined global rules (in particular the environment ones) --&amp;gt;&lt;br /&gt;
    &amp;lt;name&amp;gt;My property rule&amp;lt;/name&amp;gt;  &amp;lt;!--  Optional name tag useful for debugging and other maintenance --&amp;gt;&lt;br /&gt;
    &amp;lt;path&amp;gt;Systems/my-propertyrules.xml&amp;lt;/path&amp;gt;  &amp;lt;!-- path can be relative to the current aircraft-set.xml location --&amp;gt;&lt;br /&gt;
  &amp;lt;/property-rule&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
to the :&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;sim&amp;gt;&lt;br /&gt;
   &amp;lt;systems&amp;gt;&lt;br /&gt;
     &amp;lt;!-- many other elements live here --&amp;gt;&lt;br /&gt;
     &amp;lt;property-rule n=&amp;quot;100&amp;quot;&amp;gt;  &amp;lt;!-- &amp;quot;n&amp;quot; needs to be &amp;gt;= 100 to avoid overwriting other predefined global rules (in particular the environment ones) --&amp;gt;&lt;br /&gt;
       &amp;lt;name&amp;gt;My property rule&amp;lt;/name&amp;gt;  &amp;lt;!--  Optional name tag useful for debugging and other maintenance --&amp;gt;&lt;br /&gt;
       &amp;lt;path&amp;gt;Systems/my-propertyrules.xml&amp;lt;/path&amp;gt;  &amp;lt;!-- path can be relative to the current aircraft-set.xml location --&amp;gt;&lt;br /&gt;
     &amp;lt;/property-rule&amp;gt;&lt;br /&gt;
   &amp;lt;/systems&amp;gt;&lt;br /&gt;
  &amp;lt;/sim&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
node of your aircraft-set.xml file. Note that you can add multiple &amp;lt;property-rule&amp;gt; elements, similar to the &amp;lt;autopilot&amp;gt; as described above.&lt;br /&gt;
&lt;br /&gt;
== Available Elements ==&lt;br /&gt;
All elements may contain the attributes &amp;quot;include&amp;quot; and &amp;quot;alias&amp;quot;. &lt;br /&gt;
The &amp;quot;include&amp;quot; property takes a file name as a parameter. This can be used to read the document tree of an external XML file into the node containing the &amp;quot;include&amp;quot; attribute. The included file must have a PropertyList node as the root node. All nodes under this PropertyList node will be added to the node containing the &amp;quot;include&amp;quot; attribute.&lt;br /&gt;
The &amp;quot;alias&amp;quot; attribute refers to an element defined elsewhere in this XMl document. Alias references are in a path-style syntax, either as a relative or absolute path. Absolute paths start with a slash, like &amp;lt;foo alias=&amp;quot;/params/bar/baz&amp;quot;/&amp;gt;. Use the colon to move through the document tree, similar to file system paths like &amp;lt;foo alias=&amp;quot;../../bar/baz&amp;quot;/&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Any top-level element can appear in an autopilot XML file, but only the following elements will be recognised and used:&lt;br /&gt;
* &amp;lt;pid-controller&amp;gt;&lt;br /&gt;
* &amp;lt;pi-simple-controller&amp;gt;&lt;br /&gt;
* &amp;lt;filter&amp;gt;&lt;br /&gt;
* &amp;lt;predict-simple&amp;gt;&lt;br /&gt;
* &amp;lt;logic&amp;gt;&lt;br /&gt;
* &amp;lt;flipflop&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Common Elements Used By All Elements ==&lt;br /&gt;
&lt;br /&gt;
=== Name ===&lt;br /&gt;
The &amp;lt;name&amp;gt; element is optional, but should be added to give the controller a distinct name. It is only used in debug output.&lt;br /&gt;
 &amp;lt;name&amp;gt;NAV hold&amp;lt;/name&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Feedback if disabled ===&lt;br /&gt;
The &amp;lt;feedback-if-disabled&amp;gt; element advises the controller to feed back the output property value to the active input property if the&lt;br /&gt;
condition defined in the &amp;lt;enable&amp;gt; tag evaluates to false. This is usually required for controllers like servo drivers behind a PID-controller to give that PID-controller a valid starting value when it becomes enabled. The absence of this element or anything but the word ''true'' within this element results in feedback disabled.&lt;br /&gt;
 &amp;lt;feedback-if-disabled&amp;gt;true&amp;lt;/feedback-if-disabled&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Debug ===&lt;br /&gt;
If the &amp;lt;debug&amp;gt; element is present and if it contains the word ''true'', the containing controller prints out some diagnostic information on the console for each processing loop.&lt;br /&gt;
 &amp;lt;debug&amp;gt;true&amp;lt;/debug&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Input and Reference ===&lt;br /&gt;
Each controller has two input &amp;quot;lines&amp;quot;, denoted by the tags &amp;lt;input&amp;gt; and &amp;lt;reference&amp;gt;. The arithmetic difference of these two values is used by the respective controller to compute it's output. Unfortunately due to historical reasons, the sign of input and reference is not consistent for all controllers. While the pid-controller and the pi-simple-controller compute &amp;quot;reference-input&amp;quot;, the filter controller computes &amp;quot;input-reference&amp;quot;. Each element is optional with a default value of zero. These elements are made of so called '''Input Values''' described further down in this document.&lt;br /&gt;
&lt;br /&gt;
Example for a simple differential amplifier, computing output = (input-reference)*2&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;filter&amp;gt;&lt;br /&gt;
   &amp;lt;type&amp;gt;gain&amp;lt;/type&amp;gt;&lt;br /&gt;
   &amp;lt;gain&amp;gt;1.0&amp;lt;/gain&amp;gt;&lt;br /&gt;
   &amp;lt;input&amp;gt;/some/input&amp;lt;/input&amp;gt;&lt;br /&gt;
   &amp;lt;reference&amp;gt;/some/output&amp;lt;/reference&amp;gt;&lt;br /&gt;
   &amp;lt;output&amp;gt;/some/output&amp;lt;/output&amp;gt;&lt;br /&gt;
 &amp;lt;/filter&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Output ===&lt;br /&gt;
The &amp;lt;outptu&amp;gt; element names the properties, the computed value should be written to. More than one &amp;lt;output&amp;gt; may be present, each named property will be assigned the computed value.&lt;br /&gt;
 &amp;lt;output&amp;gt;controls/flight/elevator&amp;lt;/output&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
=== Enable ===&lt;br /&gt;
Controllers can be enabled or disabled using property values. This element &amp;lt;enable&amp;gt; may contain a &amp;lt;prop&amp;gt; and a &amp;lt;value&amp;gt; element. The controller is enabled, if the value of the named property equals the given value. This feature is considered deprecated and might go away in future releases. The preferred way of defining the enable-condition is by adding a &amp;lt;condition&amp;gt; element to the &amp;lt;enable&amp;gt; element. This &amp;lt;condition&amp;gt; follows the same syntactical rules as the one used in model animations and can model complex expression trees.&lt;br /&gt;
To enable a wing leveler only if the current bank angle does not exceed 30° of bank, use this condition&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;enable&amp;gt;&lt;br /&gt;
   &amp;lt;condition&amp;gt;&lt;br /&gt;
     &amp;lt;less-than&amp;gt;&lt;br /&gt;
       &amp;lt;property&amp;gt;orientation/bank-angle-deg&amp;lt;/property&amp;gt;&lt;br /&gt;
       &amp;lt;value&amp;gt;30.0&amp;lt;/value&amp;gt;&lt;br /&gt;
     &amp;lt;/less-than&amp;gt;&lt;br /&gt;
     &amp;lt;greater-than&amp;gt;&lt;br /&gt;
       &amp;lt;property&amp;gt;orientation/bank-angle-deg&amp;lt;/property&amp;gt;&lt;br /&gt;
       &amp;lt;value&amp;gt;-30.0&amp;lt;/value&amp;gt;&lt;br /&gt;
     &amp;lt;/greater-than&amp;gt;&lt;br /&gt;
   &amp;lt;/condition&amp;gt;&lt;br /&gt;
 &amp;lt;/enable&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Input Values ===&lt;br /&gt;
Input values for controllers may be specified in several notations. Values may be supplied as constants, from properties or by means of simple linear transformations. Conditions allow the selection of one of multiple input sources. The following text will use the &amp;lt;tt&amp;gt;reference&amp;lt;/tt&amp;gt; element as an example but it may be substituted by any other input element like &amp;lt;tt&amp;gt;Kp&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;gain&amp;lt;/tt&amp;gt; etc. Input values will be interpreted as double values.&lt;br /&gt;
&lt;br /&gt;
==== A constant value ====&lt;br /&gt;
A constant value is defined by just adding the value as text to the input element: &lt;br /&gt;
 &amp;lt;reference&amp;gt;&lt;br /&gt;
   &amp;lt;value&amp;gt;3.5&amp;lt;/value&amp;gt;&lt;br /&gt;
 &amp;lt;/reference&amp;gt;&lt;br /&gt;
The shortcut syntax is also valid:&lt;br /&gt;
 &amp;lt;reference&amp;gt;3.5&amp;lt;/reference&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If the text can be parsed by &amp;lt;tt&amp;gt;strtod()&amp;lt;/tt&amp;gt; to a double value, it will be used as a constant value, otherwise it will be interpreted as a property value (see next paragraph)&lt;br /&gt;
&lt;br /&gt;
==== A property value ====&lt;br /&gt;
To evaluate the value of a property, place the name of the property into the text element:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;reference&amp;gt;&lt;br /&gt;
   &amp;lt;property&amp;gt;/my/property&amp;lt;/property&amp;gt;&lt;br /&gt;
 &amp;lt;/reference&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The shortcut syntax is also valid:&lt;br /&gt;
 &amp;lt;reference&amp;gt;/my/property&amp;lt;/reference&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{note|The shortcut syntax is only valid, if neither &amp;lt;property&amp;gt; nor &amp;lt;value&amp;gt; element exists.&lt;br /&gt;
If both &amp;lt;property&amp;gt; '''and''' &amp;lt;value&amp;gt; element exist, the property will be initialized with the given value with scale and offset applied correctly.&lt;br /&gt;
Properties don't have to exist, the will be created as needed.}}&lt;br /&gt;
{{note|For backward compatibility, the notation &amp;lt;prop&amp;gt; instead of &amp;lt;property&amp;gt; is also valid but considered deprecated and might go away in future releases.}}&lt;br /&gt;
&lt;br /&gt;
==== Linear transformation of the input value ====&lt;br /&gt;
Input values may be scaled and shifted before they are processed by the controller using the formula &amp;lt;tt&amp;gt;y = value * scale + offset&amp;lt;/tt&amp;gt;&lt;br /&gt;
To use a celsius temperature property in a controller which expects the temperature in fahrenheit you might use&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;reference&amp;gt;&lt;br /&gt;
   &amp;lt;property&amp;gt;/environment/temperature-degc&amp;lt;/property&amp;gt;&lt;br /&gt;
   &amp;lt;scale&amp;gt;1.8&amp;lt;/scale&amp;gt;&lt;br /&gt;
   &amp;lt;offset&amp;gt;32&amp;lt;/offset&amp;gt;&lt;br /&gt;
 &amp;lt;/reference&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== Periodical transformation of the input value ====&lt;br /&gt;
Periodical (like angular) input values can be transformed to appear in the correct phase before they are processed by the controller by adding or substracting multiples of the period to the input value until the values is in the requested periods interval.&lt;br /&gt;
The following example converts the heading which comes in the range of [0..360] into the range of [-180..+180]. This will cause a heading of 270 to be processed as a value of -90.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;reference&amp;gt;&lt;br /&gt;
   &amp;lt;property&amp;gt;/orientation/heading-deg&amp;lt;/property&amp;gt;&lt;br /&gt;
   &amp;lt;period&amp;gt;&lt;br /&gt;
     &amp;lt;min&amp;gt;-180.0&amp;lt;/min&amp;gt;&lt;br /&gt;
     &amp;lt;max&amp;gt;180.0&amp;lt;/max&amp;gt;&lt;br /&gt;
   &amp;lt;/period&amp;gt;&lt;br /&gt;
 &amp;lt;/reference&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== Input clamping ====&lt;br /&gt;
To clamp the input to a minimum value, maximum value or both, the tags &amp;lt;tt&amp;gt;&amp;lt;min&amp;gt;&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;&amp;lt;max&amp;gt;&amp;lt;/tt&amp;gt; can be used. Clamping will occur after the linear transformation has been applied. Note the difference of input clamping to output clamping. While input clamping is applied '''before''' the signal reaches the controller, output clamping will be applied to the output signal '''after''' it has been processed.&lt;br /&gt;
&lt;br /&gt;
The following code will keep the input to the controller in the range of 60 to 80 degrees Fahrenheit:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;reference&amp;gt;&lt;br /&gt;
   &amp;lt;property&amp;gt;/environment/temperature-degc&amp;lt;/property&amp;gt;&lt;br /&gt;
   &amp;lt;scale&amp;gt;1.8&amp;lt;/scale&amp;gt;&lt;br /&gt;
   &amp;lt;offset&amp;gt;32&amp;lt;/offset&amp;gt;&lt;br /&gt;
   &amp;lt;min&amp;gt;60&amp;lt;/min&amp;gt;&lt;br /&gt;
   &amp;lt;max&amp;gt;80&amp;lt;/max&amp;gt;&lt;br /&gt;
 &amp;lt;/reference&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== Absolute values ====&lt;br /&gt;
To use the absolute (unsigned) value of the input, add &amp;lt;tt&amp;gt;&amp;lt;abs type=&amp;quot;bool&amp;quot;&amp;gt;true&amp;lt;/abs&amp;gt;&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;reference&amp;gt;&lt;br /&gt;
   &amp;lt;property&amp;gt;/autopilot/internal/course-error-deg&amp;lt;/property&amp;gt;&lt;br /&gt;
   &amp;lt;abs type=&amp;quot;bool&amp;quot;&amp;gt;true&amp;lt;/abs&amp;gt;&lt;br /&gt;
 &amp;lt;/reference&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== Recursive definition ====&lt;br /&gt;
The elements &amp;lt;tt&amp;gt;&amp;lt;scale&amp;gt;&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;&amp;lt;offset&amp;gt;&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;&amp;lt;min&amp;gt;&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;&amp;lt;max&amp;gt;&amp;lt;/tt&amp;gt; itself can be defined as input values. This code uses as reference the value of course-error-deg, scaled by two and an offset applied which is calculated as the product of the bank-angle-de and the property some/property which itself is limited within the range of -1.5 .. +1.5.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;reference&amp;gt;&lt;br /&gt;
   &amp;lt;property&amp;gt;/autopilot/internal/course-error-deg&amp;lt;/property&amp;gt;&lt;br /&gt;
   &amp;lt;scale&amp;gt;2.0&amp;lt;/scale&amp;gt;&lt;br /&gt;
   &amp;lt;offset&amp;gt;&lt;br /&gt;
     &amp;lt;property&amp;gt;orientation/bank-angle-deg&amp;lt;/property&amp;gt;&lt;br /&gt;
     &amp;lt;scale&amp;gt;&lt;br /&gt;
       &amp;lt;property&amp;gt;some/property&lt;br /&gt;
       &amp;lt;min&amp;gt;-1.5&amp;lt;/min&amp;gt;&lt;br /&gt;
       &amp;lt;max&amp;gt;1.5&amp;lt;/max&amp;gt;&lt;br /&gt;
     &amp;lt;/scale&amp;gt;&lt;br /&gt;
   &amp;lt;/offset&amp;gt;&lt;br /&gt;
 &amp;lt;/reference&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== Conditional input values ====&lt;br /&gt;
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 &amp;lt;tt&amp;gt;&amp;lt;condition&amp;gt;&amp;lt;/tt&amp;gt; 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.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;reference&amp;gt;&lt;br /&gt;
   &amp;lt;condition&amp;gt;&lt;br /&gt;
     &amp;lt;property&amp;gt;/autopilot/coupled-to-gps&amp;lt;/property&amp;gt;&lt;br /&gt;
   &amp;lt;/condition&amp;gt;&lt;br /&gt;
   &amp;lt;property&amp;gt;instrumentation/gps/desired-track-deg&amp;lt;/property&amp;gt;&lt;br /&gt;
 &amp;lt;/reference&amp;gt;&lt;br /&gt;
 &amp;lt;reference&amp;gt;&lt;br /&gt;
   &amp;lt;condition&amp;gt;&lt;br /&gt;
     &amp;lt;property&amp;gt;/autopilot/coupled-to-nav2&amp;lt;/property&amp;gt;&lt;br /&gt;
   &amp;lt;/condition&amp;gt;&lt;br /&gt;
   &amp;lt;property&amp;gt;instrumentation/nav[1]/radials/selected-deg&amp;lt;/property&amp;gt;&lt;br /&gt;
 &amp;lt;/reference&amp;gt;&lt;br /&gt;
 &amp;lt;reference&amp;gt;instrumentation/nav[0]/radials/selected-deg&amp;lt;/reference&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note the unconditional last &amp;lt;tt&amp;gt;&amp;lt;reference&amp;lt;&amp;gt;&amp;lt;/tt&amp;gt; element which acts as an &amp;quot;if all others fail, use NAV1&amp;quot; anchor. If no input value return with a successful condition, the input value is undefined.&amp;lt;br /&amp;gt;&lt;br /&gt;
The &amp;lt;tt&amp;gt;&amp;lt;scale&amp;gt;&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;&amp;lt;offset&amp;gt;&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;&amp;lt;min&amp;gt;&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;&amp;lt;max&amp;gt;&amp;lt;/tt&amp;gt; elements of input values itself currently don't support input value lists.&lt;br /&gt;
&lt;br /&gt;
==== Expressions ====&lt;br /&gt;
Complex math or lookup tables may be represented using the [[Expression]] syntax. The expression has to be enclosed in &amp;lt;expression&amp;gt; tag.&lt;br /&gt;
&lt;br /&gt;
=== Output Values ===&lt;br /&gt;
After processing of a component, the resulting value passes a transformation stage where it can be clipped or normalized into a given period. Periodic values such as angular properties may be normalized into a given period by adding a &amp;lt;period&amp;gt; element, defining the lower and upper bounds of the period. Additionally, a maximun and a minimum value may be given which will guarantee that the output value will ever exceed a defined value. &lt;br /&gt;
&lt;br /&gt;
{{note|Both periodical normalization and clipping may be defined. If both are given, the value will be normalized first and the clipping will be applied to the normalized value.}}&lt;br /&gt;
&lt;br /&gt;
The following example shifts the computed value into the interval of [-180..180] thereafter being limited into the interval of [-30..30]. The following table contains some computed values and the resulting written value:&lt;br /&gt;
{| class=&amp;quot;prettytable&amp;quot;&lt;br /&gt;
!computed&lt;br /&gt;
!written&lt;br /&gt;
|-&lt;br /&gt;
|-&lt;br /&gt;
| -350&lt;br /&gt;
|10&lt;br /&gt;
|-&lt;br /&gt;
| -270&lt;br /&gt;
|30&lt;br /&gt;
|-&lt;br /&gt;
| -90&lt;br /&gt;
| -30&lt;br /&gt;
|-&lt;br /&gt;
| -29&lt;br /&gt;
| -29&lt;br /&gt;
|-&lt;br /&gt;
|29&lt;br /&gt;
|29&lt;br /&gt;
|-&lt;br /&gt;
|90&lt;br /&gt;
|30&lt;br /&gt;
|-&lt;br /&gt;
|350&lt;br /&gt;
| -10&lt;br /&gt;
|}&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;output&amp;gt;/some/property&amp;lt;/output&amp;gt;&lt;br /&gt;
 &amp;lt;period&amp;gt;&lt;br /&gt;
   &amp;lt;min&amp;gt;-180&amp;lt;/min&amp;gt;&lt;br /&gt;
   &amp;lt;max&amp;gt;180&amp;lt;/max&amp;gt;&lt;br /&gt;
 &amp;lt;/period&amp;gt;&lt;br /&gt;
 &amp;lt;min&amp;gt;-30&amp;lt;/min&amp;gt;&lt;br /&gt;
 &amp;lt;max&amp;gt;30&amp;lt;/max&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== logic ==&lt;br /&gt;
The logic controller provides a simple way of creating property values from the result of the condition expression in the &amp;lt;input&amp;gt; element. The condition expression is evaluated once per iteration and the result is written as a boolean value to the named output property or properties. An optional &amp;lt;inverted&amp;gt; element inverts the logic. The default is &amp;quot;not inverted&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Example: output = not( ( a is true ) or ( ( b greater than c ) and ( d is true ) )&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;logic&amp;gt;&lt;br /&gt;
   &amp;lt;inverted&amp;gt;true&amp;lt;/inverted&amp;gt;&lt;br /&gt;
   &amp;lt;input&amp;gt;&lt;br /&gt;
     &amp;lt;property&amp;gt;a&amp;lt;/property&amp;gt;&lt;br /&gt;
     &amp;lt;or&amp;gt;&lt;br /&gt;
       &amp;lt;greater-than&amp;gt;&lt;br /&gt;
         &amp;lt;property&amp;gt;b&amp;lt;/property&amp;gt;&lt;br /&gt;
         &amp;lt;property&amp;gt;c&amp;lt;/property&amp;gt;&lt;br /&gt;
       &amp;lt;greater-than&amp;gt;&lt;br /&gt;
       &amp;lt;property&amp;gt;d&amp;lt;/property&amp;gt;&lt;br /&gt;
     &amp;lt;/or&amp;gt;&lt;br /&gt;
   &amp;lt;/input&amp;gt;&lt;br /&gt;
   &amp;lt;output&amp;gt;output&amp;lt;/output&amp;gt;&lt;br /&gt;
 &amp;lt;/logic&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Flip Flop ==&lt;br /&gt;
A flip flop is a controller that has two stable states so it can be used as a one bit memory. Four types of flip flops are implemented: '''RS''', '''JK''', '''D''' and '''T'''. All use positive logic and operate on the raising edge of the clock signal if a clock is used.&lt;br /&gt;
All input lines, including the clock line, are encoded as condition constructs.&lt;br /&gt;
If negative logic for the input line is required, wrap the condition into a &amp;lt;not&amp;gt; tag to invert the logic.&lt;br /&gt;
&lt;br /&gt;
=== RS Flip Flop ===&lt;br /&gt;
This flip flop sets its output according to the set (S) or reset (R) input lines. If the set line is set, the output gets set. If the reset line is set, the output gets reset. If no line is set, the output stays unchanged. For the special case where set and reset lines are both set, two types of RS flip flops exist: for the RS flip flop (&amp;lt;type&amp;gt;RS&amp;lt;/type&amp;gt;), the reset line is dominant and the output is reset. Alternatively, a SR flip flop (&amp;lt;type&amp;gt;SR&amp;lt;/type&amp;gt;) has a dominant set line and the output gets set if set and reset line are set.&lt;br /&gt;
&lt;br /&gt;
Example: simple RS flip flop&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;flipflop&amp;gt;&lt;br /&gt;
   &amp;lt;type&amp;gt;RS&amp;lt;/type&amp;gt; &amp;lt;!-- or SR --&amp;gt;&lt;br /&gt;
   &amp;lt;S&amp;gt;&lt;br /&gt;
     &amp;lt;property&amp;gt;/myflipflop/set&amp;lt;/property&amp;gt;&lt;br /&gt;
   &amp;lt;/S&amp;gt;&lt;br /&gt;
   &amp;lt;R&amp;gt;&lt;br /&gt;
     &amp;lt;property&amp;gt;/myflipflop/reset&amp;lt;/property&amp;gt;&lt;br /&gt;
   &amp;lt;/R&amp;gt;&lt;br /&gt;
   &amp;lt;output&amp;gt;/myflipflop/output&amp;lt;/output&amp;gt;&lt;br /&gt;
 &amp;lt;/flipflop&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== JK Flip Flop ===&lt;br /&gt;
The JK flip flop is an extension of the RS flip flop. In addition to the set and reset lines of the RS flip flop it uses J, K and a clock input.&lt;br /&gt;
The J line serves as a clock dependent set input while the K line does the reset job. Optionally, a clock input may be provided. State changes do not occour immediately, but on the next raising edge of the clock signal. The state of J=K=true causes the output to toggle it's current state on the next raising edge of the clock signal.&lt;br /&gt;
If no clock signal is provided, the frame rate serves as the clock input.&lt;br /&gt;
&lt;br /&gt;
Example: simple JK flip flop with negative edge clock&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;flipflop&amp;gt;&lt;br /&gt;
   &amp;lt;type&amp;gt;JK&amp;lt;/type&amp;gt;&lt;br /&gt;
   &amp;lt;J&amp;gt;&lt;br /&gt;
     &amp;lt;property&amp;gt;/myflipflop/set&amp;lt;/property&amp;gt;&lt;br /&gt;
   &amp;lt;/J&amp;gt;&lt;br /&gt;
   &amp;lt;K&amp;gt;&lt;br /&gt;
     &amp;lt;property&amp;gt;/myflipflop/reset&amp;lt;/property&amp;gt;&lt;br /&gt;
   &amp;lt;/K&amp;gt;&lt;br /&gt;
   &amp;lt;clock&amp;gt;&lt;br /&gt;
     &amp;lt;not&amp;gt;&lt;br /&gt;
       &amp;lt;property&amp;gt;/myflipflop/clock&amp;lt;/property&amp;gt;&lt;br /&gt;
     &amp;lt;/not&amp;gt;&lt;br /&gt;
   &amp;lt;/clock&amp;gt;&lt;br /&gt;
   &amp;lt;output&amp;gt;/myflipflop/output&amp;lt;/output&amp;gt;&lt;br /&gt;
 &amp;lt;/flipflop&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== D Flip Flop ===&lt;br /&gt;
The D flip flop transfers the state of the input signal '''D''' to the output line at the next raising edge of the clock signal, which is mandatory for this flip flop.&lt;br /&gt;
&lt;br /&gt;
Example: simple D flip flop with inverted output&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;flipflop&amp;gt;&lt;br /&gt;
   &amp;lt;type&amp;gt;D&amp;lt;/type&amp;gt;&lt;br /&gt;
   &amp;lt;D&amp;gt;&lt;br /&gt;
     &amp;lt;property&amp;gt;/myflipflop/data&amp;lt;/property&amp;gt;&lt;br /&gt;
   &amp;lt;/D&amp;gt;&lt;br /&gt;
   &amp;lt;clock&amp;gt;&lt;br /&gt;
     &amp;lt;property&amp;gt;/myflipflop/clock&amp;lt;/property&amp;gt;&lt;br /&gt;
   &amp;lt;/clock&amp;gt;&lt;br /&gt;
   &amp;lt;output&amp;gt;/myflipflop/output&amp;lt;/output&amp;gt;&lt;br /&gt;
   &amp;lt;inverted type=&amp;quot;bool&amp;quot;&amp;gt;true&amp;lt;/inverted&amp;gt;&lt;br /&gt;
 &amp;lt;/flipflop&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== T Flip Flop ===&lt;br /&gt;
The T flip flop toggles the state of the output signal at the next raising edge of the clock signal, which is mandatory for this flip flop.&lt;br /&gt;
&lt;br /&gt;
Example: simple T flip flop&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;flipflop&amp;gt;&lt;br /&gt;
   &amp;lt;type&amp;gt;T&amp;lt;/type&amp;gt;&lt;br /&gt;
   &amp;lt;clock&amp;gt;&lt;br /&gt;
     &amp;lt;property&amp;gt;/myflipflop/clock&amp;lt;/property&amp;gt;&lt;br /&gt;
   &amp;lt;/clock&amp;gt;&lt;br /&gt;
   &amp;lt;output&amp;gt;/myflipflop/output&amp;lt;/output&amp;gt;&lt;br /&gt;
 &amp;lt;/flipflop&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Monostable ===&lt;br /&gt;
A monostable flip flop has only one stable state which will be reentered after a well defined time. The stable state in current implementation is the output set 'false' or 0. The Monostable is an extension of the JK flip flop. Additionally to the input values defined there, an InputValue for the definition of the pulse time is mandatory. &lt;br /&gt;
&lt;br /&gt;
The moment the time for the astable state starts counting depends on the input used to set the output. If the output is set from the SET input of the RS flipflop, the output is kept true for the defined time ''after'' the SET input enters it's false state. The total time the output is true equals the time, the SET input is true plus the time defined in the &amp;lt;time&amp;gt; element.&lt;br /&gt;
If the output is set from the J and clock inputs of the JK flipflop, the timer starts on the raising edge of the clock input. The output signal will be true for exactly the time defined in the &amp;lt;time&amp;gt; element. &lt;br /&gt;
&lt;br /&gt;
{{note|The optional &amp;lt;R&amp;gt; and &amp;lt;K&amp;gt; inputs may be used to reset the output before the internal timer expired. This will also reset the timer to zero, so no additional event will be triggered after the defined timer interval.}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;flipflop&amp;gt;&lt;br /&gt;
   &amp;lt;name&amp;gt;Test mf&amp;lt;/name&amp;gt;&lt;br /&gt;
   &amp;lt;type&amp;gt;monostable&amp;lt;/type&amp;gt;&lt;br /&gt;
   &amp;lt;time&amp;gt;&lt;br /&gt;
     &amp;lt;property&amp;gt;/myflipflop/pulsetime-sec&amp;lt;/property&amp;gt;&lt;br /&gt;
     &amp;lt;value&amp;gt;10&amp;lt;/value&amp;gt;&lt;br /&gt;
   &amp;lt;/time&amp;gt;&lt;br /&gt;
   &amp;lt;S&amp;gt;&amp;lt;property&amp;gt;/myflipflop/s&amp;lt;/property&amp;gt;&amp;lt;/S&amp;gt;&lt;br /&gt;
   &amp;lt;J&amp;gt;&amp;lt;property&amp;gt;/myflipflop/j&amp;lt;/property&amp;gt;&amp;lt;/J&amp;gt;&lt;br /&gt;
   &amp;lt;clock&amp;gt;&amp;lt;property&amp;gt;/myflipflop/clock&amp;lt;/property&amp;gt;&amp;lt;/clock&amp;gt;&lt;br /&gt;
   &amp;lt;output&amp;gt;/myflipflop/output&amp;lt;/output&amp;gt;&lt;br /&gt;
  &amp;lt;/flipflop&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The following example shows how a monostable can be used to enable a certain property (/myflipflop/output) if another property (/myflipflop/s) is true for at least the specified amount of time:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;flipflop&amp;gt;&lt;br /&gt;
    &amp;lt;name&amp;gt;Test mf&amp;lt;/name&amp;gt;&lt;br /&gt;
    &amp;lt;type&amp;gt;monostable&amp;lt;/type&amp;gt;&lt;br /&gt;
    &amp;lt;inverted type=&amp;quot;bool&amp;quot;&amp;gt;true&amp;lt;/inverted&amp;gt;&lt;br /&gt;
    &amp;lt;S&amp;gt;&lt;br /&gt;
        &amp;lt;not&amp;gt;&lt;br /&gt;
            &amp;lt;property&amp;gt;/myflipflop/s&amp;lt;/property&amp;gt;&lt;br /&gt;
        &amp;lt;/not&amp;gt;&lt;br /&gt;
    &amp;lt;/S&amp;gt;&lt;br /&gt;
    &amp;lt;time&amp;gt;&lt;br /&gt;
        &amp;lt;value&amp;gt;10.0&amp;lt;/value&amp;gt;&lt;br /&gt;
    &amp;lt;/time&amp;gt;&lt;br /&gt;
    &amp;lt;output&amp;gt;&lt;br /&gt;
        &amp;lt;property&amp;gt;/myflipflop/output&amp;lt;/property&amp;gt;&lt;br /&gt;
    &amp;lt;/output&amp;gt;&lt;br /&gt;
&amp;lt;/flipflop&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this example the monostable is inverted, which means the stable state is true instead of false. The key idea here is to keep the monostable in its unstable state (false) by keeping the set line true, which is the case when /myflipflop/s is false. Then, when /myflipflop/s becomes true the set line becomes false, which causes the timer to start. When the timer expires (in this case 10 seconds) the monostable will enter its stable state (true). At any time when the set line becomes true (when /myflipflop/s becomes false) the monostable will immediately enter its unstable state (false) again, resulting in /myflipflop/output to become false immediately.&lt;br /&gt;
&lt;br /&gt;
== filter ==&lt;br /&gt;
&lt;br /&gt;
=== Pure Gain &amp;lt;gain&amp;gt; ===&lt;br /&gt;
A gain filter multiplies the &amp;lt;input&amp;gt; value by a given factor or gain &amp;lt;gain&amp;gt; and returns the output to &amp;lt;output&amp;gt;. More than one &amp;lt;gain&amp;gt; element formatted as in [[Autopilot Configuration Reference#Input Values|Input Values]] may be present.  Within a &amp;lt;condition&amp;gt; evaluating as true the first &amp;lt;gain&amp;gt; will define the used gain.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;filter&amp;gt;&lt;br /&gt;
   &amp;lt;type&amp;gt;gain&amp;lt;/type&amp;gt;&lt;br /&gt;
   &amp;lt;gain&amp;gt;6.28&amp;lt;/gain&amp;gt;&lt;br /&gt;
   &amp;lt;input&amp;gt;radius&amp;lt;/input&amp;gt;&lt;br /&gt;
   &amp;lt;output&amp;gt;circumfence&amp;lt;/output&amp;gt;&lt;br /&gt;
 &amp;lt;/filter&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== First Order Low Pass Filter &amp;lt;exponential&amp;gt; ===&lt;br /&gt;
The exponential filter is a typical [http://en.wikipedia.org/wiki/Low-pass_filter low pass filter]. The magic euler number and the associated mathematical funtion exp() plays a major role here. As the name implies, lower frequencies can pass this filter while higher frequencies are cut. The frequency where only half of the input signal reaches the output is called cutoff frequency. This cutoff frequency is defined by the parameter &amp;lt;filter-time&amp;gt; and resolves as cutoff-frequency = 1/(2*pi*cutoff-frequency).&lt;br /&gt;
&lt;br /&gt;
Example: a 1Hz first order low pass filter &lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;filter&amp;gt;&lt;br /&gt;
   &amp;lt;type&amp;gt;exponential&amp;lt;/type&amp;gt;&lt;br /&gt;
   &amp;lt;filter-time&amp;gt;0.16&amp;lt;/filter-time&amp;gt;&lt;br /&gt;
   &amp;lt;input&amp;gt;/some/input&amp;lt;/input&amp;gt;&lt;br /&gt;
   &amp;lt;output&amp;gt;/some/output/&amp;lt;/output&amp;gt;&lt;br /&gt;
 &amp;lt;/filter&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Second Order Low Pass Filter &amp;lt;double-exponential&amp;gt; ===&lt;br /&gt;
The double exponential filter is a low pass filter like the exponential filter with a steeper slope of the filter diagram. It acts basically like two chained exponential filters and it is some times called second order filter. &lt;br /&gt;
&lt;br /&gt;
The configuration is the same for exponential and double-exponential filters, just the type entry differs.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;filter&amp;gt;&lt;br /&gt;
   &amp;lt;type&amp;gt;double-exponential&amp;lt;/type&amp;gt;&lt;br /&gt;
   &amp;lt;filter-time&amp;gt;0.16&amp;lt;/filter-time&amp;gt;&lt;br /&gt;
   &amp;lt;input&amp;gt;/some/input&amp;lt;/input&amp;gt;&lt;br /&gt;
   &amp;lt;output&amp;gt;/some/output/&amp;lt;output&amp;gt;&lt;br /&gt;
 &amp;lt;/filter&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Moving Average Filter &amp;lt;moving-average&amp;gt; ===&lt;br /&gt;
Calculates average of specified number of values.&lt;br /&gt;
&lt;br /&gt;
Currently the average length can only be given as number of samples and not time.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;filter&amp;gt;&lt;br /&gt;
  &amp;lt;type&amp;gt;moving-average&amp;lt;/type&amp;gt;&lt;br /&gt;
  &amp;lt;samples&amp;gt;120&amp;lt;/samples&amp;gt;&lt;br /&gt;
  &amp;lt;input&amp;gt;/some/input&amp;lt;/input&amp;gt;&lt;br /&gt;
  &amp;lt;output&amp;gt;/some/output&amp;lt;/output&amp;gt;&lt;br /&gt;
 &amp;lt;/filter&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Rate Limit Filter &amp;lt;noise-spike&amp;gt; ===&lt;br /&gt;
A better name for a noise spike filter would probably have been &amp;quot;rate limit filter&amp;quot;. This is exactly what it does: limit the rate of change of the output value. The relevant configuration element is &amp;lt;max-rate-of-change&amp;gt; setting the maximum rate of change of the output property per second.&lt;br /&gt;
&lt;br /&gt;
Example: A transition from 0 to 4 at the input property results in a linear increase of the output property over 8 seconds from 0 to 4 at a rate of 0.5/sec.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;filter&amp;gt;&lt;br /&gt;
   &amp;lt;type&amp;gt;noise-spike&amp;lt;/type&amp;gt;&lt;br /&gt;
   &amp;lt;max-rate-of-change&amp;gt;0.5&amp;lt;/max-rate-of-change&amp;gt;&lt;br /&gt;
   &amp;lt;input&amp;gt;/some/input&amp;lt;/input&amp;gt;&lt;br /&gt;
   &amp;lt;output&amp;gt;/some/output&amp;lt;/output&amp;gt;&lt;br /&gt;
 &amp;lt;/filter&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Reciprocal Filter &amp;lt;reciprocal&amp;gt; ===&lt;br /&gt;
Compute the reciprocal (1/x) value of the input property. If x is zero, no computation is performed. The optional &amp;lt;gain&amp;gt; element may be used to scale the value. Output computes as gain divided by input.&lt;br /&gt;
&lt;br /&gt;
Example: compute the flight time per pound of burned fuel from the fuel flow&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;filter&amp;gt;&lt;br /&gt;
   &amp;lt;type&amp;gt;reciprocal&amp;lt;/type&amp;gt;&lt;br /&gt;
   &amp;lt;gain&amp;gt;1.0&amp;lt;/gain&amp;gt;&lt;br /&gt;
   &amp;lt;input&amp;gt;/engines/engine[0]/fuel-flow-pph&amp;lt;/input&amp;gt;&lt;br /&gt;
   &amp;lt;output&amp;gt;/engines/engine[0]/fuel-flow-hpp&amp;lt;/output&amp;gt;&lt;br /&gt;
 &amp;lt;/filter&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Derivative Filter &amp;lt;derivative&amp;gt; ===&lt;br /&gt;
Compute first time derivative of the input property, that is change per unit of time. Time is measured in seconds. A &amp;lt;filter-time&amp;gt; acts as gain and must be given because it has default 0.&lt;br /&gt;
&lt;br /&gt;
Example: compute derivative of static port pressure&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;filter&amp;gt;&lt;br /&gt;
  &amp;lt;type&amp;gt;derivative&amp;lt;/type&amp;gt;&lt;br /&gt;
  &amp;lt;input&amp;gt;systems/static[0]/pressure-inhg&amp;lt;/input&amp;gt;&lt;br /&gt;
  &amp;lt;output&amp;gt;autopilot/internal/pressure-rate&amp;lt;/output&amp;gt;&lt;br /&gt;
  &amp;lt;filter-time&amp;gt;1.0&amp;lt;/filter-time&amp;gt;&lt;br /&gt;
 &amp;lt;/filter&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== PID Controller &amp;lt;pid-controller&amp;gt; ==&lt;br /&gt;
The [http://en.wikipedia.org/wiki/PID_controller PID controller] is the swiss army knife of automation and this implementation is suitable for most situations. It has a builtin anti-windup logic, and usage of &amp;lt;max&amp;gt; and &amp;lt;min&amp;gt; elements for clamping the output is mandatory. The most important thing to know is that this controller 'does not' compute absolute output values but an offset from the current value of the output property. This can lead to unexpected behavior if the current value of the output property is unknown when the controller is enabled. This behavior is different to that of the pi-simple-controller.&lt;br /&gt;
The xml element creating a pid controller is &amp;lt;tt&amp;gt;&amp;lt;pid-controller&amp;gt;&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Legal elements are:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;prettytable&amp;quot;&lt;br /&gt;
!Kp&lt;br /&gt;
|the overall gain for the proportional, integral and derivative part&lt;br /&gt;
|-&lt;br /&gt;
!Ti&lt;br /&gt;
|integrator time&lt;br /&gt;
|-&lt;br /&gt;
!Td&lt;br /&gt;
|derivator time&lt;br /&gt;
|-&lt;br /&gt;
!Ts&lt;br /&gt;
|sampling interval (default: sample at frame rate)&lt;br /&gt;
|-&lt;br /&gt;
!alpha&lt;br /&gt;
|scaling factor for Td (defaults to 0.1)&lt;br /&gt;
|-&lt;br /&gt;
!beta&lt;br /&gt;
|reference weighing factor for the proportional component (defaults to 1.0)&lt;br /&gt;
|-&lt;br /&gt;
!gamma&lt;br /&gt;
|reference weighing factor for the derivate component (defaults to 0.0)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== PI Controller &amp;lt;pi-simple-controller&amp;gt; ==&lt;br /&gt;
This controller implements a PI controller. Other than the PID controller, it computes absolute output values, regardless of the value of the output property. It can by configured as an I-only, P-only or PI-controller. It has anti windup logic if &amp;lt;min&amp;gt; and &amp;lt;max&amp;gt; elements are present.&lt;br /&gt;
The xml element creating a PI controller is &amp;lt;tt&amp;gt;&amp;lt;pi-simple-controller&amp;gt;&amp;lt;/tt&amp;gt;&lt;br /&gt;
Legal elements are:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;prettytable&amp;quot;&lt;br /&gt;
!Kp&lt;br /&gt;
|gain of the proportional component&lt;br /&gt;
|-&lt;br /&gt;
!Ki&lt;br /&gt;
|gain of the integrator component&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Predictor &amp;lt;predict-simple&amp;gt; ==&lt;br /&gt;
Estimates the future value for a given property based on its current (or averaged) rate of change.&lt;br /&gt;
&lt;br /&gt;
Legal elements are:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;prettytable&amp;quot;&lt;br /&gt;
!seconds&lt;br /&gt;
|the time to be estimated ahead&lt;br /&gt;
|-&lt;br /&gt;
!filter-gain&lt;br /&gt;
|Smoothing factor (0.0-1.0, 1.0=no smoothing)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Example: compute estimated speed 5 seconds ahead&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;predict-simple&amp;gt;&lt;br /&gt;
   &amp;lt;name&amp;gt;predicted air speed 5 seconds ahead&amp;lt;/name&amp;gt;&lt;br /&gt;
   &amp;lt;debug&amp;gt;false&amp;lt;/debug&amp;gt;&lt;br /&gt;
   &amp;lt;input&amp;gt;velocities/airspeed-kt&amp;lt;/input&amp;gt;&lt;br /&gt;
   &amp;lt;output&amp;gt;autopilot/internal/airspeed-5-sec-ahead&amp;lt;/output&amp;gt;&lt;br /&gt;
   &amp;lt;seconds&amp;gt;5.0&amp;lt;/seconds&amp;gt;&lt;br /&gt;
   &amp;lt;filter-gain&amp;gt;0.1&amp;lt;/filter-gain&amp;gt;&lt;br /&gt;
 &amp;lt;/predict-simple&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Proposed extensions ==&lt;br /&gt;
This sections contains new features for the autopilot to be implemented. Nobody knows if and when this will happen. Consider this as a collection of ideas as a base for discussion on the mailing list, the forum or IRC.&lt;br /&gt;
&lt;br /&gt;
Also see: [[State machines]].&lt;br /&gt;
&lt;br /&gt;
[[Category:Aircraft enhancement]]&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=77083</id>
		<title>Runway Awareness and Advisory System</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=77083"/>
		<updated>2014-10-10T10:38:34Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{infobox subsystem&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
|image =.png&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
|name = Runway Awareness and Advisory System&lt;br /&gt;
|started = 08/2014 &lt;br /&gt;
|description = System to give advisories about runways&lt;br /&gt;
|status = Under active development as of 08/2014&lt;br /&gt;
|developers = onox&lt;br /&gt;
|subforum = http://forum.flightgear.org/viewtopic.php?f=66&amp;amp;t=21266&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Features ==&lt;br /&gt;
&lt;br /&gt;
The Runway Advisory and Awareness System can give a number of advisories:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Feature !! RAAS&lt;br /&gt;
|-&lt;br /&gt;
| On runway and alignment &amp;lt; 20 degrees || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| On short runway, announcing remaining distance || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| On runway (reminder) || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (on ground) when groundspeed &amp;lt; 40 knots || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (airborne) when distance &amp;lt; 3 nm, alignment &amp;lt; 20 degrees, AFE is 300 - 750 ft || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (airborne), announcing available distance || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Distance remaining (during landing) when AGL &amp;lt; 100 feet and groundspeed &amp;gt; 40 knots || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Distance remaining after rejected takeoff, past 50 % of runway and 7 knots below maximum groundspeed || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Runway end when distance remaininig &amp;lt; 100 feet or 30 meters and groundspeed &amp;lt; 40 knots || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Taxiway takeoff when groundspeed &amp;gt; 40 knots while not on runway || {{Not done}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=59ymnKUi49A#t=117&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=0jkRhIMZAZo#t=171&lt;br /&gt;
&lt;br /&gt;
== Aircraft ==&lt;br /&gt;
&lt;br /&gt;
Currently RAAS is only used in the [https://github.com/dogsaysmoo/747-8i/ 747-8i].&lt;br /&gt;
&lt;br /&gt;
{{tip|Ask the developer of your favorite aircraft if you want it to support RAAS.}}&lt;br /&gt;
&lt;br /&gt;
== TODO ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| Use *.groundnet.xml to detect when the aircraft is near a holding point to more accurately emit &amp;quot;approaching-runway&amp;quot; signal || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Allow remaining-distance to be emitted while aircraft is not on ground || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Allow to choose between 450 - 550 ft or 350 - 450 ft suppression of approaching-runway (in air) || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Require climb rate to be &amp;lt; 450 ft/min for remaining-distance || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Require the presence of a mk-viii (GPWS) module || {{Not done}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Signals ==&lt;br /&gt;
&lt;br /&gt;
In order to give these advisories, callbacks for a number of signals can be registered to two announcers. Depending on the current mode of each announcer they will emit certain signals:&lt;br /&gt;
&lt;br /&gt;
=== Takeoff announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| taxi-and-takeoff || approaching-runway, on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| approach || approaching-runway, approaching-short-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Landing announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || remaining-distance, vacated-runway&lt;br /&gt;
|-&lt;br /&gt;
| landing || remaining-distance, landed-runway, vacated-runway, landed-outside-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Installation ==&lt;br /&gt;
&lt;br /&gt;
In case logger.nas and runway_announcer.nas have not been added to FlightGear's fgdata project yet, add the following to the beginning of the &amp;lt;nasal&amp;gt; element in your aircraft's -set.xml file:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;logger&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/logger.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/logger&amp;gt;&lt;br /&gt;
&amp;lt;runway&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway_announcer.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/runway&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the following to the &amp;lt;nasal&amp;gt; element below the previous two:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the file runway.nas to your aircraft's Nasal folder. This file is aircraft specific and needs to be constructed using the steps below.&lt;br /&gt;
&lt;br /&gt;
== Nasal/runway.nas ==&lt;br /&gt;
&lt;br /&gt;
The following example listens to /gear/on-ground and overrides a number of properties of the takeoff_config object so that it can be used for large airliners.&lt;br /&gt;
&lt;br /&gt;
=== Step 1 of 3: Functions ===&lt;br /&gt;
&lt;br /&gt;
First, create a number of functions to format and print messages:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
# Copyright (C) 2014  onox&lt;br /&gt;
#&lt;br /&gt;
# This program is free software: you can redistribute it and/or modify&lt;br /&gt;
# it under the terms of the GNU General Public License as published by&lt;br /&gt;
# the Free Software Foundation; either version 2 of the License, or&lt;br /&gt;
# (at your option) any later version.&lt;br /&gt;
#&lt;br /&gt;
# This program is distributed in the hope that it will be useful,&lt;br /&gt;
# but WITHOUT ANY WARRANTY; without even the implied warranty of&lt;br /&gt;
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the&lt;br /&gt;
# GNU General Public License for more details.&lt;br /&gt;
#&lt;br /&gt;
# You should have received a copy of the GNU General Public License&lt;br /&gt;
# along with this program.  If not, see &amp;lt;http://www.gnu.org/licenses/&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
var copilot_say = func (message) {&lt;br /&gt;
    setprop(&amp;quot;/sim/messages/copilot&amp;quot;, message);&lt;br /&gt;
    logger.info(sprintf(&amp;quot;Announcing '%s'&amp;quot;, message));&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var on_short_runway_format = func {&lt;br /&gt;
    var distance = getprop(&amp;quot;/sim/runway-announcer/short-runway-distance&amp;quot;);&lt;br /&gt;
    return sprintf(&amp;quot;On runway %%s, %d %s remaining&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var approaching_short_runway_format = func {&lt;br /&gt;
    var distance = takeoff_announcer.get_short_runway_distance();&lt;br /&gt;
    return sprintf(&amp;quot;Approaching runway %%s, %d %s available&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var remaining_distance_format = func {&lt;br /&gt;
    return sprintf(&amp;quot;%%d %s remaining&amp;quot;, landing_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{tip|You might want to replace copilot_say().}}&lt;br /&gt;
&lt;br /&gt;
=== Step 2 of 3: Announcers ===&lt;br /&gt;
&lt;br /&gt;
Second, create configuration objects, override some of their parameters, create the announcers, and then connect the various signals to callbacks:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var takeoff_config = { parents: [runway.TakeoffRunwayAnnounceConfig] };&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
takeoff_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
# Will cause the announcer to emit the &amp;quot;on-runway&amp;quot; signal if the&lt;br /&gt;
# aircraft is at most 15 meters from the center line of the runway&lt;br /&gt;
takeoff_config.distance_center_line_m = 15;&lt;br /&gt;
&lt;br /&gt;
# Let the announcer emit the &amp;quot;approaching-runway&amp;quot; signal if the&lt;br /&gt;
# nose of the aircraft comes within 120 meters of the runway&lt;br /&gt;
takeoff_config.distance_edge_max_m = 150;&lt;br /&gt;
&lt;br /&gt;
var landing_config = { parents: [runway.LandingRunwayAnnounceConfig] };&lt;br /&gt;
landing_config.distance_center_nose_m = 30;&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
landing_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
# Create announcers&lt;br /&gt;
var takeoff_announcer = runway.TakeoffRunwayAnnounceClass.new(takeoff_config);&lt;br /&gt;
var landing_announcer = runway.LandingRunwayAnnounceClass.new(landing_config);&lt;br /&gt;
&lt;br /&gt;
var stop_announcer    = runway.make_stop_announcer_func(takeoff_announcer, landing_announcer);&lt;br /&gt;
var switch_to_takeoff = runway.make_switch_to_takeoff_func(takeoff_announcer, landing_announcer);&lt;br /&gt;
&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;On runway %s&amp;quot;, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, on_short_runway_format, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Approaching runway %s&amp;quot;));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, approaching_short_runway_format));&lt;br /&gt;
&lt;br /&gt;
landing_announcer.connect(&amp;quot;remaining-distance&amp;quot;, runway.make_betty_cb(copilot_say, remaining_distance_format));&lt;br /&gt;
landing_announcer.connect(&amp;quot;vacated-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Vacated runway %s&amp;quot;, stop_announcer));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Touchdown on runway %s&amp;quot;));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-outside-runway&amp;quot;, runway.make_betty_cb(nil, nil, stop_announcer));&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Step 3 of 3: Listeners ===&lt;br /&gt;
&lt;br /&gt;
Finally, set up a listener to detect when the aircraft is on the ground and when it is airborne:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
# Depending on whether the aircraft is on the ground or not, it will start, stop, or change the modes of the announcers&lt;br /&gt;
var set_on_ground = runway.make_set_ground_func(takeoff_announcer, landing_announcer);&lt;br /&gt;
&lt;br /&gt;
var init_announcers = func {&lt;br /&gt;
    setlistener(&amp;quot;/gear/on-ground&amp;quot;, func (node) {&lt;br /&gt;
        set_on_ground(node.getBoolValue());&lt;br /&gt;
    }, startup=1, runtime=0);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
setlistener(&amp;quot;/sim/signals/fdm-initialized&amp;quot;, func {&lt;br /&gt;
    var timer = maketimer(5.0, func init_announcers());&lt;br /&gt;
    timer.singleShot = 1;&lt;br /&gt;
    timer.start();&lt;br /&gt;
});&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Note|In this example the /gear/on-ground property is used to detect whether the aircraft is on the ground or in the air. Make sure to use a &amp;lt;logic&amp;gt; element in a &amp;lt;autopilot&amp;gt; XML file to set this to true or false depending on your gears' wow values.}}&lt;br /&gt;
&lt;br /&gt;
{{Note|It is your responsibility to start and stop the announcers and to set the correct modes. Therefore it is necessary to connect to signals like landed-outside-runway and vacated-runway, even if they appear to be useless for your specific aircraft. The example of runway.nas above already does this for you.}}&lt;br /&gt;
&lt;br /&gt;
== Configuring the announcers ==&lt;br /&gt;
&lt;br /&gt;
The configuration object takeoff_config has a number of properties with default values. These properties can be modified if you want to change when certain signals are emitted. For example, in the example of runway.nas above, distance_center_line_m and distance_edge_max_m where overridden for large airliners. The defaults are:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
diff_runway_heading_deg: 20,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# get an announcement that the aircraft is on the runway for takeoff&lt;br /&gt;
# or approaching while airborne.&lt;br /&gt;
&lt;br /&gt;
diff_approach_heading_deg: 40,&lt;br /&gt;
# Maximum angle at which the aircraft should approach the runway.&lt;br /&gt;
# Must be higher than 0 and lower than 90.&lt;br /&gt;
&lt;br /&gt;
distance_center_line_m: 10,&lt;br /&gt;
# The distance in meters from the center line of the runway&lt;br /&gt;
&lt;br /&gt;
distance_edge_min_m: 20,&lt;br /&gt;
distance_edge_max_m: 80,&lt;br /&gt;
# Minimum and maximum distance in meters from the edge of the runway&lt;br /&gt;
# for announcing approaches.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_takeoff_m: 3000,&lt;br /&gt;
# Minimum distance in meters required for a normal takeoff. If&lt;br /&gt;
# remaining distance when entering the runway is less than the distance&lt;br /&gt;
# required for a normal takeoff, then the on-short-runway instead of&lt;br /&gt;
# on-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_landing_m: 2000,&lt;br /&gt;
# Minimum distance in meters required for a normal landing. If&lt;br /&gt;
# runway length when approaching the runway is less than the distance&lt;br /&gt;
# required for a normal landing, then the approaching-short-runway&lt;br /&gt;
# instead of approaching-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance of short runways. Can&lt;br /&gt;
# be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
groundspeed_max_kt: 40,&lt;br /&gt;
# Maximum groundspeed in knots for approaching runway callouts&lt;br /&gt;
&lt;br /&gt;
approach_afe_min_ft: 300,&lt;br /&gt;
approach_afe_max_ft: 750,&lt;br /&gt;
# Minimum and maximum altitude Above Field Elevation in feet. Used to&lt;br /&gt;
# decide whether to announce that the aircraft is approaching a runway.&lt;br /&gt;
&lt;br /&gt;
approach_distance_max_nm: 3.0,&lt;br /&gt;
# Maximum distance in nautical miles of the aircraft to the&lt;br /&gt;
# approaching runway&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The same applies to the configuration object landing_config:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
distances_meter: [100,  300,  600,  900, 1200, 1500],&lt;br /&gt;
&lt;br /&gt;
distances_feet:  [500, 1000, 2000, 3000, 4000, 5000],&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance. Can be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;&lt;br /&gt;
&lt;br /&gt;
distance_center_nose_m: 0,&lt;br /&gt;
# Distance from the center to the nose in meters&lt;br /&gt;
&lt;br /&gt;
diff_runway_heading_deg: 20,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# detect the correct runway on which the aircraft is landing.&lt;br /&gt;
&lt;br /&gt;
groundspeed_min_kt: 40,&lt;br /&gt;
# Minimum groundspeed in knots for remaining distance callouts&lt;br /&gt;
&lt;br /&gt;
agl_max_ft: 100,&lt;br /&gt;
# Maximum AGL in feet for remaining distance callouts&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=77082</id>
		<title>Runway Awareness and Advisory System</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=77082"/>
		<updated>2014-10-10T10:35:01Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{infobox subsystem&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
|image =.png&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
|name = Runway Awareness and Advisory System&lt;br /&gt;
|started = 08/2014 &lt;br /&gt;
|description = System to give advisories about runways&lt;br /&gt;
|status = Under active development as of 08/2014&lt;br /&gt;
|developers = onox&lt;br /&gt;
|subforum = http://forum.flightgear.org/viewtopic.php?f=66&amp;amp;t=21266&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Features ==&lt;br /&gt;
&lt;br /&gt;
The Runway Advisory and Awareness System can give a number of advisories:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Feature !! RAAS&lt;br /&gt;
|-&lt;br /&gt;
| On runway and alignment &amp;lt; 20 degrees || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| On short runway, announcing remaining distance || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| On runway (reminder) || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (on ground) when groundspeed &amp;lt; 40 knots || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (airborne) when distance &amp;lt; 3 nm, alignment &amp;lt; 20 degrees, AFE is 300 - 750 ft || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (airborne), announcing available distance || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Distance remaining (during landing) when AGL &amp;lt; 100 feet and groundspeed &amp;gt; 40 knots || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Distance remaining after rejected takeoff, past 50 % of runway and 7 knots below maximum groundspeed || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Runway end when distance remaininig &amp;lt; 100 feet or 30 meters and groundspeed &amp;lt; 40 knots || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Taxiway takeoff when groundspeed &amp;gt; 40 knots while not on runway || {{Not done}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=59ymnKUi49A#t=117&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=0jkRhIMZAZo#t=171&lt;br /&gt;
&lt;br /&gt;
== Aircraft ==&lt;br /&gt;
&lt;br /&gt;
Currently RAAS is only used in the [https://github.com/dogsaysmoo/747-8i/ 747-8i].&lt;br /&gt;
&lt;br /&gt;
{{tip|Ask the developer of your favorite aircraft if you want it to support RAAS.}}&lt;br /&gt;
&lt;br /&gt;
== TODO ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| Use *.groundnet.xml to detect when the aircraft is near a holding point to more accurately emit &amp;quot;approaching-runway&amp;quot; signal || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Allow remaining-distance to be emitted while aircraft is not on ground || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Allow to choose between 450 - 550 ft or 350 - 450 ft suppression of approaching-runway (in air) || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Require climb rate to be &amp;lt; 450 ft/min for remaining-distance || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Require the presence of a mk-viii (GPWS) module || {{Not done}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Signals ==&lt;br /&gt;
&lt;br /&gt;
In order to give these advisories, callbacks for a number of signals can be registered to two announcers. Depending on the current mode of each announcer they will emit certain signals:&lt;br /&gt;
&lt;br /&gt;
=== Takeoff announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| taxi-and-takeoff || approaching-runway, on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| approach || approaching-runway, approaching-short-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Landing announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || remaining-distance, vacated-runway&lt;br /&gt;
|-&lt;br /&gt;
| landing || remaining-distance, landed-runway, vacated-runway, landed-outside-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Installation ==&lt;br /&gt;
&lt;br /&gt;
In case logger.nas and runway_announcer.nas have not been added to FlightGear's fgdata project yet, add the following to the beginning of the &amp;lt;nasal&amp;gt; element in your aircraft's -set.xml file:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;logger&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/logger.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/logger&amp;gt;&lt;br /&gt;
&amp;lt;runway&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway_announcer.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/runway&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the following to the &amp;lt;nasal&amp;gt; element below the previous two:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the file runway.nas to your aircraft's Nasal folder.&lt;br /&gt;
&lt;br /&gt;
== Nasal/runway.nas ==&lt;br /&gt;
&lt;br /&gt;
The following example listens to /gear/on-ground and overrides a number of properties of the takeoff_config object so that it can be used for large airliners.&lt;br /&gt;
&lt;br /&gt;
=== Step 1 of 3: Functions ===&lt;br /&gt;
&lt;br /&gt;
First, create a number of functions to format and print messages:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
# Copyright (C) 2014  onox&lt;br /&gt;
#&lt;br /&gt;
# This program is free software: you can redistribute it and/or modify&lt;br /&gt;
# it under the terms of the GNU General Public License as published by&lt;br /&gt;
# the Free Software Foundation; either version 2 of the License, or&lt;br /&gt;
# (at your option) any later version.&lt;br /&gt;
#&lt;br /&gt;
# This program is distributed in the hope that it will be useful,&lt;br /&gt;
# but WITHOUT ANY WARRANTY; without even the implied warranty of&lt;br /&gt;
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the&lt;br /&gt;
# GNU General Public License for more details.&lt;br /&gt;
#&lt;br /&gt;
# You should have received a copy of the GNU General Public License&lt;br /&gt;
# along with this program.  If not, see &amp;lt;http://www.gnu.org/licenses/&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
var copilot_say = func (message) {&lt;br /&gt;
    setprop(&amp;quot;/sim/messages/copilot&amp;quot;, message);&lt;br /&gt;
    logger.info(sprintf(&amp;quot;Announcing '%s'&amp;quot;, message));&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var on_short_runway_format = func {&lt;br /&gt;
    var distance = getprop(&amp;quot;/sim/runway-announcer/short-runway-distance&amp;quot;);&lt;br /&gt;
    return sprintf(&amp;quot;On runway %%s, %d %s remaining&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var approaching_short_runway_format = func {&lt;br /&gt;
    var distance = takeoff_announcer.get_short_runway_distance();&lt;br /&gt;
    return sprintf(&amp;quot;Approaching runway %%s, %d %s available&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var remaining_distance_format = func {&lt;br /&gt;
    return sprintf(&amp;quot;%%d %s remaining&amp;quot;, landing_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{tip|You might want to replace copilot_say().}}&lt;br /&gt;
&lt;br /&gt;
=== Step 2 of 3: Announcers ===&lt;br /&gt;
&lt;br /&gt;
Second, create configuration objects, override some of their parameters, create the announcers, and then connect the various signals to callbacks:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var takeoff_config = { parents: [runway.TakeoffRunwayAnnounceConfig] };&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
takeoff_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
# Will cause the announcer to emit the &amp;quot;on-runway&amp;quot; signal if the&lt;br /&gt;
# aircraft is at most 15 meters from the center line of the runway&lt;br /&gt;
takeoff_config.distance_center_line_m = 15;&lt;br /&gt;
&lt;br /&gt;
# Let the announcer emit the &amp;quot;approaching-runway&amp;quot; signal if the&lt;br /&gt;
# nose of the aircraft comes within 120 meters of the runway&lt;br /&gt;
takeoff_config.distance_edge_max_m = 150;&lt;br /&gt;
&lt;br /&gt;
var landing_config = { parents: [runway.LandingRunwayAnnounceConfig] };&lt;br /&gt;
landing_config.distance_center_nose_m = 30;&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
landing_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
# Create announcers&lt;br /&gt;
var takeoff_announcer = runway.TakeoffRunwayAnnounceClass.new(takeoff_config);&lt;br /&gt;
var landing_announcer = runway.LandingRunwayAnnounceClass.new(landing_config);&lt;br /&gt;
&lt;br /&gt;
var stop_announcer    = runway.make_stop_announcer_func(takeoff_announcer, landing_announcer);&lt;br /&gt;
var switch_to_takeoff = runway.make_switch_to_takeoff_func(takeoff_announcer, landing_announcer);&lt;br /&gt;
&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;On runway %s&amp;quot;, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, on_short_runway_format, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Approaching runway %s&amp;quot;));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, approaching_short_runway_format));&lt;br /&gt;
&lt;br /&gt;
landing_announcer.connect(&amp;quot;remaining-distance&amp;quot;, runway.make_betty_cb(copilot_say, remaining_distance_format));&lt;br /&gt;
landing_announcer.connect(&amp;quot;vacated-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Vacated runway %s&amp;quot;, stop_announcer));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Touchdown on runway %s&amp;quot;));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-outside-runway&amp;quot;, runway.make_betty_cb(nil, nil, stop_announcer));&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Step 3 of 3: Listeners ===&lt;br /&gt;
&lt;br /&gt;
Finally, set up a listener to detect when the aircraft is on the ground and when it is airborne:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
# Depending on whether the aircraft is on the ground or not, it will start, stop, or change the modes of the announcers&lt;br /&gt;
var set_on_ground = runway.make_set_ground_func(takeoff_announcer, landing_announcer);&lt;br /&gt;
&lt;br /&gt;
var init_announcers = func {&lt;br /&gt;
    setlistener(&amp;quot;/gear/on-ground&amp;quot;, func (node) {&lt;br /&gt;
        set_on_ground(node.getBoolValue());&lt;br /&gt;
    }, startup=1, runtime=0);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
setlistener(&amp;quot;/sim/signals/fdm-initialized&amp;quot;, func {&lt;br /&gt;
    var timer = maketimer(5.0, func init_announcers());&lt;br /&gt;
    timer.singleShot = 1;&lt;br /&gt;
    timer.start();&lt;br /&gt;
});&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Note|In this example the /gear/on-ground property is used to detect whether the aircraft is on the ground or in the air. Make sure to use a &amp;lt;logic&amp;gt; element in a &amp;lt;autopilot&amp;gt; XML file to set this to true or false depending on your gears' wow values.}}&lt;br /&gt;
&lt;br /&gt;
{{Note|It is your responsibility to start and stop the announcers and to set the correct modes. Therefore it is necessary to connect to signals like landed-outside-runway and vacated-runway, even if they appear to be useless for your specific aircraft. The example of runway.nas above already does this for you.}}&lt;br /&gt;
&lt;br /&gt;
== Configuring the announcers ==&lt;br /&gt;
&lt;br /&gt;
The configuration object takeoff_config has a number of properties with default values. These properties can be modified if you want to change when certain signals are emitted. For example, in the example of runway.nas above, distance_center_line_m and distance_edge_max_m where overridden for large airliners. The defaults are:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
diff_runway_heading_deg: 20,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# get an announcement that the aircraft is on the runway for takeoff&lt;br /&gt;
# or approaching while airborne.&lt;br /&gt;
&lt;br /&gt;
diff_approach_heading_deg: 40,&lt;br /&gt;
# Maximum angle at which the aircraft should approach the runway.&lt;br /&gt;
# Must be higher than 0 and lower than 90.&lt;br /&gt;
&lt;br /&gt;
distance_center_line_m: 10,&lt;br /&gt;
# The distance in meters from the center line of the runway&lt;br /&gt;
&lt;br /&gt;
distance_edge_min_m: 20,&lt;br /&gt;
distance_edge_max_m: 80,&lt;br /&gt;
# Minimum and maximum distance in meters from the edge of the runway&lt;br /&gt;
# for announcing approaches.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_takeoff_m: 3000,&lt;br /&gt;
# Minimum distance in meters required for a normal takeoff. If&lt;br /&gt;
# remaining distance when entering the runway is less than the distance&lt;br /&gt;
# required for a normal takeoff, then the on-short-runway instead of&lt;br /&gt;
# on-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_landing_m: 2000,&lt;br /&gt;
# Minimum distance in meters required for a normal landing. If&lt;br /&gt;
# runway length when approaching the runway is less than the distance&lt;br /&gt;
# required for a normal landing, then the approaching-short-runway&lt;br /&gt;
# instead of approaching-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance of short runways. Can&lt;br /&gt;
# be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
groundspeed_max_kt: 40,&lt;br /&gt;
# Maximum groundspeed in knots for approaching runway callouts&lt;br /&gt;
&lt;br /&gt;
approach_afe_min_ft: 300,&lt;br /&gt;
approach_afe_max_ft: 750,&lt;br /&gt;
# Minimum and maximum altitude Above Field Elevation in feet. Used to&lt;br /&gt;
# decide whether to announce that the aircraft is approaching a runway.&lt;br /&gt;
&lt;br /&gt;
approach_distance_max_nm: 3.0,&lt;br /&gt;
# Maximum distance in nautical miles of the aircraft to the&lt;br /&gt;
# approaching runway&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The same applies to the configuration object landing_config:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
distances_meter: [100,  300,  600,  900, 1200, 1500],&lt;br /&gt;
&lt;br /&gt;
distances_feet:  [500, 1000, 2000, 3000, 4000, 5000],&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance. Can be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;&lt;br /&gt;
&lt;br /&gt;
distance_center_nose_m: 0,&lt;br /&gt;
# Distance from the center to the nose in meters&lt;br /&gt;
&lt;br /&gt;
diff_runway_heading_deg: 20,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# detect the correct runway on which the aircraft is landing.&lt;br /&gt;
&lt;br /&gt;
groundspeed_min_kt: 40,&lt;br /&gt;
# Minimum groundspeed in knots for remaining distance callouts&lt;br /&gt;
&lt;br /&gt;
agl_max_ft: 100,&lt;br /&gt;
# Maximum AGL in feet for remaining distance callouts&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=76904</id>
		<title>Runway Awareness and Advisory System</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=76904"/>
		<updated>2014-10-02T15:17:35Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{infobox subsystem&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
|image =.png&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
|name = Runway Awareness and Advisory System&lt;br /&gt;
|started = 08/2014 &lt;br /&gt;
|description = System to give advisories about runways&lt;br /&gt;
|status = Under active development as of 08/2014&lt;br /&gt;
|developers = onox&lt;br /&gt;
|subforum = http://forum.flightgear.org/viewtopic.php?f=66&amp;amp;t=21266&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Features ==&lt;br /&gt;
&lt;br /&gt;
The Runway Advisory and Awareness System can give a number of advisories:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Feature !! RAAS&lt;br /&gt;
|-&lt;br /&gt;
| On runway and alignment &amp;lt; 20 degrees || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| On short runway, announcing remaining distance || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| On runway (reminder) || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (on ground) when groundspeed &amp;lt; 40 knots || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (airborne) when distance &amp;lt; 3 nm, alignment &amp;lt; 20 degrees, AFE is 300 - 750 ft || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (airborne), announcing available distance || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Distance remaining (during landing) when AGL &amp;lt; 100 feet and groundspeed &amp;gt; 40 knots || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Distance remaining after rejected takeoff, past 50 % of runway and 7 knots below maximum groundspeed || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Runway end when distance remaininig &amp;lt; 100 feet or 30 meters and groundspeed &amp;lt; 40 knots || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Taxiway takeoff when groundspeed &amp;gt; 40 knots while not on runway || {{Not done}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=59ymnKUi49A#t=117&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=0jkRhIMZAZo#t=171&lt;br /&gt;
&lt;br /&gt;
== Aircraft ==&lt;br /&gt;
&lt;br /&gt;
Currently RAAS is only used in the [https://github.com/dogsaysmoo/747-8i/ 747-8i].&lt;br /&gt;
&lt;br /&gt;
{{tip|Ask the developer of your favorite aircraft if you want it to support RAAS.}}&lt;br /&gt;
&lt;br /&gt;
== TODO ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| Use *.groundnet.xml to detect when the aircraft is near a holding point to more accurately emit &amp;quot;approaching-runway&amp;quot; signal || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Allow remaining-distance to be emitted while aircraft is not on ground || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Allow to choose between 450 - 550 ft or 350 - 450 ft suppression of approaching-runway (in air) || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Require climb rate to be &amp;lt; 450 ft/min for remaining-distance || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Require the presence of a mk-viii (GPWS) module || {{Not done}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Signals ==&lt;br /&gt;
&lt;br /&gt;
In order to give these advisories, callbacks for a number of signals can be registered to two announcers. Depending on the current mode of each announcer they will emit certain signals:&lt;br /&gt;
&lt;br /&gt;
=== Takeoff announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| taxi-and-takeoff || approaching-runway, on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| approach || approaching-runway, approaching-short-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Landing announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || remaining-distance, vacated-runway&lt;br /&gt;
|-&lt;br /&gt;
| landing || remaining-distance, landed-runway, vacated-runway, landed-outside-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Installation ==&lt;br /&gt;
&lt;br /&gt;
In case logger.nas and runway_announcer.nas have not been added to FlightGear's fgdata project yet, add the following to the beginning of the &amp;lt;nasal&amp;gt; element in your aircraft's -set.xml file:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;logger&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/logger.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/logger&amp;gt;&lt;br /&gt;
&amp;lt;runway&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway_announcer.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/runway&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the following to the &amp;lt;nasal&amp;gt; element below the previous two:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the file runway.nas to your aircraft's Nasal folder. The following example listens to /gear/on-ground and overrides a number of properties of the takeoff_config object so that it can be used for large airliners.&lt;br /&gt;
&lt;br /&gt;
=== Functions ===&lt;br /&gt;
&lt;br /&gt;
First, create a number of functions to format and print messages:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
# Copyright (C) 2014  onox&lt;br /&gt;
#&lt;br /&gt;
# This program is free software: you can redistribute it and/or modify&lt;br /&gt;
# it under the terms of the GNU General Public License as published by&lt;br /&gt;
# the Free Software Foundation; either version 2 of the License, or&lt;br /&gt;
# (at your option) any later version.&lt;br /&gt;
#&lt;br /&gt;
# This program is distributed in the hope that it will be useful,&lt;br /&gt;
# but WITHOUT ANY WARRANTY; without even the implied warranty of&lt;br /&gt;
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the&lt;br /&gt;
# GNU General Public License for more details.&lt;br /&gt;
#&lt;br /&gt;
# You should have received a copy of the GNU General Public License&lt;br /&gt;
# along with this program.  If not, see &amp;lt;http://www.gnu.org/licenses/&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
var copilot_say = func (message) {&lt;br /&gt;
    setprop(&amp;quot;/sim/messages/copilot&amp;quot;, message);&lt;br /&gt;
    logger.info(sprintf(&amp;quot;Announcing '%s'&amp;quot;, message));&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var on_short_runway_format = func {&lt;br /&gt;
    var distance = getprop(&amp;quot;/sim/runway-announcer/short-runway-distance&amp;quot;);&lt;br /&gt;
    return sprintf(&amp;quot;On runway %%s, %d %s remaining&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var approaching_short_runway_format = func {&lt;br /&gt;
    var distance = takeoff_announcer.get_short_runway_distance();&lt;br /&gt;
    return sprintf(&amp;quot;Approaching runway %%s, %d %s available&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var remaining_distance_format = func {&lt;br /&gt;
    return sprintf(&amp;quot;%%d %s remaining&amp;quot;, landing_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{tip|You might want to replace copilot_say().}}&lt;br /&gt;
&lt;br /&gt;
=== Announcers ===&lt;br /&gt;
&lt;br /&gt;
Second, create configuration objects, override some of their parameters, create the announcers, and then connect the various signals to callbacks:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var takeoff_config = { parents: [runway.TakeoffRunwayAnnounceConfig] };&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
takeoff_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
# Will cause the announcer to emit the &amp;quot;on-runway&amp;quot; signal if the&lt;br /&gt;
# aircraft is at most 15 meters from the center line of the runway&lt;br /&gt;
takeoff_config.distance_center_line_m = 15;&lt;br /&gt;
&lt;br /&gt;
# Let the announcer emit the &amp;quot;approaching-runway&amp;quot; signal if the&lt;br /&gt;
# nose of the aircraft comes within 120 meters of the runway&lt;br /&gt;
takeoff_config.distance_edge_max_m = 150;&lt;br /&gt;
&lt;br /&gt;
var landing_config = { parents: [runway.LandingRunwayAnnounceConfig] };&lt;br /&gt;
landing_config.distance_center_nose_m = 30;&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
landing_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
# Create announcers&lt;br /&gt;
var takeoff_announcer = runway.TakeoffRunwayAnnounceClass.new(takeoff_config);&lt;br /&gt;
var landing_announcer = runway.LandingRunwayAnnounceClass.new(landing_config);&lt;br /&gt;
&lt;br /&gt;
var stop_announcer    = runway.make_stop_announcer_func(takeoff_announcer, landing_announcer);&lt;br /&gt;
var switch_to_takeoff = runway.make_switch_to_takeoff_func(takeoff_announcer, landing_announcer);&lt;br /&gt;
&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;On runway %s&amp;quot;, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, on_short_runway_format, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Approaching runway %s&amp;quot;));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, approaching_short_runway_format));&lt;br /&gt;
&lt;br /&gt;
landing_announcer.connect(&amp;quot;remaining-distance&amp;quot;, runway.make_betty_cb(copilot_say, remaining_distance_format));&lt;br /&gt;
landing_announcer.connect(&amp;quot;vacated-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Vacated runway %s&amp;quot;, stop_announcer));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Touchdown on runway %s&amp;quot;));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-outside-runway&amp;quot;, runway.make_betty_cb(nil, nil, stop_announcer));&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Listeners ===&lt;br /&gt;
&lt;br /&gt;
Finally, set up a listener to detect when the aircraft is on the ground and when it is airborne:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
# Depending on whether the aircraft is on the ground or not, it will start, stop, or change the modes of the announcers&lt;br /&gt;
var set_on_ground = runway.make_set_ground_func(takeoff_announcer, landing_announcer);&lt;br /&gt;
&lt;br /&gt;
var init_announcers = func {&lt;br /&gt;
    setlistener(&amp;quot;/gear/on-ground&amp;quot;, func (node) {&lt;br /&gt;
        set_on_ground(node.getBoolValue());&lt;br /&gt;
    }, startup=1, runtime=0);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
setlistener(&amp;quot;/sim/signals/fdm-initialized&amp;quot;, func {&lt;br /&gt;
    var timer = maketimer(5.0, func init_announcers());&lt;br /&gt;
    timer.singleShot = 1;&lt;br /&gt;
    timer.start();&lt;br /&gt;
});&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Note|In this example the /gear/on-ground property is used to detect whether the aircraft is on the ground or in the air. Make sure to use a &amp;lt;logic&amp;gt; element in a &amp;lt;autopilot&amp;gt; XML file to set this to true or false depending on your gears' wow values.}}&lt;br /&gt;
&lt;br /&gt;
{{Note|It is your responsibility to start and stop the announcers and to set the correct modes. Therefore it is necessary to connect to signals like landed-outside-runway and vacated-runway, even if they appear to be useless for your specific aircraft. The example of runway.nas above already does this for you.}}&lt;br /&gt;
&lt;br /&gt;
== Configuring the announcers ==&lt;br /&gt;
&lt;br /&gt;
The configuration object takeoff_config has a number of properties with default values. These properties can be modified if you want to change when certain signals are emitted. For example, in the example of runway.nas above, distance_center_line_m and distance_edge_max_m where overridden for large airliners. The defaults are:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
diff_runway_heading_deg: 20,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# get an announcement that the aircraft is on the runway for takeoff&lt;br /&gt;
# or approaching while airborne.&lt;br /&gt;
&lt;br /&gt;
diff_approach_heading_deg: 40,&lt;br /&gt;
# Maximum angle at which the aircraft should approach the runway.&lt;br /&gt;
# Must be higher than 0 and lower than 90.&lt;br /&gt;
&lt;br /&gt;
distance_center_line_m: 10,&lt;br /&gt;
# The distance in meters from the center line of the runway&lt;br /&gt;
&lt;br /&gt;
distance_edge_min_m: 20,&lt;br /&gt;
distance_edge_max_m: 80,&lt;br /&gt;
# Minimum and maximum distance in meters from the edge of the runway&lt;br /&gt;
# for announcing approaches.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_takeoff_m: 3000,&lt;br /&gt;
# Minimum distance in meters required for a normal takeoff. If&lt;br /&gt;
# remaining distance when entering the runway is less than the distance&lt;br /&gt;
# required for a normal takeoff, then the on-short-runway instead of&lt;br /&gt;
# on-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_landing_m: 2000,&lt;br /&gt;
# Minimum distance in meters required for a normal landing. If&lt;br /&gt;
# runway length when approaching the runway is less than the distance&lt;br /&gt;
# required for a normal landing, then the approaching-short-runway&lt;br /&gt;
# instead of approaching-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance of short runways. Can&lt;br /&gt;
# be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
groundspeed_max_kt: 40,&lt;br /&gt;
# Maximum groundspeed in knots for approaching runway callouts&lt;br /&gt;
&lt;br /&gt;
approach_afe_min_ft: 300,&lt;br /&gt;
approach_afe_max_ft: 750,&lt;br /&gt;
# Minimum and maximum altitude Above Field Elevation in feet. Used to&lt;br /&gt;
# decide whether to announce that the aircraft is approaching a runway.&lt;br /&gt;
&lt;br /&gt;
approach_distance_max_nm: 3.0,&lt;br /&gt;
# Maximum distance in nautical miles of the aircraft to the&lt;br /&gt;
# approaching runway&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The same applies to the configuration object landing_config:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
distances_meter: [100,  300,  600,  900, 1200, 1500],&lt;br /&gt;
&lt;br /&gt;
distances_feet:  [500, 1000, 2000, 3000, 4000, 5000],&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance. Can be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;&lt;br /&gt;
&lt;br /&gt;
distance_center_nose_m: 0,&lt;br /&gt;
# Distance from the center to the nose in meters&lt;br /&gt;
&lt;br /&gt;
diff_runway_heading_deg: 20,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# detect the correct runway on which the aircraft is landing.&lt;br /&gt;
&lt;br /&gt;
groundspeed_min_kt: 40,&lt;br /&gt;
# Minimum groundspeed in knots for remaining distance callouts&lt;br /&gt;
&lt;br /&gt;
agl_max_ft: 100,&lt;br /&gt;
# Maximum AGL in feet for remaining distance callouts&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=76902</id>
		<title>Runway Awareness and Advisory System</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=76902"/>
		<updated>2014-10-02T14:50:53Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{infobox subsystem&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
|image =.png&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
|name = Runway Awareness and Advisory System&lt;br /&gt;
|started = 08/2014 &lt;br /&gt;
|description = System to give advisories about runways&lt;br /&gt;
|status = Under active development as of 08/2014&lt;br /&gt;
|developers = onox&lt;br /&gt;
|subforum = http://forum.flightgear.org/viewtopic.php?f=66&amp;amp;t=21266&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Features ==&lt;br /&gt;
&lt;br /&gt;
The Runway Advisory and Awareness System can give a number of advisories:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Feature !! RAAS&lt;br /&gt;
|-&lt;br /&gt;
| On runway and alignment &amp;lt; 20 degrees || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| On short runway, announcing remaining distance || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| On runway (reminder) || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (on ground) when groundspeed &amp;lt; 40 knots || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (airborne) when distance &amp;lt; 3 nm, alignment &amp;lt; 20 degrees, AFE is 300 - 750 ft || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (airborne), announcing available distance || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Distance remaining (during landing) when AGL &amp;lt; 100 feet and groundspeed &amp;gt; 40 knots || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Distance remaining after rejected takeoff, past 50 % of runway and 7 knots below maximum groundspeed || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Runway end when distance remaininig &amp;lt; 100 feet or 30 meters and groundspeed &amp;lt; 40 knots || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Taxiway takeoff when groundspeed &amp;gt; 40 knots while not on runway || {{Not done}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=59ymnKUi49A#t=117&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=0jkRhIMZAZo#t=171&lt;br /&gt;
&lt;br /&gt;
== Aircraft ==&lt;br /&gt;
&lt;br /&gt;
Currently RAAS is only used in the [https://github.com/dogsaysmoo/747-8i/ 747-8i].&lt;br /&gt;
&lt;br /&gt;
{{tip|Ask the developer of your favorite aircraft if you want it to support RAAS.}}&lt;br /&gt;
&lt;br /&gt;
== TODO ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| Use *.groundnet.xml to detect when the aircraft is near a holding point to more accurately emit &amp;quot;approaching-runway&amp;quot; signal || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Allow remaining-distance to be emitted while aircraft is not on ground || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Allow to choose between 450 - 550 ft or 350 - 450 ft suppression of approaching-runway (in air) || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Require climb rate to be &amp;lt; 450 ft/min for remaining-distance || {{Not done}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Signals ==&lt;br /&gt;
&lt;br /&gt;
In order to give these advisories, callbacks for a number of signals can be registered to two announcers. Depending on the current mode of each announcer they will emit certain signals:&lt;br /&gt;
&lt;br /&gt;
=== Takeoff announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| taxi-and-takeoff || approaching-runway, on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| approach || approaching-runway, approaching-short-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Landing announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || remaining-distance, vacated-runway&lt;br /&gt;
|-&lt;br /&gt;
| landing || remaining-distance, landed-runway, vacated-runway, landed-outside-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Installation ==&lt;br /&gt;
&lt;br /&gt;
In case logger.nas and runway_announcer.nas have not been added to FlightGear's fgdata project yet, add the following to the beginning of the &amp;lt;nasal&amp;gt; element in your aircraft's -set.xml file:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;logger&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/logger.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/logger&amp;gt;&lt;br /&gt;
&amp;lt;runway&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway_announcer.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/runway&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the following to the &amp;lt;nasal&amp;gt; element below the previous two:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the file runway.nas to your aircraft's Nasal folder. The following example listens to /gear/on-ground and overrides a number of properties of the takeoff_config object so that it can be used for large airliners.&lt;br /&gt;
&lt;br /&gt;
=== Functions ===&lt;br /&gt;
&lt;br /&gt;
First, create a number of functions to format and print messages:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
# Copyright (C) 2014  onox&lt;br /&gt;
#&lt;br /&gt;
# This program is free software: you can redistribute it and/or modify&lt;br /&gt;
# it under the terms of the GNU General Public License as published by&lt;br /&gt;
# the Free Software Foundation; either version 2 of the License, or&lt;br /&gt;
# (at your option) any later version.&lt;br /&gt;
#&lt;br /&gt;
# This program is distributed in the hope that it will be useful,&lt;br /&gt;
# but WITHOUT ANY WARRANTY; without even the implied warranty of&lt;br /&gt;
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the&lt;br /&gt;
# GNU General Public License for more details.&lt;br /&gt;
#&lt;br /&gt;
# You should have received a copy of the GNU General Public License&lt;br /&gt;
# along with this program.  If not, see &amp;lt;http://www.gnu.org/licenses/&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
var copilot_say = func (message) {&lt;br /&gt;
    setprop(&amp;quot;/sim/messages/copilot&amp;quot;, message);&lt;br /&gt;
    logger.info(sprintf(&amp;quot;Announcing '%s'&amp;quot;, message));&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var on_short_runway_format = func {&lt;br /&gt;
    var distance = getprop(&amp;quot;/sim/runway-announcer/short-runway-distance&amp;quot;);&lt;br /&gt;
    return sprintf(&amp;quot;On runway %%s, %d %s remaining&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var approaching_short_runway_format = func {&lt;br /&gt;
    var distance = takeoff_announcer.get_short_runway_distance();&lt;br /&gt;
    return sprintf(&amp;quot;Approaching runway %%s, %d %s available&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var remaining_distance_format = func {&lt;br /&gt;
    return sprintf(&amp;quot;%%d %s remaining&amp;quot;, landing_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{tip|You might want to replace copilot_say().}}&lt;br /&gt;
&lt;br /&gt;
=== Announcers ===&lt;br /&gt;
&lt;br /&gt;
Second, create configuration objects, override some of their parameters, create the announcers, and then connect the various signals to callbacks:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var takeoff_config = { parents: [runway.TakeoffRunwayAnnounceConfig] };&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
takeoff_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
# Will cause the announcer to emit the &amp;quot;on-runway&amp;quot; signal if the&lt;br /&gt;
# aircraft is at most 15 meters from the center line of the runway&lt;br /&gt;
takeoff_config.distance_center_line_m = 15;&lt;br /&gt;
&lt;br /&gt;
# Let the announcer emit the &amp;quot;approaching-runway&amp;quot; signal if the&lt;br /&gt;
# nose of the aircraft comes within 120 meters of the runway&lt;br /&gt;
takeoff_config.distance_edge_max_m = 150;&lt;br /&gt;
&lt;br /&gt;
var landing_config = { parents: [runway.LandingRunwayAnnounceConfig] };&lt;br /&gt;
landing_config.distance_center_nose_m = 30;&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
landing_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
# Create announcers&lt;br /&gt;
var takeoff_announcer = runway.TakeoffRunwayAnnounceClass.new(takeoff_config);&lt;br /&gt;
var landing_announcer = runway.LandingRunwayAnnounceClass.new(landing_config);&lt;br /&gt;
&lt;br /&gt;
var stop_announcer    = runway.make_stop_announcer_func(takeoff_announcer, landing_announcer);&lt;br /&gt;
var switch_to_takeoff = runway.make_switch_to_takeoff_func(takeoff_announcer, landing_announcer);&lt;br /&gt;
&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;On runway %s&amp;quot;, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, on_short_runway_format, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Approaching runway %s&amp;quot;));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, approaching_short_runway_format));&lt;br /&gt;
&lt;br /&gt;
landing_announcer.connect(&amp;quot;remaining-distance&amp;quot;, runway.make_betty_cb(copilot_say, remaining_distance_format));&lt;br /&gt;
landing_announcer.connect(&amp;quot;vacated-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Vacated runway %s&amp;quot;, stop_announcer));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Touchdown on runway %s&amp;quot;));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-outside-runway&amp;quot;, runway.make_betty_cb(nil, nil, stop_announcer));&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Listeners ===&lt;br /&gt;
&lt;br /&gt;
Finally, set up a listener to detect when the aircraft is on the ground and when it is airborne:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
# Depending on whether the aircraft is on the ground or not, it will start, stop, or change the modes of the announcers&lt;br /&gt;
var set_on_ground = runway.make_set_ground_func(takeoff_announcer, landing_announcer);&lt;br /&gt;
&lt;br /&gt;
var init_announcers = func {&lt;br /&gt;
    setlistener(&amp;quot;/gear/on-ground&amp;quot;, func (node) {&lt;br /&gt;
        set_on_ground(node.getBoolValue());&lt;br /&gt;
    }, startup=1, runtime=0);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
setlistener(&amp;quot;/sim/signals/fdm-initialized&amp;quot;, func {&lt;br /&gt;
    var timer = maketimer(5.0, func init_announcers());&lt;br /&gt;
    timer.singleShot = 1;&lt;br /&gt;
    timer.start();&lt;br /&gt;
});&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Note|In this example the /gear/on-ground property is used to detect whether the aircraft is on the ground or in the air. Make sure to use a &amp;lt;logic&amp;gt; element in a &amp;lt;autopilot&amp;gt; XML file to set this to true or false depending on your gears' wow values.}}&lt;br /&gt;
&lt;br /&gt;
{{Note|It is your responsibility to start and stop the announcers and to set the correct modes. Therefore it is necessary to connect to signals like landed-outside-runway and vacated-runway, even if they appear to be useless for your specific aircraft. The example of runway.nas above already does this for you.}}&lt;br /&gt;
&lt;br /&gt;
== Configuring the announcers ==&lt;br /&gt;
&lt;br /&gt;
The configuration object takeoff_config has a number of properties with default values. These properties can be modified if you want to change when certain signals are emitted. For example, in the example of runway.nas above, distance_center_line_m and distance_edge_max_m where overridden for large airliners. The defaults are:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
diff_runway_heading_deg: 20,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# get an announcement that the aircraft is on the runway for takeoff&lt;br /&gt;
# or approaching while airborne.&lt;br /&gt;
&lt;br /&gt;
diff_approach_heading_deg: 40,&lt;br /&gt;
# Maximum angle at which the aircraft should approach the runway.&lt;br /&gt;
# Must be higher than 0 and lower than 90.&lt;br /&gt;
&lt;br /&gt;
distance_center_line_m: 10,&lt;br /&gt;
# The distance in meters from the center line of the runway&lt;br /&gt;
&lt;br /&gt;
distance_edge_min_m: 20,&lt;br /&gt;
distance_edge_max_m: 80,&lt;br /&gt;
# Minimum and maximum distance in meters from the edge of the runway&lt;br /&gt;
# for announcing approaches.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_takeoff_m: 3000,&lt;br /&gt;
# Minimum distance in meters required for a normal takeoff. If&lt;br /&gt;
# remaining distance when entering the runway is less than the distance&lt;br /&gt;
# required for a normal takeoff, then the on-short-runway instead of&lt;br /&gt;
# on-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_landing_m: 2000,&lt;br /&gt;
# Minimum distance in meters required for a normal landing. If&lt;br /&gt;
# runway length when approaching the runway is less than the distance&lt;br /&gt;
# required for a normal landing, then the approaching-short-runway&lt;br /&gt;
# instead of approaching-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance of short runways. Can&lt;br /&gt;
# be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
groundspeed_max_kt: 40,&lt;br /&gt;
# Maximum groundspeed in knots for approaching runway callouts&lt;br /&gt;
&lt;br /&gt;
approach_afe_min_ft: 300,&lt;br /&gt;
approach_afe_max_ft: 750,&lt;br /&gt;
# Minimum and maximum altitude Above Field Elevation in feet. Used to&lt;br /&gt;
# decide whether to announce that the aircraft is approaching a runway.&lt;br /&gt;
&lt;br /&gt;
approach_distance_max_nm: 3.0,&lt;br /&gt;
# Maximum distance in nautical miles of the aircraft to the&lt;br /&gt;
# approaching runway&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The same applies to the configuration object landing_config:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
distances_meter: [100,  300,  600,  900, 1200, 1500],&lt;br /&gt;
&lt;br /&gt;
distances_feet:  [500, 1000, 2000, 3000, 4000, 5000],&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance. Can be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;&lt;br /&gt;
&lt;br /&gt;
distance_center_nose_m: 0,&lt;br /&gt;
# Distance from the center to the nose in meters&lt;br /&gt;
&lt;br /&gt;
diff_runway_heading_deg: 20,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# detect the correct runway on which the aircraft is landing.&lt;br /&gt;
&lt;br /&gt;
groundspeed_min_kt: 40,&lt;br /&gt;
# Minimum groundspeed in knots for remaining distance callouts&lt;br /&gt;
&lt;br /&gt;
agl_max_ft: 100,&lt;br /&gt;
# Maximum AGL in feet for remaining distance callouts&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=76840</id>
		<title>Runway Awareness and Advisory System</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=76840"/>
		<updated>2014-09-29T14:31:02Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{infobox subsystem&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
|image =.png&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
|name = Runway Awareness and Advisory System&lt;br /&gt;
|started = 08/2014 &lt;br /&gt;
|description = System to give advisories about runways&lt;br /&gt;
|status = Under active development as of 08/2014&lt;br /&gt;
|developers = onox&lt;br /&gt;
|subforum = http://forum.flightgear.org/viewtopic.php?f=66&amp;amp;t=21266&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Features ==&lt;br /&gt;
&lt;br /&gt;
The Runway Advisory and Awareness System can give a number of advisories:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Feature !! RAAS&lt;br /&gt;
|-&lt;br /&gt;
| On runway and alignment &amp;lt; 20 degrees || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| On short runway, announcing remaining distance || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| On runway (reminder) || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (on ground) when groundspeed &amp;lt; 40 knots || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (airborne) when distance &amp;lt; 3 nm, alignment &amp;lt; 20 degrees, AFE is 300 - 750 ft || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (airborne), announcing available distance || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Distance remaining (during landing) when AGL &amp;lt; 100 feet and groundspeed &amp;gt; 40 knots || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Distance remaining after rejected takeoff, past 50 % of runway and 7 knots below maximum groundspeed || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Runway end when distance remaininig &amp;lt; 100 feet or 30 meters and groundspeed &amp;lt; 40 knots || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Taxiway takeoff when groundspeed &amp;gt; 40 knots while not on runway || {{Not done}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=59ymnKUi49A#t=117&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=0jkRhIMZAZo#t=171&lt;br /&gt;
&lt;br /&gt;
== Aircraft ==&lt;br /&gt;
&lt;br /&gt;
Currently RAAS is only used in the [https://github.com/dogsaysmoo/747-8i/ 747-8i].&lt;br /&gt;
&lt;br /&gt;
{{tip|Ask the developer of your favorite aircraft if you want it to support RAAS.}}&lt;br /&gt;
&lt;br /&gt;
== TODO ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| Use *.groundnet.xml to detect when the aircraft is near a holding point to more accurately emit &amp;quot;approaching-runway&amp;quot; signal || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Allow remaining-distance to be emitted while aircraft is not on ground || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Allow to choose between 450 - 550 ft or 350 - 450 ft suppression of approaching-runway (in air) || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Require climb rate to be &amp;lt; 450 ft/min for remaining-distance || {{Not done}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Signals ==&lt;br /&gt;
&lt;br /&gt;
In order to give these advisories, callbacks for a number of signals can be registered to two announcers. Depending on the current mode of each announcer they will emit certain signals:&lt;br /&gt;
&lt;br /&gt;
=== Takeoff announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| taxi-and-takeoff || approaching-runway, on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| approach || approaching-runway, approaching-short-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Landing announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || remaining-distance, vacated-runway&lt;br /&gt;
|-&lt;br /&gt;
| landing || remaining-distance, landed-runway, vacated-runway, landed-outside-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Installation ==&lt;br /&gt;
&lt;br /&gt;
In case logger.nas and runway_announcer.nas have not been added to FlightGear's fgdata project yet, add the following to the beginning of the &amp;lt;nasal&amp;gt; element in your aircraft's -set.xml file:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;logger&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/logger.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/logger&amp;gt;&lt;br /&gt;
&amp;lt;runway&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway_announcer.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/runway&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the following to the &amp;lt;nasal&amp;gt; element below the previous two:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the file runway.nas to your aircraft's Nasal folder. The following example listens to /gear/on-ground and overrides a number of properties of the takeoff_config object so that it can be used for large airliners.&lt;br /&gt;
&lt;br /&gt;
=== Functions ===&lt;br /&gt;
&lt;br /&gt;
First, create a number of functions to format and print messages:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
# Copyright (C) 2014  onox&lt;br /&gt;
#&lt;br /&gt;
# This program is free software: you can redistribute it and/or modify&lt;br /&gt;
# it under the terms of the GNU General Public License as published by&lt;br /&gt;
# the Free Software Foundation; either version 2 of the License, or&lt;br /&gt;
# (at your option) any later version.&lt;br /&gt;
#&lt;br /&gt;
# This program is distributed in the hope that it will be useful,&lt;br /&gt;
# but WITHOUT ANY WARRANTY; without even the implied warranty of&lt;br /&gt;
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the&lt;br /&gt;
# GNU General Public License for more details.&lt;br /&gt;
#&lt;br /&gt;
# You should have received a copy of the GNU General Public License&lt;br /&gt;
# along with this program.  If not, see &amp;lt;http://www.gnu.org/licenses/&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
var copilot_say = func (message) {&lt;br /&gt;
    setprop(&amp;quot;/sim/messages/copilot&amp;quot;, message);&lt;br /&gt;
    logger.info(sprintf(&amp;quot;Announcing '%s'&amp;quot;, message));&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var on_short_runway_format = func {&lt;br /&gt;
    var distance = getprop(&amp;quot;/sim/runway-announcer/short-runway-distance&amp;quot;);&lt;br /&gt;
    return sprintf(&amp;quot;On runway %%s, %d %s remaining&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var approaching_short_runway_format = func {&lt;br /&gt;
    var distance = takeoff_announcer.get_short_runway_distance();&lt;br /&gt;
    return sprintf(&amp;quot;Approaching runway %%s, %d %s available&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var remaining_distance_format = func {&lt;br /&gt;
    return sprintf(&amp;quot;%%d %s remaining&amp;quot;, landing_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{tip|You might want to replace copilot_say().}}&lt;br /&gt;
&lt;br /&gt;
=== Announcers ===&lt;br /&gt;
&lt;br /&gt;
Second, create configuration objects, override some of their parameters, create the announcers, and then connect the various signals to callbacks:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var takeoff_config = { parents: [runway.TakeoffRunwayAnnounceConfig] };&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
takeoff_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
# Will cause the announcer to emit the &amp;quot;on-runway&amp;quot; signal if the&lt;br /&gt;
# aircraft is at most 15 meters from the center line of the runway&lt;br /&gt;
takeoff_config.distance_center_line_m = 15;&lt;br /&gt;
&lt;br /&gt;
# Let the announcer emit the &amp;quot;approaching-runway&amp;quot; signal if the&lt;br /&gt;
# nose of the aircraft comes within 120 meters of the runway&lt;br /&gt;
takeoff_config.distance_edge_max_m = 150;&lt;br /&gt;
&lt;br /&gt;
var landing_config = { parents: [runway.LandingRunwayAnnounceConfig] };&lt;br /&gt;
landing_config.distance_center_nose_m = 30;&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
landing_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
# Create announcers&lt;br /&gt;
var takeoff_announcer = runway.TakeoffRunwayAnnounceClass.new(takeoff_config);&lt;br /&gt;
var landing_announcer = runway.LandingRunwayAnnounceClass.new(landing_config);&lt;br /&gt;
&lt;br /&gt;
var stop_announcer    = runway.make_stop_announcer_func(takeoff_announcer, landing_announcer);&lt;br /&gt;
var switch_to_takeoff = runway.make_switch_to_takeoff_func(takeoff_announcer, landing_announcer);&lt;br /&gt;
&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;On runway %s&amp;quot;, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, on_short_runway_format, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Approaching runway %s&amp;quot;));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, approaching_short_runway_format));&lt;br /&gt;
&lt;br /&gt;
landing_announcer.connect(&amp;quot;remaining-distance&amp;quot;, runway.make_betty_cb(copilot_say, remaining_distance_format));&lt;br /&gt;
landing_announcer.connect(&amp;quot;vacated-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Vacated runway %s&amp;quot;, stop_announcer));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Touchdown on runway %s&amp;quot;));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-outside-runway&amp;quot;, runway.make_betty_cb(nil, nil, stop_announcer));&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Listeners ===&lt;br /&gt;
&lt;br /&gt;
Finally, set up a listener to detect when the aircraft is on the ground and when it is airborne:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
# Depending on whether the aircraft is on the ground or not, it will start, stop, or change the modes of the announcers&lt;br /&gt;
var set_on_ground = runway.make_set_ground_func(takeoff_announcer, landing_announcer);&lt;br /&gt;
&lt;br /&gt;
var init_announcers = func {&lt;br /&gt;
    setlistener(&amp;quot;/gear/on-ground&amp;quot;, func (node) {&lt;br /&gt;
        set_on_ground(node.getBoolValue());&lt;br /&gt;
    }, startup=1, runtime=0);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
setlistener(&amp;quot;/sim/signals/fdm-initialized&amp;quot;, func {&lt;br /&gt;
    var timer = maketimer(5.0, func init_announcers());&lt;br /&gt;
    timer.singleShot = 1;&lt;br /&gt;
    timer.start();&lt;br /&gt;
});&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Note|In this example the /gear/on-ground property is used to detect whether the aircraft is on the ground or in the air. Make sure to use a &amp;lt;logic&amp;gt; element in a &amp;lt;autopilot&amp;gt; XML file to set this to true or false depending on your gears' wow values.}}&lt;br /&gt;
&lt;br /&gt;
{{Note|It is your responsibility to start and stop the announcers and to set the correct modes. Therefore it is necessary to connect to signals like landed-outside-runway and vacated-runway, even if they appear to be useless for your specific aircraft. The example of runway.nas above already does this for you.}}&lt;br /&gt;
&lt;br /&gt;
== Configuring the announcers ==&lt;br /&gt;
&lt;br /&gt;
The configuration object takeoff_config has a number of properties with default values. These properties can be modified if you want to change when certain signals are emitted. For example, in the example of runway.nas above, distance_center_line_m and distance_edge_max_m where overridden for large airliners. The defaults are:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
distance_start_m: nil,&lt;br /&gt;
# The maximum distance in meters from the starting position&lt;br /&gt;
# on the runway. Large runways are usually 40 to 60 meters wide&lt;br /&gt;
# to give you an idea of the scale. If nil then the distance is&lt;br /&gt;
# not taken into account, which means the aircraft can be anywhere&lt;br /&gt;
# on the runway for the on-runway signal to be emitted.&lt;br /&gt;
&lt;br /&gt;
diff_runway_heading_deg: 20,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# get an announcement that the aircraft is on the runway for takeoff.&lt;br /&gt;
&lt;br /&gt;
diff_approach_heading_deg: 40,&lt;br /&gt;
# Maximum angle at which the aircraft should approach the runway.&lt;br /&gt;
# Must be higher than 0 and lower than 90.&lt;br /&gt;
&lt;br /&gt;
distance_center_line_m: 10,&lt;br /&gt;
# The distance in meters from the center line of the runway&lt;br /&gt;
&lt;br /&gt;
distance_edge_min_m: 20,&lt;br /&gt;
distance_edge_max_m: 80,&lt;br /&gt;
# Minimum and maximum distance in meters from the edge of the runway&lt;br /&gt;
# for announcing approaches.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_takeoff_m: 3000,&lt;br /&gt;
# Minimum distance in meters required for a normal takeoff. If&lt;br /&gt;
# remaining distance when entering the runway is less than the distance&lt;br /&gt;
# required for a normal takeoff, then the on-short-runway instead of&lt;br /&gt;
# on-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_landing_m: 2000,&lt;br /&gt;
# Minimum distance in meters required for a normal landing. If&lt;br /&gt;
# runway length when approaching the runway is less than the distance&lt;br /&gt;
# required for a normal landing, then the approaching-short-runway&lt;br /&gt;
# instead of approaching-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance of short runways. Can&lt;br /&gt;
# be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
groundspeed_max_kt: 40,&lt;br /&gt;
# Maximum groundspeed in knots for approaching runway callouts&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The same applies to the configuration object landing_config:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
distances_meter: [100,  300,  600,  900, 1200, 1500],&lt;br /&gt;
&lt;br /&gt;
distances_feet:  [500, 1000, 2000, 3000, 4000, 5000],&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance. Can be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;&lt;br /&gt;
&lt;br /&gt;
distance_center_nose_m: 0,&lt;br /&gt;
# Distance from the center to the nose in meters&lt;br /&gt;
&lt;br /&gt;
diff_runway_heading_deg: 15,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# detect the correct runway on which the aircraft is landing.&lt;br /&gt;
&lt;br /&gt;
groundspeed_min_kt: 40,&lt;br /&gt;
# Minimum groundspeed in knots for remaining distance callouts&lt;br /&gt;
&lt;br /&gt;
agl_max_ft: 100,&lt;br /&gt;
# Maximum AGL in feet for remaining distance callouts&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=76839</id>
		<title>Runway Awareness and Advisory System</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=76839"/>
		<updated>2014-09-29T12:17:32Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{infobox subsystem&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
|image =.png&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
|name = Runway Awareness and Advisory System&lt;br /&gt;
|started = 08/2014 &lt;br /&gt;
|description = System to give advisories about runways&lt;br /&gt;
|status = Under active development as of 08/2014&lt;br /&gt;
|developers = onox&lt;br /&gt;
|subforum = http://forum.flightgear.org/viewtopic.php?f=66&amp;amp;t=21266&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Features ==&lt;br /&gt;
&lt;br /&gt;
The Runway Advisory and Awareness System can give a number of advisories:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Feature !! RAAS&lt;br /&gt;
|-&lt;br /&gt;
| On runway and alignment &amp;lt; 20 degrees || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| On short runway, announcing remaining distance || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| On runway (reminder) || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (on ground) when groundspeed &amp;lt; 40 knots || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (airborne) when distance &amp;lt; 3 nm, alignment &amp;lt; 20 degrees, AFE is 300 - 450 ft or  550 - 750 ft || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (airborne), announcing available distance || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Distance remaining (during rollout) || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Distance remaining after rejected takeoff, past 50 % of runway and 7 knots below maximum groundspeed || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Runway end when distance remaininig &amp;lt; 100 feet and groundspeed &amp;lt; 40 knots || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Taxiway takeoff when groundspeed &amp;gt; 40 knots while not on runway || {{Not done}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=59ymnKUi49A#t=117&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=0jkRhIMZAZo#t=171&lt;br /&gt;
&lt;br /&gt;
== Aircraft ==&lt;br /&gt;
&lt;br /&gt;
Currently RAAS is only used in the [https://github.com/dogsaysmoo/747-8i/ 747-8i].&lt;br /&gt;
&lt;br /&gt;
{{tip|Ask the developer of your favorite aircraft if you want it to support RAAS.}}&lt;br /&gt;
&lt;br /&gt;
== TODO ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| Use *.groundnet.xml to detect when the aircraft is near a holding point to more accurately emit &amp;quot;approaching-runway&amp;quot; signal || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Give &amp;quot;Long landing&amp;quot; caution when aircraft has less than a specified distance/percentage remaining || {{Not done}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Signals ==&lt;br /&gt;
&lt;br /&gt;
In order to give these advisories, callbacks for a number of signals can be registered to two announcers. Depending on the current mode of each announcer they will emit certain signals:&lt;br /&gt;
&lt;br /&gt;
=== Takeoff announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| taxi-and-takeoff || approaching-runway, on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| taxi || approaching-runway&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| approach || approaching-runway, approaching-short-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Landing announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || remaining-distance, vacated-runway&lt;br /&gt;
|-&lt;br /&gt;
| landing || remaining-distance, landed-runway, vacated-runway, landed-outside-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Installation ==&lt;br /&gt;
&lt;br /&gt;
In case logger.nas and runway_announcer.nas have not been added to FlightGear's fgdata project yet, add the following to the beginning of the &amp;lt;nasal&amp;gt; element in your aircraft's -set.xml file:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;logger&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/logger.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/logger&amp;gt;&lt;br /&gt;
&amp;lt;runway&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway_announcer.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/runway&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the following to the &amp;lt;nasal&amp;gt; element below the previous two:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the file runway.nas to your aircraft's Nasal folder. The following example listens to /gear/on-ground and overrides a number of properties of the takeoff_config object so that it can be used for large airliners.&lt;br /&gt;
&lt;br /&gt;
=== Functions ===&lt;br /&gt;
&lt;br /&gt;
First, create a number of functions to format and print messages:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
# Copyright (C) 2014  onox&lt;br /&gt;
#&lt;br /&gt;
# This program is free software: you can redistribute it and/or modify&lt;br /&gt;
# it under the terms of the GNU General Public License as published by&lt;br /&gt;
# the Free Software Foundation; either version 2 of the License, or&lt;br /&gt;
# (at your option) any later version.&lt;br /&gt;
#&lt;br /&gt;
# This program is distributed in the hope that it will be useful,&lt;br /&gt;
# but WITHOUT ANY WARRANTY; without even the implied warranty of&lt;br /&gt;
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the&lt;br /&gt;
# GNU General Public License for more details.&lt;br /&gt;
#&lt;br /&gt;
# You should have received a copy of the GNU General Public License&lt;br /&gt;
# along with this program.  If not, see &amp;lt;http://www.gnu.org/licenses/&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
var copilot_say = func (message) {&lt;br /&gt;
    setprop(&amp;quot;/sim/messages/copilot&amp;quot;, message);&lt;br /&gt;
    logger.info(sprintf(&amp;quot;Announcing '%s'&amp;quot;, message));&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var on_short_runway_format = func {&lt;br /&gt;
    var distance = getprop(&amp;quot;/sim/runway-announcer/short-runway-distance&amp;quot;);&lt;br /&gt;
    return sprintf(&amp;quot;On runway %%s, %d %s remaining&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var approaching_short_runway_format = func {&lt;br /&gt;
    var distance = takeoff_announcer.get_short_runway_distance();&lt;br /&gt;
    return sprintf(&amp;quot;Approaching runway %%s, %d %s available&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var remaining_distance_format = func {&lt;br /&gt;
    return sprintf(&amp;quot;%%d %s remaining&amp;quot;, landing_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{tip|You might want to replace copilot_say().}}&lt;br /&gt;
&lt;br /&gt;
=== Announcers ===&lt;br /&gt;
&lt;br /&gt;
Second, create configuration objects, override some of their parameters, create the announcers, and then connect the various signals to callbacks:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var takeoff_config = { parents: [runway.TakeoffRunwayAnnounceConfig] };&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
takeoff_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
# Will cause the announcer to emit the &amp;quot;on-runway&amp;quot; signal if the&lt;br /&gt;
# aircraft is at most 15 meters from the center line of the runway&lt;br /&gt;
takeoff_config.distance_center_line_m = 15;&lt;br /&gt;
&lt;br /&gt;
# Let the announcer emit the &amp;quot;approaching-runway&amp;quot; signal if the&lt;br /&gt;
# nose of the aircraft comes within 120 meters of the runway&lt;br /&gt;
takeoff_config.distance_edge_max_m = 150;&lt;br /&gt;
&lt;br /&gt;
var landing_config = { parents: [runway.LandingRunwayAnnounceConfig] };&lt;br /&gt;
landing_config.distance_center_nose_m = 30;&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
landing_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
# Create announcers&lt;br /&gt;
var takeoff_announcer = runway.TakeoffRunwayAnnounceClass.new(takeoff_config);&lt;br /&gt;
var landing_announcer = runway.LandingRunwayAnnounceClass.new(landing_config);&lt;br /&gt;
&lt;br /&gt;
var stop_announcer    = runway.make_stop_announcer_func(takeoff_announcer, landing_announcer);&lt;br /&gt;
var switch_to_takeoff = runway.make_switch_to_takeoff_func(takeoff_announcer, landing_announcer);&lt;br /&gt;
&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;On runway %s&amp;quot;, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, on_short_runway_format, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Approaching runway %s&amp;quot;));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, approaching_short_runway_format));&lt;br /&gt;
&lt;br /&gt;
landing_announcer.connect(&amp;quot;remaining-distance&amp;quot;, runway.make_betty_cb(copilot_say, remaining_distance_format));&lt;br /&gt;
landing_announcer.connect(&amp;quot;vacated-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Vacated runway %s&amp;quot;, stop_announcer));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Touchdown on runway %s&amp;quot;));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-outside-runway&amp;quot;, runway.make_betty_cb(nil, nil, stop_announcer));&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Listeners ===&lt;br /&gt;
&lt;br /&gt;
Finally, set up a listener to detect when the aircraft is on the ground and when it is airborne:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
# Depending on whether the aircraft is on the ground or not, it will start, stop, or change the modes of the announcers&lt;br /&gt;
var set_on_ground = runway.make_set_ground_func(takeoff_announcer, landing_announcer);&lt;br /&gt;
&lt;br /&gt;
var init_announcers = func {&lt;br /&gt;
    setlistener(&amp;quot;/gear/on-ground&amp;quot;, func (node) {&lt;br /&gt;
        set_on_ground(node.getBoolValue());&lt;br /&gt;
    }, startup=1, runtime=0);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
setlistener(&amp;quot;/sim/signals/fdm-initialized&amp;quot;, func {&lt;br /&gt;
    var timer = maketimer(5.0, func init_announcers());&lt;br /&gt;
    timer.singleShot = 1;&lt;br /&gt;
    timer.start();&lt;br /&gt;
});&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Note|In this example the /gear/on-ground property is used to detect whether the aircraft is on the ground or in the air. Make sure to use a &amp;lt;logic&amp;gt; element in a &amp;lt;autopilot&amp;gt; XML file to set this to true or false depending on your gears' wow values.}}&lt;br /&gt;
&lt;br /&gt;
{{Note|It is your responsibility to start and stop the announcers and to set the correct modes. Therefore it is necessary to connect to signals like landed-outside-runway and vacated-runway, even if they appear to be useless for your specific aircraft. The example of runway.nas above already does this for you.}}&lt;br /&gt;
&lt;br /&gt;
== Configuring the announcers ==&lt;br /&gt;
&lt;br /&gt;
The configuration object takeoff_config has a number of properties with default values. These properties can be modified if you want to change when certain signals are emitted. For example, in the example of runway.nas above, distance_center_line_m and distance_edge_max_m where overridden for large airliners. The defaults are:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
distance_start_m: nil,&lt;br /&gt;
# The maximum distance in meters from the starting position&lt;br /&gt;
# on the runway. Large runways are usually 40 to 60 meters wide&lt;br /&gt;
# to give you an idea of the scale. If nil then the distance is&lt;br /&gt;
# not taken into account, which means the aircraft can be anywhere&lt;br /&gt;
# on the runway for the on-runway signal to be emitted.&lt;br /&gt;
&lt;br /&gt;
diff_runway_heading_deg: 20,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# get an announcement that the aircraft is on the runway for takeoff.&lt;br /&gt;
&lt;br /&gt;
diff_approach_heading_deg: 40,&lt;br /&gt;
# Maximum angle at which the aircraft should approach the runway.&lt;br /&gt;
# Must be higher than 0 and lower than 90.&lt;br /&gt;
&lt;br /&gt;
distance_center_line_m: 10,&lt;br /&gt;
# The distance in meters from the center line of the runway&lt;br /&gt;
&lt;br /&gt;
distance_edge_min_m: 20,&lt;br /&gt;
distance_edge_max_m: 80,&lt;br /&gt;
# Minimum and maximum distance in meters from the edge of the runway&lt;br /&gt;
# for announcing approaches.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_takeoff_m: 3000,&lt;br /&gt;
# Minimum distance in meters required for a normal takeoff. If&lt;br /&gt;
# remaining distance when entering the runway is less than the distance&lt;br /&gt;
# required for a normal takeoff, then the on-short-runway instead of&lt;br /&gt;
# on-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_landing_m: 2000,&lt;br /&gt;
# Minimum distance in meters required for a normal landing. If&lt;br /&gt;
# runway length when approaching the runway is less than the distance&lt;br /&gt;
# required for a normal landing, then the approaching-short-runway&lt;br /&gt;
# instead of approaching-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance of short runways. Can&lt;br /&gt;
# be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
groundspeed_max_kt: 40,&lt;br /&gt;
# Maximum groundspeed in knots for approaching runway callouts&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The same applies to the configuration object landing_config:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
distances_meter: [ 30, 100,  300,  600,  900, 1200, 1500],&lt;br /&gt;
&lt;br /&gt;
distances_feet:  [100, 300, 1000, 2000, 3000, 4000, 5000],&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance. Can be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;&lt;br /&gt;
&lt;br /&gt;
distance_center_nose_m: 0,&lt;br /&gt;
# Distance from the center to the nose in meters&lt;br /&gt;
&lt;br /&gt;
diff_runway_heading_deg: 15,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# detect the correct runway on which the aircraft is landing.&lt;br /&gt;
&lt;br /&gt;
groundspeed_min_kt: 40,&lt;br /&gt;
# Minimum groundspeed in knots for remaining distance callouts&lt;br /&gt;
&lt;br /&gt;
agl_max_ft: 100,&lt;br /&gt;
# Maximum AGL in feet for remaining distance callouts&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=76831</id>
		<title>Runway Awareness and Advisory System</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=76831"/>
		<updated>2014-09-28T23:27:33Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{infobox subsystem&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
|image =.png&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
|name = Runway Awareness and Advisory System&lt;br /&gt;
|started = 08/2014 &lt;br /&gt;
|description = System to give advisories about runways&lt;br /&gt;
|status = Under active development as of 08/2014&lt;br /&gt;
|developers = onox&lt;br /&gt;
|subforum = http://forum.flightgear.org/viewtopic.php?f=66&amp;amp;t=21266&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Features ==&lt;br /&gt;
&lt;br /&gt;
The Runway Advisory and Awareness System can give a number of advisories:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Feature !! RAAS&lt;br /&gt;
|-&lt;br /&gt;
| On runway and alignment &amp;lt; 20 degrees || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| On short runway, announcing remaining distance || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| On runway (reminder) || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (on ground) when groundspeed &amp;lt; 40 knots || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (airborne) when distance &amp;lt; 3 nm, alignment &amp;lt; 20 degrees, AFE is 300 - 450 ft or  550 - 750 ft || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (airborne), announcing available distance || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Distance remaining (during rollout) || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Distance remaining after rejected takeoff, past 50 % of runway and 7 knots below maximum groundspeed || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Runway end when distance remaininig &amp;lt; 100 feet and groundspeed &amp;lt; 40 knots || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Taxiway takeoff when groundspeed &amp;gt; 40 knots while not on runway || {{Not done}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=59ymnKUi49A#t=117&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=0jkRhIMZAZo#t=171&lt;br /&gt;
&lt;br /&gt;
== Aircraft ==&lt;br /&gt;
&lt;br /&gt;
Currently RAAS is only used in the [https://github.com/dogsaysmoo/747-8i/ 747-8i].&lt;br /&gt;
&lt;br /&gt;
{{tip|Ask the developer of your favorite aircraft if you want it to support RAAS.}}&lt;br /&gt;
&lt;br /&gt;
== TODO ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| Use *.groundnet.xml to detect when the aircraft is near a holding point to more accurately emit &amp;quot;approaching-runway&amp;quot; signal || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Give &amp;quot;Long landing&amp;quot; caution when aircraft has less than a specified distance/percentage remaining || {{Not done}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Signals ==&lt;br /&gt;
&lt;br /&gt;
In order to give these advisories, callbacks for a number of signals can be registered to two announcers. Depending on the current mode of each announcer they will emit certain signals:&lt;br /&gt;
&lt;br /&gt;
=== Takeoff announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| taxi-and-takeoff || approaching-runway, on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| taxi || approaching-runway&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| approach || approaching-runway, approaching-short-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Landing announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || remaining-distance, vacated-runway&lt;br /&gt;
|-&lt;br /&gt;
| landing || remaining-distance, landed-runway, vacated-runway, landed-outside-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Installation ==&lt;br /&gt;
&lt;br /&gt;
In case logger.nas and runway_announcer.nas have not been added to FlightGear's fgdata project yet, add the following to the beginning of the &amp;lt;nasal&amp;gt; element in your aircraft's -set.xml file:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;logger&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/logger.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/logger&amp;gt;&lt;br /&gt;
&amp;lt;runway&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway_announcer.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/runway&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the following to the &amp;lt;nasal&amp;gt; element below the previous two:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the file runway.nas to your aircraft's Nasal folder. The following example listens to /gear/on-ground and overrides a number of properties of the takeoff_config object so that it can be used for large airliners.&lt;br /&gt;
&lt;br /&gt;
=== Functions ===&lt;br /&gt;
&lt;br /&gt;
First, create a number of functions to format and print messages, and to execute certain actions when some signals are emitted:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
# Copyright (C) 2014  onox&lt;br /&gt;
#&lt;br /&gt;
# This program is free software: you can redistribute it and/or modify&lt;br /&gt;
# it under the terms of the GNU General Public License as published by&lt;br /&gt;
# the Free Software Foundation; either version 2 of the License, or&lt;br /&gt;
# (at your option) any later version.&lt;br /&gt;
#&lt;br /&gt;
# This program is distributed in the hope that it will be useful,&lt;br /&gt;
# but WITHOUT ANY WARRANTY; without even the implied warranty of&lt;br /&gt;
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the&lt;br /&gt;
# GNU General Public License for more details.&lt;br /&gt;
#&lt;br /&gt;
# You should have received a copy of the GNU General Public License&lt;br /&gt;
# along with this program.  If not, see &amp;lt;http://www.gnu.org/licenses/&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
var copilot_say = func (message) {&lt;br /&gt;
    setprop(&amp;quot;/sim/messages/copilot&amp;quot;, message);&lt;br /&gt;
    logger.info(sprintf(&amp;quot;Announcing '%s'&amp;quot;, message));&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var on_short_runway_format = func {&lt;br /&gt;
    var distance = getprop(&amp;quot;/sim/runway-announcer/short-runway-distance&amp;quot;);&lt;br /&gt;
    return sprintf(&amp;quot;On runway %%s, %d %s remaining&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var approaching_short_runway_format = func {&lt;br /&gt;
    var distance = takeoff_announcer.get_short_runway_distance();&lt;br /&gt;
    return sprintf(&amp;quot;Approaching runway %%s, %d %s available&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var remaining_distance_format = func {&lt;br /&gt;
    return sprintf(&amp;quot;%%d %s remaining&amp;quot;, landing_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var stop_announcer = func {&lt;br /&gt;
    landing_announcer.stop();&lt;br /&gt;
    logger.warn(&amp;quot;Stopping landing announcer&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
    takeoff_announcer.set_mode(&amp;quot;taxi-and-takeoff&amp;quot;);&lt;br /&gt;
    logger.warn(sprintf(&amp;quot;Takeoff mode: %s&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var switch_to_takeoff = func {&lt;br /&gt;
    # Switch to takeoff mode so that the &amp;quot;approaching-runway&amp;quot; signal&lt;br /&gt;
    # is not emitted for any runways that are crossed during takeoff&lt;br /&gt;
    if (takeoff_announcer.mode == &amp;quot;taxi-and-takeoff&amp;quot;) {&lt;br /&gt;
        takeoff_announcer.set_mode(&amp;quot;takeoff&amp;quot;);&lt;br /&gt;
        logger.warn(sprintf(&amp;quot;Takeoff mode: %s&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
&lt;br /&gt;
        landing_announcer.set_mode(&amp;quot;takeoff&amp;quot;);&lt;br /&gt;
        landing_announcer.start();&lt;br /&gt;
        logger.warn(sprintf(&amp;quot;Starting landing (%s) announcer&amp;quot;, landing_announcer.mode));&lt;br /&gt;
    }&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Connecting signals ===&lt;br /&gt;
&lt;br /&gt;
Second, create configuration objects, override some of their parameters, and then connect the various signals to callbacks:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var takeoff_config = { parents: [runway.TakeoffRunwayAnnounceConfig] };&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
takeoff_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
# Will cause the announcer to emit the &amp;quot;on-runway&amp;quot; signal if the&lt;br /&gt;
# aircraft is at most 15 meters from the center line of the runway&lt;br /&gt;
takeoff_config.distance_center_line_m = 15;&lt;br /&gt;
&lt;br /&gt;
# Let the announcer emit the &amp;quot;approaching-runway&amp;quot; signal if the&lt;br /&gt;
# nose of the aircraft comes within 120 meters of the runway&lt;br /&gt;
takeoff_config.distance_edge_max_m = 150;&lt;br /&gt;
&lt;br /&gt;
var takeoff_announcer = runway.TakeoffRunwayAnnounceClass.new(takeoff_config);&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;On runway %s&amp;quot;, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, on_short_runway_format, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Approaching runway %s&amp;quot;));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, approaching_short_runway_format));&lt;br /&gt;
&lt;br /&gt;
var landing_config = { parents: [runway.LandingRunwayAnnounceConfig] };&lt;br /&gt;
landing_config.distance_center_nose_m = 30;&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
landing_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
var landing_announcer = runway.LandingRunwayAnnounceClass.new(landing_config);&lt;br /&gt;
landing_announcer.connect(&amp;quot;remaining-distance&amp;quot;, runway.make_betty_cb(copilot_say, remaining_distance_format));&lt;br /&gt;
landing_announcer.connect(&amp;quot;vacated-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Vacated runway %s&amp;quot;, stop_announcer));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Touchdown on runway %s&amp;quot;));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-outside-runway&amp;quot;, runway.make_betty_cb(nil, nil, stop_announcer));&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Listeners ===&lt;br /&gt;
&lt;br /&gt;
Finally, set up a listener to detect when the aircraft is on the ground and when it is airborne. Depending on this conditions, you need to start, stop, or change the modes of the announcers:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var have_been_in_air = 0;&lt;br /&gt;
&lt;br /&gt;
var test_on_ground = func (on_ground) {&lt;br /&gt;
    if (on_ground) {&lt;br /&gt;
        takeoff_announcer.start();&lt;br /&gt;
        logger.warn(&amp;quot;Starting takeoff announce&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
        if (have_been_in_air == 1) {&lt;br /&gt;
            have_been_in_air = 0;&lt;br /&gt;
&lt;br /&gt;
            takeoff_announcer.set_mode(&amp;quot;&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
            landing_announcer.set_mode(&amp;quot;landing&amp;quot;);&lt;br /&gt;
            landing_announcer.start();&lt;br /&gt;
            logger.warn(sprintf(&amp;quot;Starting landing (%s) announcer&amp;quot;, landing_announcer.mode));&lt;br /&gt;
        }&lt;br /&gt;
        else {&lt;br /&gt;
            takeoff_announcer.set_mode(&amp;quot;taxi-and-takeoff&amp;quot;);&lt;br /&gt;
            logger.warn(sprintf(&amp;quot;Takeoff mode: %s&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
        }&lt;br /&gt;
        takeoff_announcer.start();&lt;br /&gt;
        logger.warn(sprintf(&amp;quot;Starting takeoff (%s) announcer&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
    }&lt;br /&gt;
    else {&lt;br /&gt;
        takeoff_announcer.set_mode(&amp;quot;approach&amp;quot;);&lt;br /&gt;
        logger.warn(sprintf(&amp;quot;Takeoff mode: %s&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
&lt;br /&gt;
        landing_announcer.stop();&lt;br /&gt;
        logger.warn(&amp;quot;Stopping landing announcer&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
        if (have_been_in_air == 0) {&lt;br /&gt;
            have_been_in_air = 1;&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var init_announcers = func {&lt;br /&gt;
    setlistener(&amp;quot;/gear/on-ground&amp;quot;, func (node) {&lt;br /&gt;
        test_on_ground(node.getBoolValue());&lt;br /&gt;
    }, startup=1, runtime=0);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
setlistener(&amp;quot;/sim/signals/fdm-initialized&amp;quot;, func {&lt;br /&gt;
    var timer = maketimer(5.0, func init_announcers());&lt;br /&gt;
    timer.singleShot = 1;&lt;br /&gt;
    timer.start();&lt;br /&gt;
});&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Note|In this example the /gear/on-ground property is used to detect whether the aircraft is on the ground or in the air. Make sure to use a &amp;lt;logic&amp;gt; element in a &amp;lt;autopilot&amp;gt; XML file to set this to true or false depending on your gears' wow values.}}&lt;br /&gt;
&lt;br /&gt;
{{Note|It is your responsibility to start and stop the announcers and to set the correct modes. Therefore it is necessary to connect to signals like landed-outside-runway and vacated-runway, even if they appear to be useless for your specific aircraft. The example of runway.nas above already does this for you.}}&lt;br /&gt;
&lt;br /&gt;
{{tip|You might want to replace copilot_say().}}&lt;br /&gt;
&lt;br /&gt;
== Configuring the announcers ==&lt;br /&gt;
&lt;br /&gt;
The configuration object takeoff_config has a number of properties with default values. These properties can be modified if you want to change when certain signals are emitted. For example, in the example of runway.nas above, distance_center_line_m and distance_edge_max_m where overridden for large airliners. The defaults are:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
distance_start_m: nil,&lt;br /&gt;
# The maximum distance in meters from the starting position&lt;br /&gt;
# on the runway. Large runways are usually 40 to 60 meters wide&lt;br /&gt;
# to give you an idea of the scale. If nil then the distance is&lt;br /&gt;
# not taken into account, which means the aircraft can be anywhere&lt;br /&gt;
# on the runway for the on-runway signal to be emitted.&lt;br /&gt;
&lt;br /&gt;
diff_runway_heading_deg: 20,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# get an announcement that the aircraft is on the runway for takeoff.&lt;br /&gt;
&lt;br /&gt;
diff_approach_heading_deg: 40,&lt;br /&gt;
# Maximum angle at which the aircraft should approach the runway.&lt;br /&gt;
# Must be higher than 0 and lower than 90.&lt;br /&gt;
&lt;br /&gt;
distance_center_line_m: 10,&lt;br /&gt;
# The distance in meters from the center line of the runway&lt;br /&gt;
&lt;br /&gt;
distance_edge_min_m: 20,&lt;br /&gt;
distance_edge_max_m: 80,&lt;br /&gt;
# Minimum and maximum distance in meters from the edge of the runway&lt;br /&gt;
# for announcing approaches.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_takeoff_m: 3000,&lt;br /&gt;
# Minimum distance in meters required for a normal takeoff. If&lt;br /&gt;
# remaining distance when entering the runway is less than the distance&lt;br /&gt;
# required for a normal takeoff, then the on-short-runway instead of&lt;br /&gt;
# on-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_landing_m: 2000,&lt;br /&gt;
# Minimum distance in meters required for a normal landing. If&lt;br /&gt;
# runway length when approaching the runway is less than the distance&lt;br /&gt;
# required for a normal landing, then the approaching-short-runway&lt;br /&gt;
# instead of approaching-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance of short runways. Can&lt;br /&gt;
# be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
groundspeed_max_kt: 40,&lt;br /&gt;
# Maximum groundspeed in knots for approaching runway callouts&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The same applies to the configuration object landing_config:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
distances_meter: [ 30, 100,  300,  600,  900, 1200, 1500],&lt;br /&gt;
&lt;br /&gt;
distances_feet:  [100, 300, 1000, 2000, 3000, 4000, 5000],&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance. Can be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;&lt;br /&gt;
&lt;br /&gt;
distance_center_nose_m: 0,&lt;br /&gt;
# Distance from the center to the nose in meters&lt;br /&gt;
&lt;br /&gt;
diff_runway_heading_deg: 15,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# detect the correct runway on which the aircraft is landing.&lt;br /&gt;
&lt;br /&gt;
groundspeed_min_kt: 40,&lt;br /&gt;
# Minimum groundspeed in knots for remaining distance callouts&lt;br /&gt;
&lt;br /&gt;
agl_max_ft: 100,&lt;br /&gt;
# Maximum AGL in feet for remaining distance callouts&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=76830</id>
		<title>Runway Awareness and Advisory System</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=76830"/>
		<updated>2014-09-28T23:21:48Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{infobox subsystem&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
|image =.png&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
|name = Runway Awareness and Advisory System&lt;br /&gt;
|started = 08/2014 &lt;br /&gt;
|description = System to give advisories about runways&lt;br /&gt;
|status = Under active development as of 08/2014&lt;br /&gt;
|developers = onox&lt;br /&gt;
|subforum = http://forum.flightgear.org/viewtopic.php?f=66&amp;amp;t=21266&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Features ==&lt;br /&gt;
&lt;br /&gt;
The Runway Advisory and Awareness System can give a number of advisories:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Feature !! RAAS&lt;br /&gt;
|-&lt;br /&gt;
| On runway and alignment &amp;lt; 20 degrees || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| On short runway, announcing remaining distance || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| On runway (reminder) || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway when taxiing and groundspeed &amp;lt; 40 knots || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway (airborne) when distance &amp;lt; 3 nm, alignment &amp;lt; 20 degrees, AFE is 300 - 450 ft or  550 - 750 ft || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Approaching runway, announcing available distance || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Distance remaining (during rollout) || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Distance remaining after rejected takeoff, past 50 % of runway and 7 knots below maximum groundspeed || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Runway end when distance remaininig &amp;lt; 100 feet and groundspeed &amp;lt; 40 knots || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Taxiway takeoff when groundspeed &amp;gt; 40 knots while not on runway || {{Not done}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=59ymnKUi49A#t=117&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=0jkRhIMZAZo#t=171&lt;br /&gt;
&lt;br /&gt;
== Aircraft ==&lt;br /&gt;
&lt;br /&gt;
Currently RAAS is only used in the [https://github.com/dogsaysmoo/747-8i/ 747-8i].&lt;br /&gt;
&lt;br /&gt;
{{tip|Ask the developer of your favorite aircraft if you want it to support RAAS.}}&lt;br /&gt;
&lt;br /&gt;
== TODO ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| Use *.groundnet.xml to detect when the aircraft is near a holding point to more accurately emit &amp;quot;approaching-runway&amp;quot; signal || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Give &amp;quot;Long landing&amp;quot; caution when aircraft has less than a specified distance/percentage remaining || {{Not done}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Signals ==&lt;br /&gt;
&lt;br /&gt;
In order to give these advisories, callbacks for a number of signals can be registered to two announcers. Depending on the current mode of each announcer they will emit certain signals:&lt;br /&gt;
&lt;br /&gt;
=== Takeoff announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| taxi-and-takeoff || approaching-runway, on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| taxi || approaching-runway&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| approach || approaching-runway, approaching-short-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Landing announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || remaining-distance, vacated-runway&lt;br /&gt;
|-&lt;br /&gt;
| landing || remaining-distance, landed-runway, vacated-runway, landed-outside-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Installation ==&lt;br /&gt;
&lt;br /&gt;
In case logger.nas and runway_announcer.nas have not been added to FlightGear's fgdata project yet, add the following to the beginning of the &amp;lt;nasal&amp;gt; element in your aircraft's -set.xml file:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;logger&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/logger.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/logger&amp;gt;&lt;br /&gt;
&amp;lt;runway&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway_announcer.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/runway&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the following to the &amp;lt;nasal&amp;gt; element below the previous two:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the file runway.nas to your aircraft's Nasal folder. The following example listens to /gear/on-ground and overrides a number of properties of the takeoff_config object so that it can be used for large airliners.&lt;br /&gt;
&lt;br /&gt;
=== Functions ===&lt;br /&gt;
&lt;br /&gt;
First, create a number of functions to format and print messages, and to execute certain actions when some signals are emitted:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
# Copyright (C) 2014  onox&lt;br /&gt;
#&lt;br /&gt;
# This program is free software: you can redistribute it and/or modify&lt;br /&gt;
# it under the terms of the GNU General Public License as published by&lt;br /&gt;
# the Free Software Foundation; either version 2 of the License, or&lt;br /&gt;
# (at your option) any later version.&lt;br /&gt;
#&lt;br /&gt;
# This program is distributed in the hope that it will be useful,&lt;br /&gt;
# but WITHOUT ANY WARRANTY; without even the implied warranty of&lt;br /&gt;
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the&lt;br /&gt;
# GNU General Public License for more details.&lt;br /&gt;
#&lt;br /&gt;
# You should have received a copy of the GNU General Public License&lt;br /&gt;
# along with this program.  If not, see &amp;lt;http://www.gnu.org/licenses/&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
var copilot_say = func (message) {&lt;br /&gt;
    setprop(&amp;quot;/sim/messages/copilot&amp;quot;, message);&lt;br /&gt;
    logger.info(sprintf(&amp;quot;Announcing '%s'&amp;quot;, message));&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var on_short_runway_format = func {&lt;br /&gt;
    var distance = getprop(&amp;quot;/sim/runway-announcer/short-runway-distance&amp;quot;);&lt;br /&gt;
    return sprintf(&amp;quot;On runway %%s, %d %s remaining&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var approaching_short_runway_format = func {&lt;br /&gt;
    var distance = takeoff_announcer.get_short_runway_distance();&lt;br /&gt;
    return sprintf(&amp;quot;Approaching runway %%s, %d %s available&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var remaining_distance_format = func {&lt;br /&gt;
    return sprintf(&amp;quot;%%d %s remaining&amp;quot;, landing_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var stop_announcer = func {&lt;br /&gt;
    landing_announcer.stop();&lt;br /&gt;
    logger.warn(&amp;quot;Stopping landing announcer&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
    takeoff_announcer.set_mode(&amp;quot;taxi-and-takeoff&amp;quot;);&lt;br /&gt;
    logger.warn(sprintf(&amp;quot;Takeoff mode: %s&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var switch_to_takeoff = func {&lt;br /&gt;
    # Switch to takeoff mode so that the &amp;quot;approaching-runway&amp;quot; signal&lt;br /&gt;
    # is not emitted for any runways that are crossed during takeoff&lt;br /&gt;
    if (takeoff_announcer.mode == &amp;quot;taxi-and-takeoff&amp;quot;) {&lt;br /&gt;
        takeoff_announcer.set_mode(&amp;quot;takeoff&amp;quot;);&lt;br /&gt;
        logger.warn(sprintf(&amp;quot;Takeoff mode: %s&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
&lt;br /&gt;
        landing_announcer.set_mode(&amp;quot;takeoff&amp;quot;);&lt;br /&gt;
        landing_announcer.start();&lt;br /&gt;
        logger.warn(sprintf(&amp;quot;Starting landing (%s) announcer&amp;quot;, landing_announcer.mode));&lt;br /&gt;
    }&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Connecting signals ===&lt;br /&gt;
&lt;br /&gt;
Second, create configuration objects, override some of their parameters, and then connect the various signals to callbacks:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var takeoff_config = { parents: [runway.TakeoffRunwayAnnounceConfig] };&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
takeoff_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
# Will cause the announcer to emit the &amp;quot;on-runway&amp;quot; signal if the&lt;br /&gt;
# aircraft is at most 15 meters from the center line of the runway&lt;br /&gt;
takeoff_config.distance_center_line_m = 15;&lt;br /&gt;
&lt;br /&gt;
# Let the announcer emit the &amp;quot;approaching-runway&amp;quot; signal if the&lt;br /&gt;
# nose of the aircraft comes within 120 meters of the runway&lt;br /&gt;
takeoff_config.distance_edge_max_m = 150;&lt;br /&gt;
&lt;br /&gt;
var takeoff_announcer = runway.TakeoffRunwayAnnounceClass.new(takeoff_config);&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;On runway %s&amp;quot;, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, on_short_runway_format, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Approaching runway %s&amp;quot;));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, approaching_short_runway_format));&lt;br /&gt;
&lt;br /&gt;
var landing_config = { parents: [runway.LandingRunwayAnnounceConfig] };&lt;br /&gt;
landing_config.distance_center_nose_m = 30;&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
landing_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
var landing_announcer = runway.LandingRunwayAnnounceClass.new(landing_config);&lt;br /&gt;
landing_announcer.connect(&amp;quot;remaining-distance&amp;quot;, runway.make_betty_cb(copilot_say, remaining_distance_format));&lt;br /&gt;
landing_announcer.connect(&amp;quot;vacated-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Vacated runway %s&amp;quot;, stop_announcer));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Touchdown on runway %s&amp;quot;));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-outside-runway&amp;quot;, runway.make_betty_cb(nil, nil, stop_announcer));&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Listeners ===&lt;br /&gt;
&lt;br /&gt;
Finally, set up a listener to detect when the aircraft is on the ground and when it is airborne. Depending on this conditions, you need to start, stop, or change the modes of the announcers:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var have_been_in_air = 0;&lt;br /&gt;
&lt;br /&gt;
var test_on_ground = func (on_ground) {&lt;br /&gt;
    if (on_ground) {&lt;br /&gt;
        takeoff_announcer.start();&lt;br /&gt;
        logger.warn(&amp;quot;Starting takeoff announce&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
        if (have_been_in_air == 1) {&lt;br /&gt;
            have_been_in_air = 0;&lt;br /&gt;
&lt;br /&gt;
            takeoff_announcer.set_mode(&amp;quot;&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
            landing_announcer.set_mode(&amp;quot;landing&amp;quot;);&lt;br /&gt;
            landing_announcer.start();&lt;br /&gt;
            logger.warn(sprintf(&amp;quot;Starting landing (%s) announcer&amp;quot;, landing_announcer.mode));&lt;br /&gt;
        }&lt;br /&gt;
        else {&lt;br /&gt;
            takeoff_announcer.set_mode(&amp;quot;taxi-and-takeoff&amp;quot;);&lt;br /&gt;
            logger.warn(sprintf(&amp;quot;Takeoff mode: %s&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
        }&lt;br /&gt;
        takeoff_announcer.start();&lt;br /&gt;
        logger.warn(sprintf(&amp;quot;Starting takeoff (%s) announcer&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
    }&lt;br /&gt;
    else {&lt;br /&gt;
        takeoff_announcer.set_mode(&amp;quot;approach&amp;quot;);&lt;br /&gt;
        logger.warn(sprintf(&amp;quot;Takeoff mode: %s&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
&lt;br /&gt;
        landing_announcer.stop();&lt;br /&gt;
        logger.warn(&amp;quot;Stopping landing announcer&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
        if (have_been_in_air == 0) {&lt;br /&gt;
            have_been_in_air = 1;&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var init_announcers = func {&lt;br /&gt;
    setlistener(&amp;quot;/gear/on-ground&amp;quot;, func (node) {&lt;br /&gt;
        test_on_ground(node.getBoolValue());&lt;br /&gt;
    }, startup=1, runtime=0);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
setlistener(&amp;quot;/sim/signals/fdm-initialized&amp;quot;, func {&lt;br /&gt;
    var timer = maketimer(5.0, func init_announcers());&lt;br /&gt;
    timer.singleShot = 1;&lt;br /&gt;
    timer.start();&lt;br /&gt;
});&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Note|In this example the /gear/on-ground property is used to detect whether the aircraft is on the ground or in the air. Make sure to use a &amp;lt;logic&amp;gt; element in a &amp;lt;autopilot&amp;gt; XML file to set this to true or false depending on your gears' wow values.}}&lt;br /&gt;
&lt;br /&gt;
{{Note|It is your responsibility to start and stop the announcers and to set the correct modes. Therefore it is necessary to connect to signals like landed-outside-runway and vacated-runway, even if they appear to be useless for your specific aircraft. The example of runway.nas above already does this for you.}}&lt;br /&gt;
&lt;br /&gt;
{{tip|You might want to replace copilot_say().}}&lt;br /&gt;
&lt;br /&gt;
== Configuring the announcers ==&lt;br /&gt;
&lt;br /&gt;
The configuration object takeoff_config has a number of properties with default values. These properties can be modified if you want to change when certain signals are emitted. For example, in the example of runway.nas above, distance_center_line_m and distance_edge_max_m where overridden for large airliners. The defaults are:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
distance_start_m: nil,&lt;br /&gt;
# The maximum distance in meters from the starting position&lt;br /&gt;
# on the runway. Large runways are usually 40 to 60 meters wide&lt;br /&gt;
# to give you an idea of the scale. If nil then the distance is&lt;br /&gt;
# not taken into account, which means the aircraft can be anywhere&lt;br /&gt;
# on the runway for the on-runway signal to be emitted.&lt;br /&gt;
&lt;br /&gt;
diff_runway_heading_deg: 20,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# get an announcement that the aircraft is on the runway for takeoff.&lt;br /&gt;
&lt;br /&gt;
diff_approach_heading_deg: 40,&lt;br /&gt;
# Maximum angle at which the aircraft should approach the runway.&lt;br /&gt;
# Must be higher than 0 and lower than 90.&lt;br /&gt;
&lt;br /&gt;
distance_center_line_m: 10,&lt;br /&gt;
# The distance in meters from the center line of the runway&lt;br /&gt;
&lt;br /&gt;
distance_edge_min_m: 20,&lt;br /&gt;
distance_edge_max_m: 80,&lt;br /&gt;
# Minimum and maximum distance in meters from the edge of the runway&lt;br /&gt;
# for announcing approaches.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_takeoff_m: 3000,&lt;br /&gt;
# Minimum distance in meters required for a normal takeoff. If&lt;br /&gt;
# remaining distance when entering the runway is less than the distance&lt;br /&gt;
# required for a normal takeoff, then the on-short-runway instead of&lt;br /&gt;
# on-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_landing_m: 2000,&lt;br /&gt;
# Minimum distance in meters required for a normal landing. If&lt;br /&gt;
# runway length when approaching the runway is less than the distance&lt;br /&gt;
# required for a normal landing, then the approaching-short-runway&lt;br /&gt;
# instead of approaching-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance of short runways. Can&lt;br /&gt;
# be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
groundspeed_max_kt: 40,&lt;br /&gt;
# Maximum groundspeed in knots for approaching runway callouts&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The same applies to the configuration object landing_config:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
distances_meter: [ 30, 100,  300,  600,  900, 1200, 1500],&lt;br /&gt;
&lt;br /&gt;
distances_feet:  [100, 300, 1000, 2000, 3000, 4000, 5000],&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance. Can be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;&lt;br /&gt;
&lt;br /&gt;
distance_center_nose_m: 0,&lt;br /&gt;
# Distance from the center to the nose in meters&lt;br /&gt;
&lt;br /&gt;
diff_runway_heading_deg: 15,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# detect the correct runway on which the aircraft is landing.&lt;br /&gt;
&lt;br /&gt;
groundspeed_min_kt: 40,&lt;br /&gt;
# Minimum groundspeed in knots for remaining distance callouts&lt;br /&gt;
&lt;br /&gt;
agl_max_ft: 100,&lt;br /&gt;
# Maximum AGL in feet for remaining distance callouts&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=76787</id>
		<title>Runway Awareness and Advisory System</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=76787"/>
		<updated>2014-09-28T09:31:55Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{infobox subsystem&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
|image =.png&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
|name = Runway Awareness and Advisory System&lt;br /&gt;
|started = 08/2014 &lt;br /&gt;
|description = System to give advisories about runways&lt;br /&gt;
|status = Under active development as of 08/2014&lt;br /&gt;
|developers = onox&lt;br /&gt;
|subforum = http://forum.flightgear.org/viewtopic.php?f=66&amp;amp;t=21266&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Features ==&lt;br /&gt;
&lt;br /&gt;
The Runway Advisory and Awareness System can give a number of advisories:&lt;br /&gt;
&lt;br /&gt;
* Advisory when approaching a runway while taxiing if groundspeed is less than 40 knots&lt;br /&gt;
&lt;br /&gt;
* Advisory when the aircraft is on the runway and aligned within 20 degrees with runway&lt;br /&gt;
&lt;br /&gt;
* Advisory when the aircraft is on a short runway&lt;br /&gt;
&lt;br /&gt;
* Advisory of remaining distance to the end of the runway during a landing while groundspeed is more than 40 knots and AGL less than 100 feet&lt;br /&gt;
&lt;br /&gt;
* Advisory of remaining distance during RTO after passing 50 % of runway&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=59ymnKUi49A#t=117&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=0jkRhIMZAZo#t=171&lt;br /&gt;
&lt;br /&gt;
== Aircraft ==&lt;br /&gt;
&lt;br /&gt;
Currently RAAS is only used in the [https://github.com/dogsaysmoo/747-8i/ 747-8i].&lt;br /&gt;
&lt;br /&gt;
{{tip|Complain to the developer of your favorite aircraft if you want it to support RAAS.}}&lt;br /&gt;
&lt;br /&gt;
== TODO ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| Use *.groundnet.xml to detect when the aircraft is near a holding point to more accurately emit &amp;quot;approaching-runway&amp;quot; signal || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Give an advisory of which runway the aircraft is lined up with when the aircraft is airborne and approaching a runway || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Give &amp;quot;Approaching runway &amp;lt;runway&amp;gt;, &amp;lt;distance&amp;gt; available&amp;quot; advisory when the aircraft is airborne and approaching a short runway || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Give &amp;quot;Long landing&amp;quot; caution when aircraft has less than a specified distance/percentage remaining || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Give &amp;quot;On runway &amp;lt;runway&amp;gt;, &amp;lt;distance&amp;gt; remaining&amp;quot; advisory if remaining distance is less than required for a normal takeoff || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Give remaining distance callouts after a rejected takeoff || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Give &amp;quot;&amp;lt;distance&amp;gt; remaining&amp;quot; advisory if groundspeed is less than 40 knots and remaining distance is at most 30 meter or 100 feet || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Allow aircraft developers to program whether between feet/meter should be used for distance remaining advisory || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Allow distance from center to nose to be specified for a more accurate remaining distance || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Allow distance_start_m to be nil so that on-runway signal will be emitted anywhere on the runway || {{Progressbar|100}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Signals ==&lt;br /&gt;
&lt;br /&gt;
In order to give these advisories, callbacks for a number of signals can be registered to two announcers. Depending on the current mode of each announcer they will emit certain signals:&lt;br /&gt;
&lt;br /&gt;
=== Takeoff announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| taxi-and-takeoff || approaching-runway, on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| taxi || approaching-runway&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| approach || approaching-runway, approaching-short-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Landing announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || remaining-distance, vacated-runway&lt;br /&gt;
|-&lt;br /&gt;
| landing || remaining-distance, landed-runway, vacated-runway, landed-outside-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Installation ==&lt;br /&gt;
&lt;br /&gt;
In case logger.nas and runway_announcer.nas have not been added to FlightGear's fgdata project yet, add the following to the beginning of the &amp;lt;nasal&amp;gt; element in your aircraft's -set.xml file:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;logger&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/logger.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/logger&amp;gt;&lt;br /&gt;
&amp;lt;runway&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway_announcer.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/runway&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the following to the &amp;lt;nasal&amp;gt; element below the previous two:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the file runway.nas to your aircraft's Nasal folder. The following example listens to /gear/on-ground and overrides a number of properties of the takeoff_config object so that it can be used for large airliners.&lt;br /&gt;
&lt;br /&gt;
=== Functions ===&lt;br /&gt;
&lt;br /&gt;
First, create a number of functions to format and print messages, and to execute certain actions when some signals are emitted:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
# Copyright (C) 2014  onox&lt;br /&gt;
#&lt;br /&gt;
# This program is free software: you can redistribute it and/or modify&lt;br /&gt;
# it under the terms of the GNU General Public License as published by&lt;br /&gt;
# the Free Software Foundation; either version 2 of the License, or&lt;br /&gt;
# (at your option) any later version.&lt;br /&gt;
#&lt;br /&gt;
# This program is distributed in the hope that it will be useful,&lt;br /&gt;
# but WITHOUT ANY WARRANTY; without even the implied warranty of&lt;br /&gt;
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the&lt;br /&gt;
# GNU General Public License for more details.&lt;br /&gt;
#&lt;br /&gt;
# You should have received a copy of the GNU General Public License&lt;br /&gt;
# along with this program.  If not, see &amp;lt;http://www.gnu.org/licenses/&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
var copilot_say = func (message) {&lt;br /&gt;
    setprop(&amp;quot;/sim/messages/copilot&amp;quot;, message);&lt;br /&gt;
    logger.info(sprintf(&amp;quot;Announcing '%s'&amp;quot;, message));&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var on_short_runway_format = func {&lt;br /&gt;
    var distance = getprop(&amp;quot;/sim/runway-announcer/short-runway-distance&amp;quot;);&lt;br /&gt;
    return sprintf(&amp;quot;On runway %%s, %d %s remaining&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var approaching_short_runway_format = func {&lt;br /&gt;
    var distance = takeoff_announcer.get_short_runway_distance();&lt;br /&gt;
    return sprintf(&amp;quot;Approaching runway %%s, %d %s available&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var remaining_distance_format = func {&lt;br /&gt;
    return sprintf(&amp;quot;%%d %s remaining&amp;quot;, landing_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var stop_announcer = func {&lt;br /&gt;
    landing_announcer.stop();&lt;br /&gt;
    logger.warn(&amp;quot;Stopping landing announcer&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
    takeoff_announcer.set_mode(&amp;quot;taxi-and-takeoff&amp;quot;);&lt;br /&gt;
    logger.warn(sprintf(&amp;quot;Takeoff mode: %s&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var switch_to_takeoff = func {&lt;br /&gt;
    # Switch to takeoff mode so that the &amp;quot;approaching-runway&amp;quot; signal&lt;br /&gt;
    # is not emitted for any runways that are crossed during takeoff&lt;br /&gt;
    if (takeoff_announcer.mode == &amp;quot;taxi-and-takeoff&amp;quot;) {&lt;br /&gt;
        takeoff_announcer.set_mode(&amp;quot;takeoff&amp;quot;);&lt;br /&gt;
        logger.warn(sprintf(&amp;quot;Takeoff mode: %s&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
&lt;br /&gt;
        landing_announcer.set_mode(&amp;quot;takeoff&amp;quot;);&lt;br /&gt;
        landing_announcer.start();&lt;br /&gt;
        logger.warn(sprintf(&amp;quot;Starting landing (%s) announcer&amp;quot;, landing_announcer.mode));&lt;br /&gt;
    }&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Connecting signals ===&lt;br /&gt;
&lt;br /&gt;
Second, create configuration objects, override some of their parameters, and then connect the various signals to callbacks:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var takeoff_config = { parents: [runway.TakeoffRunwayAnnounceConfig] };&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
takeoff_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
# Will cause the announcer to emit the &amp;quot;on-runway&amp;quot; signal if the&lt;br /&gt;
# aircraft is at most 15 meters from the center line of the runway&lt;br /&gt;
takeoff_config.distance_center_line_m = 15;&lt;br /&gt;
&lt;br /&gt;
# Let the announcer emit the &amp;quot;approaching-runway&amp;quot; signal if the&lt;br /&gt;
# nose of the aircraft comes within 120 meters of the runway&lt;br /&gt;
takeoff_config.distance_edge_max_m = 150;&lt;br /&gt;
&lt;br /&gt;
var takeoff_announcer = runway.TakeoffRunwayAnnounceClass.new(takeoff_config);&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;On runway %s&amp;quot;, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, on_short_runway_format, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Approaching runway %s&amp;quot;));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, approaching_short_runway_format));&lt;br /&gt;
&lt;br /&gt;
var landing_config = { parents: [runway.LandingRunwayAnnounceConfig] };&lt;br /&gt;
landing_config.distance_center_nose_m = 30;&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
landing_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
var landing_announcer = runway.LandingRunwayAnnounceClass.new(landing_config);&lt;br /&gt;
landing_announcer.connect(&amp;quot;remaining-distance&amp;quot;, runway.make_betty_cb(copilot_say, remaining_distance_format));&lt;br /&gt;
landing_announcer.connect(&amp;quot;vacated-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Vacated runway %s&amp;quot;, stop_announcer));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Touchdown on runway %s&amp;quot;));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-outside-runway&amp;quot;, runway.make_betty_cb(nil, nil, stop_announcer));&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Listeners ===&lt;br /&gt;
&lt;br /&gt;
Finally, set up a listener to detect when the aircraft is on the ground and when it is airborne. Depending on this conditions, you need to start, stop, or change the modes of the announcers:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var have_been_in_air = 0;&lt;br /&gt;
&lt;br /&gt;
var test_on_ground = func (on_ground) {&lt;br /&gt;
    if (on_ground) {&lt;br /&gt;
        takeoff_announcer.start();&lt;br /&gt;
        logger.warn(&amp;quot;Starting takeoff announce&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
        if (have_been_in_air == 1) {&lt;br /&gt;
            have_been_in_air = 0;&lt;br /&gt;
&lt;br /&gt;
            takeoff_announcer.set_mode(&amp;quot;&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
            landing_announcer.set_mode(&amp;quot;landing&amp;quot;);&lt;br /&gt;
            landing_announcer.start();&lt;br /&gt;
            logger.warn(sprintf(&amp;quot;Starting landing (%s) announcer&amp;quot;, landing_announcer.mode));&lt;br /&gt;
        }&lt;br /&gt;
        else {&lt;br /&gt;
            takeoff_announcer.set_mode(&amp;quot;taxi-and-takeoff&amp;quot;);&lt;br /&gt;
            logger.warn(sprintf(&amp;quot;Takeoff mode: %s&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
        }&lt;br /&gt;
        takeoff_announcer.start();&lt;br /&gt;
        logger.warn(sprintf(&amp;quot;Starting takeoff (%s) announcer&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
    }&lt;br /&gt;
    else {&lt;br /&gt;
        takeoff_announcer.set_mode(&amp;quot;approach&amp;quot;);&lt;br /&gt;
        logger.warn(sprintf(&amp;quot;Takeoff mode: %s&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
&lt;br /&gt;
        landing_announcer.stop();&lt;br /&gt;
        logger.warn(&amp;quot;Stopping landing announcer&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
        if (have_been_in_air == 0) {&lt;br /&gt;
            have_been_in_air = 1;&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var init_announcers = func {&lt;br /&gt;
    setlistener(&amp;quot;/gear/on-ground&amp;quot;, func (node) {&lt;br /&gt;
        test_on_ground(node.getBoolValue());&lt;br /&gt;
    }, startup=1, runtime=0);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
setlistener(&amp;quot;/sim/signals/fdm-initialized&amp;quot;, func {&lt;br /&gt;
    var timer = maketimer(5.0, func init_announcers());&lt;br /&gt;
    timer.singleShot = 1;&lt;br /&gt;
    timer.start();&lt;br /&gt;
});&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Note|In this example the /gear/on-ground property is used to detect whether the aircraft is on the ground or in the air. Make sure to use a &amp;lt;logic&amp;gt; element in a &amp;lt;autopilot&amp;gt; XML file to set this to true or false depending on your gears' wow values.}}&lt;br /&gt;
&lt;br /&gt;
{{Note|It is your responsibility to start and stop the announcers and to set the correct modes. Therefore it is necessary to connect to signals like landed-outside-runway and vacated-runway, even if they appear to be useless for your specific aircraft. The example of runway.nas above already does this for you.}}&lt;br /&gt;
&lt;br /&gt;
{{tip|You might want to replace copilot_say().}}&lt;br /&gt;
&lt;br /&gt;
== Configuring the announcers ==&lt;br /&gt;
&lt;br /&gt;
The configuration object takeoff_config has a number of properties with default values. These properties can be modified if you want to change when certain signals are emitted. For example, in the example of runway.nas above, distance_center_line_m and distance_edge_max_m where overridden for large airliners. The defaults are:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
distance_start_m: nil,&lt;br /&gt;
# The maximum distance in meters from the starting position&lt;br /&gt;
# on the runway. Large runways are usually 40 to 60 meters wide&lt;br /&gt;
# to give you an idea of the scale. If nil then the distance is&lt;br /&gt;
# not taken into account, which means the aircraft can be anywhere&lt;br /&gt;
# on the runway for the on-runway signal to be emitted.&lt;br /&gt;
&lt;br /&gt;
diff_runway_heading_deg: 20,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# get an announcement that the aircraft is on the runway for takeoff.&lt;br /&gt;
&lt;br /&gt;
diff_approach_heading_deg: 40,&lt;br /&gt;
# Maximum angle at which the aircraft should approach the runway.&lt;br /&gt;
# Must be higher than 0 and lower than 90.&lt;br /&gt;
&lt;br /&gt;
distance_center_line_m: 10,&lt;br /&gt;
# The distance in meters from the center line of the runway&lt;br /&gt;
&lt;br /&gt;
distance_edge_min_m: 20,&lt;br /&gt;
distance_edge_max_m: 80,&lt;br /&gt;
# Minimum and maximum distance in meters from the edge of the runway&lt;br /&gt;
# for announcing approaches.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_takeoff_m: 3000,&lt;br /&gt;
# Minimum distance in meters required for a normal takeoff. If&lt;br /&gt;
# remaining distance when entering the runway is less than the distance&lt;br /&gt;
# required for a normal takeoff, then the on-short-runway instead of&lt;br /&gt;
# on-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_landing_m: 2000,&lt;br /&gt;
# Minimum distance in meters required for a normal landing. If&lt;br /&gt;
# runway length when approaching the runway is less than the distance&lt;br /&gt;
# required for a normal landing, then the approaching-short-runway&lt;br /&gt;
# instead of approaching-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance of short runways. Can&lt;br /&gt;
# be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
groundspeed_max_kt: 40,&lt;br /&gt;
# Maximum groundspeed in knots for approaching runway callouts&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The same applies to the configuration object landing_config:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
distances_meter: [ 30, 100,  300,  600,  900, 1200, 1500],&lt;br /&gt;
&lt;br /&gt;
distances_feet:  [100, 300, 1000, 2000, 3000, 4000, 5000],&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance. Can be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;&lt;br /&gt;
&lt;br /&gt;
distance_center_nose_m: 0,&lt;br /&gt;
# Distance from the center to the nose in meters&lt;br /&gt;
&lt;br /&gt;
diff_runway_heading_deg: 15,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# detect the correct runway on which the aircraft is landing.&lt;br /&gt;
&lt;br /&gt;
groundspeed_min_kt: 40,&lt;br /&gt;
# Minimum groundspeed in knots for remaining distance callouts&lt;br /&gt;
&lt;br /&gt;
agl_max_ft: 100,&lt;br /&gt;
# Maximum AGL in feet for remaining distance callouts&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=76786</id>
		<title>Runway Awareness and Advisory System</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=76786"/>
		<updated>2014-09-28T09:30:04Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{infobox subsystem&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
|image =.png&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
|name = Runway Awareness and Advisory System&lt;br /&gt;
|started = 08/2014 &lt;br /&gt;
|description = System to give advisories about runways&lt;br /&gt;
|status = Under active development as of 08/2014&lt;br /&gt;
|developers = onox&lt;br /&gt;
|subforum = http://forum.flightgear.org/viewtopic.php?f=66&amp;amp;t=21266&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Features ==&lt;br /&gt;
&lt;br /&gt;
The Runway Advisory and Awareness System can give a number of advisories:&lt;br /&gt;
&lt;br /&gt;
* Advisory when approaching a runway while taxiing if groundspeed is less than 40 knots&lt;br /&gt;
&lt;br /&gt;
* Advisory when the aircraft is on the runway and aligned within 20 degrees with runway&lt;br /&gt;
&lt;br /&gt;
* Advisory when the aircraft is on a short runway&lt;br /&gt;
&lt;br /&gt;
* Advisory of remaining distance to the end of the runway during a landing while groundspeed is more than 40 knots and AGL less than 100 feet&lt;br /&gt;
&lt;br /&gt;
* Advisory of remaining distance during RTO after passing 50 % of runway&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=59ymnKUi49A#t=117&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=0jkRhIMZAZo#t=171&lt;br /&gt;
&lt;br /&gt;
== Aircraft ==&lt;br /&gt;
&lt;br /&gt;
Currently RAAS is only used in the [https://github.com/dogsaysmoo/747-8i/ 747-8i].&lt;br /&gt;
&lt;br /&gt;
{{tip|Complain to the developer of your favorite aircraft if you want it to support RAAS.}}&lt;br /&gt;
&lt;br /&gt;
== TODO ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| Use *.groundnet.xml to detect when the aircraft is near a holding point to more accurately emit &amp;quot;approaching-runway&amp;quot; signal || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Give an advisory of which runway the aircraft is lined up with when the aircraft is airborne and approaching a runway || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Give &amp;quot;Approaching runway &amp;lt;runway&amp;gt;, &amp;lt;distance&amp;gt; available&amp;quot; advisory when the aircraft is airborne and approaching a short runway || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Give &amp;quot;Long landing&amp;quot; caution when aircraft has less than a specified distance/percentage remaining || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Give &amp;quot;On runway &amp;lt;runway&amp;gt;, &amp;lt;distance&amp;gt; remaining&amp;quot; advisory if remaining distance is less than required for a normal takeoff || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Give remaining distance callouts after a rejected takeoff || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Give &amp;quot;&amp;lt;distance&amp;gt; remaining&amp;quot; advisory if groundspeed is less than 40 knots and remaining distance is at most 30 meter or 100 feet || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Allow aircraft developers to program whether between feet/meter should be used for distance remaining advisory || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Allow distance from center to nose to be specified for a more accurate remaining distance || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Allow distance_start_m to be nil so that on-runway signal will be emitted anywhere on the runway || {{Progressbar|100}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Signals ==&lt;br /&gt;
&lt;br /&gt;
In order to give these advisories, callbacks for a number of signals can be registered to two announcers. Depending on the current mode of each announcer they will emit certain signals:&lt;br /&gt;
&lt;br /&gt;
=== Takeoff announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| taxi-and-takeoff || approaching-runway, on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| taxi || approaching-runway&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| approach || approaching-runway, approaching-short-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Landing announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || remaining-distance, vacated-runway&lt;br /&gt;
|-&lt;br /&gt;
| landing || remaining-distance, landed-runway, vacated-runway, landed-outside-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Installation ==&lt;br /&gt;
&lt;br /&gt;
In case logger.nas and runway_announcer.nas have not been added to FlightGear's fgdata project yet, add the following to the beginning of the &amp;lt;nasal&amp;gt; element in your aircraft's -set.xml file:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;logger&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/logger.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/logger&amp;gt;&lt;br /&gt;
&amp;lt;runway&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway_announcer.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/runway&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the following to the &amp;lt;nasal&amp;gt; element below the previous two:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the file runway.nas to your aircraft's Nasal folder. The following example listens to /gear/on-ground and overrides a number of properties of the takeoff_config object so that it can be used for large airliners.&lt;br /&gt;
&lt;br /&gt;
=== Functions ===&lt;br /&gt;
&lt;br /&gt;
First, create a number of functions to format and print messages, and to execute certain actions when some signals are emitted:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
# Copyright (C) 2014  onox&lt;br /&gt;
#&lt;br /&gt;
# This program is free software: you can redistribute it and/or modify&lt;br /&gt;
# it under the terms of the GNU General Public License as published by&lt;br /&gt;
# the Free Software Foundation; either version 2 of the License, or&lt;br /&gt;
# (at your option) any later version.&lt;br /&gt;
#&lt;br /&gt;
# This program is distributed in the hope that it will be useful,&lt;br /&gt;
# but WITHOUT ANY WARRANTY; without even the implied warranty of&lt;br /&gt;
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the&lt;br /&gt;
# GNU General Public License for more details.&lt;br /&gt;
#&lt;br /&gt;
# You should have received a copy of the GNU General Public License&lt;br /&gt;
# along with this program.  If not, see &amp;lt;http://www.gnu.org/licenses/&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
var copilot_say = func (message) {&lt;br /&gt;
    setprop(&amp;quot;/sim/messages/copilot&amp;quot;, message);&lt;br /&gt;
    logger.info(sprintf(&amp;quot;Announcing '%s'&amp;quot;, message));&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var on_short_runway_format = func {&lt;br /&gt;
    var distance = getprop(&amp;quot;/sim/runway-announcer/short-runway-distance&amp;quot;);&lt;br /&gt;
    return sprintf(&amp;quot;On runway %%s, %d %s remaining&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var approaching_short_runway_format = func {&lt;br /&gt;
    var distance = takeoff_announcer.get_short_runway_distance();&lt;br /&gt;
    return sprintf(&amp;quot;Approaching runway %%s, %d %s available&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var remaining_distance_format = func {&lt;br /&gt;
    return sprintf(&amp;quot;%%d %s remaining&amp;quot;, landing_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var stop_announcer = func {&lt;br /&gt;
    landing_announcer.stop();&lt;br /&gt;
    logger.warn(&amp;quot;Stopping landing announcer&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
    takeoff_announcer.set_mode(&amp;quot;taxi-and-takeoff&amp;quot;);&lt;br /&gt;
    logger.warn(sprintf(&amp;quot;Takeoff mode: %s&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var switch_to_takeoff = func {&lt;br /&gt;
    # Switch to takeoff mode so that the &amp;quot;approaching-runway&amp;quot; signal&lt;br /&gt;
    # is not emitted for any runways that are crossed during takeoff&lt;br /&gt;
    if (takeoff_announcer.mode == &amp;quot;taxi-and-takeoff&amp;quot;) {&lt;br /&gt;
        takeoff_announcer.set_mode(&amp;quot;takeoff&amp;quot;);&lt;br /&gt;
        logger.warn(sprintf(&amp;quot;Takeoff mode: %s&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
&lt;br /&gt;
        landing_announcer.set_mode(&amp;quot;takeoff&amp;quot;);&lt;br /&gt;
        landing_announcer.start();&lt;br /&gt;
        logger.warn(sprintf(&amp;quot;Starting landing (%s) announcer&amp;quot;, landing_announcer.mode));&lt;br /&gt;
    }&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Connecting signals ===&lt;br /&gt;
&lt;br /&gt;
Second, create configuration objects, override some of their parameters, and then connect the various functions to callbacks:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var takeoff_config = { parents: [runway.TakeoffRunwayAnnounceConfig] };&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
takeoff_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
# Will cause the announcer to emit the &amp;quot;on-runway&amp;quot; signal if the&lt;br /&gt;
# aircraft is at most 15 meters from the center line of the runway&lt;br /&gt;
takeoff_config.distance_center_line_m = 15;&lt;br /&gt;
&lt;br /&gt;
# Let the announcer emit the &amp;quot;approaching-runway&amp;quot; signal if the&lt;br /&gt;
# nose of the aircraft comes within 120 meters of the runway&lt;br /&gt;
takeoff_config.distance_edge_max_m = 150;&lt;br /&gt;
&lt;br /&gt;
var takeoff_announcer = runway.TakeoffRunwayAnnounceClass.new(takeoff_config);&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;On runway %s&amp;quot;, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, on_short_runway_format, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Approaching runway %s&amp;quot;));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, approaching_short_runway_format));&lt;br /&gt;
&lt;br /&gt;
var landing_config = { parents: [runway.LandingRunwayAnnounceConfig] };&lt;br /&gt;
landing_config.distance_center_nose_m = 30;&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
landing_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
var landing_announcer = runway.LandingRunwayAnnounceClass.new(landing_config);&lt;br /&gt;
landing_announcer.connect(&amp;quot;remaining-distance&amp;quot;, runway.make_betty_cb(copilot_say, remaining_distance_format));&lt;br /&gt;
landing_announcer.connect(&amp;quot;vacated-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Vacated runway %s&amp;quot;, stop_announcer));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Touchdown on runway %s&amp;quot;));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-outside-runway&amp;quot;, runway.make_betty_cb(nil, nil, stop_announcer));&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Listeners ===&lt;br /&gt;
&lt;br /&gt;
Finally, set up a listener to detect when the aircraft is on the ground and when it is airborne. Depending on this conditions, you need to start, stop, or change the modes of the announcers:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var have_been_in_air = 0;&lt;br /&gt;
&lt;br /&gt;
var test_on_ground = func (on_ground) {&lt;br /&gt;
    if (on_ground) {&lt;br /&gt;
        takeoff_announcer.start();&lt;br /&gt;
        logger.warn(&amp;quot;Starting takeoff announce&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
        if (have_been_in_air == 1) {&lt;br /&gt;
            have_been_in_air = 0;&lt;br /&gt;
&lt;br /&gt;
            takeoff_announcer.set_mode(&amp;quot;&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
            landing_announcer.set_mode(&amp;quot;landing&amp;quot;);&lt;br /&gt;
            landing_announcer.start();&lt;br /&gt;
            logger.warn(sprintf(&amp;quot;Starting landing (%s) announcer&amp;quot;, landing_announcer.mode));&lt;br /&gt;
        }&lt;br /&gt;
        else {&lt;br /&gt;
            takeoff_announcer.set_mode(&amp;quot;taxi-and-takeoff&amp;quot;);&lt;br /&gt;
            logger.warn(sprintf(&amp;quot;Takeoff mode: %s&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
        }&lt;br /&gt;
        takeoff_announcer.start();&lt;br /&gt;
        logger.warn(sprintf(&amp;quot;Starting takeoff (%s) announcer&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
    }&lt;br /&gt;
    else {&lt;br /&gt;
        takeoff_announcer.set_mode(&amp;quot;approach&amp;quot;);&lt;br /&gt;
        logger.warn(sprintf(&amp;quot;Takeoff mode: %s&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
&lt;br /&gt;
        landing_announcer.stop();&lt;br /&gt;
        logger.warn(&amp;quot;Stopping landing announcer&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
        if (have_been_in_air == 0) {&lt;br /&gt;
            have_been_in_air = 1;&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var init_announcers = func {&lt;br /&gt;
    setlistener(&amp;quot;/gear/on-ground&amp;quot;, func (node) {&lt;br /&gt;
        test_on_ground(node.getBoolValue());&lt;br /&gt;
    }, startup=1, runtime=0);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
setlistener(&amp;quot;/sim/signals/fdm-initialized&amp;quot;, func {&lt;br /&gt;
    var timer = maketimer(5.0, func init_announcers());&lt;br /&gt;
    timer.singleShot = 1;&lt;br /&gt;
    timer.start();&lt;br /&gt;
});&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Note|In this example the /gear/on-ground property is used to detect whether the aircraft is on the ground or in the air. Make sure to use a &amp;lt;logic&amp;gt; element in a &amp;lt;autopilot&amp;gt; XML file to set this to true or false depending on your gears' wow values.}}&lt;br /&gt;
&lt;br /&gt;
{{Note|It is your responsibility to start and stop the announcers and to set the correct modes. Therefore it is necessary to connect to signals like landed-outside-runway and vacated-runway, even if they appear to be useless for your specific aircraft. The example of runway.nas above already does this for you.}}&lt;br /&gt;
&lt;br /&gt;
{{tip|You might want to replace copilot_say().}}&lt;br /&gt;
&lt;br /&gt;
== Configuring the announcers ==&lt;br /&gt;
&lt;br /&gt;
The configuration object takeoff_config has a number of properties with default values. These properties can be modified if you want to change when certain signals are emitted. For example, in the example of runway.nas above, distance_center_line_m and distance_edge_max_m where overridden for large airliners. The defaults are:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
distance_start_m: nil,&lt;br /&gt;
# The maximum distance in meters from the starting position&lt;br /&gt;
# on the runway. Large runways are usually 40 to 60 meters wide&lt;br /&gt;
# to give you an idea of the scale. If nil then the distance is&lt;br /&gt;
# not taken into account, which means the aircraft can be anywhere&lt;br /&gt;
# on the runway for the on-runway signal to be emitted.&lt;br /&gt;
&lt;br /&gt;
diff_runway_heading_deg: 20,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# get an announcement that the aircraft is on the runway for takeoff.&lt;br /&gt;
&lt;br /&gt;
diff_approach_heading_deg: 40,&lt;br /&gt;
# Maximum angle at which the aircraft should approach the runway.&lt;br /&gt;
# Must be higher than 0 and lower than 90.&lt;br /&gt;
&lt;br /&gt;
distance_center_line_m: 10,&lt;br /&gt;
# The distance in meters from the center line of the runway&lt;br /&gt;
&lt;br /&gt;
distance_edge_min_m: 20,&lt;br /&gt;
distance_edge_max_m: 80,&lt;br /&gt;
# Minimum and maximum distance in meters from the edge of the runway&lt;br /&gt;
# for announcing approaches.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_takeoff_m: 3000,&lt;br /&gt;
# Minimum distance in meters required for a normal takeoff. If&lt;br /&gt;
# remaining distance when entering the runway is less than the distance&lt;br /&gt;
# required for a normal takeoff, then the on-short-runway instead of&lt;br /&gt;
# on-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_landing_m: 2000,&lt;br /&gt;
# Minimum distance in meters required for a normal landing. If&lt;br /&gt;
# runway length when approaching the runway is less than the distance&lt;br /&gt;
# required for a normal landing, then the approaching-short-runway&lt;br /&gt;
# instead of approaching-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance of short runways. Can&lt;br /&gt;
# be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
groundspeed_max_kt: 40,&lt;br /&gt;
# Maximum groundspeed in knots for approaching runway callouts&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The same applies to the configuration object landing_config:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
distances_meter: [ 30, 100,  300,  600,  900, 1200, 1500],&lt;br /&gt;
&lt;br /&gt;
distances_feet:  [100, 300, 1000, 2000, 3000, 4000, 5000],&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance. Can be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;&lt;br /&gt;
&lt;br /&gt;
distance_center_nose_m: 0,&lt;br /&gt;
# Distance from the center to the nose in meters&lt;br /&gt;
&lt;br /&gt;
diff_runway_heading_deg: 15,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# detect the correct runway on which the aircraft is landing.&lt;br /&gt;
&lt;br /&gt;
groundspeed_min_kt: 40,&lt;br /&gt;
# Minimum groundspeed in knots for remaining distance callouts&lt;br /&gt;
&lt;br /&gt;
agl_max_ft: 100,&lt;br /&gt;
# Maximum AGL in feet for remaining distance callouts&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
	<entry>
		<id>https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=76785</id>
		<title>Runway Awareness and Advisory System</title>
		<link rel="alternate" type="text/html" href="https://wiki.flightgear.org/w/index.php?title=Runway_Awareness_and_Advisory_System&amp;diff=76785"/>
		<updated>2014-09-28T09:17:56Z</updated>

		<summary type="html">&lt;p&gt;Onox: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{infobox subsystem&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
|image =.png&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
|name = Runway Awareness and Advisory System&lt;br /&gt;
|started = 08/2014 &lt;br /&gt;
|description = System to give advisories about runways&lt;br /&gt;
|status = Under active development as of 08/2014&lt;br /&gt;
|developers = onox&lt;br /&gt;
|subforum = http://forum.flightgear.org/viewtopic.php?f=66&amp;amp;t=21266&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Features ==&lt;br /&gt;
&lt;br /&gt;
The Runway Advisory and Awareness System can give a number of advisories:&lt;br /&gt;
&lt;br /&gt;
* Advisory when approaching a runway while taxiing if groundspeed is less than 40 knots&lt;br /&gt;
&lt;br /&gt;
* Advisory when the aircraft is on the runway and aligned within 20 degrees with runway&lt;br /&gt;
&lt;br /&gt;
* Advisory when the aircraft is on a short runway&lt;br /&gt;
&lt;br /&gt;
* Advisory of remaining distance to the end of the runway during a landing while groundspeed is more than 40 knots and AGL less than 100 feet&lt;br /&gt;
&lt;br /&gt;
* Advisory of remaining distance during RTO after passing 50 % of runway&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=59ymnKUi49A#t=117&lt;br /&gt;
&lt;br /&gt;
https://www.youtube.com/watch?feature=player_detailpage&amp;amp;v=0jkRhIMZAZo#t=171&lt;br /&gt;
&lt;br /&gt;
== TODO ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| Use *.groundnet.xml to detect when the aircraft is near a holding point to more accurately emit &amp;quot;approaching-runway&amp;quot; signal || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Give an advisory of which runway the aircraft is lined up with when the aircraft is airborne and approaching a runway || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Give &amp;quot;Approaching runway &amp;lt;runway&amp;gt;, &amp;lt;distance&amp;gt; available&amp;quot; advisory when the aircraft is airborne and approaching a short runway || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Give &amp;quot;Long landing&amp;quot; caution when aircraft has less than a specified distance/percentage remaining || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Give &amp;quot;On runway &amp;lt;runway&amp;gt;, &amp;lt;distance&amp;gt; remaining&amp;quot; advisory if remaining distance is less than required for a normal takeoff || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Give remaining distance callouts after a rejected takeoff || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Give &amp;quot;&amp;lt;distance&amp;gt; remaining&amp;quot; advisory if groundspeed is less than 40 knots and remaining distance is at most 30 meter or 100 feet || {{Not done}}&lt;br /&gt;
|-&lt;br /&gt;
| Allow aircraft developers to program whether between feet/meter should be used for distance remaining advisory || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Allow distance from center to nose to be specified for a more accurate remaining distance || {{Progressbar|100}}&lt;br /&gt;
|-&lt;br /&gt;
| Allow distance_start_m to be nil so that on-runway signal will be emitted anywhere on the runway || {{Progressbar|100}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Signals ==&lt;br /&gt;
&lt;br /&gt;
In order to give these advisories, callbacks for a number of signals can be registered to two announcers. Depending on the current mode of each announcer they will emit certain signals:&lt;br /&gt;
&lt;br /&gt;
=== Takeoff announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| taxi-and-takeoff || approaching-runway, on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| taxi || approaching-runway&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || on-runway, on-short-runway&lt;br /&gt;
|-&lt;br /&gt;
| approach || approaching-runway, approaching-short-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Landing announcer ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Mode !! Emitted signals&lt;br /&gt;
|-&lt;br /&gt;
| takeoff || remaining-distance, vacated-runway&lt;br /&gt;
|-&lt;br /&gt;
| landing || remaining-distance, landed-runway, vacated-runway, landed-outside-runway&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Installation ==&lt;br /&gt;
&lt;br /&gt;
In case logger.nas and runway_announcer.nas have not been added to FlightGear's fgdata project yet, add the following to the beginning of the &amp;lt;nasal&amp;gt; element in your aircraft's -set.xml file:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;logger&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/logger.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/logger&amp;gt;&lt;br /&gt;
&amp;lt;runway&amp;gt;&lt;br /&gt;
    &amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway_announcer.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/runway&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the following to the &amp;lt;nasal&amp;gt; element below the previous two:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;file&amp;gt;Aircraft/$YOUR_AIRCRAFT_FOLDER/Nasal/runway.nas&amp;lt;/file&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add the file runway.nas to your aircraft's Nasal folder. The following example listens for gear[1] and gear[2] and overrides a number of properties of the takeoff_config object so that it can be used for large airliners:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
# Copyright (C) 2014  onox&lt;br /&gt;
#&lt;br /&gt;
# This program is free software: you can redistribute it and/or modify&lt;br /&gt;
# it under the terms of the GNU General Public License as published by&lt;br /&gt;
# the Free Software Foundation; either version 2 of the License, or&lt;br /&gt;
# (at your option) any later version.&lt;br /&gt;
#&lt;br /&gt;
# This program is distributed in the hope that it will be useful,&lt;br /&gt;
# but WITHOUT ANY WARRANTY; without even the implied warranty of&lt;br /&gt;
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the&lt;br /&gt;
# GNU General Public License for more details.&lt;br /&gt;
#&lt;br /&gt;
# You should have received a copy of the GNU General Public License&lt;br /&gt;
# along with this program.  If not, see &amp;lt;http://www.gnu.org/licenses/&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
var copilot_say = func (message) {&lt;br /&gt;
    setprop(&amp;quot;/sim/messages/copilot&amp;quot;, message);&lt;br /&gt;
    logger.info(sprintf(&amp;quot;Announcing '%s'&amp;quot;, message));&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var on_short_runway_format = func {&lt;br /&gt;
    var distance = getprop(&amp;quot;/sim/runway-announcer/short-runway-distance&amp;quot;);&lt;br /&gt;
    return sprintf(&amp;quot;On runway %%s, %d %s remaining&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var approaching_short_runway_format = func {&lt;br /&gt;
    var distance = takeoff_announcer.get_short_runway_distance();&lt;br /&gt;
    return sprintf(&amp;quot;Approaching runway %%s, %d %s available&amp;quot;, distance, takeoff_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var remaining_distance_format = func {&lt;br /&gt;
    return sprintf(&amp;quot;%%d %s remaining&amp;quot;, landing_config.distances_unit);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var stop_announcer = func {&lt;br /&gt;
    landing_announcer.stop();&lt;br /&gt;
    logger.warn(&amp;quot;Stopping landing announcer&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
    takeoff_announcer.set_mode(&amp;quot;taxi-and-takeoff&amp;quot;);&lt;br /&gt;
    logger.warn(sprintf(&amp;quot;Takeoff mode: %s&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var switch_to_takeoff = func {&lt;br /&gt;
    # Switch to takeoff mode so that the &amp;quot;approaching-runway&amp;quot; signal&lt;br /&gt;
    # is not emitted for any runways that are crossed during takeoff&lt;br /&gt;
    if (takeoff_announcer.mode == &amp;quot;taxi-and-takeoff&amp;quot;) {&lt;br /&gt;
        takeoff_announcer.set_mode(&amp;quot;takeoff&amp;quot;);&lt;br /&gt;
        logger.warn(sprintf(&amp;quot;Takeoff mode: %s&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
&lt;br /&gt;
        landing_announcer.set_mode(&amp;quot;takeoff&amp;quot;);&lt;br /&gt;
        landing_announcer.start();&lt;br /&gt;
        logger.warn(sprintf(&amp;quot;Starting landing (%s) announcer&amp;quot;, landing_announcer.mode));&lt;br /&gt;
    }&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var takeoff_config = { parents: [runway.TakeoffRunwayAnnounceConfig] };&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
takeoff_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
# Will cause the announcer to emit the &amp;quot;on-runway&amp;quot; signal if the&lt;br /&gt;
# aircraft is at most 15 meters from the center line of the runway&lt;br /&gt;
takeoff_config.distance_center_line_m = 15;&lt;br /&gt;
&lt;br /&gt;
# Let the announcer emit the &amp;quot;approaching-runway&amp;quot; signal if the&lt;br /&gt;
# nose of the aircraft comes within 120 meters of the runway&lt;br /&gt;
takeoff_config.distance_edge_max_m = 150;&lt;br /&gt;
&lt;br /&gt;
var takeoff_announcer = runway.TakeoffRunwayAnnounceClass.new(takeoff_config);&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;On runway %s&amp;quot;, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;on-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, on_short_runway_format, switch_to_takeoff));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Approaching runway %s&amp;quot;));&lt;br /&gt;
takeoff_announcer.connect(&amp;quot;approaching-short-runway&amp;quot;, runway.make_betty_cb(copilot_say, approaching_short_runway_format));&lt;br /&gt;
&lt;br /&gt;
var landing_config = { parents: [runway.LandingRunwayAnnounceConfig] };&lt;br /&gt;
landing_config.distance_center_nose_m = 30;&lt;br /&gt;
&lt;br /&gt;
# You can modify this setting from a GUI during runtime&lt;br /&gt;
landing_config.distances_unit = &amp;quot;meter&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
var landing_announcer = runway.LandingRunwayAnnounceClass.new(landing_config);&lt;br /&gt;
landing_announcer.connect(&amp;quot;remaining-distance&amp;quot;, runway.make_betty_cb(copilot_say, remaining_distance_format));&lt;br /&gt;
landing_announcer.connect(&amp;quot;vacated-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Vacated runway %s&amp;quot;, stop_announcer));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-runway&amp;quot;, runway.make_betty_cb(copilot_say, &amp;quot;Touchdown on runway %s&amp;quot;));&lt;br /&gt;
landing_announcer.connect(&amp;quot;landed-outside-runway&amp;quot;, runway.make_betty_cb(nil, nil, stop_announcer));&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
var have_been_in_air = 0;&lt;br /&gt;
&lt;br /&gt;
var test_on_ground = func (on_ground) {&lt;br /&gt;
    if (on_ground) {&lt;br /&gt;
        takeoff_announcer.start();&lt;br /&gt;
        logger.warn(&amp;quot;Starting takeoff announce&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
        if (have_been_in_air == 1) {&lt;br /&gt;
            have_been_in_air = 0;&lt;br /&gt;
&lt;br /&gt;
            takeoff_announcer.set_mode(&amp;quot;&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
            landing_announcer.set_mode(&amp;quot;landing&amp;quot;);&lt;br /&gt;
            landing_announcer.start();&lt;br /&gt;
            logger.warn(sprintf(&amp;quot;Starting landing (%s) announcer&amp;quot;, landing_announcer.mode));&lt;br /&gt;
        }&lt;br /&gt;
        else {&lt;br /&gt;
            takeoff_announcer.set_mode(&amp;quot;taxi-and-takeoff&amp;quot;);&lt;br /&gt;
            logger.warn(sprintf(&amp;quot;Takeoff mode: %s&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
        }&lt;br /&gt;
        takeoff_announcer.start();&lt;br /&gt;
        logger.warn(sprintf(&amp;quot;Starting takeoff (%s) announcer&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
    }&lt;br /&gt;
    else {&lt;br /&gt;
        takeoff_announcer.set_mode(&amp;quot;approach&amp;quot;);&lt;br /&gt;
        logger.warn(sprintf(&amp;quot;Takeoff mode: %s&amp;quot;, takeoff_announcer.mode));&lt;br /&gt;
&lt;br /&gt;
        landing_announcer.stop();&lt;br /&gt;
        logger.warn(&amp;quot;Stopping landing announcer&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
        if (have_been_in_air == 0) {&lt;br /&gt;
            have_been_in_air = 1;&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
var init_announcers = func {&lt;br /&gt;
    setlistener(&amp;quot;/gear/on-ground&amp;quot;, func (node) {&lt;br /&gt;
        test_on_ground(node.getBoolValue());&lt;br /&gt;
    }, startup=1, runtime=0);&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
setlistener(&amp;quot;/sim/signals/fdm-initialized&amp;quot;, func {&lt;br /&gt;
    var timer = maketimer(5.0, func init_announcers());&lt;br /&gt;
    timer.singleShot = 1;&lt;br /&gt;
    timer.start();&lt;br /&gt;
});&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Note|In this example the /gear/on-ground property is used to detect whether the aircraft is on the ground or in the air. Make sure to use a &amp;lt;logic&amp;gt; element in a &amp;lt;autopilot&amp;gt; XML file to set this to true or false depending on your gears' wow values.}}&lt;br /&gt;
&lt;br /&gt;
{{Note|It is your responsibility to start and stop the announcers and to set the correct modes. Therefore it is necessary to connect to signals like landed-outside-runway and vacated-runway, even if they appear to be useless for your specific aircraft. The example of runway.nas above already does this for you.}}&lt;br /&gt;
&lt;br /&gt;
{{tip|You might want to replace copilot_say().}}&lt;br /&gt;
&lt;br /&gt;
The configuration object takeoff_config has a number of properties with default values. These properties can be modified if you want to change when certain signals are emitted. For example, in the example of runway.nas above, distance_center_line_m and distance_edge_max_m where overridden for large airliners. The defaults are:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
distance_start_m: nil,&lt;br /&gt;
# The maximum distance in meters from the starting position&lt;br /&gt;
# on the runway. Large runways are usually 40 to 60 meters wide&lt;br /&gt;
# to give you an idea of the scale. If nil then the distance is&lt;br /&gt;
# not taken into account, which means the aircraft can be anywhere&lt;br /&gt;
# on the runway for the on-runway signal to be emitted.&lt;br /&gt;
&lt;br /&gt;
diff_runway_heading_deg: 20,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# get an announcement that the aircraft is on the runway for takeoff.&lt;br /&gt;
&lt;br /&gt;
diff_approach_heading_deg: 40,&lt;br /&gt;
# Maximum angle at which the aircraft should approach the runway.&lt;br /&gt;
# Must be higher than 0 and lower than 90.&lt;br /&gt;
&lt;br /&gt;
distance_center_line_m: 10,&lt;br /&gt;
# The distance in meters from the center line of the runway&lt;br /&gt;
&lt;br /&gt;
distance_edge_min_m: 20,&lt;br /&gt;
distance_edge_max_m: 80,&lt;br /&gt;
# Minimum and maximum distance in meters from the edge of the runway&lt;br /&gt;
# for announcing approaches.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_takeoff_m: 3000,&lt;br /&gt;
# Minimum distance in meters required for a normal takeoff. If&lt;br /&gt;
# remaining distance when entering the runway is less than the distance&lt;br /&gt;
# required for a normal takeoff, then the on-short-runway instead of&lt;br /&gt;
# on-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
nominal_distance_landing_m: 2000,&lt;br /&gt;
# Minimum distance in meters required for a normal landing. If&lt;br /&gt;
# runway length when approaching the runway is less than the distance&lt;br /&gt;
# required for a normal landing, then the approaching-short-runway&lt;br /&gt;
# instead of approaching-runway signal will be emitted.&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance of short runways. Can&lt;br /&gt;
# be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
groundspeed_max_kt: 40,&lt;br /&gt;
# Maximum groundspeed in knots for approaching runway callouts&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The same applies to the configuration object landing_config:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;nasal&amp;quot;&amp;gt;&lt;br /&gt;
distances_meter: [ 30, 100,  300,  600,  900, 1200, 1500],&lt;br /&gt;
&lt;br /&gt;
distances_feet:  [100, 300, 1000, 2000, 3000, 4000, 5000],&lt;br /&gt;
&lt;br /&gt;
distances_unit: &amp;quot;meter&amp;quot;,&lt;br /&gt;
# The unit to use for the remaining distance. Can be &amp;quot;meter&amp;quot; or &amp;quot;feet&amp;quot;&lt;br /&gt;
&lt;br /&gt;
distance_center_nose_m: 0,&lt;br /&gt;
# Distance from the center to the nose in meters&lt;br /&gt;
&lt;br /&gt;
diff_runway_heading_deg: 15,&lt;br /&gt;
# Difference in heading between runway and aircraft in order to&lt;br /&gt;
# detect the correct runway on which the aircraft is landing.&lt;br /&gt;
&lt;br /&gt;
groundspeed_min_kt: 40,&lt;br /&gt;
# Minimum groundspeed in knots for remaining distance callouts&lt;br /&gt;
&lt;br /&gt;
agl_max_ft: 100,&lt;br /&gt;
# Maximum AGL in feet for remaining distance callouts&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Onox</name></author>
	</entry>
</feed>