Jump to content
The simFlight Network Forums

Offset 0x0330 problem


Recommended Posts

Hi

I was using this offset to read and write reference pressure. Everything was ok except fact I could read range only from 1000 hPa and whatever below still I am reading 1000 hPa. FSUIPC 4.40 registered

Then I downloaded FSUIPC 4.60

and now my reading is like that: 1062485632 for 1000 hPa in fsx

Am I missing something?

Thanks for help.

Link to comment
Share on other sites

and now my reading is like that: 1062485632 for 1000 hPa in fsx

Am I missing something?

1062485632? Obviously you are missing something pretty fundamental. Offset 0330 is only a 16-bit value (occupying 2 bytes), with a maximum possible unsigned value of 65535, so you are making some serious error in reading it, and therefore probably in writing it too.

Use the tools available. FSUIPC provides IPC read and write logging and FSInterrogate allows you to play to your heart's content with any offsets.

Pete

Link to comment
Share on other sites

with a maximum possible unsigned value of 65535, so you are making some serious error in reading it, and therefore probably in writing it too.

That's right Pete, I know that is out of 16-bit integer. But the question is why that's happend after installing new FSUIPC4.60. With 4.40 version reading was correct 16-bit only? I was thinking, probably something has changed in nev version and this is the reason.

Anyway I will check with FSInterrogate as you suggest.

Thank you

Marcin

Link to comment
Share on other sites

I know that is out of 16-bit integer. But the question is why that's happend after installing new FSUIPC4.60. With 4.40 version reading was correct 16-bit only?

Maybe the offset after 0330 now comes into play? Either way it is irrelevant. If you are getting a value greater than 65535 from a 16-bit quantity the error is in your program in how you are reading or interpreting the results. I suggest you use a debugger appropriate to the compiler and language you are using.

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.