Flightplan XML formats: Difference between revisions

Jump to navigation Jump to search
→‎Related content: + Links to the source code
(Extending)
(→‎Related content: + Links to the source code)
(7 intermediate revisions by the same user not shown)
Line 1: Line 1:
FlightGear use a few different '''flightplan xml formats''' stored in property-list xml files.  Due to having different needs the flightplans used in the route manager and AI scenarios and have different formats.
FlightGear use a few different '''flightplan XML formats''' stored in property-list xml files.  Due to different needs the flightplans used in the route manager and AI scenarios and have different formats.


== AI flightplans ==
== AI flightplans ==
Line 8: Line 8:
=== Waypoint tags ===
=== Waypoint tags ===
Each waypoint can contain the following tags:
Each waypoint can contain the following tags:
* <tt>'''<name>'''</tt> - Waypoint name, if it is the last waypoint use <tt>'''EOF'''</tt> or, if you want the AI model deleted, use <tt>'''END'''</tt>.
{| class="wikitable"
* <tt>'''<lat>'''</tt> - Latitude, decimal degrees
! Tag !! Type !! Use !! Remarks
* <tt>'''<lon>'''</tt> - Longitude, decimal degrees
|-
* <tt>'''<alt>'''</tt> - Altitude above mean sea level, feet
| <code>&lt;name&gt;</code> || string || Waypoint name || The last waypoint use <code>EOF</code>, or if the AI model is to be deleted <code>END</code>.
* <tt>'''<crossat>'''</tt> - Crossing altitude, feet
|-
* <tt>'''<ktas>'''</tt> - Knots true air speed
| <code>&lt;lat&gt;</code> || double || Latitude, decimal degrees ||
* <tt>'''<on-ground>'''</tt> - Set to <tt>'''true'''</tt> or <tt>1</tt> if on ground, if in air or in a tunnel set to <tt>'''false'''</tt> or <tt>'''0'''</tt>
|-
* <tt>'''<gear-down>'''</tt> - <tt>'''true'''</tt> for gear down, <tt>'''false'''</tt> for gear up, or any number between 0 and 1
| <code>&lt;lon&gt;</code> || double || Longitude, decimal degrees ||
* <tt>'''<flaps-down>'''</tt> - <tt>'''true'''</tt> for flaps down, <tt>'''false'''</tt> for flaps up, or any number between 0 and 1
|-
| <code>&lt;alt&gt;</code> || double || Altitude above mean sea level, feet ||
|-
| <code>&lt;crossat&gt;</code> || double || Crossing altitude, feet ||
|-
| <code>&lt;ktas&gt;</code> || double || True air speed, knots ||
|-
| <code>&lt;on-ground&gt;</code> || bool || Set to <code>true</code> or <code>1</code> if on ground
 
Set to <code>false</code> or <code>0</code> if in air or in a tunnel
|
|-
| <code>&lt;gear-down&gt;</code> || double || <code>true</code> for gear down
 
<code>false</code> for gear up
| Or any number between 0 and 1
|-
| <code>&lt;flaps-down&gt;</code> || double || <code>true</code> for flaps down
 
<code>false</code> for flaps up
| Or any number between 0 and 1
|}


=== Example ===
=== Example ===
Line 51: Line 72:


=== Departure and destination tags ===
=== Departure and destination tags ===
* <tt>'''<airport type="string">'''</tt> - The ICAO identifier of the airport
{| class="wikitable"
* <tt>'''<sid type="string">'''</tt> - Any available SID
! Tag !! Type !! Use !! Remarks
* <tt>'''<star type="string">'''</tt> - Any available STAR
|-
* <tt>'''<transition type="string">'''</tt> -  
| <code>&lt;airport&gt;</code> || string || The ICAO identifier of the airport ||
* <tt>'''<runway type="string">'''</tt> - Departure or destination runway
|-
| <code>&lt;sid&gt;</code> || string || Any available SID ||
|-
| <code>&lt;star&gt;</code> || string || Any available STAR ||
|-
| <code>&lt;transition&gt;</code> || string ||  ||
|-
| <code>&lt;runway&gt;</code> || string || Departure or destination runway ||
|}


