Jump to content
Sign in to follow this  
Guest roland_lfor

Metar questions for Davis Sandberg (SquawkBox weather)

Recommended Posts

Guest roland_lfor

Hi David,With the help of Lefteris Kalamaras, I'm now officially part of the Protodev group. So I have their agreement to continue the SquawkBox development for Fly! II.I have many idea of enhancement of course and first of all, I've tried to implement automatic weather retreiving from the virtual ATC environment.At the moment I have to download the metar from the nearest airport, then save it a temp file to ask fly! to load it.- 1. it's not an elegant and fast solution (temp file use)- 2. the importation (APILoadMetar() ) seems to be buggy, even with last patch.I know you are the specialist of metar in Fly!, and probably know all the input value to be corrected before Fly! importation.So could you teach me how to extract the useful data from a single airport metar line, or send me a code example ?The goal is to send them directly with the APISetWeatherInfo() function.Then I'll be able to code it directly inside SB.I beleive it could be a real improvement for online flying.Thanksmy e-mail : rolby@tele2.fr

Share this post


Link to post
Share on other sites
Guest DSandberg

Hi. Sorry I didn't see your question right away. (Thanks to Randall Rocke for pointing it out to me.)There is a "standard" decoder for U.S. format METARs created by NOAA (using the C language) and called MDSP ("METAR Decoder Software Package") that can be freely obtained. Be forewarned that the code isn't pretty and has lots of problems, but in combination with the METAR coding specifications it should give you enough information to either modify their code or write your own. But be prepared to do some extra legwork to figure out how to handle various international METARs as opposed to U.S. ones), as finding documentation on the varied standards used in some nations proved difficult at best for me. I researched these differences for a long time and via many sources, and still ended up having to handle a few of the differences through "educated guesses".Here's where to get the Federal Meteorological Handbook (FCM-H1-1995) that includes the complete coding spec for U.S. METARs (in chapter 12):http://www.ofcm.noaa.gov/fmh-1/pdf/fmh1.pdfUPDATE: I just dug out the former location for the source code for the MDSP software that I was talking about. It used to be available at the following URL:http://www.nws.noaa.gov/oso/metardcd.shtmlUnfortunately it looks like the actual download links there no longer work in the wake of NOAA's major site transition of a couple of years ago. However, the program can now also be had (as a compressed tarball) at the following URL:http://limulus.net/mdsplib/It looks like the version at this 2nd website has been edited slightly. I haven't tried it so I don't know if it is the same, better or worse than the older version I'd looked at.I apologize, but I cannot send you my proprietary InfoMETAR sources for decoding METARs. I spent months developing my decoder from scratch as a more robust alternative to the government's public code, and it has a potential monetary value to me even though InfoMETAR is freely distributed.[table cellspacing=0 cellpadding=0][tr][td width=320]http://www.usinternet.com/users/mystic/infomsig.gif[/td][/tr][/table]

Share this post


Link to post
Share on other sites
Guest roland_lfor

Thanks for your answer David,I understand well your opinion , no problem with that.But could you just tell me what corrections I have to apply to the weather parameters, before importing them in Fly!, regarding the known weather importation problems ?

Share this post


Link to post
Share on other sites
Guest DSandberg

Rather than me typing up all of the info about the known problems and their corrections, it would be much easier for you to just read the text of InfoMETAR's help file about each of the "METAR Modification Options" (in the "Saving METARs" chapter), as they detail the various problems quite extensively. Other than those documented modifications, InfoMETAR does very little outside of its "thinning" algorithm, and the latter shouldn't be applicable in your case at all since you are evidently planning to set the weather globally instead (something that is probably a very good idea, given Fly II's various misbehaviors with METARs).Best of luck to you![table cellspacing=0 cellpadding=0][tr][td width=320]http://www.usinternet.com/users/mystic/infomsig.gif[/td][/tr][/table]

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Tom Allensworth,
    Founder of AVSIM Online


  • Flight Simulation's Premier Resource!

    AVSIM is a free service to the flight simulation community. AVSIM is staffed completely by volunteers and all funds donated to AVSIM go directly back to supporting the community. Your donation here helps to pay our bandwidth costs, emergency funding, and other general costs that crop up from time to time. Thank you for your support!

    Click here for more information and to see all donations year to date.
×
×
  • Create New...