Sign in to follow this  
phjvh

Is it possible in XML to do.......

Recommended Posts

Hi,Is it possible, in XML, to create a gauge that reads, oil pressure or oil temperature or both, then once a particular pressure or temperature is reached starts a counter and when this counter hits a certain number causes the planes engine/s to stop?.CheersDan.

Share this post


Link to post
Share on other sites
Help AVSIM continue to serve you!
Please donate today!

You mean:If the set temp/pressure is exceeded, the counter is incremented. And when both temp/pressure drop below the set value, and then exceed it again, the counter is incremented again.And this repeats untill the counter exceeds a set maximum.This is very easy to make in XML (about 10-20 lines of code), for one engine. Even to make the pressure/temp threshold and counter settable (via mouseclicks), but that's more work of course.Would be a nice exercise to learn XML gauge programming :-)Rob

Share this post


Link to post
Share on other sites

Hi Rob,Yes thats exactly what I am after.How would I even start to program this in XML, I have "dabbled" in XML before but really simple stuff, ASI, VSI etc.I had a look at the thread mention, but unfortunatly I cannot really understand it.Could someone give me a leg up in this, just to get me started?.Thanks very muchDan.

Share this post


Link to post
Share on other sites

Hi Dan,Just an example, this one should work:(A:General eng1 oil temperature,celsius) 100 > if{ (G:Var1) 0 == if{ 1 (>G:Var1) (P:Local Time, seconds) 10 + (>G:Var2) } } els{ 0 (>G:Var1) } (G:Var1) 1 == if{ (P:Local Time, seconds) (G:Var2) > if{ (>K:MIXTURE1_LEAN) } }If oil temperature gets higher than 100, the engine will shut off after 10 seconds.When you manage to keep temp below 100, nothing will happen.Variations in time and parameters are possible of course.Jan"Procul Negotiis"

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