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
Shimokuta
Posts: 1
Supporter
Hello

I recently discovered the MobiFlight solution
Great work! :thumbup:
But what i am missing is push button support?!!
Only On-Off switches are possible as far as i understand.
Is this correct, or am i missing something?

Regards
2016-01-03 22:51
Avatar
DocMoebiuz
Moderator
From: EDSH, Germany
Posts: 1516
Welcome to MobiFlight!

Actually to Mobiflight there is no difference between a (momentary) push button and a switch with steady on/off positions.
Both types of switches / buttons can be connected with the same device type and for both you can assign onPress/onRelease actions.

Have fun with MobiFlight!
Have a great day!
Sebastian

MobiFlight - Simply build your own home cockpit for your favorite flight sim - MSFS2020, FSX, Prepar3D (FSUIPC), X-Plane (XPUIPC)
2016-01-04 00:19
Avatar
Tuna
Posts: 11
iconShimokuta:

Hello

I recently discovered the MobiFlight solution
Great work! :thumbup:
But what i am missing is push button support?!!
Only On-Off switches are possible as far as i understand.
Is this correct, or am i missing something?

Regards



I've tried to do that on efis meter button, I set OnPress parameter "0", OnRelease parameter "-1", works fine.
2016-02-12 23:16
Avatar
DocMoebiuz
Moderator
From: EDSH, Germany
Posts: 1516
For MobiFlight there is no difference between a switch and a push button. The only difference is that a switch holds its position whereas a push button has a momentary position.

I somehow suspect that you are asking for a toggle function, like: OnPress is triggered the first time you push and release the button. And OnRelease is triggered the next time you push and release the button. Is my assumption correct?

Currently you can have such a behaviour. Example:
You only assign the OnRelease function.
In the value field you can use the current Offset's value with $ and you can also have a function
iconCode:
if($=1,0,1)


This would mean: If the current value at the Offset I want to set is "1" then set it to 0 else set it to 1.

I agree that we could also think about having an explicit toggle button as device...
Have a great day!
Sebastian

MobiFlight - Simply build your own home cockpit for your favorite flight sim - MSFS2020, FSX, Prepar3D (FSUIPC), X-Plane (XPUIPC)
2016-02-13 13:32
Avatar
Julesta
Posts: 129
OK, but I can´t find the offset of REVERSE ENGINES in FSUIPC. It´s as you know F2 in FSX. Then I can´t use the $.

I can´t use a button or switch for it because I need to push F2 several seconds and with this it´s imposible. Do you know how to make it?.

Thanks.
2016-03-29 17:02
Avatar
fabiomun
Posts: 3
i don't understand !! How can i use momentary push buttons with pmdg ? :-/
2016-12-10 17:25
Avatar
pizman82
From: ETSI, Germany
Posts: 6010
Supporter
Hi Fabiomun

Normaly PMDG works with EventID.... Most Buttons got a Left click for Pushing....
As Offset use the Event ID from the PMDG SDK. Value is the Mouseaction you need..... Theres a list of Mouse Actions-Values in the SDK too.

If you tell me what function you like to controll and what Aircraft i can show you a example Config.
Good Luck !
2016-12-11 01:02
Avatar
fabiomun
Posts: 3
ok thanks .:D:rolleyes:
I want to program the MCP of the 737 PMDG. (one switch for example),
I Always used the event id for all toggle switch but i have problems to configure that momentary switch.


:O
I think I found what you were talking about, I had never seen:

MOUSE_FLAG_RIGHTSINGLE 2147483648
MOUSE_FLAG_MIDDLESINGLE 1073741824
MOUSE_FLAG_LEFTSINGLE 536870912
ETC ETC ...
You mean THESE PARAMETERS ?


YESSSSSS !!!! GREAT!!!

THANKS !!!:w00t:
[Last edited by fabiomun, 2016-12-12 22:16]
2016-12-12 16:21
Avatar
pizman82
From: ETSI, Germany
Posts: 6010
Supporter
Yes.

Lot´s of EventID´s got normaly parameters too. EFIS Mode selector for example got parameter 0,1,2,3.
Principial we can say... "If you click the Button in Virtual cockpit for example with leftclick to do what you want....... then the Leftclick Parameter works in Mobiflight too.

