Skip to content

ronaldvdmeer/ATC-Trainer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ATC-Trainer ✈️

Project Status JavaScript Bootstrap License

Practice realistic air traffic control communication — A modern, standalone web application for aviation enthusiasts, pilots, and ATC students.

The ATC-Trainer generates realistic pilot and ATC phraseology for various flight phases. It runs 100% in your browser with no backend required, featuring live VATSIM ATIS integration and optional OpenAI-powered ATIS analysis.

Report Bug | Request Feature


✨ Features

Core Functionality

  • 📡 Multi-frequency Support — Delivery, Ground, Tower, Departure, Center, and Approach
  • 💬 Realistic Phraseology — Auto-generates pilot, ATC, and readback phrases following ICAO standards
  • 🔄 Dynamic Form Fields — Context-aware input fields that change based on frequency and request type
  • 🎯 Smart Formatting — Automatic NATO alphabet conversion, runway formatting, and digit separation

ATIS Integration

  • 🌐 Live VATSIM Data — Fetches real-time ATIS from VATSIM network (60s cache)
  • 🤖 AI Analysis (optional) — OpenAI-powered ATIS summarization and runway extraction
  • 📍 300+ Airports — Built-in ICAO-to-airport name mapping

User Experience

  • 🎨 Modern Dark Theme — Glassmorphism design with aviation-inspired colors
  • 💾 Persistent Storage — Saves all inputs with configurable TTL (default 30 min)
  • Live Validation — Highlights empty required fields in real-time
  • 📱 Fully Responsive — Works seamlessly on desktop, tablet, and mobile

Technical

  • Zero Dependencies — No Node.js, no build step, no backend server
  • 🔒 Privacy First — API keys stored locally, never sent anywhere except OpenAI
  • 🚫 No Tracking — No analytics, no cookies, no data collection

🚀 Quick Start

Run Locally:

  1. Clone the repository

    git clone https://github.com/ronaldvdmeer/ATC-Trainer.git
    cd ATC-Trainer
  2. Open in browser

    # Simply open index.html in any modern browser
    # Windows
    start index.html
    
    # macOS
    open index.html
    
    # Linux
    xdg-open index.html
  3. (Optional) Configure OpenAI

    • Click Settings at the top
    • Enter your OpenAI API key
    • Select your preferred model (gpt-4o-mini recommended)
    • Click Save

📖 Usage Guide

Basic Workflow

  1. Select Frequency — Choose from Delivery, Ground, Tower, Departure, Center, or Approach
  2. Select Request Type — Pick a specific operation (e.g., Clearance, Pushback, Lineup)
  3. Fill Parameters — Enter flight details (callsign, gate, squawk, runway, etc.)
  4. View Communication — Phraseology appears automatically in the communication log

ATIS Features

  • Enter an origin ICAO code (e.g., EHAM) → loads live VATSIM ATIS
  • Enter a destination ICAO code → loads arrival ATIS
  • With OpenAI configured → automatic runway and info letter extraction

Example Scenario

Frequency: Delivery
Request: Clearance
Parameters:
  - Callsign: KLM1234
  - Origin: EHAM
  - Destination: LFPG
  - Gate: D5
  - ATIS: K
  - Departure Route: BERGI1A
  - Runway: 18C
  - Squawk: 2401

Generated:
  Pilot: "Amsterdam delivery, good day, KLM1234, at stand Delta 5, 
          with information Kilo, requesting clearance to Paris Charles de Gaulle."
  
  ATC: "KLM1234, cleared to Paris Charles de Gaulle, via BERGI1A, 
        departure runway One Eight Center, squawk 2 4 0 1."
  
  Readback: "Cleared to Paris Charles de Gaulle via BERGI1A, runway One Eight Center,
             squawk 2 4 0 1, KLM1234."

🏗️ Project Structure

ATC-Trainer/
├── index.html              # Main HTML structure
├── css/
│   └── styles.css          # Custom dark aviation theme (on top of Bootstrap)
├── js/
│   ├── config.js           # Configuration (API URLs, subcategories, field definitions, ICAO data)
│   └── app.js              # Application logic (classes, ATIS fetcher, OpenAI, UI handlers)
└── README.md               # This file

Key Components

  • ATISDataFetcher — Fetches VATSIM data with 60s cache
  • ChatGPTAnalyzer — OpenAI chat completion wrapper
  • StorageManager — localStorage wrapper with TTL support
  • Utility — Static helpers (NATO alphabet, runway formatting, validation)
  • FieldManager — Dynamic Bootstrap grid field generation
  • CommunicationGenerator — Phraseology builder and table updater

🔧 Configuration

OpenAI API (Optional)

The app works without OpenAI, but ATIS analysis requires it:

  1. Get an API key from OpenAI Platform
  2. Open Settings in the app
  3. Paste your key (stored in localStorage)
  4. Choose a model:
    • gpt-4o-mini (default) — Fast, cheap, good for ATIS
    • gpt-4o — More capable, higher cost
    • gpt-4-turbo — Balanced performance
    • gpt-3.5-turbo — Budget option

Privacy: Your API key never leaves your browser except for direct OpenAI API calls. It's not sent to any other server.

Field Expiry

Default TTL is 30 minutes. Stored in localStorage with each field value.


🛠️ Browser Requirements

  • Chrome 90+ (recommended)
  • Firefox 88+
  • Edge 90+
  • Safari 14+

Required Features:

  • ES2022 (private class fields #field)
  • Fetch API
  • LocalStorage
  • CSS backdrop-filter (for glassmorphism)

🤝 Contributing

Contributions are welcome! Here's how:

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

Development Guidelines

  • Follow existing code style (ESLint: no semicolons except required)
  • Use Bootstrap 5 utilities where possible
  • Keep CSS custom properties for theming
  • Test in multiple browsers
  • Update README if adding features

📝 License

This project is licensed under the MIT License — see the LICENSE file for details.


🙏 Acknowledgments

  • VATSIM — For providing public ATIS data via data.vatsim.net
  • Bootstrap 5 — For the dark theme foundation
  • OpenAI — For GPT models powering ATIS analysis
  • Aviation Community — For feedback and phraseology validation

📬 Contact & Support


Made with ❤️ for the aviation community
For training purposes only — not for real-world ATC operations

About

The ATC Phraseology Generator generates realistic pilot and ATC phraseology for various flight phases. It runs 100% in your browser with no backend required, featuring live VATSIM ATIS integration and optional OpenAI-powered ATIS analysis.

Topics

Resources

License

Stars

Watchers

Forks

Contributors