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
dieharder
Posts: 6
Hi all,

I'm new to all this, and a bit stuck, so hoping anyone can help me.
I followed the tutorial for the Parking brake led, configured my Arduino MEGA, the pin etc works correctly (if I do test in the config, the led lights up properly).

FSUIPC7 beta, and Mobiflight 7.10 are both running and show connection to the sim (Flight Simulator 2020).

When I toggle the brakes, I see events firing in the console of FSUIPC. But nothing changes in Mobiflight / on my Arduino. And don't really see anything happen in the Mobiflight logs either. To me it looks like somehow Mobiflight isn't able to poll FSUIPC.

Any idea what I could do / where to look further?

Thanks!
2020-09-10 12:01
Avatar
pizman82
Moderator
From: ETSI, Germany
Posts: 6010
Supporter
Only two possible issues.....

You still confirm your LED is working electrical ( By test mode)

So ....

1. You use a wrong config setting. Please not trust basicly in the Presets. We not test all of them and most of users finaly not use them. Please check your FSUIPC Offset List and confirm you use the correct Offsetadress, Size and Typ. If not enter the right data.
On first view it´s 0BC8 2 Byte INT

2. Issue in FSUIPC.
The FS2020 Version of FSUIPC (v7) is "deep" Beta. You can see in the list most of the Systems are not working yet. Mobiflight is technical FS2020 Ready.... But i think FSUIPC will take some more weeks or month until it is stable like in P3D.
Good Luck !
2020-09-10 16:11
Avatar
StephanHo
Moderator
From: EDDG, Germany
Posts: 1867
Supporter
Hi Dieharder,

welcome to MobiFlight!

Please note, that FSUIPC 7 is only a beta-version, so the full function is not guaranteed.

But to check the functionality try as follows:

I assume that you use a latching switch and not a momentary button.

Look, that you use in the ConfigWizard for the OnPress Tab the offset 0x0BC8, INT, 2 Bytes
In the field "Set Value" use 32767. In the tutorial there is the value 1. That won't work.
Now change to the tab OnRelease and use the same offset (0x0BC8, INT, 2 Bytes)
In the field "Set Value" now use the value 0.

To switch on the led got to the output tab in the MF main window
Here create a new config if not already done.

Klick on three points at the end of the line and you will enter the ConfigWizard.
Click on FSUIPC tab.
As offset you take again 0x0BC8
in the transform line insert "if($=0,1,0)"

Here you read out the offset of the parking brake with the same offset you use for your switch.
If you set the Parking Brake the value will be set to 32767 and if you release the value will be set to 0.
This config will switch your LED on, if the parking brake is set and the value is 0.
You have to read this formula as follows: if $ (the present value of this offset) is Zero, then the output has to be 1 (+5V), at any other valie than 0 the output is 0 and the LED is off.

Because your config in the display area works fine you needn't change here anything.

Now try your parking brake and please report here.
Grüße,
Stephan (Time: UTC+2)
2020-09-10 16:26
Avatar
dieharder
Posts: 6
Hi StephanHo,

Thanks for your detailed answer. I was only trying the LED part, but have now also added a switch, and configured them both as you said.
The offset etc was already right, I now added the transform value as you mentioned.

However, neither the button nor the led work. I validated my circuit, all the components work, and the led works if I press test in the config.

Is there a way to see in the logs of FSUIPC or Mobiflight if the polling is working?
Because I see in FSUIPC events for Parking brake change when I press the joystick button ("EVENT: Cntrl= 65752 (0x000100d8), Param= 0 (0x00000000) PARKING_BRAKES"), but I don't see any polling logs or anything. And when I flip the switch, I also don't see a log in FSUIPC7. So it feels a bit (with my limited knowledge :)), that MobiFlight isn't able to properly talk to FSUIPC. The FSUIPC status box in Mobiflight shows a green tickmark though.

