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! 

Go to page 1Go to page 0123Go to page 2Go to page 3
Avatar
VR-FlightSim
From: United Kingdom
Posts: 97
Supporter
Hey guys
I wanted to share my latest discovery that I'm very excited about. I'm sure it can help many others too.
While working on my Piper Aztec cockpit section, I was facing an interesting challenge when I needed to convert real Collins VHF radios to work with the sim.
Replacing seven-segment numeric "bulbs" with LED Max7219 module was a piece of cake. The challenge came with the dual encoders. I really wanted to maintain the firm "click" of the original 20 detent mechanism so I 3d printed few parts to attach an ordinary 20 detent encoder to the existing shafts.
Unfortunately, this solution didn't work. Although both devices have 20 detents, they did not match perfectly so the readings had many missing steps.
I was really puzzled by this so I started reading online about how encoders actually work.
And then it struck me!
"there is an option (4 detents per circle) in Mobiflight's client. What if I used two ordinary microswitches to simulate an encoder?"
I jumped back to my pc and designed little camwheel. Well long story short, that worked like a charm!
The theory is quite simple since Mobiflight supports (4 detents per circle) option, all we need to do is connect/disconnect one switch at the time/one detent.
There are no missing steps, no matter how fast you turn the knob and the response is fantastic.

Finally, a picture is worth thousand words.

https://drive.google.com/file/d/1XZBBZcZtQQVBYYJnw_hPM8ZADIJwDhGQ/view?usp=sharing

https://drive.google.com/file/d/1hNyiRSjZdVANpwcWutx8_ulU7cwSXqSc/view?usp=sharing

The exciting part of this technique is that it can be used in many other applications where mechanical resistance/feedback is required and no missing steps allowed.

Regards Jay
p.s thanks for the MobiFlight guys, it is a super great tool:thumbup:

p.p.s how can I embed the actual pictures into the post?
[Last edited by VR-FlightSim, 2019-09-30 22:42]
2019-09-30 22:31
Avatar
VR-FlightSim
From: United Kingdom
Posts: 97
Supporter
Really, nobody knows how to post a picture here?

Jay
2019-10-01 18:47
Avatar
StephanHo
From: EDDG, Germany
Posts: 1521
Supporter
Hi Jay,

you need a storage in the web for your pictures. These link you here in the forum with the globe (hyperlink) and already your pictures appear here in the forum.
A direct setting is unfortunately not possible.
Grüße,
Stephan
2019-10-01 23:48
Avatar
VR-FlightSim
From: United Kingdom
Posts: 97
Supporter
Yes, I've done that (hyperlink) but there are no pictures displayed, only the links them self:-/

Jay
2019-10-01 23:56
Avatar
DocMoebiuz
Moderator
From: NW of KPWK, United States
Posts: 1443
That’s crazy man! Good job!!! How did you design the wheel?
Have a great day!
Sebastian

MobiFlight - Simply build your own home cockpit for your favorite flight sim - FSX, Prepar3D (FSUIPC), X-Plane (XPUIPC)
2019-10-02 06:38
Avatar
VR-FlightSim
From: United Kingdom
Posts: 97
Supporter
Fusion 360, great tool for cockpit builders though ;)

Jay
2019-10-03 12:33
Avatar
DocMoebiuz
Moderator
From: NW of KPWK, United States
Posts: 1443
Oh yeah! I use it too. It’s amazing!!! I love that parametric modeling and the possibility to go back in history, make a change and apply all other edits on top of that.
Have a great day!
Sebastian

MobiFlight - Simply build your own home cockpit for your favorite flight sim - FSX, Prepar3D (FSUIPC), X-Plane (XPUIPC)
2019-10-03 12:44
Avatar
VR-FlightSim
From: United Kingdom
Posts: 97
Supporter
Just a quick technical question...
I want to implement the OFF switch on my Collins radio, however, there is no such offset in FSUIPC to do this via software.
Can I simply take the 7 segment display's power line (+5V) and run it through this switch?
In other words, would it cause any harm to the hardware if I interrupt the displays power supply "on the go"?

Jay
2019-10-08 23:21
Avatar
DocMoebiuz
Moderator
From: NW of KPWK, United States
Posts: 1443
That’s not gonna work because there is an init command when the Config is loaded.

You can set the display to blank though using a custom offset as indicator. Your switch writes an offset. If the value of that offset is let’s say 0 then you send spaces to the display and it will look like turned off.
Have a great day!
Sebastian

MobiFlight - Simply build your own home cockpit for your favorite flight sim - FSX, Prepar3D (FSUIPC), X-Plane (XPUIPC)
2019-10-09 01:04
Avatar
StephanHo
From: EDDG, Germany
Posts: 1521
Supporter
Hello Jay,

