flybywiresim / aircraft

The A32NX & A380X Project are community driven open source projects to create free Airbus aircraft in Microsoft Flight Simulator that are as close to reality as possible.
https://flybywiresim.com
GNU General Public License v3.0
4.98k stars 1.04k forks source link

[REQUEST] Implement Sim Connect variables and commands for EFIS buttons and knobs #411

Closed WzdOz closed 3 years ago

WzdOz commented 4 years ago

Is your feature request related to a problem? Please describe. No

Describe the features you'd like to see implemented I would like to control EFIS buttons and knobs via Sim Connect variables and commands.

Additional context EFIS is one of the most interacted instrument during all stages of the flight. It is important to have the ability to bind its functions to game controllers and panels. At the moment EFIS functions can only be controlled with mouse input, as there are no sim connect variables and commands defined for those. Having the datarefs and commands for EFIS buttons and knobs, will give us the ability to bind those functions. This is essential for home cockpit builders and simmers who use flight simulation peripherals.

UncleClapton commented 4 years ago

We may be able to tie something to custom simvars, but the proper solution here probably needs to come from Asobo.

WzdOz commented 4 years ago

Thank you, I understand. If it is indeed possible, even a partial temporary solution will be greatly appreciated.

I am afraid, if we leave it to Asobo, it'll take ages. They have quite a lot in their plate, most of which have higher priority than enhancements like these.

2hwk commented 3 years ago

You can access EFIS buttons through H:Events

See A32NX_GlassCockpit_Push_Template in flybywire-aircraft-a320-neo/ModelBehaviorDefs/A32NX/Airbus.xml specifically line 1129

        <UseTemplate Name="FBW_AIRLINER_SubNodes_Setter_Template">
            <TEMPLATE_TO_CALL>ASOBO_GT_Push_Button_Airliner</TEMPLATE_TO_CALL>
            <LEFT_SINGLE_CODE>(&gt;H:#PLANE_PREFIX#_MFD_BTN_#BTN_ID#) (&gt;H:#PLANE_PREFIX#_PFD_BTN_#BTN_ID#) and</LEFT_SINGLE_CODE> <!---- HERE
            <SEQ1_EMISSIVE_CODE>(L:BTN_#BTN_ID#_FILTER_ACTIVE)</SEQ1_EMISSIVE_CODE>
            <TOOLTIPID>%((#ONOFF_VARIABLE#))%{if}TT:#ON_TOOLTIP#%{else}TT:#OFF_TOOLTIP#%{end}</TOOLTIPID>
        </UseTemplate>
    </Template>

Also see flybywire-aircraft-a320-neo/html_ui/Pages/VCockpit/Instruments/Airliners/FlyByWire_A320_Neo/MFD/A320_Neo_MFD.js:447 onEvent()

i.e. H:A320_Neo_MFD_BTN_APRT_1 H:A320_Neo_MFD_BTN_VORD_1 H:A320_Neo_MFD_BTN_WPT_1 etc. etc.

EFIS Knobs are L:Vars, i.e. L:A320_Neo_MFD_Range_1

tracernz commented 3 years ago

Note these will soon change in the autopilot-custom-fpm branch (and soon experimental), some already have.