Sign in to follow this  
Guest Zapem

Fuel Gauge problem

Recommended Posts

Hi all,I need some help on 2 gauges. I am new to this and am learning as I start new panels. This is the first I used with "time" var. 1. Does anyone know the correct way to make a fuel gauge show correctly in KG? I have it set on LBS with a switch to change it to KG. The problem is it shows the wrong amount in kg.KG %((A:Fuel tank center quantity, liter))%!4d!LBS %((A:Fuel tank center quantity, gallons) (A:Fuel weight per gallon, pounds per gallon) *)%!5d! 2. I have a fuel test gauge that comes on in a loop. I copied the code from another panel to get it to work. What it's supposed to do is come on and show 5 different bitmaps in order for about 2 seconds each and when it finishes, it cuts off. I don't want to hold down the button, just press once. (P:Local time, seconds) 0 max s1 2 / 5 % flr l1 10 % 99 > if{ l1 10 % 9 - + }Fuel Quantity Test Switch0 (>K:TOGGLE_AFTERBURNER2) 0 (L:Fuel Quantity Test, bool) ! (>L:Fuel Quantity Test, bool) 1

Share this post


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

Hi,The first one (Fuel Weight in Kg) - the only way I have managed this is to convert to pounds and then use a multiplier e.g.(A:FUEL TANK CENTER QUANTITY, gallon) (A:FUEL WEIGHT PER GALLON, pound per gallon) * 0.45359237(1 pound = 0.45359237 Kg)For your second problem...On my panels I have set a one second tick in a small gauge for use in these types of situations..(L:ONE SECOND TIMER, number) 1 + (>L:ONE SECOND TIMER, number)with this running what your doing is then easy...When you click the switch it takes a reference timer...(L:ONE SECOND TIMER, number) (>L:FUEL REF TIMER, number)And your bmp images are just controlled by visible statements...(L:ONE SECOND TIMER, number) (L:REF TIMER, number) 2 + <(L:ONE SECOND TIMER, number) (L:REF TIMER, number) 4 + < (L:ONE SECOND TIMER, number) (L:REF TIMER, number) 2 + > &&etc..This is probably not the tidiest but it works for me!!Cheers,

Share this post


Link to post
Share on other sites

Paul,Thanks for the help on the gauges. So far I have tried to use the string you gave me for the KG conversion and no luck. Here is the string.%((A:FUEL TANK CENTER QUANTITY, gallon) (A:FUEL WEIGHT PER GALLON, pound per gallon) * 0.45359237)%!4d!Can you tell me what I'm doing wrong? Please?I will start on the other gauge and let you know of the outcome.

Share this post


Link to post
Share on other sites

Hi,Try:%((A:FUEL TANK CENTER QUANTITY, gallon) (A:FUELWEIGHT PER GALLON, pound per gallon) 0.45359237 *)%!4d!Jan"Beatus Ille Procul Negotiis"

Share this post


Link to post
Share on other sites

Hi Jan and Paul,Thanks for the help on the string, but all I got was a 7.I don't know if this is the 7 fron the tag-end of the code or 7202 KG read out I should be getting. I tried to increase the text to see if anything was hiding but no luck. So I took the original code and implemented the new code attachment thinking..."if the 0.45359237 divides the pounds into KG's, then why not find the difference in the quantity of liters and pounds. So with some calculations done I implemented it into the string like you guys did". Works great!! I only included this so maybe you can use this info in future panels.WORKING CODE FOR KG)%((A:Fuel tank center quantity, liter) 0.8027474 *)%!4d!

Share this post


Link to post
Share on other sites

I use this string line to get the TOTAL Fuel Weight in KG:%((A:Fuel total quantity weight,kg))%!d!or this%((A:Fuel left quantity, meter cubed) (A:Fuel weight per gallon, kilogram per cubic meter) *)%!d!

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