Sebastian is unfortunately right.
You did not write what you use for a simulator and what addon.
Since you have FSUIPC, there may be an elegant solution to getting out if a) the (virtual) Collins device has an on / off switch and b) you put it on e.g. can operate with the mouse.
Just open FSUIPC and select the tab LOGGING. There you hook Event ..., then new LOG and Output in Window and click ok.
You should now see the logging window of FSUIPC.
If you now use the mouse or key combination to toggle the Collins switch, FSUIPC should display this with the corresponding EventID and the parameter.
This EventID you put with the parameter on the corresponding device in MobiFlight, each for on and off and you can operate the device accordingly. The associated displays should then go out. If that is not the case, you put on the corresponding displays in Mobiflight a Precondition, which refers to the switch.
Then in FSUIPC do not forget to switch off the logging window again, otherwise it appears again with every simulator start
If you have any questions, please contact me.
Grüße,
Stephan
2019-10-09 01:18
Avatar
VR-FlightSim
From: United Kingdom
Posts: 97
Supporter
Thank you guys.
Can someone explain little more about the custom offset and how to set it to blank out the display please?

The virtual Collins does not have this function so the mouse emulation won't work.
I'm running X plane.

Regards
Jay
2019-10-09 11:11
Avatar
pizman82
Moderator
From: ETSI, Germany
Posts: 3520
Supporter
Hi

Basic technic.

1. You can NOT cut a line electrical from a Display..... Cause initiallisation must be correct. Only way to set a Display Blank is via Software.

2. As Stephan said..... The most profitable way is a Indication Offset from the Sim.... Before you startup a improvisional solution you should again doublecheck if your AddOn Aircraft support a Offset ( Or Dataref in case of Xplane) that show us the status (1/0 ON/OFF) of the "virtual" Radio.
If YES then we can simply use this Offset as "precondition" of the Display..... If Offset is 1 then it should show frequencys and that stuff..... If Offset is OFF then it should show Spaces (Blank)

******

3. If this Offset not exist and you find no Dataref the last solution is to build a "own" indicator..... By using a Custom Offset that is written by your switch.

Here i´m not 100% sure if XPUIPC is compatible...... But i hope so.
FSUIPC give us a range of "Custom Offsets" ... Beginning with 66C0 . This Offsets work 100% Logical but are NOT controlled by the simulator.... So You can write/read them manualy by hand as you need it. ( I not use Xplane so i can not garantee if XPUIPC also work same way here.... You need to test out)

Technic is simple.....
1. You create a INPUT Config that use your Button/switch/Endstop of Potti (whatever you use for that ON/OFF System) .....
2. You set this Input Config to a free Offset.... For example Offset 66C0 1 Byte INT.
For the ON Position you define "Set Value 1" .... For the OFF Position ( Mostly On Release if its a ON/OFF Switch) you use "Set Value 0"

NOTE: At Systemstart those Offsets are ALWAYS Zero.... So your Display would be OFF whatever your Real switch is in ON Position that time. So get sure you shoutdown the cockpit correctly or make a "Sync" at beginning..... Otherwise you must use the switch one time at beginning to sync it manualy.

3. You create a OUTPUT Config that read exactly this Offset ( e.g. 66C0 1 Byte INT) ..... This Config is our "indicator" now.

4. Now you rework your Display Output Config. You can use a Precondition ( or work with variables). Finaly you build a situation ( 1 or 2 Configs whatever technic is used) that your Display check the Switch Indicator and then show Value or Spaces...... Whatever the switch is ON or OFF.

If you need more help please request again and tell me on what point you stop...... I will try to help !
Good Luck !
2019-10-09 12:49
Avatar
StephanHo
From: EDDG, Germany
Posts: 1521
Supporter
maybe the battery main switch is an indicator for you?
Grüße,
Stephan
2019-10-09 13:00
Avatar
pizman82
Moderator
From: ETSI, Germany
Posts: 3520
Supporter
iconStephanHo:

maybe the battery main switch is an indicator for you?



If i understand right his target is to use the "Real" Hardware Panel from a real aircraft. ( Thats why he build the switches in a difficult way to have the same mechanical feeling like in real panel) .

If i also understand correct this panel have a ON/OFF switch to temporary Disable the Radio ( Indipendent from the Master Battery ). If i remember right that switch is part of the Volume Potentiometer..... Like in older Car Radios.... If you turn the Volume to the left there is a Endstop Switch that complety Disable the Radio ( or activate it by rightturn to the lowest volume setting) I remeber to my first "Audi 80 B3" ... there this technic was included.

Whatever..... Like always.... If you need a special feature and you like "as real as possible" you must invest a bit of money and time.
Good Luck !
2019-10-09 13:33
Avatar
DocMoebiuz
Moderator
From: NW of KPWK, United States
Posts: 1443
If there was no Offset or LVAR or so available, I am still convinced that he can use a switch (however close to reality it is) and switch indicates On or Off. The switch writes this state to a Custom Offset. The Custom Offset is then used in a precondition exactly like you would use the precondition for a Master Switch. If precondition is satisfied show only Blanks on the display, it looks like it’s turned off. If Precondition not satisfied, show actual values from COM offset.

The disadvantage of this approach for sure is that the switch position might be out of sync with the sim.
[Last edited by DocMoebiuz, 2019-10-09 14:42]
Have a great day!
Sebastian

MobiFlight - Simply build your own home cockpit for your favorite flight sim - FSX, Prepar3D (FSUIPC), X-Plane (XPUIPC)
2019-10-09 14:21
Go to page 1Go to page 0123Go to page 2Go to page 3