Good Luck !
Good Luck !
2016-12-13 00:45
Avatar
jefmachia
Posts: 1
Hello everyone, great software, I really liked it. Congratulations. I have the same problem with my friend Shimokuta, I used a power switch and the lock worked perfectly. Now I would like a one button to press and release equal the Altitude Hold of the autopilot, I would like to push a button and it will trigger the LNav of the autopilot of the PMDG, but I was not successful, I just changed the option and I used the same logic of the The power switch turns off, but nothing does on the screen. I noticed that there is a mouse event with the right and left mouse button, but I do not quite understand where I put these parameters, how would I describe the details so that I can continue with the panel? It's very cool and I'm having a lot of fun with the experience. Forgive me if anything does not come out very clear, I'm using google translator, I'm Brazilian. Big hug and congratulations.
2017-03-09 12:58
Avatar
pizman82
Moderator
From: ETSI, Germany
Posts: 6010
Supporter
Hi Jefmachia.

Hope this guide can translate via Google into portuguese.... If not please ask again..... If i remember correct we got a brazilian Member here who speaks english.... Maby he can awnser you in youre own language.

************
PMDG use "Event ID" for Input !
Use on Input Tab as "Action Type" the "Event ID".... There are 2 fields..... ID, and Parameter.... ( Use only the "ON PRESS" Tab )

You find the needed Data for PMDG737 NGX here.... http://myhomecockpit.de/PMDG_737NGX_EVENT_IDs_SP1d.pdf
(If you use another PMDG like 777, 747 please tell us)

For Example LNAV Button in B737 is : "EVT_MCP_LNAV_SWITCH......... EVENTID: 70029 (Enter This in ID Field)
Parameter is in that situation a "Left Click". As you see in the Document (last page) the Left Click Parameter = 536870912 .... (So simply enter this in Parameter field).

So... Everytime you press the Button it´s like you will do a Left Mouseclick on the Button in the Virtual Cockpit.
Good Luck !
2017-03-09 15:00
Avatar
fazli
Posts: 91
iconpizman82:

Hi Jefmachia.

Hope this guide can translate via Google into portuguese.... If not please ask again..... If i remember correct we got a brazilian Member here who speaks english.... Maby he can awnser you in youre own language.

************
PMDG use "Event ID" for Input !
Use on Input Tab as "Action Type" the "Event ID".... There are 2 fields..... ID, and Parameter.... ( Use only the "ON PRESS" Tab )

You find the needed Data for PMDG737 NGX here.... http://myhomecockpit.de/PMDG_737NGX_EVENT_IDs_SP1d.pdf
(If you use another PMDG like 777, 747 please tell us)

For Example LNAV Button in B737 is : "EVT_MCP_LNAV_SWITCH......... EVENTID: 70029 (Enter This in ID Field)
Parameter is in that situation a "Left Click". As you see in the Document (last page) the Left Click Parameter = 536870912 .... (So simply enter this in Parameter field).

So... Everytime you press the Button it´s like you will do a Left Mouseclick on the Button in the Virtual Cockpit.

2018-03-26 08:19
Avatar
fazli
Posts: 91
i have big problem. till one month i try fine solution
my mcp button approach, vor loc and level change. cant function. before this ok. after build efis and config
precondition button offset 660C .
the problem caming
2018-03-26 08:23
Avatar
pizman82
Moderator
From: ETSI, Germany
Posts: 6010
Supporter
Hi Fazli !

At First...
Please not make 2 Postings in a row ( I see you do lots of times last weeks) . If you "Quote" something then write your text in same Posting and not make a additional one directly after.... And by the way.... Quoting a full text makes no sense.... Quote only the needed Information.... I can simply read the last entry myself so you not need to quote it 1:1.

About Problem.

Your information are to poor....
-Whats the exact Problem....
-What do you mean with Offset 660C ( thats FS2Crew : 660C 4 FLT32 FMC_DistanceToTOD nm; 0.0 if passed, negative if n/a )
I not see your MCC File.... If something not work then you have make a error there pretty shure youreself.

First Aid: Check your Device Names.... If some Functions stop working ( whatever they worked in the past before adding new stuff) then mostly to long Names are the problem.
Get shure your devices on the Arduino have no names Longer then 5-8 Diggits and if possibe no "Signs" like $%&(! .

Report experince and if needed more details so i can help you directly !
Good Luck !
2018-03-26 12:52
Avatar
fazli
Posts: 91
the problem solved.
i just rename app before this app button.
now push button cam operate. im happy now.
tq sir
2018-03-26 20:26
icon