SimConnect and Me - A Little (lot) of help

Hi everyone,

I’m hoping to get some help and guidance. For several weeks now, I’ve been struggling to get my connection to SimConnect to actually work. I’ve tried asking multiple AI assistants for help, but none of them have been able to figure it out either. I’ve also gone through the SDK documentation, but I still can’t seem to make any progress.

What I’m specifically trying to work with are the variables listed on this page:

GPS Variables Documentation

These include:

  • Airports
  • Airport Runways
  • Airport Approaches
  • Airport Departures
  • Airport Arrivals
  • Nearest Airport
  • Intersections
  • Nearest Intersection
  • NDB (Non-Directional Beacon)
  • Nearest NDB
  • VOR (VHF Omnidirectional Range)
  • Nearest VOR
  • Nearest Airspace
  • Messages
  • ICAO Search
  • Name Search
  • Flightplans
  • Flightplan Departures
  • Flightplan Destinations
  • Alternate Flightplan
  • Flightplan Approaches
  • Flightplan Waypoints
  • New Flightplan
  • Facilities
  • Geo Calculations

I’m wondering if anyone would be willing to help me understand what I’m doing wrong and how I can fix it. I don’t have experience with C++ or C# (honestly, I can barely spell them!), though I do have some JavaScript experience. I’m more than happy to pay for tutoring or even send you your favorite beverage(s) as a thank you!

As the saying goes, “Give a man a fish and you feed him for a day; teach a man to fish and you feed him for a lifetime.” I’d love to learn so I can eventually create something useful for myself. And if I come up with something interesting, I’d be more than happy to share it with others.

We can communicate here in the forums, or if you prefer, we can use email. Any help or advice would be greatly appreciated—I’m still stuck at square -56 and would love to finally make it to square 1!

Thank you so much for your time and consideration!

Hey there,

first of all, the variables you mentioned are very much legacy and should not be used (I’m not even sure they work via simconnect).

The facility api (SimConnect API Reference) is the correct way to access the data.

About simconnect in general, there are multiple samples provided in the sdk (both in c++ and C#). One example is the simvarwatcher. You need to install the samples for that (in msfs dev mode you can find the link like you did with the base sdk).

Guide for managed code (C# for example): Programming SimConnect Clients Using Managed Code

Explanation of the SDK samples:
https://docs.flightsimulator.com/msfs2024/html/7_Samples_Tutorials/Samples/VisualStudio/SimConnect_Samples.htm

That should help you getting started.

1 Like

Hi,

what Saschl mentioned is an excellent starting point for you to begin learning and reviewing how it works.

If you’re going to work with C#, I recommend checking out the SimvarWatcher example code. This project helped me a lot in the beginning.

1 Like

I’m feeling lost and would love to pay someone for some guidance.

Let me explain what I’m trying to do. This is likely my fault—I’m not a programmer, but I want to learn the basics so I can continue my education through online resources like YouTube. My goal is to eventually become proficient.

I want to access various GPS-related data in Microsoft Flight Simulator 2024, such as:

  • WaypointAirportDepartureName
  • NearestAirportCurrentICAO
  • NearestNdbCurrentIdent
  • FlightPlanDepartureAirportIdent
  • FlightPlanDestinationAirportIdent
  • FlightPlanDestinationName

These are just examples from the MSFS 2024 GPS Variables page. However, I’ve been advised (by @saschl) that these are legacy variables, and I should instead use the SimConnect API:

:point_right: SimConnect API Reference

Right now, terms like SDK, API, SimConnect, JavaScript, WASM, etc., are beyond my current understanding. I’m struggling to figure out the first step in setting up a working environment.

My Goal:

I want to collect specific flight data from MSFS 2024 (such as the GPS variables mentioned earlier) and write them to an L: variable so I can display or manipulate them using my Stream Deck.

What I Need:

I need help setting up a basic framework that allows me to access and work with MSFS 2024 data through SimConnect, the MSFS SDK, and JavaScript options like:

  • Facility Data: Using JS_LISTENER_FACILITY for Coherent listener API calls or the SimConnect Facilities API in WASM.
  • Flight Plan Data: Using JS_LISTENER_PLANNEDROUTE or the Planned Route API in WASM.
  • Geographical & Navigational Math: Using GeoPoint, GeoCircle, and NavMath from the MSFS Avionics Framework.

Willing to Pay for Help:

I am offering $50 for the first hour, then $25/hour for additional help if needed. Whether you can tutor me, point me in the right direction, or help me get started, I’d really appreciate it.

If you’re interested in helping a nice guy get started, I’d be eternally grateful!