Thanks,
DieHarder
2020-09-10 18:14
Avatar
dieharder
Posts: 6
Oh and: when I flip the switch, I see Tx flashing on the Arduino, so it's sending data back to Mobiflight (but thus not showing up in FSUIPC or in the sim).
But I never see an Rx light flashing to get data onto the Arduino (which I guess should happen based on polling interval)
2020-09-10 18:15
Avatar
StephanHo
Moderator
From: EDDG, Germany
Posts: 1867
Supporter
Please try the logging function in MF

MENU -> SETTINGS - LOGGING

Tick the Hook in front of logging and use debug. Then click ok and you see the logging window at the bottom of the MF main window. Is there any reaction?
Grüße,
Stephan (Time: UTC+2)
2020-09-10 20:53
Avatar
dieharder
Posts: 6
Hi Stephan,

I see in FSUIPC, some read activity when I start up Mobiflight, but nothing after those 4 lines:
iconCode:
66266  READ0[40608]  3308,   4 bytes: 0D 00 DE FA                                      ....
    66266  READ0[40608]  3124,   1 bytes: 6E                                               n
    66391  READ0[40608]  290C,   4 bytes: 38 00 00 00                                      8...
    66391  READ0[40608]  320C,   4 bytes: 38 00 00 00                                      8...


