On Wed, 06 Jan 2021 20:52:13 +0100 deloptes deloptes@gmail.com wrote:
Stefan Krusche via tde-users wrote:
I had a look into it…
$ grep Berlin /opt/trinity/share/apps/kweatherservice/stations.dat
EDDB;10;385;Berlin-Schoenefeld;;Germany;6;52-23N;013-31E;52-23N;013-31E;47;50;P
EDDI;10;384;Berlin-Tempelhof;;Germany;6;52-28N;013-24E;52-29N;013-25E;50;49;P
EDDT;10;382;Berlin-Tegel;;Germany;6;52-34N;013-19E;;;37;37; KBML;72;616;Berlin, Berlin Municipal Airport;NH;United States;4;44-34-34N;071-10-43W;44-34-41N;071-10-49W;353;345;
Now the question is: why does Berlin-Schönefeld not show up in the list which kweather offers to choose stations from?
BTW, is there any documentation of the format of this file? Is it also retrieved from noaa.gov? Or created dynamically?
Better look into the code. The code uses
https://tgftp.nws.noaa.gov/data/observations/metar/stations/
and whatever your mapping is - so it might be we need update for a mapping for Berlin if the DB @noaa.gov was updated.
I have no idea what corresponds to Berlin-Schoenefeld. Is Berlin-Schoenefeld the new airport there? I heard lately in the news they managed to finish and open it, but not exactly sure which is the new one.
and may be we have to check the date of the data and display a warning if it is not recent enough.
A quick check of Wikipedia shows that Berlin Schönefeld is now part of Berlin Brandenburg Airport (the "new airport"), which has inherited Schönefeld's ICAO code but has a different IATA code.
The first element of the lines in the stations.dat file is the airport or weather station ICAO code, second and third seem to be the WMO ID code, fourth is city, fifth is US state (if the location is in the US), sixth is country, seventh I'm not sure of (possibly a numeric code for "continent" or similar), 8-11 are location (latitude and longitude), 12-13 are probably elevation (min-max? above sea level, in meters), and I'm not sure about the trailing slot that sometimes has a P in it (it may have something to do with whether or not the station is permanently manned, but not all countries seem to use it). The file is stored verbatim in git, so it isn't being created programmatically and might easily be out-of-date.
The important identifiers are probably the first three slots. Since Schönefeld and Brandenburg both have ICAO code EDDB, it's possible that it's the WMO code that needs to be changed from 10385 to whatever Brandenburg's been issued, if it's different. Or it may just be that the system is confused by the existence of what are technically two different entities using EDDB as ICAO code—I don't think those codes are usually reissued.
E. Liddell
--------------------------------------------------------------------- To unsubscribe, e-mail: trinity-users-unsubscribe@lists.pearsoncomputing.net For additional commands, e-mail: trinity-users-help@lists.pearsoncomputing.net Read list messages on the web archive: http://trinity-users.pearsoncomputing.net/ Please remember not to top-post: http://trinity.pearsoncomputing.net/mailing_lists/#top-posting