=== Waypoint types and tags ===
=== Waypoint types and tags ===
* <tt>'''<type type="string">'''</tt> - Either of:
{| class="wikitable"
** <tt>'''runway'''</tt> - The number of the departure or destination airport's runway. Accompanied in the waypoint by the <icao> tag.
! Tag !! Type !! Use !! Remarks
** <tt>'''navaid'''</tt> - Any significant point along the route. Both airports, navaids and fixes.
|-
** <tt>'''offset-navaid'''</tt> - An point offset from a navaid by a bearing and distance. Note that true bearings are used here.
| <code>&lt;type&gt;</code> || string || Type of waypoint. Either <code>runway</code>, <code>navaid</code> or <code>offset-navaid</code> ||
* <tt>'''<alt-restrict type="string">'''</tt> - ?  #FIXME
|-
* <tt>'''<altitude-ft type="double">'''</tt> - Altitude in feet
| <code>&lt;alt-restrict&gt;</code> || string ||  ||
* <tt>'''<ident type="string">'''</tt> - Identity of an  airport, navaid or fixe
|-
* <tt>'''<icao type="string">'''</tt> - ICAO code of an airport
| <code>&lt;altitude-ft&gt;</code> || double || Altitude in feet ||
* <tt>'''<lon type="double">'''</tt> - Longitude of the waypoint in decimal degrees
|-
* <tt>'''<lat type="double">'''</tt> - Latitude of the waypoint in decimal degrees
| <code>&lt;ident&gt;</code> || string || If <code>&lt;type&gt;</code> is
* <tt>'''<radial-deg type="double">'''</tt> - True bearing from a navaid, fix or airport ''Do note that radials on charts are magnetic!''
: <code>runway</code>The departure or destination airport's runway number. Accompanied in the waypoint by the <code>&lt;icao&gt;</code> tag.
* <tt>'''<distance-nm type="double">'''</tt> - Distance from a navaid, fix or airport
: <code>navaid</code>Any significant point along the route. Both airports, navaids and fixes.
: <code>offset-navaid</code>An point offset from a navaid by a bearing and distance. Note that true bearings are used here.
|
|-
| <code>&lt;icao&gt;</code> || string || ICAO code of an airport || Used only if <code>&lt;type&gt;</code> is <code>runway</code>
|-
| <code>&lt;lon&gt;</code> || double || Longitude of the waypoint in decimal degrees ||
|-
| <code>&lt;lat&gt;</code> || double || Latitude of the waypoint in decimal degrees ||
|-
| <code>&lt;radial-deg&gt;</code> || double || True bearing from a navaid, fix or airport || {{inote|Radials on charts are magnetic!}}
|-
| <code>&lt;distance-nm&gt;</code> || double || Distance from a navaid, fix or airport ||
|}


=== Example ===
=== Example ===
Line 132: Line 174:
{{main article|AI Systems#AI Models}}
{{main article|AI Systems#AI Models}}


== Related pages ==
== Related content ==
=== Wiki articles ===
* [[AI Systems]]
* [[AI Systems]]
* [[UFO from the 'White Project' of the UNESCO]]
* [[Howto:Create a flightplan]] – Contains no information whatsoever on using flightplans in FlightGear though.
* [[Interactive traffic#An example of a traffic file]] – Not flightplans per see as they only cover cruise altitude and departure and destination airport.
* [[List of Nasal extension functions#flightplan()]]
* [[List of Nasal extension functions#flightplan()]]
* [[Nasal Flightplan]]
* [[Nasal Flightplan]]
* [[PropertyList XML File]]
* [[PropertyList XML File]]
* [[Howto:Create a flightplan]], contains no information whatsoever on using flightplans in FlightGear though.
* [[UFO from the 'White Project' of the UNESCO]]
 
=== Source code ===
* {{flightgear source|src/AIModel/AIFlightPlan.hxx}}
* {{flightgear source|src/AIModel/AIFlightPlan.cxx}}
* {{flightgear source|src/Navaids/FlightPlan.hxx}}
* {{flightgear source|src/Navaids/FlightPlan.cxx}}
 
[[Category:XML]]
[[Category:Artificial intelligence]]
[[Category:Autoflight]]

Navigation menu