Jump to content
The simFlight Network Forums

METAR through FSUIPC


Recommended Posts

Hello,I want to use FSUIPC to write some METAR for fixed airports in FSX. I have read the FSUIPC4 Offsets Status.pdf document which gives some information about the area where to copy data, but i'm not sure to fully understand... Suppose I want to send the following METAR: KSEA 030405Z 27007KT 15SM SKC 17/13 A2992. I copy this string is into a string variables named Metar[]. Should I use the following API at the following 0xB000 offset ?

FSUIPC_Write(0xB000, 42, (void *)Metar, &dwResult);

FSUIPC_Process(&dwResult); Or am I completly wrong ?

Link to comment
Share on other sites

Hello,I want to use FSUIPC to write some METAR for fixed airports in FSX. I have read the FSUIPC4 Offsets Status.pdf document which gives some information about the area where to copy data, but i'm not sure to fully understand... Suppose I want to send the following METAR: KSEA 030405Z 27007KT 15SM SKC 17/13 A2992. I copy this string is into a string variables named Metar[]. Should I use the following API at the following 0xB000 offset ?

FSUIPC_Write(0xB000, 42, (void *)Metar, &dwResult);

FSUIPC_Process(&dwResult); Or am I completly wrong ?

I'd use "strlen(Metar)+1" instead of 42. The length must include the zero terminator.

For the METAR format needed, please refer to the SImConnect SDK -- function SimConnect_WeatherSetObservation. FSUIPC simply passes your string to that function. I think you might get away with:

KSEA METAR 030405Z 270007KT 15SM SKC 17/13 A2992

Don't forget, if you are writing a lot, do the Writes first with one Process at the end.

Regards

Pete

Link to comment
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
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use. Guidelines Privacy Policy We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.