Jump to content
The simFlight Network Forums

Recommended Posts

Posted

Hi,

Im trying at the moment without success to set the aircraft payload on FS2004. So far every offset I have written to for payload has resulted in a re-read of the "Current Loaded Weight" offset (0x30C0) coming back with the same value.

Here is what I have tried...

Altering Fuel Weights

This does work and is reflected in the current loaded weight. e.g. I drop the fuel mass by 5000kgs and the current loaded weight reflects this.

Altering Payload Station Data

I have tried three attempts based around the payload station data

1. Just altering the station data - the new value is reflected in both the offset (starting from 0x1400) and additionally in the FS menu. Sadly it did not change the value read back in the current loaded weight offset.

2. I then tried adding up all of the payload station weights, fuel weight and aircraft empty weight and writing this to the current loaded weight offset. This worked at first but then FS updates it back to the value that it thinks is correct. This is always the initial weight of the aircraft when loaded in FS and payload less any burnt fuel or changes to the fuel load - so again it takes the fuel into account but not the changes I have made.

3. Final attempt was to try and get FS to recompute the current loaded weight by updating the zero fuel weight. What I did here was get the basic empty mass for the aircraft, get the weight of all my payload stations add together and update it into the offset. Id hoped that what FS would do is look at this value (offset 0x3BFC) then take into account the fuel onboard and update the current loaded weight. This didnt work either.

So in summary..

- Fuel changes are correctly reflected in the current loaded weight.

- Changes to payload stations are not reflected.

- Attempts to udpate the value directly (current loaded weight) dont work.

- Attempts to update the zero fuel weight also dont work.

Totally stuck at the moment so any help appreciated! All tests done on my benchmark of the PMDG 737. The goal of my project is to get my application to load the aircraft as required for the user.

Thanks,

Tim

Posted

Update on this problem....

Ive found that if I perform my own weight calcuation of the aircraft using ..

Basic Empty Mass + Fuel + Payload (via recursing of the payload stations)

... if I then update this into 0x30C8 which is "Aircraft Mass in Slugs" the following happens:

- The aircraft weight is correctly represented in the FS "Fuel and Payload" menu.

- None of the FSUIPC offsets even 0x30C8 (which I updated a moment ago) reflect the new weight. This includes current loaded weight (30C0) and zero fuel weight (0x3BFC).

However, if I go into the FS menu and update the weights in there and re-read the offsets they show the correct values.

It looks like these offsets only "react" to changes made via the FS menus and dont show updated data if you write to them yourself although FS will show an updated weight based on what you have written to the offsets!

What am I doing wrong? :D

Tim

Posted

Im trying at the moment without success to set the aircraft payload on FS2004.

Did you miss the explicit paragraph in the documentation for this, which I think explains everything you've reported?

These loadings can be changed, and this does have some effect, but such changes are not being promulgated to the overall weights (offsets 30C0, 30C8, 3BFC) nor balance (2EF8), and it looks like they have to refreshed, as FS overrides them from time to time. It has also been reported that FS can crash if a lot of changes are made here, so care and full testing is needed.

I don't know if it is better in FSX -- I should hope so.

Pete

Posted

Hi Pete,

Yes I read that and what I thought was that changes to the payload are not propogated to the other weight offsets. This I understand.

However, what I have done is recalcuated the weights myself from the sum of the payloads and then directly updated the actual weight offsets. What I have noticed is that when updating 0x30C8 the weight is reflected in FS (that is in the FS weight and payload dialog is updated) but when re-reading this offset it goes back to its original value.

I think what you are saying is that FS then disregards my payload setting and recomputes all weight values itself from the original payload settings?

Thanks again,

Tim

Posted
... what I have done is recalcuated the weights myself from the sum of the payloads and then directly updated the actual weight offsets. What I have noticed is that when updating 0x30C8 the weight is reflected in FS (that is in the FS weight and payload dialog is updated) but when re-reading this offset it goes back to its original value.

Yes. I don't think those other offsets are really writeable, they are outputs not inputs. Writing a value there will not, I think affect the aircraft balance.

I think what you are saying is that FS then disregards my payload setting and recomputes all weight values itself from the original payload settings?

That's what others have said -- UNLESS you go into the payload menu, where you will see the values you set, and "OK" them to exit. I think there is some essential routines being carried out then which propogate the values to the places they are needed.