Mobiflight logging shows a lot at the begin, but no entries at all once I'm in the sim, even if I change parking brakes through joystick button or via clicking the cockpit interface.
iconCode:
10/09/2020 21:55:19(329): ExecutionManager.AutoConnectStart:Started auto connect timer
10/09/2020 21:55:19(298): No updates necessary. Your version: 7.10.0.0, Latest version: 7.10.0
10/09/2020 21:55:19(60): ExecutionManager.autoConnectTimer_Tick(): AutoConnect Sim
10/09/2020 21:55:19(7): Command: SetPin <2,5,0;>
10/09/2020 21:55:19(2): ExecutionManager.TestModeStop:Stopped test timer
10/09/2020 21:55:18(989): Checking for updates
10/09/2020 21:55:18(900): Command: SetPin <2,5,0;>
10/09/2020 21:55:18(894): Preventing entering EnergySaving Mode: KeepAlive!
10/09/2020 21:55:18(856): MobiFlightModule.GetInfo: MobiFlight Mega, MobiFlight Mega,1.9.5, SN-98b-a98
10/09/2020 21:55:16(790): MobiflightModule.connect: Connected to Default at COM3 of Type MobiFlight Mega (DTR=>True)
10/09/2020 21:55:16(779): MobiFlightCache.RegisterModule(Default:COM3)
10/09/2020 21:55:16(774): MobiFlightCache.connect: Clearing modules
10/09/2020 21:55:16(769): MobiFlightCache.lookupModules: End
10/09/2020 21:55:16(765): MobiflightModule.disconnect: Disconnected MobiFlight Mega at COM3
10/09/2020 21:55:16(688): MobiFlightModule.GetInfo: MobiFlight Mega, MobiFlight Mega,1.9.5, SN-98b-a98
10/09/2020 21:55:14(610): MobiflightModule.connect: Connected to Default at COM3 of Type Arduino Mega 2560 (DTR=>True)
10/09/2020 21:55:14(587): ExecutionManager.AutoConnectStart:Started auto connect timer
10/09/2020 21:55:14(577): Checking for compatible module: VID_8087&PID_0AAA
10/09/2020 21:55:14(572): Found potentially compatible module (Mega 2560): VID_2341&PID_0042@COM3
10/09/2020 21:55:14(567): Checking for compatible module: VID_2341&PID_0042
10/09/2020 21:55:14(562): Checking for compatible module: VID_1B1C&PID_1B65&MI_02
10/09/2020 21:55:14(557): Checking for compatible module: VID_1B1C&PID_1B65&MI_01
10/09/2020 21:55:14(553): Checking for compatible module: VID_1B1C&PID_1B65&MI_00
10/09/2020 21:55:14(548): Checking for compatible module: VID_1B1C&PID_1B65
10/09/2020 21:55:14(544): Checking for compatible module: VID_1B1C&PID_1B5E&MI_02
10/09/2020 21:55:14(540): Checking for compatible module: VID_1B1C&PID_1B5E&MI_01
10/09/2020 21:55:14(535): Checking for compatible module: VID_1B1C&PID_1B5E&MI_00
10/09/2020 21:55:14(530): Checking for compatible module: VID_1B1C&PID_1B5E
10/09/2020 21:55:14(525): Checking for compatible module: VID_0B05&PID_1866&MI_02
10/09/2020 21:55:14(521): Checking for compatible module: VID_0B05&PID_1866&MI_01
10/09/2020 21:55:14(516): Checking for compatible module: VID_0B05&PID_1866&MI_00
10/09/2020 21:55:14(513): Checking for compatible module: VID_0B05&PID_1866
10/09/2020 21:55:14(507): Incompatible module skipped: @oem9.inf,%iPhone.AppleUsbMux.DeviceDesc%;Apple Mobile Device USB Device - VID/PID: VID_05AC&PID_12AB&MI_01
10/09/2020 21:55:14(503): Checking for compatible module: VID_05AC&PID_12AB&MI_01
10/09/2020 21:55:14(498): Incompatible module skipped: Apple iPad - VID/PID: VID_05AC&PID_12AB&MI_00
10/09/2020 21:55:14(491): Checking for compatible module: VID_05AC&PID_12AB&MI_00
10/09/2020 21:55:14(486): Incompatible module skipped: @oem9.inf,%iPhone.AppleUSB.DeviceDesc%;Apple Mobile Device USB Composite Device - VID/PID: VID_05AC&PID_12AB
10/09/2020 21:55:14(480): Checking for compatible module: VID_05AC&PID_12AB
10/09/2020 21:55:14(474): Checking for compatible module: VID_054C&PID_0CD3
10/09/2020 21:55:14(470): Checking for compatible module: VID_044F&PID_B10A
10/09/2020 21:55:14(464): Checking for compatible module: ROOT_HUB30
10/09/2020 21:55:14(459): ^(VID_1B4F&PID_9206|VID_2341&PID_8036|VID_2341&PID_0010|VID_2341&PID_0042|VID_2341&PID_0001|VID_8087&PID_0024|VID_1A86&PID_7523|VID_2A03&PID_0042|VID_0403&PID_6001|VID_2A03&PID_0010|VID_2341&PID_0210|VID_2341&PID_0242|VID_2341&PID_0043|VID_2A03&PID_0043)
10/09/2020 21:55:14(448): MobiFlightCache.lookupModules: Start
10/09/2020 21:55:14(409): ExecutionManager.autoConnectTimer_Tick(): AutoConnect Modules
10/09/2020 21:55:14(194): MainForm() : Logger initialized Debug
2020-09-10 21:58
Avatar
Weezy
Posts: 4
Hello Stephan,

I have the same problem.
With the debugging I have the following reaction:

10.09.2020 21:49:06(189): ExecutionManager.autoConnectTimer_Tick(): AutoConnect Sim
10.09.2020 21:49:01(400): Serialized Arcaze Extension Module Settings: <?xml version="1.0" encoding="utf-16"?>
<ArrayOfArcazeModuleSettings xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" />
10.09.2020 21:48:46(78): No updates necessary. Your version: 7.10.0.0, Latest version: 7.10.0
10.09.2020 21:48:45(885): ExecutionManager.TestModeStop:Stopped test timer
10.09.2020 21:48:45(880): Checking for updates
10.09.2020 21:48:45(662): Preventing entering EnergySaving Mode: KeepAlive!
10.09.2020 21:48:41(22): MobiflightModule.connect: Connected to Default at COM3 of Type MobiFlight Uno (DTR=>True)
10.09.2020 21:48:40(961): MobiflightModule.disconnect: Disconnected MobiFlight Uno at COM3
10.09.2020 21:48:36(357): MobiflightModule.connect: Connected to Default at COM3 of Type Arduino Uno (DTR=>True)
10.09.2020 21:48:35(956): MainForm() : Logger initialized Info

