Sign in to follow this  
Guest

xml Switchable Ammeter problem.

Recommended Posts

HiI'm working on an analog ammeter with a 3-pos switch, and a 'jumpy needle behaviour' during rpms, and have encountered a problem. Here is the value tag, broken into lines with comments for easier reading:(*case selector=2, scale volts to match amps linearity table*)(A:Electrical main bus voltage,volts) 4.166667 *(*case selector=1 add jumpiness to needle if rpm > 200*)(A:Electrical genalt2 bus amps,amps) (A:PROP2 RPM,RPM) 200 > if{ (P:Absolute time, seconds) 48 * sin 8 * + } (*case selector=0 add jumpiness to needle if rpm > 200*)(A:Electrical genalt1 bus amps,amps) (A:PROP1 RPM,RPM) 200 > if{ (P:Absolute time, seconds) 36 * sin 8 * + }3 (*number of items on stack*)(L:Ampmode,enum) case (*select the value based on the switch*)Now to the problem. Selector at 0 gives the correct result, selector at 1 gives a lower result, and selector at volts seems not to scale with 4.1667 at all. If I don't use the if statements on the rpms, it works just fine.What am I missing?Secondary question: Anyone know if the fuel gauge on a C421B is 'as jumpy and unusable' as the smaller relatives (C172 etc)?

Share this post


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

Problem not solved as wanted, but I found another way.Never mind.I just used a normalized rpm value in the setup instead, and it looked good enough.

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