Tom Stian

TCAS CleanUp for the IXEG 733 - LUA Script

16 posts in this topic

TCAS CleanUp for the IXEG 733.
This script is ment for version 1.2.

IF you have problems with TCAS targets not disappearing while using IVAO, VATSIM or PILOTEDGE, then this script may help you.
If you dont have any issues, dont use this script.

This script will only run when you are connected to IVAO, VATSIM or PILOTEDGE.

If this script helped you with stuck TCAS targets please leave a comment below.

Requirement:
- You will need FlyWithLua installed - 
XP10: http://forums.x-plane.org/index.php?/files/file/17468-flywithlua-for-xp9-and-xp10/
XP11: http://forums.x-plane.org/index.php?/files/file/35579-flywithlua-for-x-plane-11-and-10-windows-linux-mac-os-x-version/

Installation:
- copy IXEG_TCAS_CleanUp.lua to [X-Plane]\Resources\plugins\FlyWithLua\Scripts

Download:
http://forums.x-pilot.com/files/file/1060-tcas-cleanup-for-the-ixeg-733/

 

Edited by Tom Stian
4

Share this post


Link to post
Share on other sites
15 hours ago, Tom Knudsen said:

Great work Stian

Thanks Tom. 

Just curious since no one have reported it yet. Did you have issues with TCAS targets not disappearing?

0

Share this post


Link to post
Share on other sites

No

Sent from my SM-G928F using Tapatalk

0

Share this post


Link to post
Share on other sites

Hi Tom

 

You posted this script a few months ago and i will shortly tell you that this lua script is working fine for me!

Without your script i had "Ghost TCAS Targets" when flying online on IVAO. And im sure because on the webeye there were no planes arround me. I tested this script on a flight  from EDDP to LEPA (about 2hrs) and NO GHOST TARGETS. When i had a TCAS Target it was an ivao Plane arround me and i checked with WEBEYE and PFPX Traffic. 100% Right.

 

So thank you for the script!!

1

Share this post


Link to post
Share on other sites

Hello Tom,

you wrote " This script is only ment for version 1.1.".

So is this script not necessary anymore for version 1.2? I just want to make sure.

Thanks for your answer.

Kind regards

Jens

1

Share this post


Link to post
Share on other sites
34 minutes ago, jixeg737 said:

Hello Tom,

you wrote " This script is only ment for version 1.1.".

So is this script not necessary anymore for version 1.2? I just want to make sure.

Thanks for your answer.

Kind regards

Jens

Hello Jens.

Nothing changed between v1.1 and v1.2 regarding TCAS, so the script is still usefull.

I even use the script(modified version) for other payware aircraft as well.

0

Share this post


Link to post
Share on other sites

Hello Tom,

ok, thank you.

Can you tell me the root cause of the issue your script may avoid? Is it e.g. a bug of X-Plane?

Do you know if the issue will be fixed by the causer?

Thanks.

Jens

0

Share this post


Link to post
Share on other sites
3 hours ago, jixeg737 said:

Hello Tom,

ok, thank you.

Can you tell me the root cause of the issue your script may avoid? Is it e.g. a bug of X-Plane?

Do you know if the issue will be fixed by the causer?

Thanks.

Jens

X-Plane uses 19 datarefs (plane1 to plane19) for multiplayer aircraft information.

And the IXEG 733 read these datarefs to show TCAS information.

The issue is how the VATSIM and IVAO client handle the datarefs.

Some examples:
1. When a aircraft is flying out of range or disconnects, the VATSIM/IVAO client do not resets the datarefs for that aircraft, but leave the datarefs with the last known values/postion. And the aircraft will show as a stuck target on the EHSI.

2. Sometimes (read often) the VATSIM/IVAO client can change the multiplayer datarefs for a aircraft, lets say from "plane4" to "plane6". The problem, again. is that the unused datarefs for "plane4" is not resetted by the VATSIM/IVAO client. So the "plane4" will appear as a stuck TCAS target on your EHSI. 

