Skip to contents
library(rddr)
library(data.table)
#> 
#> Attaching package: 'data.table'
#> The following object is masked from 'package:base':
#> 
#>     %notin%

Introduction

The rddr package is a comprehensive parser for the proprietary text formats used in aviation tools like SAAM, Gasel, and Airspace Editor. This guide covers every supported file format, grouped by functional category.


1. Network Infrastructure

These files define the static “hardware” of the network: airports, points, and runways.

Airports (.arp)

Basic airport definitions including coordinates and FIR association.

airports <- read_arp("data/network.arp")
#    icao     lat      lon     fir_id
# 1: LFPG 49.0097   2.5479   LFFF_FIR

Extended Airport Metadata (.narp)

Includes sequencing parameters crucial for capacity analysis: Taxitime, TIS (Time to Insert), and TRS (Time to Remove).

narp <- read_narp("data/network.narp")
# Check taxi times for specific airports
head(narp[, .(icao, taxitime, tis, trs)])

Defines Waypoints, VORs, and NDBs.

points <- read_nnpt("data/points.nnpt")
head(points)

Standard Instrument Departures (.sid)

Maps an airport (ICAO) to a list of allowed departure points.

sids <- read_sid("data/airports.sid")
# Find all SIDs for Brussels
brussels_sids <- sids[icao_apt == "EBBR"]

Runway Configurations (.runway)

Defines which runways (QFUs) are active during specific time windows and their sequencing capabilities.

runways <- read_runway("data/airport.runway")

# Find the default configuration for today
today_cfg <- runways[is_default == TRUE]

2. Airspace Geometry & Structure

These files define the 3D shape and hierarchy of the airspace.

2D Geometry (.are)

Defines the lat/lon polygon vertices for “Volumes” (Airblocks).

geometry <- read_are("data/sectors.are")
# Returns an ordered sequence of points ready for polygon creation
head(geometry)

Sector Definitions (.sls)

Links the 2D Volumes (.are) to vertical Flight Level limits to create 3D Elementary Sectors.

sectors <- read_sls("data/sectors.sls")
# See which volume corresponds to a sector and its FL limits
head(sectors[, .(sector_id, volume_id, fl_bottom, fl_top)])

Airspace Hierarchy (.spc)

Defines the parent-child relationships (e.g., ACC contains Sectors, Sectors contain Elementary Sectors).

hierarchy <- read_spc("data/airspace.spc")

# Find all children of the "LFMM" ACC
lfmm_components <- hierarchy[airspace_id == "LFMM"]

Sector Visualization (.aco)

Defines display attributes like RGB colors and transparency for airblocks.

colors <- read_aco("data/airspace.aco")

3. Operations & Configurations

These files control how the airspace is managed dynamically over time.

Configurations (.cfg)

Crucial for Capacity Planning. This file defines named “Configurations” (e.g., CONF_A, SPLIT_NORTH) by listing exactly which elementary sectors are open/collapsed together.

# Load configuration definitions
configs <- read_cfg("data/sectors.cfg")

# Example: Inspect what sectors make up the "CONF_1A" configuration for "LFFF"
my_config <- configs[acc_id == "LFFF" & config_id == "CONF_1A"]
print(my_config)
#    acc_id config_id    sector_id
# 1:   LFFF   CONF_1A     SECTOR_1
# 2:   LFFF   CONF_1A     SECTOR_2

Opening Scheme (.cos)

The “Calendar” of the airspace. It maps a specific date and time window to a Configuration ID defined in the .cfg file.

schedule <- read_cos("data/opening_scheme.cos")

# What configuration is active on 2024-06-01 at 09:00?
active <- schedule[
  date == "2024-06-01" & 
  start_time <= "0900" & 
  end_time >= "0900"
]

Military Opening Times (.mot)

Defines activation windows for military zones (TSA/TRA/CDR). This function automatically handles Version 1, 2, and 3 file formats.

military <- read_mot("data/military.mot")

4. Traffic Flow & Routing

These files define how aircraft move through the network.

Routes (.rts)

Defines the sequence of points that make up an airway.

routes <- read_routes("data/network.rts")

Traffic Volumes (.ntfv)

Defines complex flow filters (Traffic Volumes) used for capacity monitoring. It parses flow logic like IN, EX (Exclude), and AD (Aerodrome) filters.

tvs <- read_ntfv("data/traffic.ntfv")

Airport Groups (.soa)

Defines sets of airports (e.g., PARIS_METRO). Use resolve_recursion=TRUE to automatically flatten nested groups into a simple list of airports.

groups <- read_soa("data/groups.soa", resolve_recursion = TRUE)

5. Rules & Logic (Advanced)

These files contain pseudo-code logic. rddr parses these into structured data tables, extracting Regex patterns and boolean flags.

Flight Level Constraints (.flc2)

Defines constraints on flight levels (Max/Min/Equal) based on entry/exit points.

# parse_rules=TRUE extracts columns like 'condition_dep' and 'constraint_value'
flc <- read_flc2("data/constraints.flc2", parse_rules = TRUE)

RAD Routing Rules (.awk)

Defines Routing Restrictions (RAD).

rad <- read_awk("data/routing.awk", parse_rules = TRUE)

# Filter for rules that force a specific route (REGLE)
forced_routes <- rad[constraint_type == "ROUTING"]

Route Extension Exceptions (.rlex)

Exceptions where standard route length validation is relaxed.

exceptions <- read_rlex("data/extensions.rlex")

6. Penalties & Costs

Used for route optimization and simulation.

Turn Penalties (.tax)

Defines forbidden or penalized turns (Point A -> Point B -> Point C).

turns <- read_tax("data/penalties.tax")

Segment Costs (.pnl)

Defines additional nautical mile (NM) penalties for traversing specific segments.

costs <- read_pnl("data/costs.pnl")