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!
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.
I'm programming my overhead panel for the PMDG777. Switches with Event ID's and leds with a single offset number are all working well, but I struggle with doubles like ELEC_AnnunExtPwr_AVAIL[2]. I've been reading that I have to add an extra number for the left and right led. Where do I have to put this extra number (Offset, Size in Bytes or mask value with.) Thanks for your help, great program.....love it. Nico
PMDG just save work and not write those offsets each single in a line in that PDF.
So things that exist multiple times ( like same way for Cpt and Fo Side) are listed as "blabla x2 " ..... The size in Byte is the combine size.
So a Offset like "blabla x2 - 2 Bytes" means this are TWO Offsets in a row... Each got Size of 1 Byte.
About Hexadecimal...... Here the Windows Calculator is verry helpfull if you not understand the HEX System youreself.
Open it and choose in settings "Programmer" (instead of Standard or scientific) .... Here you can set HEX and simply say 644B + 1 = 644C (e.g.)
**************
So try it again.... Maby you just forget a checkmark or missundertand something..... The recomend technic is correct and work 100% fine !
The Hexadecimal is completely clear to me and the calculators on the net very helpful, but it still doesn't function with the latest Mobiflight 7.7.0, Prepar3D 4.513.32097 and FSUIPC 5.152.
I'm in a cold and dark cockpit and the avail lights are both on in the sim and also on my overhead Sec_Ext Power (0x644B, Value Type Int, Size in Bytes 2) Prim_Ext Power (0x644C, Value Type Int, Size in Bytes 2) When I press the Primary Ext Power switch on my overhead panel the avail light in the sim goes of, but not on my overhead. When I press the Secondary Ext Power switch the light goes of, both in the sim and on my overhead. When I press the Primary Ext power switch again the avail light goes off in the sim, not on my overhead and the Secondary Ext Power led on my overhead goes on, but not in the sim. So what's wrong, I don't know anymore?
Try Byte size 1 in the Config. I don’t know the add on and haven’t tried it but you have two adjacent Offset addresses that are 1 byte apart and you talk about 2 bytes. That means the value your read would overlap. Which might explain the weird behavior on your OVHD
Have a great day!
Sebastian
MobiFlight - Simply build your own home cockpit for your favorite flight sim - MSFS2020, FSX, Prepar3D (FSUIPC), X-Plane (XPUIPC)
Also , you can monitor the values of these offsets by looking at the last 2 columns in MF. FSUIPC value and the actual output value after transform. FSUIPC also can display up to 4 values of these offsets that you selected in a window. It is helpful to find out what for what in case you not sure.
On the same note, mask value is to choose what bit to use. Since there are 8 bits in 1 byte. You need only 1 bit to display on off state of an indicator light, so an offset of 1 byte can control a total of 8 lights. Some special add on they use 1 byte offset to control multiple indicators. Things can get complicated sometime.
So things that exist multiple times ( like same way for Cpt and Fo Side) are listed as "blabla x2 " ..... The size in Byte is the combine size.
So a Offset like "blabla x2 - 2 Bytes" means this are TWO Offsets in a row... Each got Size of 1 Byte.
****
Sec_Ext Power (0x644B, Value Type Int, Size in Bytes 2) Prim_Ext Power (0x644C, Value Type Int, Size in Bytes 2)
****
6449 2 BYTE x 2 ELEC_annunExtPowr_ON (2) Boolean
644B 2 BYTE x 2 ELEC_annunExtPowr_AVAIL (2) Boolean
644D 2 BYTE x 2 ELEC_Gen_Sw_ON (2) Boolean
*********************
At first you not read or understand my last Posting...... I clearly said..... If a Offset is x2 then the Size is for BOTH ..... So 1 Byte EACH in that case
So if you say.... Sec_Ext Power Offset 644B Size TWO Byte .... Then the Config read Offset 644B AND 644C in one sequence .
If one of the both offets is "1" then the result is LED ON . So your connected LED will light aslong one of two offsets is ON.
(Represent your reported result)
More crazy is your second Config.... Prim_Ext Power 644C 2 Byte.
This config include the Right EXT-PWR Avail Light and also the left GEN Switch ON Status Offset.....
Cause you read 2 Bytes.... Means you read 644C and also 644D .... And 644D is already the LEft Gen Switch Data.
So if the Left Gen Switch is ON in your cockpit then this Output LED Config will light always ... No matter if a Power LED is on or Off in virtual Cockpit..... Cause its still >0 in case of Gen switch.
******************
Solution again:
Every Output need a OWN Config ..... Every Config got its OWN LED Device ..... And Every Config read a OWN single 1 Byte INT Offset.
6449 - Left Ext Power ON LED
644A. Right Ext Power ON LED
644B Left Ext Power Avail LED
644C Right Ext Power Avail LED
644D Left Gen Switch status
644E Right Gen Switch Status
I hope now every problem is solved!
********************
Hello All. I changed this (Prim_Ext Power (0x644C, Value Type Int, Size in Bytes 2)) to 1 and it's all working now. Very very nice. Thank you all, Nico