Hope you understand my explanation ;)

My script simply just resettes all the unused multiplayer datarefs.

 

Edited by Tom Stian
1

Share this post


Link to post
Share on other sites

Hello Tom,

thanks a lot for your explanation!

I have just studied your script: As far as I understand you script (I am not familiar with FlyWithLua), you set the OpenGL coordinates of the multiplayer aircrafts to 0 every 10 seconds.

Since the OpenGL origin is generally positioned on the surface of the earth at the latitude and longitude reference point, the multiplayer aircrafts may be still shown in the IXEG, am I right?

Do you know where the latitude and longitude reference point typically is?

Thanks for helping me.

Regards

Jens

0

Share this post


Link to post
Share on other sites
4 minutes ago, jixeg737 said:

Hello Tom,

thanks a lot for your explanation!

I have just studied your script: As far as I understand you script (I am not familiar with FlyWithLua), you set the OpenGL coordinates of the multiplayer aircrafts to 0 every 10 seconds.

Since the OpenGL origin is generally positioned on the surface of the earth at the latitude and longitude reference point, the multiplayer aircrafts may be still shown in the IXEG, am I right?

Do you know where the latitude and longitude reference point typically is?

Thanks for helping me.

Regards

Jens

Ill guess sim/flightmodel/position/lat_ref and sim/flightmodel/position/lon_ref  but I dont know.

I never had issues with ghost/stuck target with simply just resetting the OpenGL coordinates. But I havent debugged it that much :) So it can/may happen. But again, I havent noticed it.

0

Share this post


Link to post
Share on other sites

For your information, http://www.xsquawkbox.net/xpsdk/mediawiki/ScreenCoordinates states the following:

"The reference point is generally the center of the mapped scenery, which is __not__ the same as sim/flightmodel/position/lat_ref and sim/flightmodel/position/lon_ref."

I've just read this and want to share this information.

So now the question is: Where is the center of the mapped scenery? ;-) Is it the center of the tile?

1

Share this post


Link to post
Share on other sites
59 minutes ago, jixeg737 said:

For your information, http://www.xsquawkbox.net/xpsdk/mediawiki/ScreenCoordinates states the following:

"The reference point is generally the center of the mapped scenery, which is __not__ the same as sim/flightmodel/position/lat_ref and sim/flightmodel/position/lon_ref."

I've just read this and want to share this information.

So now the question is: Where is the center of the mapped scenery? ;-) Is it the center of the tile?

That can make sence.
The datarefs plane_x, z and y is static when one of the conditions above I mentioned happens. So the unused and not resetted multiplayer datarefs will show as stuck targets since they will always have the same position relative to the users aircraft.

0

Share this post


Link to post
Share on other sites

I just did some testing with the DataRef Tool. Result: If the OpenGL coordinates of the multiplayer aircrafts do not change, these aircrafts stay at a fixed position on the map.

So, would it be better to set these coordinates depending on the OpenGL coordinates of the IXEG 737? As a result, the IXEG 737 would never reach the position of the multiplayer aircrafts.

E.g. we could set the x coordinate to the x coordinate of the IXEG 737 plus 100nm.

0

Share this post


Link to post
Share on other sites

Hello together,

in the meantime I added this functionality to my existing personal plugin:

If there is a connection to VATSIM, my plugin does the following every 60s:

I) reading of the local coordinates (x, y, z) of the ixeg 737

II) adding 10 meters to the x coordinate

III) retrieving the world coordinates of the modified local coordinates (via XPLMLocalToWorld)

IV) setting the local coordinates to the modified local coordinates and the world coordinates to the retrieved world coordinates for each of the 19 multiplayer aircrafts

I will test this functionality over the next months.

I plan to change the offset from 10 meters to a much higher value during this test.

Regards

Jens

Edited by jixeg737
0

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

  • Recently Browsing   0 members

    No registered users viewing this page.