MobiFlight Community Support

Welcome to the forum for MobiFlight! Feel free to reach out to the community in case you have questions, issues or just want to share great ideas or details about your latest home cockpit project.

You like MobiFlight? Donate via PayPal and support the MobiFlight development. Thanks! 

05/03/2024 - This forum is read-only

The community support for MobiFlight has moved exclusively over to our Discord server. Register for free and enjoy more interactive functions like image and video upload, voice chat. More than 7,000 registered users around the world make it a great experience!

See you on our MobiFlight Community Discord server.

A HUGE Thank You to everyone who participated in the forum, especially obviously to Pizman and Stephan who did an outstanding job over so many years providing an incredible service to the MobiFlight community.

The forum is still providing a lot of good content, hence we keep this information accessible.

Go to page 1Go to page 112Go to page 3Go to page 2
Avatar
volavue
From: SEILLONS SOURCE D'ARGENS, France
Posts: 13
hello ,Pizzman

Do you have some advice to solve problem about my last message n°24478
Maybe Stephan Ho you can help me?
best regards
JJZ
2021-12-01 08:31
Avatar
volavue
From: SEILLONS SOURCE D'ARGENS, France
Posts: 13
Hi Pizzman
do you have advice to solve my problem with to show position trim with LCD display ( see my message n° 24478)

Stephan can you help me ?

best, resgards
JJZ
2021-12-01 21:01
Avatar
pizman82
Moderator
From: ETSI, Germany
Posts: 6010
Supporter
Hi
I´m Sorry. Was blocked by my Job.
I will also be not online the next days in case of work.

Badly i not fully understand all the numbers you tell me..... How will a hypothetical multyply by 20.000 help ?
For sure it change the problematic Float Value into a Integer Value we can show..... But does this *20000 give you the exact "degrees" or is this just a improvisional Test by yourself ?

About Problems:

I think Preconditions can be done..... If the Display only show the Trim Value.... If the Display is also for Multi Useage ( E.g. Com1/Com2 by Keypress) then the Precondition Idea gonna be pretty fast verry confusing and untidy..... Cause then we talk about 5,10 or more Preconditions for the same display!

The Soluition is pretty simple ( on first View) WITHOUT Preconditions !

Step 1:
Recalculate the Raw Value like your "$*20000" attempt...... Target is : We need a 4 Number Value that represent the Degrees of Trim most accurate as possible.
We also remove the "minus" here by calculation..... We say e.g. in Compare : If Value is LESS then Zero <0 THEN $*-1 ELSE $
Result: Value is always Positive.... Whatever it is currently negative ! (Verry important later)

Step 2: We "Add" to this Value finally one Position .... In case it have 4 Numbers we simply say $+10000 .... so 1234 change into 11234

Step 3 We make a own definition for the "Minus" .....
So in a Additional config we again read the raw Value of the Trim..... And we say
IF Value is Less Zero <0 THEN "-" Else "Space" ( Use the Minus sign and a Space Press for a Empty Diggit)

Step 4 We build the LCD Display:
Here we use e.g. the Config fro the Trim Value as "%" and we also use the Config for the Minus Indication as "#"
Display show something like TRIM: #%%,%%

How it workes:
The Value is always Positive ( no minus anymore) .... So it will be shown on %%%% Position..... If it is below 1000 then our Trick work.... lets say we need 1,23 Degrees
Then our Value ( with the +10000 Trick) is currently "10123" .... With only 4 Placeholders in use (%%,%%) It show "01,23" on the Display.

The Minus itself is now a own system.... If Value is Positive then our Calculation Config say " When 0 or greater set to "Space-- Empty Diggit)"
So in that case a Value of +1234 is shown as _12,34 ( The _ means a empty diggit)
If value is Negative then the logic say "set a "-" sign .... Then it show -12,34 .
In easy words.... The # Position is now controlled indipended!

NOTE: If you say in the "Minus Config" for the ELSE Field "+" instead of "space" then it will show +/- in the Display.

****************

I hope you understand !
If not Please ask Stephan and tell him he should read my posting here ! OR Wait unitl i´m back...... Best way via Discord !!!
[Last edited by pizman82, 2021-12-02 22:58]
Good Luck !
2021-12-02 22:53
Avatar
volavue
From: SEILLONS SOURCE D'ARGENS, France
Posts: 13
thanks Pizzman and good luck for your job

I will try your advice and I wiil comme back if I have some problem to test ytour proposition

PS I have the right degree with this parameter
JJZ
2021-12-06 21:02
Go to page 1Go to page 112Go to page 3Go to page 2