How anviktor2411/xradio works
XRadio is an X-Plane multiplayer and radio product: pilots configure or host a flight, the plugin exchanges aircraft/session data with a UDP relay, and clients render traffic and route frequency-based voice. The product also includes ATC stations, flight plans, ATIS, shared weather, router-assisted hosting, and an optional standalone Python relay. The README and excerpts establish the main workflow; several feature-specific source files were not sampled, so their internal call paths are omitted rather than inferred.
Main entry points: main.cpp Plugin runtime · server.cpp Embedded relay · protocol.h Wire protocol · voice.cpp Voice capture and playback
Components 23
Flight plugin
- Plugin runtime
plugin/src/main.cpp - UDP networking
plugin/src/net.cpp - Settings
plugin/src/settings.h - Voice capture and playback
plugin/src/voice.cpp - Traffic rendering
plugin/src/xpmp_bridge.h - Position interpolation
plugin/src/smoothing.h
Relay and protocol
- Wire protocol
plugin/src/protocol.h - Embedded relay
plugin/src/server.cpp - Radio routing
plugin/src/radio.h - Standalone relay
server/server.py - Python wire protocol
server/protocol.py
Aviation features
- Shared weather
plugin/src/weather.h - ATC and flight data
plugin/src/tower.cpp - Tower data parsing
plugin/src/tower_parse.cpp - Flight-plan import
plugin/src/simbrief.cpp
Pilot interface
- Plugin windows
plugin/src/ui2/app_ui.cpp - Tower windows
plugin/src/ui2/tower_ui.cpp - Tower view model
plugin/src/ui2/tower_model.cpp
External services
- Home router
- GitHub releases
- Audio devices
Other components
- Pilot
- X-Plane
Connections 24
- Pilot → Plugin runtime: configures and flies
- X-Plane → Plugin runtime: provides sim state
- Plugin runtime → UDP networking: sends UDP
- Plugin runtime → Wire protocol: encodes packets
plugin/src/main.cpp - Plugin runtime → Embedded relay: hosts relay
- Plugin runtime → Settings: applies configuration
plugin/src/main.cpp - Plugin runtime → Voice capture and playback: routes voice frames
plugin/src/main.cpp - Voice capture and playback → Audio devices: captures and plays
- Plugin runtime → Traffic rendering: drives traffic display
plugin/src/main.cpp - Traffic rendering → Position interpolation: interpolates reports
- Plugin runtime → Shared weather: shares weather
plugin/src/main.cpp - Plugin runtime → ATC and flight data: handles ATC features
- ATC and flight data → Tower data parsing: parses tower data
- Plugin runtime → Flight-plan import: imports flight plans
- Embedded relay → UDP networking: owns UDP socket
plugin/src/server.cpp - Embedded relay → Wire protocol: processes packets
plugin/src/server.cpp - Embedded relay → Radio routing: routes frequencies
plugin/src/server.cpp - Standalone relay → Python wire protocol: uses protocol
server/server.py - Wire protocol → Python wire protocol: mirrors definitions
- Pilot → Plugin windows: uses settings windows
- Plugin windows → Tower windows: offers tower views
- Tower windows → Tower view model: uses view model
- Plugin runtime → Home router: requests port mapping
- Plugin runtime → GitHub releases: checks releases