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.

icon
Avatar
gergmchairy
Posts: 1
Hi Folks,

New poster here - I'm building a GA Cockpit and harve started with the Radio Stack.
I've got 8 x MAX7219's and 8 Digit 7 Segment LEDS - which are working fine (now i've found the soldering issues!)

I'd like to display 6 digits instead of the usual 5, by calulating the final digit. Something like an if, then statement... ie last supplied digit = 0 or 5 then 0, else 5) for 00(0),12(5),25(0),37(5)etc..

Is this possible ?

Thanks

Greg
2018-09-12 14:29
Avatar
thatchi
Posts: 181
U can divide the number by 5. If result is integer then set to 0 . Else set to 5. That the logic.
2018-09-12 21:16
Avatar
pizman82
Moderator
From: ETSI, Germany
Posts: 6010
Supporter
Do we talk about the 25 Khz Band or the new 8.33 Khz Band ??

FSX and P3D work already with old 25khz band.

In That case your right... the Frequencys ends with "2" and "7" should normaly have a "5" on last diggit. Like 125,77 is normaly 125,775

But as i know that was a problem in Real Aircrafts in the past, too.... In case that the last number is always the same ( 0 if number before is 5 or 0 ... AND 5 if Number before is 2 or 7)
they not include a 3.rd display and show it on a 2 Diggit Display Finaly.

*****
To solve this you need a MODULO like thatchi say... So "$%5" result in "0" if Frequency is .x5 or .x0 and it result in "2" if Frequeny is .x2 or .x7 .

a condition can be if($%5=0,$*10+100000,$*10+100005)

Example A : Frequency 123,45 (FSX) Should be shown as 123,45 ... RAW FSUIPC Value = 2345
2345 MODULO 5 = 0 ... So the THEN Command is working ($*10+100000) 2345*10 = 23450 ..... 23450+100000 = 123450 .... With a Decimalpoint on Display its 123,450

Example B : Frequency 123.47 (FSX) Should be shown as 123,475 ... Raw FSUIPC Value = 2347
2347 MODULO 5 = 2 ... So the ELSE Command is working ($*10+100005) 2347*10 = 23470 ..... 23470+100005 = 123475 .... With a Decimalpoint on Display its 123,475

Try this out !


NOTE: If you work with 8.33 khz Band like new Aircrafts in Real.... This is NOT possible in FSX directly. I Remeber we talk about that in the past but i not find the topic.
Maby Stephan still remember that ! Not remember if we found a solution to convert the FSX band into 8.33 ... but i not think so !
Good Luck !
2018-09-12 23:29
Avatar
StephanHo
From: EDDG, Germany
Posts: 1867
Supporter
The 8.33 kHz grid is not possible in FSX.
Maybe it is possible in P3DV4x.

Example:
121,000 MHz
121,008 (33)
121,016 (66)
121,025 (00) # actually (99)
121,033 (33)
121,041 (66)
121,050 (00) # actually (99)
etc.

If FSUIPC (in the 64-bit version) still only got 2 bytes (1210), a true frequency representation could not be displayed in this grid.
Enthusiasts may then be inclined to represent the complete 8 digits ;)
Grüße,
Stephan (Time: UTC+2)
2018-09-13 00:27
icon