Skip to content

zeevoffen/msfs-vr-flight-map

Repository files navigation

πŸ—ΊοΈ MSFS VR Flight Map

Real-time flight map for Microsoft Flight Simulator 2020 β€” in your browser, in VR.

License Node.js Python

A Leaflet-powered moving map that displays your MSFS 2020 aircraft position in real time, with a glass-cockpit HUD, flight plan tracking, and waypoint navigation β€” all rendered in a browser window you can pin inside your VR headset.


πŸ“Έ Screenshots

πŸ—ΊοΈ Map Overview β€” HUD Panel

Map Overview with HUD

The main view: Leaflet moving map with the FlightDeckHUD overlay showing live telemetry β€” airspeed, altitude, heading, pitch/bank, fuel, gear/flaps, wind, and vertical speed.

πŸ“‹ Flight Plan Panel

Flight Plan Panel

Flight Plan tab: waypoint list with active leg highlighting, distance, bearing, and ETA β€” displayed alongside the route polyline on the map.

πŸ“– Bridge Setup Guide

Bridge Setup Guide

Step-by-step MSFS Bridge setup guide built right into the UI β€” no need to dig through documentation.

πŸš€ Bridge Launcher & Log Viewer

Bridge Launcher

Start/stop the Python SimConnect bridge from the browser with a live log viewer and connection status indicator.


✨ Features

  • Live Telemetry β€” Aircraft position, heading, speed, altitude, pitch/bank, fuel, gear/flaps, wind, and vertical speed streamed in real time via Server-Sent Events
  • Moving Map β€” Leaflet map with multiple tile layers (CartoDB Dark/Light, OpenStreetMap, OpenAIP airspace overlay) and a rotated plane icon that follows your heading
  • Flight Plan Panel β€” Waypoint list with active leg highlighting, distance, bearing, and ETA calculations
  • Glass-Cockpit HUD β€” Real-time flight instruments displayed in a clean overlay
  • Python SimConnect Bridge β€” Reads telemetry directly from MSFS 2020 via SimConnect SDK and serves it to the Node.js backend
  • Bridge Control UI β€” Start/stop the Python bridge from the browser with live log output
  • VR-Ready β€” Open in a browser overlay (e.g., OVR Toolkit, Desktop+) pinned in your VR cockpit

πŸ—οΈ Architecture

MSFS 2020 (SimConnect SDK)
        β”‚
        β–Ό
Python Bridge (msfs_bridge.py)
  β”œβ”€ Polls telemetry every 1–2s
  └─ Serves JSON at http://localhost:5912
        β”‚
        β–Ό
Node.js Server (server.ts)
  β”œβ”€ Express REST + SSE endpoints
  β”œβ”€ Spawns/monitors bridge subprocess
  └─ Vite dev server for React SPA
        β”‚
        β–Ό
React Frontend (src/)
  β”œβ”€ Leaflet map with tile layers
  β”œβ”€ FlightDeckHUD β€” telemetry gauges
  β”œβ”€ FlightPlanPanel β€” waypoint tracking
  └─ BridgeLauncher β€” bridge control UI

See ARCHITECTURE.md for the full system diagram and data flow details.


πŸš€ Quick Start

Prerequisites

1. Install Dependencies

npm install

2. Start the Server

npm run dev

This starts the Node.js server with Vite. The app will be available at http://localhost:3000.

3. Start the Python Bridge

Make sure MSFS 2020 is running, then either:

  • From the browser β€” Click the "Start Bridge" button in the Bridge Launcher panel
  • From the terminal:
    python bridge/msfs_bridge.py

The bridge connects to MSFS via SimConnect and begins streaming telemetry to the server.

4. Open in VR

Use your VR browser overlay tool (OVR Toolkit, Desktop+, etc.) to pin http://localhost:3000 inside your cockpit view.


πŸ“ Project Structure

msfs-vr-flight-map/
β”œβ”€β”€ server.ts                  # Express + Vite server, SSE telemetry, bridge process manager
β”œβ”€β”€ bridge/
β”‚   └── msfs_bridge.py         # Python SimConnect bridge
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ App.tsx                # Root component with Leaflet map, sidebar, telemetry state
β”‚   β”œβ”€β”€ main.tsx               # React entry point
β”‚   β”œβ”€β”€ index.css              # Tailwind CSS
β”‚   β”œβ”€β”€ types.ts               # TypeScript type definitions
β”‚   β”œβ”€β”€ components/
β”‚   β”‚   β”œβ”€β”€ FlightDeckHUD.tsx       # Telemetry gauges overlay
β”‚   β”‚   β”œβ”€β”€ FlightPlanPanel.tsx     # Waypoint list & navigation info
β”‚   β”‚   β”œβ”€β”€ BridgeLauncher.tsx      # Bridge start/stop & log viewer
β”‚   β”‚   └── MSFSBridgeGuide.tsx     # Step-by-step setup instructions
β”‚   └── utils/
β”‚       β”œβ”€β”€ bearing.ts              # Bearing calculation utility
β”‚       └── bearing.test.js         # Bearing unit tests
β”œβ”€β”€ ARCHITECTURE.md            # Full architecture documentation
β”œβ”€β”€ vite.config.ts             # Vite configuration
β”œβ”€β”€ tsconfig.json              # TypeScript configuration
└── package.json

πŸ› οΈ Available Scripts

Command Description
npm run dev Start the development server (Express + Vite)
npm run build Build for production (Vite + esbuild)
npm run start Run the production build
npm run lint Type-check with TypeScript compiler
npm run test Run bearing utility tests

πŸ”§ Configuration

The Python bridge runs an HTTP server on http://localhost:5912 by default. The Node.js server expects to find it there. You can configure the bridge port and other settings in bridge/msfs_bridge.py.


πŸ“„ License

MIT

About

πŸ—ΊοΈ Real-time flight map for Microsoft Flight Simulator 2020 in VR. Leaflet-powered moving map with live telemetry via Python SimConnect bridge, flight plan tracking, and a glass-cockpit HUD β€” all in your browser.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors