Jump to content
Sign in to follow this  
n4gix

a better autopilot for airliners

Recommended Posts

>Hi Jan,>>Do you mean to say that G:Var* variables used in 2 .xml gauges>interfere with each other (i.e. the visibility of a G:Var is>NOT limited to one .xml gauge) ???Heh! That's why they're called "Global Variables..." :)L: Local (unlimited #)G: Global (limited to 10: 0-9)For most purposes, I prefer L: type because you can give 'em meaningful names!


Fr. Bill    

AOPA Member: 07141481 AARP Member: 3209010556


     Avsim Board of Directors | Avsim Forums Moderator

Share this post


Link to post
Share on other sites

Rob,I have a totally integrated autopilot, autoland and thrustmode computer, one xml gauge, and i wanted to put your code in it between the other "modes".Because i used a lot of G:Var's to rotate the knobs and switches, i had to rename them.Btw, busy to change all (G:Var's) in my panel in L:Var's!Jan"Procul Negotiis"

Share this post


Link to post
Share on other sites

Hi Bill,Sorry, but you wrong :-)From the PanelSDK:G: Gauge var. A variable that is local to this particular gaugeL: Local This parameter can be any user-defined variableSo: "G" stands for Gauge, not for Global :-)So if you want to share variables between gauges, you have to use L: variables.As explained below, Jan's problem with my FLC gauge was caused by the fact that he integrated my code in his existing XML gauge (and therefore has to replace the G: vars I used) ....For gauge-local variables, I normally use G: var, just to limit the amount of typing. Plus I always forget the "units" in L: vars :-)You are right about the "functional naming" of the L: variables; just be aware that other designers might use the same L: var names !!(I solve this by using a gaugename prefix in my variable, to limit this risk. Like: L:FlcState,number)Cheers, Rob

Share this post


Link to post
Share on other sites

>Hi Bill,>>Sorry, but you wrong :-)Of course I am! Sorry 'bout that, I must have had a brain-f@rt... :)Of course, L: being defined as "local" doesn't help; it's very misleading! There's nothing in the name to suggest that they may be "shared" between other XML gauges.Leave it to MS to make things chaotic and confused... :)


Fr. Bill    

AOPA Member: 07141481 AARP Member: 3209010556


     Avsim Board of Directors | Avsim Forums Moderator

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
Sign in to follow this  

  • Tom Allensworth,
    Founder of AVSIM Online


  • Flight Simulation's Premier Resource!

    AVSIM is a free service to the flight simulation community. AVSIM is staffed completely by volunteers and all funds donated to AVSIM go directly back to supporting the community. Your donation here helps to pay our bandwidth costs, emergency funding, and other general costs that crop up from time to time. Thank you for your support!

    Click here for more information and to see all donations year to date.
×
×
  • Create New...