I'm sorry, but I never had the time nor knowledge to follow this up in any meaningful sense. But the requirement to be able to do this properly was input to MS for FSX and I think (though it is not yet proven) that the facilities should all work as desired in FSX -- except there only the station name and weight is available (not the x/y/z). The payload weights (only) are writeable via SimConnect, so they should be propagated correctly, but this is my current comment in the Offsets Status document:

These loadings can be changed, and this does have some effect, but are changes are being promulgated to the overall weights (offsets 30C0, 30C8, 3BFC) and balance (2EF8)? Needs checking in FSX.

When this has all been verified I will note that in the document. It's all as matter of finding time to do everything, or receiving feedback from those that know and try.

Regards

Pete

Posted

Thanks for the response Pete. I think what you have said is correct. Its a shame that with those offsets being outputs that FS doesnt recompute the values and provide a correct value.

I could go ahead and manage the payload myself and write the FS in the hope that FS will use that weight even though the offset gives an incorrect weight. However, Im concerned about things such as CogG position etc. If I just put a value into the offset maybe the CofG wont move. Additionally if I just update the weight how does FS know what payload stations are populated with that weight to then work out the CofG.

Do you or anyone else know of a way to set the aircraft payload correctly? If not I'll have to shelve my idea of setting the aircraft payload. I wonder how the developers do it e.g. FS Passengers - do they use the full SDK I wonder?

Also, is there anyway that FSUIPC (a future version of) could run the routines to populate and update the values? Is it a case that a routine in FS could be run or would you have to write your own code to do it? The latter probably isnt realistic.

Thanks again,

Tim

Posted

Do you or anyone else know of a way to set the aircraft payload correctly?

Maybe some, but they've not shared it.

I wonder how the developers do it e.g. FS Passengers - do they use the full SDK I wonder?

There's no "full SDK" for such things. If their payload settings do influence balance they may just have spent more time hacking into FS's code in that direction. I have had to spend my efforts over a wide base and it has been difficult to delve deeper into some areas, especially those I know nothing about.

Have you actually checked? Does a poorly loaded aircraft using FS passengers become unbalanced, needed changes in trim or even becoming uncontrollable?

Of course there are ways of simulating balance differences in any case, aren't there? Merely making additional adjustments to trim "behind the scenes" could generate similar effects to a certain extent.

Or does FSPassengers simply change the FLT file and reload the flight? Aren't the current payload settings loaded from the FLT files, with the defaults being in the Aircraft.CFG file?

Also, is there anyway that FSUIPC (a future version of) could run the routines to populate and update the values? Is it a case that a routine in FS could be run or would you have to write your own code to do it?

Of course if I knew what to do I could do it. I just have never had the time, and now I must look forward more to FSX and beyond, not try to recover extra facilities for old simulator versions. I don't mind doing things for FS9 if they are easy, but it takes many hundreds of hours disassembling and tracing through new (i.e. unknown to me) parts of FS code to see what needs doing, and I am not going to do that for a simulator now nearly five years old. Sorry.

Regards

Pete

Posted

Hi,

Well I just checked and updating the current mass offset then does change the the CofG.

Sadly the new weights were not reflected in the PMDG FMC so that sort of puts an end to it all really.

Appreciate what you are saying about FSX. At present my user base is split between FS9 and FSX so sadly I have to code for both.

In regard to FSPax as I remember you sort of hit the load aircraft button and it seems to sort it all out without any noticable reloading. Havent investigated the FLT file route yet. Is that the FS saved flight format? If anyone can point me in the right direction for these I would appreciate it. Maybe (and Im no expert) it does it via the gauage that it has on the FS display if that is even possible.

Thanks,

Tim

Posted

In regard to FSPax as I remember you sort of hit the load aircraft button and it seems to sort it all out without any noticable reloading.

You might not notice it, if it causes a flight to be loaded from a temporary flight file just saved. AutoSave saves files in the background without folks noticing, and reading one straight back would be fast as it would still be cached.

Havent investigated the FLT file route yet. Is that the FS saved flight format? If anyone can point me in the right direction for these I would appreciate it.

When you save a flight, it gets saved as a FLT file. Try setting some payloads in the menus then saving a flight. Look at the flight file with any text editor. Search for "payload" or similar.

Regards

Pete

Posted

Thanks Pete.

Ive just tried saving and loading via FSUIPC and that works. Its a pity there isnt more of a silent load - present testing shows that you get a loading progress bar - albiet a very fast one.

As you say Ill try updating the payload entires in the file and see what happens.

Ill report back on my findings - might be useful for other people following the same road in the future.

Tim

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.