The Info "ExecutionManager.autoConnectTimer_Tick(): AutoConnect Sim" shows over and over again.

When I Test the LED everything works great.
I use MSFS2020 via Steam

THX
2020-09-10 22:00
Avatar
pizman82
Moderator
From: ETSI, Germany
Posts: 6010
Supporter
Hi Guys.

Your quoted loggings are just from the "Startup" But what we need to find out is if the Buttonpress is working.
So at first get sure..... Logging is in correct MODE..... You need Typ DEBUG from the dropdown.
Choose it and restart Mobiflight.

NOW Run the Sim and Mobiflight and press the RUN Button in Mobiflight.
If you now press your Button then in the Logging there must be a reaction.
At first it will report that the button is pressed.
In next line it will show if a Config is bind to this button ( And if yes what config is bind)
If you release the Button the same logging happen again.
It show you the detection of the release.
And it show you if a config is used for that release action and if its executed.

So if you like to show us your loggings we would need THAT part.


@ Weezy
Your logging show you use a UNO..... Remeber Arduino UNO is not supported by Mobiflight official...... We not garantee Inputs work with that Board !
Good Luck !
2020-09-11 10:32
Avatar
dieharder
Posts: 6
Hi Pizman82.

Logging level is indeed set to DEBUG.

What I shared, is all the logs I have. When I startup the game, FSUIPC7 properly connects to the Sim, no issues there. I see the 2 green tickmarks for Modules & FSUIPC status in Mobiflight. When I press Run in Mobiflight, it says "Running .........." (with the dots moving) in the bottom left, but nothing extra happens in the logs.
And the Led doesn't do anything. (led works with Test)

When I then flip the switch on the Arduino, I get
iconCode:
11/09/2020 11:02:51(54): Config found for Button: brakeButton@SN-98b-a98

But that doesn't do anything either in the Sim, and doesn't show any action in FSUIPC logs.

Thanks,
DieHarder
2020-09-11 11:26
Avatar
pizman82
Moderator
From: ETSI, Germany
Posts: 6010
Supporter
Looks good.

That means button press is detected and also the config is fired.

Final question.... Is a issue in your config ( wrong Offset Wrong Value etc) OR is your setting fine but FSUIPC simply not allow a write to that offset at the moment !
My current list show me that the Offset "should" work !

So.... Another try....

READ the Offset 0BC8 as a OUTPUT. ( Typ INT 2 Byte)
Then toggle the ParkingBrake in the Sim with your Mouse or with a keycommand ( NOT by your real switch)
Observe this Output Config in that moment.
Find out.... What Value is used if brake is set.
And exactly this value you should try to use in your input Config.
Good Luck !
2020-09-11 11:48
Avatar
dieharder
Posts: 6
Ok, now I feel really stupid. When trying to see how I could read the config, I discovered the "Active" column, which wasn't ticked. I guess I thought the activation would have happened by default. Stupid me :blush:

It works now, thanks for your help, and sorry for wasting your time on this.
2020-09-11 12:05
Avatar
pizman82
Moderator
From: ETSI, Germany
Posts: 6010
Supporter
Shit happens :P

Typical beginner issue we all have done in our first weeks.
But let me say.... The unticked Checkmark by default is finaly a good thing. If you build advanced cockpits this is more logical as a "ON by default".

Whatever i will request to Sebastian maybe for a more optical warning.... Like a Yellow Color so users get alearted if a config is unticked while Mobiflight is in RUN mode.
Or maybe a Popup like "Attention: Some Configs are not activated!!"
Good Luck !
2020-09-11 12:22
icon