So, I am trying to get a list of airports near me via simconnect. I know I’ll have to filter with my lat/lon after I get them, but thats TBD at this point.
I can either subscribe or hit the simconnect api repeatedly with RequestFacilitiesList.
Either way I go, I get the same 1243 airports in the each “entry set”. I get 30 pages of results, but they are all the same.
Has anyone else seen this?
Github to reproduce the issue, just clone it down f5 and hit connect, it will show you all the data in the little error box. I have no KCWA, KHYI, but 30 KLAXs… because it is in the results that come back for each 30 pages
I noticed, after some tinkering, that if you spawn at a new airport you are more likely that your airport will show up in that list.
if you terminate the connection to SimConnect (while leaving the sim up) and reconnect, you get that basic 1243 again…
You can repeat that cycle over and over.
Going back to main menu, spawning back at that same airport doesn’t get you the list with your airport in it either, its only on the “first” load to that airport.
I’d expect that the subscription would return all the airports or N of the ones closest to me.
I tried slewing around the area after loading in, and the subscription works, but I don’t know what the cutoff is for its search area to return new airports.
Hey, I’ve been here before & this isn’t where I parked my car.
This functionality seems to be broken. I’ve submitted a ticket also. You may also want to submit a ticket. I have not found a work around for it either.
I installed LittleNavMap, and wrote a sqlite query to get what I needed until this is fixed, since they have a sqlite db with all the nav data and frequencies as well. .
Hey there! I just stumbled over this issue today as well (Zendesk ticket created):
Subscribing to the airport facilities list kind of works, but only returns very few airports (excluding the one I was looking for). And it still returns initially 30 times the same „Same Airstrip“.
Now that I just realised - according to the C:\Program Files\Little Navmap\little_navmap_db\README.txt - that the little_navmap_navigraph.sqlite is actually placed in a well-known location, namely:
select *
from airport a
where a.name like '%Same%'
3794 1 HTSE Same AFR HT [...] 37.7000007629395 -4.08333349227905
Ah! Even the Same Airstrip is available - the same Same Airstrip that we initially get 30 times with the SubscribeToFacilities results (and the only 30 results that we get with RequestFacilitiesList), with the same lat / lon coordinates.
I will probably go for a “mixture” like:
If Little Navmap DB is installed: use it (skip the following points)
SubscribeToFacilities, store the received airports in an unsorted hashmap (key: ICAO, value: airport data) and at the end of the flight see whether we get some meaningful results out of this (that is, iterate over the hashmap and compare the start / end coordinate of the flight with the coordinates of the airports: if within a given threshold distance → that’s the airport we flew from/to)
Try again with GPS WP NEXT ID and GPS WP PREV ID and see whether we get values here (last time I tried with SimvarWatcher to get those as “string variables” I received empty values, even though I had setup a simple FROM / TO flight plan on the FS 2020 world map - maybe the aircraft needs to have a “GPS navigation device” built in in order to get actual values here? Or “GPS / NAV / autopilot” needs to be engaged?)
But jeez! All this in order to get two simple ICAO code values, of the start and end airports (if started / landed) of the flight…
That sounds cool. I am developing a flight replay application and am currently looking into adding additional information to the saved flights, in this context here the ICAO codes of the start and destination.
Just out of curiosity: are the radio / communication streams freely available, as some MP3 (or other compressed audio format) stream? Much like radio stations?
Ah, I understand: a web service “for friends and families” then That’s what I thought (streaming all the radio communications for free would cost quite some bandwidth, I guess). Unless such a service is paid I guess the bandwith requirements would exceed a “private developer’s budget”.