Jump to content
Sign in to follow this  
Guest

Momentary switches using XML

Recommended Posts

Guest sphing

hi,I'm working on a DC-9 project that requires momentary switches. The programming is being done entirely in XML.How can this type of switch be done?

Share this post


Link to post
Share on other sites
Guest

If I understand you correct, you want to create a switch that automatically returns to it's original position? If so, here is complete gaugecode for a threeposition switch which is "springloaded" to center position; used to select which tank to gauge (its realistic, not fantasy btw :))(L:tank gauging,enum)(*selected tank*) (*main tanks*) (*aux tanks*) (P:Absolute time, seconds) (L:tankgauge timer,seconds) > if{ 0 (>L:tank gauging,enum) }Down for Main, Up for Aux, Center for Selected Tank2 (>L:tank gauging,enum) (P:Absolute time, seconds) 0.75 + (>L:tankgauge timer,seconds)1 (>L:tank gauging,enum) (P:Absolute time, seconds) 0.75 + (>L:tankgauge timer,seconds)If only an on/off position is used however, you can simplify the gauge by checking the (in this case) (L:tankgauge timer,seconds) against (P:Absolute time,seconds) where you select which graphics to use, and get rid of the "set to zero" function as seen in the lower "element" above.

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