You can turn off the led with:
0·(>MIDI:3:NoteOn:11:17)
hello
anyone found the command (i try every reverse command in the config shchema.json without success) for a full reverse (throttle) command?
i’d like to put full reverse with the C208B for example.
i can do this with the throttle_DECR, but i’d like to have juste one key for FULL REVERSE
thanks
I haven’t tried them myself, but maybe look at PROP_FORCE_BETA_TOGGLE
or PROPELLER_REVERSE_THRUST_TOGGLE
, found here:
https://docs.flightsimulator.com/html/Programming_Tools/Event_IDs/#propeller
With my x-touch mini i’ve always used to zoom map on pdf for g1000 with “MobiFlight.AS1000_MFD_RANGE_DEC” and “MobiFlight.AS1000_MFD_RANGE_INC” but after the last update 10 … no longer works. what is changed? I can’t find anything! Grazie
I am late to the party on this one and am at an early research stage, so forgive my ignorance. What I am most interested in, are rotary switches and would like a solution that will allow changes to HDG and CRS modes for both Nav1 and 2 along with basic rotary functionality for Glass cockpits, predominantly Garmin. Will the behringer do this both easily and cheaply? I already have 2X Streamdeck and already use Axis and Ohs, althouh my programming skills are laughable to a three year old. That rotary functionality is all that I am short of and whilst Loupedeck might offer another avenue, the Behringer is a lot cheaper so worth a look.
Thanks in advance.
It will provide this certainly. That’s what I use of the rotary knobs for! There is good software around to program it to your liking. Not sure if there are ready made profiles for various aircraft be around.
i blast it with a bunch of values:
{ "event": "MobiFlight.AS1000_MFD_RANGE_DEC", "type": "manual", "value": 1 },
{ "event": "MobiFlight.AS3X_TOUCH_1_KNOB_INNER_R_DEC", "type": "manual", "value": 1 },
{ "event": "MobiFlight.TSC_Bottom_Knob_DEC", "type": "manual", "value": 1 },
"GPS_ZOOMIN_BUTTON",
"MAGNETO4_DECR"
],
"event_down": [
{ "event": "MobiFlight.AS1000_MFD_RANGE_INC", "type": "manual", "value": 1 },
{ "event": "MobiFlight.AS3X_TOUCH_1_KNOB_INNER_R_INC", "type": "manual", "value": 1 },
{ "event": "MobiFlight.G3000_TSC_Bottom_Knob_Inc", "type": "manual", "value": 1 },
"GPS_ZOOMOUT_BUTTON",
"MAGNETO4_INCR"
]
works for most planes and i havent noticed it stop working after any update.
i simply have to run the mobiflgith application to update the WASM module in msfs2020 and my command is back to working. Thanks for the script that I can’t wait to try!!!
I’d like to see your file to find out more commands. I never thought I could use a list for all planes to zoom the map. I added the 530 of the 172 analog…
“index”: 2,
“event_up”: [
{ “event”: “MobiFlight.AS430_RNG_Zoom”, “type”: “manual”, “value”: 1 },
{ “event”: “MobiFlight.AS530_RNG_Zoom”, “type”: “manual”, “value”: 1 },
{ “event”: “MobiFlight.AS1000_MFD_RANGE_DEC”, “type”: “manual”, “value”: 1 },
{ “event”: “MobiFlight.AS3X_TOUCH_1_KNOB_INNER_R_DEC”, “type”: “manual”, “value”: 1 },
{ “event”: “MobiFlight.TSC_Bottom_Knob_DEC”, “type”: “manual”, “value”: 1 },
“GPS_ZOOMIN_BUTTON”,
“MAGNETO4_DECR”
],
“event_down”: [
{ “event”: “MobiFlight.AS1000_MFD_RANGE_INC”, “type”: “manual”, “value”: 1 },
{ “event”: “MobiFlight.AS3X_TOUCH_1_KNOB_INNER_R_INC”, “type”: “manual”, “value”: 1 },
{ “event”: “MobiFlight.G3000_TSC_Bottom_Knob_Inc”, “type”: “manual”, “value”: 1 },
{ “event”: “MobiFlight.AS530_RNG_Dezoom”, “type”: “manual”, “value”: 1 },
{ “event”: “MobiFlight.AS430_RNG_Dezoom”, “type”: “manual”, “value”: 1 },
“GPS_ZOOMOUT_BUTTON”,
“MAGNETO4_INCR”
]
},
sure, heres the rest
"$schema": "./config.schema.json",
"version":
{
"major": 1,
"minor": 0,
"patch": 0
},
"encoders": [
{
"index": 1,
"event_up": "KOHLSMAN_INC",
"event_down": "KOHLSMAN_DEC",
"event_press": "BAROMETRIC"
},
{
"index": 2,
"event_up": [
"MAGNETO3_START",
{ "event": "LIGHT_POTENTIOMETER_INC", "type": "manual", "value": 3 },
{ "event": "LIGHT_POTENTIOMETER_INC", "type": "manual", "value": 15 },
{ "event": "LIGHT_POTENTIOMETER_INC", "type": "manual", "value": 16 },
{ "event": "LIGHT_POTENTIOMETER_INC", "type": "manual", "value": 17 },
{ "event": "LIGHT_POTENTIOMETER_INC", "type": "manual", "value": 18 },
{ "event": "LIGHT_POTENTIOMETER_INC", "type": "manual", "value": 19 },
{ "event": "LIGHT_POTENTIOMETER_INC", "type": "manual", "value": 20 }
],
"event_down": [
"MAGNETO3_SET",
{ "event": "LIGHT_POTENTIOMETER_DEC", "type": "manual", "value": 3 },
{ "event": "LIGHT_POTENTIOMETER_DEC", "type": "manual", "value": 15 },
{ "event": "LIGHT_POTENTIOMETER_DEC", "type": "manual", "value": 16 },
{ "event": "LIGHT_POTENTIOMETER_DEC", "type": "manual", "value": 17 },
{ "event": "LIGHT_POTENTIOMETER_DEC", "type": "manual", "value": 18 },
{ "event": "LIGHT_POTENTIOMETER_DEC", "type": "manual", "value": 19 },
{ "event": "LIGHT_POTENTIOMETER_DEC", "type": "manual", "value": 20 }
],
"alternate_event_up": "CLOCK_MINUTES_INC",
"alternate_event_down": "CLOCK_MINUTES_DEC",
"event_short_press": "{alternate}"
},
{
"index": 3,
"event_up": "COM_RADIO_WHOLE_INC",
"event_down": "COM_RADIO_WHOLE_DEC",
"alternate_event_up": "COM_RADIO_FRACT_INC",
"alternate_event_down": "COM_RADIO_FRACT_DEC",
"event_short_press": "{alternate}",
"event_long_press": "COM_STBY_RADIO_SWAP"
},
{
"index": 4,
"event_up": "NAV1_RADIO_WHOLE_INC",
"event_down": "NAV1_RADIO_WHOLE_DEC",
"alternate_event_up": "NAV1_RADIO_FRACT_INC",
"alternate_event_down": "NAV1_RADIO_FRACT_DEC",
"event_short_press": "{alternate}",
"event_long_press": "NAV1_RADIO_SWAP"
},
{
"index": 5,
"event_up": [
{ "event": "MobiFlight.AS1000_MFD_RANGE_DEC", "type": "manual", "value": 1 },
{ "event": "MobiFlight.AS3X_TOUCH_1_KNOB_INNER_R_DEC", "type": "manual", "value": 1 },
{ "event": "MobiFlight.TSC_Bottom_Knob_DEC", "type": "manual", "value": 1 },
"GPS_ZOOMIN_BUTTON",
"MAGNETO4_DECR"
],
"event_down": [
{ "event": "MobiFlight.AS1000_MFD_RANGE_INC", "type": "manual", "value": 1 },
{ "event": "MobiFlight.AS3X_TOUCH_1_KNOB_INNER_R_INC", "type": "manual", "value": 1 },
{ "event": "MobiFlight.G3000_TSC_Bottom_Knob_Inc", "type": "manual", "value": 1 },
"GPS_ZOOMOUT_BUTTON",
"MAGNETO4_INCR"
],
"event_short_press": "GPS_CURSOR_BUTTON",
"event_long_press": "GPS_ENTER_BUTTON"
},
{
"index": 6,
"event_up": "HEADING_BUG_INC",
"event_down": "HEADING_BUG_DEC",
"event_press": {
"type": "condition-file",
"event": "Functions/Generic/heading-bug-sync.jinja2",
"description": "Set heading bug to current heading"
},
"event_long_press": "{alternate}",
"alternate_event_up": "VOR1_OBI_INC",
"alternate_event_down": "VOR1_OBI_DEC"
},
{
"index": 7,
"event_up": "AP_SPD_VAR_INC",
"event_down": "AP_SPD_VAR_DEC",
"event_press": "{alternate}",
"alternate_event_up": "AP_VS_VAR_INC",
"alternate_event_down": "AP_VS_VAR_DEC"
},
{
"index": 8,
"event_up": "AP_ALT_VAR_INC",
"event_down": "AP_ALT_VAR_DEC",
"event_press": {
"type": "condition-file",
"event": "Functions/Generic/alt-bug-sync.jinja2",
"description": "Set alt bug to current alt"
}
},
{
"index": 13,
"event_up": [
{ "event": "MobiFlight.AS1000_MFD_RANGE_DEC", "type": "manual", "value": 1 },
{ "event": "MobiFlight.AS3X_TOUCH_1_KNOB_INNER_R_DEC", "type": "manual", "value": 1 },
{ "event": "MobiFlight.TSC_Bottom_Knob_DEC", "type": "manual", "value": 1 },
"GPS_ZOOMIN_BUTTON",
"MAGNETO4_DECR"
],
"event_down": [
{ "event": "MobiFlight.AS1000_MFD_RANGE_INC", "type": "manual", "value": 1 },
{ "event": "MobiFlight.AS3X_TOUCH_1_KNOB_INNER_R_INC", "type": "manual", "value": 1 },
{ "event": "MobiFlight.G3000_TSC_Bottom_Knob_Inc", "type": "manual", "value": 1 },
"GPS_ZOOMOUT_BUTTON",
"MAGNETO4_INCR"
],
"event_short_press": "GPS_CURSOR_BUTTON",
"event_long_press": "GPS_ENTER_BUTTON"
},
{
"index": 14,
"event_up": "HEADING_BUG_INC",
"event_down": "HEADING_BUG_DEC",
"event_press": {
"type": "condition-file",
"event": "Functions/Generic/heading-bug-sync.jinja2",
"description": "Set heading bug to current heading"
},
"event_long_press": "{alternate}",
"alternate_event_up": "VOR1_OBI_INC",
"alternate_event_down": "VOR1_OBI_DEC"
},
{
"index": 15,
"event_up": { "event": "MobiFlight.AS1000_PFD_FMS_Upper_INC", "type": "manual", "value": 1 },
"event_down": { "event": "MobiFlight.AS1000_PFD_FMS_Upper_DEC", "type": "manual", "value": 1 },
"alternate_event_up": { "event": "MobiFlight.AS1000_MFD_FMS_Upper_INC", "type": "manual", "value": 1 },
"alternate_event_down": { "event": "MobiFlight.AS1000_MFD_FMS_Upper_DEC", "type": "manual", "value": 1 },
"event_long_press": "{alternate}",
"event_short_press": { "event": "MobiFlight.AS1000_PFD_FMS_Upper_PUSH", "type": "manual", "value": 1 }
},
{
"index": 16,
"event_up": { "event": "MobiFlight.AS1000_PFD_FMS_Lower_INC", "type": "manual", "value": 1 },
"event_down": { "event": "MobiFlight.AS1000_PFD_FMS_Lower_DEC", "type": "manual", "value": 1 },
"alternate_event_up": { "event": "MobiFlight.AS1000_MFD_FMS_Lower_INC", "type": "manual", "value": 1 },
"alternate_event_down": { "event": "MobiFlight.AS1000_MFD_FMS_Lower_DEC", "type": "manual", "value": 1 },
"event_long_press": "{alternate}"
}
],
"buttons": [
{
"index": 1,
"event_press": "TOGGLE_VARIOMETER_SWITCH",
"simvar_led": "VARIOMETER_SWITCH"
},
{
"index": 2,
"event_press": [ "TOGGLE_TAXI_LIGHTS", "STROBES_TOGGLE", "TOGGLE_NAV_LIGHTS", "TOGGLE_BEACON_LIGHTS" ],
"simvar_led": "LIGHT_TAXI_ON"
},
{
"index": 3
},
{
"index": 4,
"event_press": "AP_NAV1_HOLD",
"simvar_led": "AUTOPILOT_NAV1_LOCK"
},
{
"index": 5,
"event_press": "AP_APR_HOLD",
"simvar_led": "AUTOPILOT_APPROACH_HOLD"
},
{
"index": 6,
"event_press": "AP_HDG_HOLD",
"simvar_led": "AUTOPILOT_HEADING_LOCK"
},
{
"index": 7,
"event_press": "AP_PANEL_VS_HOLD",
"simvar_led": "AUTOPILOT_VERTICAL_HOLD"
},
{
"index": 8,
"event_press": "AP_ALT_HOLD",
"simvar_led": "AUTOPILOT_ALTITUDE_LOCK"
},
{
"index": 9,
"event_press": "TOGGLE_MASTER_BATTERY",
"simvar_led": "ELECTRICAL_MASTER_BATTERY"
},
{
"index": 10,
"event_press": "TOGGLE_MASTER_ALTERNATOR",
"simvar_led": "GENERAL_ENG_MASTER_ALTERNATOR"
},
{
"index": 11,
"event_short_press": "ENGINE_AUTO_START",
"event_long_press": "ENGINE_AUTO_SHUTDOWN"
},
{
"index": 12,
"event_press": "AP_MASTER",
"simvar_led": "AUTOPILOT_MASTER"
},
{
"index": 13,
"event_short_press": "TOGGLE_FLIGHT_DIRECTOR",
"event_long_press": "SYNC_FLIGHT_DIRECTOR_PITCH",
"simvar_led": "AUTOPILOT_FLIGHT_DIRECTOR_ACTIVE"
},
{
"index": 14,
"event_press": "YAW_DAMPER_TOGGLE",
"simvar_led": "AUTOPILOT YAW DAMPER"
},
{
"index": 15,
"event_press": [
"ANTI_ICE_TOGGLE_ENG1",
"ANTI_ICE_TOGGLE_ENG2",
"PITOT_HEAT_TOGGLE",
"TOGGLE_STRUCTURAL_DEICE",
"TOGGLE_PROPELLER_DEICE"
],
"simvar_led": "PITOT_HEAT"
},
{
"index": 16,
"event_press": "FLIGHT_LEVEL_CHANGE",
"simvar_led": "AUTOPILOT_FLIGHT_LEVEL_CHANGE"
},
{
"index": 21,
"event_short_press": { "event": "MobiFlight.AS1000_PFD_SOFTKEYS_11", "type": "manual", "value": 1 },
"event_long_press": { "event": "MobiFlight.AS1000_MFD_SOFTKEYS_11", "type": "manual", "value": 1 }
}, {
"index": 22,
"event_short_press": { "event": "MobiFlight.AS1000_PFD_DIRECTTO", "type": "manual", "value": 1 },
"event_long_press": { "event": "MobiFlight.AS1000_MFD_DIRECTTO", "type": "manual", "value": 1 }
},
{
"index": 23,
"event_short_press": { "event": "MobiFlight.AS1000_PFD_MENU_Push", "type": "manual", "value": 1 },
"event_long_press": { "event": "MobiFlight.AS1000_MFD_MENU_Push", "type": "manual", "value": 1 }
},
{
"index": 24,
"event_short_press": { "event": "MobiFlight.AS1000_PFD_ENT_Push", "type": "manual", "value": 1 },
"event_long_press": { "event": "MobiFlight.AS1000_MFD_ENT_Push", "type": "manual", "value": 1 }
},
{
"index": 29,
"event_short_press": { "event": "MobiFlight.AS1000_PFD_SOFTKEYS_12", "type": "manual", "value": 1 },
"event_long_press": { "event": "MobiFlight.AS1000_MFD_SOFTKEYS_12", "type": "manual", "value": 1 }
},
{
"index": 30,
"event_short_press": { "event": "MobiFlight.AS1000_PFD_FPL_Push", "type": "manual", "value": 1 },
"event_long_press": { "event": "MobiFlight.AS1000_MFD_FPL_Push", "type": "manual", "value": 1 }
},
{
"index": 31,
"event_short_press": { "event": "MobiFlight.AS1000_PFD_PROC_Push", "type": "manual", "value": 1 },
"event_long_press": { "event": "MobiFlight.AS1000_MFD_PROC_Push", "type": "manual", "value": 1 }
},
{
"index": 32,
"event_short_press": { "event": "MobiFlight.AS1000_PFD_CLR_Push", "type": "manual", "value": 1 },
"event_long_press": { "event": "MobiFlight.AS1000_MFD_CLR_Push", "type": "manual", "value": 1 }
}
],
"faders": [
{
"index": 1,
"event_change": "FLAPS_SET",
"min_value": 16383,
"max_value": 0
},
{
"index": 2,
"event_change": "FLAPS_SET",
"min_value": 16383,
"max_value": 0
}
],
"triggers": [
{
"trigger_type": "condition-file",
"simvar": "AUTOPILOT_VERTICAL_HOLD",
"condition": "Functions/Generic/ap-spd-vs-encoder-switcher.jinja2"
},
{
"trigger_type": "condition-file",
"simvar": "AUTOPILOT_VERTICAL_HOLD_VAR",
"condition": "Functions/Generic/alt-vs-sync.jinja2"
},
{
"trigger_type": "condition-file",
"simvar": "VERTICAL_SPEED",
"condition": "Functions/Generic/alt-vs-sync.jinja2"
},
{
"trigger_type": "condition-file",
"simvar": "KOHLSMAN_SETTING_HG",
"condition": "Functions/Generic/baro-sync.jinja2"
},
{
"trigger_type": "condition-file",
"simvar": "COM_ACTIVE_FREQUENCY:1",
"condition": "Functions/Generic/com-sync.jinja2"
},
{
"trigger_type": "condition-file",
"simvar": "NAV_ACTIVE_FREQUENCY:1",
"condition": "Functions/Generic/nav-sync.jinja2"
},
{
"trigger_type": "condition-file",
"simvar": "INDICATED_ALTITUDE",
"condition": "Functions/Generic/alt-lock-sync.jinja2"
},
{
"trigger_type": "condition-file",
"simvar": "AUTOPILOT_HEADING_LOCK_DIR",
"condition": "Functions/Generic/hdg-lock-sync.jinja2"
},
{
"trigger_type": "condition-file",
"simvar": "HEADING_INDICATOR",
"condition": "Functions/Generic/hdg-lock-sync.jinja2"
},
{
"trigger_type": "condition-file",
"simvar": "AUTOPILOT_YAW_DAMPER",
"condition": "Functions/Generic/yd-active-sync.jinja2"
},
{
"trigger_type": "condition-file",
"simvar": "ELECTRICAL_BATTERY_LOAD",
"condition": "Functions/Generic/batt-load-sync.jinja2"
}
],
"initialization": {
"global_variables": [
{
"name": "BARO_ENC_IDX",
"value": 1
},
{
"name": "COM_ENC_IDX",
"value": 3
},
{
"name": "NAV_ENC_IDX",
"value": 4
},
{
"name": "HEADING_ENC_IDX",
"value": 6
},
{
"name": "AP_SPD_ENC_IDX",
"value": 7
},
{
"name": "ALT_ENC_IDX",
"value": 8
},
{
"name": "YD_BUT_IDX",
"value": 14
},
{
"name": "BATT_BUT_IDX",
"value": 9
}
]
}
}
Thank’s for your script! but … your script calls a lot of functions that i miss in my configuration folder. where can i find them? Sorry for my english … Grazie
.
Do the rotary knobs on this thing have high enough number of registered positions to function as selector for heading bug, CDI OBS knob, and gyro compass course correction etc. (i.e. at least 360)? I understand that the knobs have infinite range of movement, but do they register sufficient number of positions too?
YES … works very well – I use AAO with “Both” my X-Touch Minis !!
16 (x2) Rotary controls
here’s all my function files. you’ll have to save each to a separate .jinja2 file:
C:\GameData\X-Touch-Mini-FS2020\Configurations\Functions\Generic>type *
adf-down-encoder-condition.jinja2
{% if data.get_global_variable('ADF_SELECTION') == 100 %}
{{ data.trigger_event('ADF_100_DEC', 1) }}
{% elif data.get_global_variable('ADF_SELECTION') == 10 %}
{{ data.trigger_event('ADF_10_DEC', 1) }}
{% else %}
{{ data.trigger_event('ADF_1_DEC', 1) }}
{% endif %}
adf-press-encoder-condition.jinja2
{% if data.get_global_variable('ADF_SELECTION') == 1 %}
{{ data.print('ADF_SELECTION 10') }}
{{ data.set_global_variable('ADF_SELECTION', 10) }}
{{ data.set_encoder_led_value(7, 7) }}
{% elif data.get_global_variable('ADF_SELECTION') == 10 %}
{{ data.print('ADF_SELECTION 100') }}
{{ data.set_global_variable('ADF_SELECTION', 100) }}
{{ data.set_encoder_led_value(7, 13) }}
{% else %}
{{ data.print('ADF_SELECTION 1') }}
{{ data.set_global_variable('ADF_SELECTION', 1) }}
{{ data.set_encoder_led_value(7, 1) }}
{% endif %}
adf-up-encoder-condition.jinja2
{% if data.get_global_variable('ADF_SELECTION') == 100 %}
{{ data.trigger_event('ADF_100_INC', 1) }}
{% elif data.get_global_variable('ADF_SELECTION') == 10 %}
{{ data.trigger_event('ADF_10_INC', 1) }}
{% else %}
{{ data.trigger_event('ADF_1_INC', 1) }}
{% endif %}
alt-bug-sync.jinja2
{# Set the alt bug to the current alt nearest 100 #}
{% set alt = (data.get_simvar_value('INDICATED_ALTITUDE') /100) | round | int %}
{{ data.trigger_event('AP_ALT_VAR_SET_ENGLISH', alt * 100) }}
alt-lock-sync.jinja2
{% set encoder_index = data.get_global_variable('ALT_ENC_IDX') %}
{% set bug = (data.get_simvar_value('AUTOPILOT_ALTITUDE_LOCK_VAR') /100) | round | int %}
{% set alt = (data.get_simvar_value('INDICATED_ALTITUDE') /100 ) %}
{% set knob = ((bug-alt) + 7)*10 | round /10 %}
{% if knob < 1 %}
{% set knobpos = 1 %}
{% elif knob > 13 %}
{% set knobpos = 13 %}
{% else %}
{% set knobpos = knob %}
{% endif %}
{#{ data.print('alt ' ~ alt ~' bug ' ~ bug ~' knob ' ~ knobpos) }#}
{{ data.set_encoder_led_value(encoder_index, knobpos) }}
alt-vs-sync.jinja2
{% set encoder_index = data.get_global_variable('AP_SPD_ENC_IDX') %}
{% if data.get_simvar_value('AUTOPILOT_VERTICAL_HOLD') == 1.0 %}
{% set bug = (data.get_simvar_value('AUTOPILOT_VERTICAL_HOLD_VAR') /200) | round | int %}
{% else %}
{% set bug = (data.get_simvar_value('VERTICAL_SPEED') /200) | round | int %}
{% endif %}
{% set knob = ((bug) + 7)*10 | round /10 %}
{% if knob < 1 %}
{% set knobpos = 1 %}
{% elif knob > 13 %}
{% set knobpos = 13 %}
{% else %}
{% set knobpos = knob %}
{% endif %}
{#{ data.print(' vs bug ' ~ bug ~' knob ' ~ knobpos) }#}
{{ data.set_encoder_led_value(encoder_index, knobpos) }}
ap-spd-vs-encoder-switcher.jinja2
{% set encoder_index = data.get_global_variable('AP_SPD_ENC_IDX') %}
{% if data.get_simvar_value('AUTOPILOT_VERTICAL_HOLD') == 1.0 %}
{{ data.trigger_encoder_alternate(encoder_index, True) }}
{{ data.set_encoder_led(encoder_index, True) }}
{% else %}
{{ data.print(' vs ' ~ bug ~' knob ' ~ knobpos) }}
{{ data.trigger_encoder_alternate(encoder_index, False) }}
{{ data.set_encoder_led(encoder_index, False) }}
{% endif %}
baro-sync.jinja2
{# Set the baro encoder ring to range 29 - 31 #}
{% set encoder_index = data.get_global_variable('BARO_ENC_IDX') %}
{% set baro = (data.get_simvar_value('KOHLSMAN_SETTING_HG') *100) | round |int /100 %}
{% set knob = (((baro *14) -411.38) *10) | round |int /10 %}
{% if knob < 1 %}
{% set knobpos = 1 %}
{% elif knob > 13 %}
{% set knobpos = 13 %}
{% else %}
{% set knobpos = knob %}
{% endif %}
{{ data.print('baro ' ~ baro ~' knob ' ~ knobpos) }}
{{ data.set_encoder_led_value(encoder_index, knobpos) }}
batt-load-sync.jinja2
{% set button_index = data.get_global_variable('BATT_BUT_IDX') %}
{% set batt_load = data.get_simvar_value('ELECTRICAL_BATTERY_LOAD') %}
{% set battery_on = data.get_simvar_value('ELECTRICAL_MASTER_BATTERY') %}
{{ data.set_button_led(button_index, battery_on, blink=(batt_load < 0)) }}
com-sync.jinja2
{# Set the com encoder ring to range 118 - 139 #}
{% set encoder_index = data.get_global_variable('COM_ENC_IDX') %}
{% set com = data.get_simvar_value('COM_ACTIVE_FREQUENCY:1') %}
{% set knob = (((com *0.6) -70) *10) | round |int /10 %}
{% if knob < 1 %}
{% set knobpos = 1 %}
{% elif knob > 13 %}
{% set knobpos = 13 %}
{% else %}
{% set knobpos = knob %}
{% endif %}
{{ data.print('com ' ~ com ~' knob ' ~ knobpos) }}
{{ data.set_encoder_led_value(encoder_index, knobpos) }}
flaps-position-sync.jinja2
{% set flaps_up_button_index = data.get_global_variable('FLAPS_UP_BUT_IDX') %}
{% set flaps_down_button_index = data.get_global_variable('FLAPS_DN_BUT_IDX') %}
{% set flaps_position = data.get_simvar_value('FLAPS_HANDLE_INDEX') %}
{% set gear_down = data.get_simvar_value('GEAR_POSITION') %}
{% if flaps_position == 0 %}
{{ data.set_button_led(flaps_up_button_index, 1) }}
{{ data.set_button_led(flaps_down_button_index, 0) }}
{% else %}
{% if gear_down == 1 %}
{{ data.set_button_led(flaps_up_button_index, 0) }}
{{ data.set_button_led(flaps_down_button_index, 1, blink=False) }}
{% else %}
{{ data.set_button_led(flaps_up_button_index, 0) }}
{{ data.set_button_led(flaps_down_button_index, 1, blink=True) }}
{% endif %}
{% endif %}
gear-position-sync.jinja2
{% set button_index = data.get_global_variable('GEAR_BUT_IDX') %}
{% set gear_down = data.get_simvar_value('GEAR_POSITION') %}
{% if gear_down != 1 and gear_down != 0 %}
{{ data.set_button_led(button_index, 1, blink=True) }}
{% else %}
{{ data.set_button_led(button_index, gear_down) }}
{% endif %}
hdg-lock-sync.jinja2
{% set encoder_index = data.get_global_variable('HEADING_ENC_IDX') %}
{# HEADING_INDICATOR returns in radians but need it in degrees - encoder should show relative bug position #}
{% set bug = (data.get_simvar_value('AUTOPILOT_HEADING_LOCK_DIR')) | round | int %}
{% set hdg = ((data.get_simvar_value('HEADING_INDICATOR') * 180 / 3.1415)) %}
{% set knob = (((bug - hdg) / 27) + 7)*10 | round |int /10 |round %}
{% if knob < 0 %}
{% set knobpos = knob + 14 %}
{% elif knob > 13 %}
{% set knobpos = knob - 14 %}
{% else %}
{% set knobpos = knob %}
{% endif %}
{#{ data.print('hdg ' ~ hdg ~' bug ' ~ bug ~' knob ' ~ knobpos) }#}
{{ data.set_encoder_led_value(encoder_index, knobpos) }}
hdg-lock-sync.jinja2.bak
{% set encoder_index = data.get_global_variable('HEADING_ENC_IDX') %}
{% set heading = (data.get_simvar_value('AUTOPILOT_HEADING_LOCK_DIR') / 27.0) | round %}
{{ data.set_encoder_led_value(encoder_index, heading) }}
heading-bug-sync.jinja2
{# Set the heading bug to the current flown heading #}
{# HEADING_INDICATOR returns in radians but HEADING_BUG_SET needs it in degrees #}
{% set heading = (data.get_simvar_value('HEADING_INDICATOR') * 180 / 3.14) | round %}
{{ data.trigger_event('HEADING_BUG_SET', heading) }}
nav-sync.jinja2
{# Set the nav encoder ring to range 108 - 118 #}
{% set encoder_index = data.get_global_variable('NAV_ENC_IDX') %}
{% set nav = data.get_simvar_value('NAV_ACTIVE_FREQUENCY:1') %}
{% set knob = (((nav *1.6) -173) *10) | round |int /10 %}
{% if knob < 1 %}
{% set knobpos = 1 %}
{% elif knob > 13 %}
{% set knobpos = 13 %}
{% else %}
{% set knobpos = knob %}
{% endif %}
{{ data.print('nav ' ~ nav ~' knob ' ~ knobpos) }}
{{ data.set_encoder_led_value(encoder_index, knobpos) }}
vor-bug-sync.jinja2
{% set heading = (data.get_simvar_value('HEADING_INDICATOR') * 180 / 3.14) | round %}
{{ data.trigger_event('VOR1_SET', heading) }}
yd-active-sync.jinja2
{% set button_index = data.get_global_variable('YD_BUT_IDX') %}
{% set yaw_damper_active = data.get_simvar_value('AUTOPILOT_YAW_DAMPER') %}
{% set gear_down = data.get_simvar_value('GEAR_POSITION') %}
{% if yaw_damper_active == 1 and gear_down > 0 %}
{{ data.set_button_led(button_index, 1, blink=True) }}
{% else %}
{{ data.set_button_led(button_index, yaw_damper_active) }}
{% endif %}
not working, i think i tested every command in the command list file :-/
Hi,
Do you where does the plug-in search for the mobiflight events ?
OK. Found it. Community directory
How can I put in the ILS frequency at the A 320 Neo?
hi ppl. trying to implement my x-touch with msfs using AAO.
i am just at the starting point i am using these two things:
http://www.funatic.de/XTMGLB/alpha.html
as well as the xml scripts provided within this one: CJ4 AAO Scripts & StreamDeck XL Profile and MCP Combo template » Microsoft Flight Simulator
my x-touch programmed withe the default settings (provided files within x-touch editor)
However, i struggle to implement the following
-
i would like to zoom in/out the cockpit view with an encoder (like you normally do with the middle mouse using default msfs mouse settings). i tried all of the 3 different sets of zoom options (in the pic marked all 3 sets, and one set added as an example)
-
Working Title CJ4: i would like to put the spoiler on the x-touch slider. so when the slider is full-forwad it means no spoilers, and moving it to the back (towards the operator) it means gradually deploy spoilers until full deployed (like the spoiler handle in the cockpit of the WT CJ4). i found out with the AAO reading out the events when moving the spoiler handly by mouse in the cockpit triggers the following: >K:SPOILERS_SET … however i dont know how to set this one up within AAO.
thanks for your help!
Thanks a lot to Thomas (Funatic>Discord), the Zoom on the encoder and the spoilers on the fader (WT CJ4) now works in AAO. here the things you put into your Layer File used within AxisAndOhs
- Zoom
1.1) Script for the Encoder#1:
:Rotary_1_Left
(A:COCKPIT CAMERA ZOOM, Percentage) 10 - 0 max 100 min (>A:COCKPIT CAMERA ZOOM, Percentage) (END)
:Rotary_1_Right
(A:COCKPIT CAMERA ZOOM, Percentage) 10 + 0 max 100 min (>A:COCKPIT CAMERA ZOOM, Percentage) (END)
1.2) LED for Zoom on Encoder#1:
(A:COCKPIT CAMERA ZOOM, Percentage) 100 / 13 * near 32 + 1 @XTouch_Macro_LED_Value
- Spoiler of the WT CJ4 on the SLider
2.1) Fader Script:
:SliderScript
(L:XTouch_SliderAxisValue) -1 * 16384 + 2 / 0 max 16383 min (>K:SPOILERS_SET) (END)
2.2) since the fader delivers values from -16383 to 16383, these are many values the AAO script has to get from the device, which causes small fps drops. to counteract, the following script to be imported into AAO reduces the amount of queries.
- copy the following code into a text exitor and save it as a *.xml file.
<?xml version="1.0" encoding="utf-8"?>
<ScriptList xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<scripts>
<Script>
<group>XTouch</group>
<label>AXIS_Slider_SET</label>
<script>(L:XTouch-AXIS_Slider_SET) 1638.4 / near 1638.4 * near d (>L:XTouch_SliderAxisValue) (L:XTouch_SliderAxisValue) != if{ 0 (>K:XTouch-MISC_CallScriptLabel_EXEC;SliderScript) }</script>
<edition><Section xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xml:space="preserve" TextAlignment="Left" LineHeight="Auto" IsHyphenationEnabled="False" xml:lang="en-us" FlowDirection="LeftToRight" NumberSubstitution.CultureSource="Text" NumberSubstitution.Substitution="AsCulture" FontFamily="Courier New" FontStyle="Normal" FontWeight="Normal" FontStretch="Normal" FontSize="12" Foreground="#FF000000" Typography.StandardLigatures="True" Typography.ContextualLigatures="True" Typography.DiscretionaryLigatures="False" Typography.HistoricalLigatures="False" Typography.AnnotationAlternates="0" Typography.ContextualAlternates="True" Typography.HistoricalForms="False" Typography.Kerning="True" Typography.CapitalSpacing="False" Typography.CaseSensitiveForms="False" Typography.StylisticSet1="False" Typography.StylisticSet2="False" Typography.StylisticSet3="False" Typography.StylisticSet4="False" Typography.StylisticSet5="False" Typography.StylisticSet6="False" Typography.StylisticSet7="False" Typography.StylisticSet8="False" Typography.StylisticSet9="False" Typography.StylisticSet10="False" Typography.StylisticSet11="False" Typography.StylisticSet12="False" Typography.StylisticSet13="False" Typography.StylisticSet14="False" Typography.StylisticSet15="False" Typography.StylisticSet16="False" Typography.StylisticSet17="False" Typography.StylisticSet18="False" Typography.StylisticSet19="False" Typography.StylisticSet20="False" Typography.Fraction="Normal" Typography.SlashedZero="False" Typography.MathematicalGreek="False" Typography.EastAsianExpertForms="False" Typography.Variants="Normal" Typography.Capitals="Normal" Typography.NumeralStyle="Normal" Typography.NumeralAlignment="Normal" Typography.EastAsianWidths="Normal" Typography.EastAsianLanguage="Normal" Typography.StandardSwashes="0" Typography.ContextualSwashes="0" Typography.StylisticAlternates="0"><Paragraph><Run FontStyle="Italic" FontWeight="Bold" Background="#FFFFFFFF">//·XTouch·Slider·Axis</Run></Paragraph><Paragraph><Run FontStyle="Italic" Background="#FFFFFFFF">//·Default·Settings·-16384·..·16384</Run></Paragraph><Paragraph><Run Background="#FFFFFFFF"></Run></Paragraph><Paragraph><Run Background="#FFFFFFFF">(L:XTouch-AXIS_Slider_SET)</Run></Paragraph><Paragraph><Run Background="#FFFFFFFF"></Run></Paragraph><Paragraph><Run xml:lang="de-de" Background="#FFFFFFFF">1638.4·/·near·1638.4·*·near</Run></Paragraph><Paragraph><Run xml:lang="de-de" Background="#FFFFFFFF">d</Run><Run Background="#FFFFFFFF">·</Run><Run xml:lang="de-de" Background="#FFFFFFFF">(&gt;L:XTouch_SliderAxisValue)</Run></Paragraph><Paragraph><Run xml:lang="de-de" Background="#FFFFFFFF">(L:XTouch_SliderAxisValue)·!=·if{·0</Run><Run Background="#FFFFFFFF">·(&gt;K:XTouch-MISC_CallScriptLabel_EXEC;</Run><Run xml:lang="de-de" Background="#FFFFFFFF">SliderScript</Run><Run Background="#FFFFFFFF">)·</Run><Run xml:lang="de-de" Background="#FFFFFFFF">}</Run></Paragraph></Section></edition>
</Script>
</scripts>
</ScriptList>
-
Within AAO, click Scripting>Import Scripts
-
select the xml file created within the first step here and click open
-
in the small pop up window that appears within AAO, tick the boxes and click Import. when it prompts and ask, click yes to overwrite existing script.
-
in the next promt to overwrite all duplicate scripts, click yes.
now you are up to go!
Note:
prerequisites: X-Touch Mini Gauge for use with AAO (Axis and Ohs) » Microsoft Flight Simulator
Hey there, could you explain how this works? I am able to set the light, however the standard behavior of the light is triggered first.
Hello there, anyone working FBW A32x events/vars bound to X-Touch-Mini via FS2020-X-Touch-Mini? I mean FBW events/vars (e.g., now I am trying to resolve how to bound AP2), not FS2020 events/vars. I am able to find name of variables via mobiflight, but have no idea how to get them working with FS2020-X-touch-mini.
Any minimal working example appreciated.
TIA