Jump to content
The simFlight Network Forums

Recommended Posts

Posted

I searched the forum but came up with nothing useful - I am currently trying to read as much aircraft information on AI-Traffic using FSUIPC 4.16 as I can. My little C# Program works fine reading the data blocks D040/E080 & D840/F080 - that gives me almost all information I want but I am missing a possibility to retrieve the current transponder (squawk) codes for the AI-Traffic... is there any way to get to this information?

I checked out SimConnect and was wondering if that would be a way but honestly, if I'd start using the SimConnect Interface, I would not need to use the FSUIPC Interface at all... (which I find easier to work with).

By the way: I noticed in the FSUIPC4 Offset Document that (i.e. the D040-Section) the formula for conversion is given as "*65536 / 360" - shouldn't that be the other way round: "/65536 * 360"?

Andreas

Posted
I searched the forum but came up with nothing useful - I am currently trying to read as much aircraft information on AI-Traffic using FSUIPC 4.16 as I can. My little C# Program works fine reading the data blocks D040/E080 & D840/F080 - that gives me almost all information I want but I am missing a possibility to retrieve the current transponder (squawk) codes for the AI-Traffic... is there any way to get to this information?

It may well be possible, but as far as I'm aware the information isn't specifically useful as I didn't think AI traffic bothered to use the transponder. In fact nothing in FS itself really uses it -- external programs such as Radar Contact and of course the on-line flight programs do, but they are dealing with user-flown aircraft.

I checked out SimConnect and was wondering if that would be a way but honestly, if I'd start using the SimConnect Interface, I would not need to use the FSUIPC Interface at all... (which I find easier to work with).

It wouldn't be at all easy to add transponder details, assuming they are available, as the data structures are rather overfilled as it is, and expanding them is not an option because of current program compatibility. Maybe I could make the values available on a specific request basis, similar to the way the full string data is provided. but this is a lot of work. I'd really like to understand your reasons, please.

By the way: I noticed in the FSUIPC4 Offset Document that (i.e. the D040-Section) the formula for conversion is given as "*65536 / 360" - shouldn't that be the other way round: "/65536 * 360"?

It surely depends on which way you view it. For instance:

"Autopilot heading value, as degrees*65536/360" for offset 07CC is correct -- the formula says how the value is created from degrees. Whilst 0578 is worded "Heading, *360/(65536*65536) for degrees" implying that the formul is how you convert back to degrees.

In the D040 section the wording is "in degrees * 65536 / 360", which is perfectly correct. Take your degrees, multiply by 65536 and divide by 360 and you get the value in those locations.

Please always read the words around the formula which provide the correct context! (I'm sorry it isn't consistent throughout, but the document has been derived over many years bit by bit, not composed from scratch as a single work).

Regards

Pete

Posted

Hi Pete,

thanks for the input - you are right, usually the Transponder Codes would not matter in any way... unless you'd like to display the Squawks of Multiplayer Aircrafts which at least for FSX - I did not test FS2004 - are nicely reported through the same tables as it seems. Anyway, thanks for the reply and thanks for the great efforts you are putting into that great tool of yours...

Andreas

Posted

... unless you'd like to display the Squawks of Multiplayer Aircrafts which at least for FSX - I did not test FS2004 - are nicely reported through the same tables as it seems.

Hmm. FSX "MP" aircraft, yesthey are created via the AI interface of SimConnect I think, by programs like Squawkbox and FSInn? They are not true MP.

I can see the possible use of the Squawk code there. I'll put it on my list for consideration. Maybe I can find a way to fit it in, somehow.

Regards

Pete

Posted
... usually the Transponder Codes would not matter in any way... unless you'd like to display the Squawks of Multiplayer Aircrafts which at least for FSX - I did not test FS2004 - are nicely reported through the same tables as it seems.

It occurred to me that for MP aircraft there isn't a filed Flight Plan for ATC in the local PC, so the fields for source and destination ICAO codes are unused. Perhaps I could put a character version ("nnnn") of the Transponder Code into the Destination field? It would show as a numeric in my own TrafficLook progra too, then.

What do you think? Are you able to test such a change (FSX only) if I incorporate it?

Regards

Pete

Posted

Hi Pete,

thanks for your consideration - and my apologies for responding a bit late. I have been working a little bit with the .NET DLL in the meantime and that kept me busy... still sort of "probing my possibilites..."

It occurred to me that for MP aircraft there isn't a filed Flight Plan for ATC in the local PC, so the fields for source and destination ICAO codes are unused. Perhaps I could put a character version ("nnnn") of the Transponder Code into the Destination field? It would show as a numeric in my own TrafficLook progra too, then.

True, the ICAO Codes for both Departure and Arrival Airport are empty for MP-Aircraft and that (at least to my observations) might be the case as well for aircraft spawned through FSX's MP-Interface.

However, putting something into the code tables that would only be valid for MP-Aircraft seems a bit odd to me - I was going through your documentation several times to look up things and one thing I did not get to work yet (but sounds promising) is what you labelled as "TCASid option" - I got it to work through the UI-Setting and Trafficlook but did not try in my own code yet.

What do you think of just adding another option (i.e. 6 = Transponder Code) like you did for the other Items 0-5? Maybe that would provide a way of getting this aircraft detail in without changing the behaviour of the existing items?

What do you think? Are you able to test such a change (FSX only) if I incorporate it?

I'd be honoured to :) - wouldn't matter to me that it is "just" FSX-only although the beauty of FSUIPC currently seems to be that it would work against both versions?

Andreas

Posted

However, putting something into the code tables that would only be valid for MP-Aircraft seems a bit odd to me

Well, not if it was only applicable to MP aircraft, like this.

What do you think of just adding another option (i.e. 6 = Transponder Code) like you did for the other Items 0-5? Maybe that would provide a way of getting this aircraft detail in without changing the behaviour of the existing items?

That's actually a lot more work. I've just done it the way I suggested -- basically, if an aircraft has got to or past the initial taxi-out stage and hasn't been assigned a destination airport yet, then I assume it isn't under local FS ATC control. Then, if there's a non-zero Transponder code set, I provide it in place of the destination ICAO, as 4 printables.

This means it is immediately visible in places like TrafficLook, but doesn't adversely affect any known program.

I'd be honoured to :) - wouldn't matter to me that it is "just" FSX-only although the beauty of FSUIPC currently seems to be that it would work against both versions?

I strive to make facilities which were in FS2004 or before work in FSX, but I rarely am able to go backwards -- too much hacking involved. Each new version of FS brings new facilities, such as this. Previous versions didn't support MP aircraft as AI in any case, so it is actually impossible to do the same thing there.

Regards

Pete

Posted

I'd be honoured to :) - wouldn't matter to me that it is "just" FSX

Okay, the change I described in in version 4.168 (yes, FSX only), is now available in the FSX Downloads announcement above. Please let me know if it works okay -- I've never used Multiplayer or On-line flying programs and I'm not about to start just yet! ;-)

You should be able to view the Squawk codes in the airport "To" column in TrafficLook.

Regards

Pete

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.