Jump to content
Sign in to follow this  
Guest A320 Co-Pilot

Delay in an XML Gauge

Recommended Posts

Hi,Which switch must stay on?(L:PreDep,bool)? In that case leave it out the value section.You can switch it off in the click section.Jan"Beatus ille qui procul negotiis..."

Share this post


Link to post
Share on other sites
Guest A320 Co-Pilot

Hi JanThe (L:PreDep,bool) must stay on untill the sound plays for the cabin crew to tell the Captain cabin is ready for departure, it is then turned off by the code. I want the code to turn on all the switch and leave them in the on position, but not keep them held in the on position. I think the easiest way to explain this is: When I turn on the switch (L:PreDep,bool) to start the pre departure procedure, after 5 mins plays sound for FO entering cockpit after performing walk around. Then on 8 minutes he starts his first flow Seat belt switch - On, No Smoking switch - on etc. After he has complete the first flow, the switches which he has turned on, are stuck on, if I click on them to turn them to the off position, then the code automatically turns them back on. This is not a realy a problem for the fuel switches etc, but is a problem for the IRS system. The 3 IRS switches are held in the on position and not released by the code untill the PreDep switch is turned off, and so will not align. The IRS System has two switch position off and Nav(On), but must be in the Nav position to align, there is a timer in the IRS code which once all switches are in the on position, after a short time the IRS will align, but as I said before using this code they do not align, as it will not let the code in the IRS go on to the aligning part as it wants to keep the switches held on. The code below is a simplifed version, I have not tested it, but I think it should work. It turns taxi, landing and beacon lights on, once the code has turned on the lights, try turning them off. It will not let you, clicking the switches flicks the switch to off but the code moves it straight to on again. Turn the PreFlight,switch off and the switches will remain in the on position, but can be switched off if needed to be. So for the IRS system the three switches need to kept in the on postion, but not held permantly on by the code. I have tried adding another variable to the Value part, but that either does not work, or makes the first three Variable turn on with the first one. I have tried a lot of different if{. I also added another L:Var to the ie (L:Preflight,bool) ! (>L:PreFlight,bool) (>L:FirstFlow,bool) (P:Local Time,seconds) and then putting (L:FirstFlow,bool) in place of (L:PreFlight,bool) but that did not work. I have tried every thing I can think of and no joy. I am begining to wonder if this is not possible. I could go back to the old idea I had of after 12 mins PreDeparture switch is switched off, and then you must click another switch Before Start, to go to the next set of events, then the IRS system would align, but was hopeing that I could get it all in one switch, do you think it is possible to get it to work in one switch ?(L:PreFlight,bool)(P:Local Time,seconds) s1 (L:PreFlight,bool) if{ l1 (L:taxi timer,seconds) > if{ (A:LIGHT TAXI,bool) ! if{ (>K:TOGGLE_TAXI_LIGHTS) } l1 (L:landing timer,seconds) > if{ (A:LIGHT LANDING,bool ! if{ (>K:LANDING_LIGHTS_TOGGLE } l1 (L:beacon timer,seconds) > if{ (A:LIGHT BEACON,bool) ! if{ (>K:TOGGLE_BEACON_LIGHTS) } } Preflight(L:PreFlight,bool) ! (>L:PreFlight,bool) (P:Local Time,seconds) 2 + (>L:taxi timer,seconds) (P:Local Time,seconds) 4 + (>L:landing timer,seconds) (P:Local Time,seconds) 6 + (>L:beacon timer,seconds)

Share this post


Link to post
Share on other sites

Hi,So if I do understand you well the IRS switches are the problem.My switches has 4 positions: off, align, nav and att.Do your switches have 3: off, align and nav?In that case you could try(not tested):(L:irs switch,enum)(P:Absolute Time,seconds) s1 (L:predep,bool) etc. etc.if{ l1 (L:irs timer align,number) > if{ 1 (>L:irs switch,enum) 0 (>L:irs timer align,number) }//alignl1 (L:irs timer nav,number) > if{ 2 (>L:irs switch,enum) }//nav } etc. etc.(L:predep,bool) ! (>L:predep,bool) etc. etc.l1 xxx + (>L:irs timer align,seconds) l1 xxx + align time + (>L:irs timer nav,seconds) Jan"Beatus ille qui procul negotiis..."

Share this post


Link to post
Share on other sites
Guest A320 Co-Pilot

Hi JanNo the IRS has two switch positions, on and off. When the three switches are in the on position, after a few seconds the IRS Aligns, but the switches remain in the on position. The panel I am trying to get this to work with is not a panel I have made so the IRS code is not mine, otherwise I would post the code for the IRS system. I have looked at the code for the IRS Switches and it is full of G:Var and I do not understand them. The IRS Alignment is not very realistic, and would be more realistic to Align at 12 mins, so I might go back to my first idea of the pre dep switch doing up to 12 mins, and then a before start switch needing to be turned on after that to start the next flow. If I do decide to go back to the first idea, then I will need to make a timer which counts down from 20 so I no where I am in the program, the only thing putting me off is the G:Var in a clocktimer.I would like to thank you for your time in this problem, I am very greatful for the help you have given me. I wil get this to work one way or another, the timer route is looking my best option at the moment.

Share this post


Link to post
Share on other sites

Hi,The (G:Var) is not that difficult, only 9 per gauge.Try to translate them in (L:var's)!Example:(P:absolute Time,seconds) 10 + (>G:Var1) is the same as:(P:absolute Time,seconds) 10 + (>L:Var1,seconds) //or number or enumOnly when changing vieuws, or reload or new startup the (G:Var) always will be 0!Jan"Beatus ille qui procul negotiis..."

Share this post


Link to post
Share on other sites
Guest A320 Co-Pilot

Hi JanI have decide to leave the code as it is and go the two switch route, then the IRS Aligns after 12 mins, so I will need to make a timer. Thanks for the tip about G:Var I will have a look at the default 747 clock and see if I can work out how the timer code works.If I do get any problems I no where to post, Thanks once again for your help.

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...