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!
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.
via free offset to monitor Battery State and placeholder to assign the function if(a=1,$,0) in Transform fields for desired Led Outputs.

Hi my friend !
1. 7SEG .
Here you use nearly the same logic like in LED.... With a little trick.
via free offset to monitor Battery State and placeholder to assign the function if(a=1,$,0) in Transform fields for desired Led Outputs.
You stil use the same logic ...... A 7Seg will use the "Space Character" for a Blank .
So technical we woud say here : if(a=1,$,' ') BUT badly this work NOT in the Transform field..... Cause here Strings are permitted. So the Resut MUST be a Integer Value.
The Key is.... Using a FAKE Value that never can occure. In a Heading Display e.g. every value above 359 ( cause Heading is 0-359) For example "999"
So you use the Formula if(a=1,$,999) here in transform.
Finaly in COMPARE Tab you can work like in the XPDR solution..... You know. If Value is 999 (by the transform formula) this means Display must be blank.
So say.... IF Vaue = 999 THEN Some Spaces ( in number of digits) ELSE $
Result: If Battery Offset is 0 the Transform change Value to 999 .... The Compare Change 999 into Spaces ..... If Battery is ON the Vaue is simply the Offset and is shown.
2. LCD:
Here you need a Electrical Solution !
In Mobiflight you just can say all Diggits should be show nothing.... But the Backlight is STILL ON. To disable the Backlight you must CUT the Line from Controller to Backlight Pin ( i think 5v) by a Relais......
The Relais is used in Mobiflight like a LED.... And it use simply BAT Status. If BAT is ON the Offset is 1 so the Relais is powerd. Means the Line to Backlicht is close and it is light.
If Battery is OFF and Offset is "0" the Relais is disabled.... This CUT the Power line of the Backlicht and your LCD is dark !

Yes this is possibe.... And Yes. It can be done in Transform or Compare... Whatever you like. Finay your also right..... The Key is a ELSEIF !
Only GLOBAL Rule: You can use Srings ( whatever as indication or result) ONLY in Compare Tab..... NEVER in transform !!!
Lots of possible ways.....
Solution via Transform:
Include the needed calculation you done currenty in Compare tab simply into the transform.
For example : "r" is the battery .... And currently comapre is IF Vaue <0 Then $+360 Else $
Use Transform: if(r=1,999999,if($<0,$+360,$))
Finaly in Compare you say now IF Vaue = 999999 THEN "x time Spaces" ELSE $
( The Calculation If $<0 is already done now in Transform and no longer needed in Compare! )
****
Solution Via Compare and Transform
Use in transform just the Battery Function : if(r=1,999999,$)
In Compare you say.... IF Value = 999999 THEN "x time Spaces" ELSE : if($<0,$+360,$)
(Here the Function if Battery is ON is done in Transform ! ....The Logic to Show spaces is done in the THEN of Compare (cause its a String) .... The Calculation <0 is done as a ELSEIF (Formula) in the ELSE of the Compare)
****
Solution in Compare Only: ( Cause you can use Placeholders also in Compare)
IF Value is less < 0 .... THEN if(r=999999,' ',$+360) ELSE if(r=999999,' ',$)
(Here all is done in compare..... We just "incude" the Battery Function 2 times.... So whatever the THEN or the ELSE occure in case of If $<0 Situation.... Both use also the Battery System same time additionaly)
*********
You see.... All is posible.... You just need to understand the code. Basicy you should choose the shortest and most easy way ! In that case Way 1.