Jump to content

Keybinds for using ON/OF type commands are faulty and the resulting action does not match the key used, or listed in Commands list.


WillyPete

Recommended Posts

Example:

Commands list shows "LCTRL+LSHIFT+1" for "Battery 1 ON/OFF".  

However "LCTRL+LSHIFT+2" is the working key for "Battery 1 ON/OFF" even though that keybind is assigned to "Battery 2 ON/OFF"

 

Findings: 

In the commands list, setting "LCTRL+LSHIFT+1" to the  "Battery 1 ON" command allows the use of "LCTRL+LSHIFT+1" properly.   

 

In default.lua for keyboard input: 

"Battery 1 ON"  has the entry of "device_commands.Button_3"  

"Battery 1 ON/OFF"  has the entry of "device_commands.Button_111"    

 

 

All keybinds that use a 3 numeral identifier in the "device_commands.Button_XXX" entry in the default.lua used for input in the Mi-8 mod are faulty.  


Edited by WillyPete
  • Like 1
  • Thanks 1
Link to comment
Share on other sites

It's become obvious to me that there is a version control error for either Input>Keyboard>default.lua or Cockpit>Scripts>clickabledata.lua in the module files.  

 

To start with, I tried to find a command in the autostart macro that was not working.   

In autostart, the pilot's window does not close.

 

Macro_sequences.lua is the autostart macro for the Mi-8.  

During the startup, the macro calls to close the pilot's seat "Blister" or window.  

The command calls  

push_start_command(1.0,{device = devices.CPT_MECH, action =  device_commands.Button_15, value = 1.0})

 

clickabledata.lua uses the same Button variable when it specifies the type of action to be used:  

elements["PTR-BLISTER-LOCK-L"]	= default_2_position_tumb(_("Left Blister, OPEN/CLOSE"),devices.CPT_MECH, device_commands.Button_15, 215)

 

The default keybind does work for the pilot window.  

These are found in default.lua.  

default.lua has the following variable for the Blister (window):  

{combos = {{key = 'C', reformers = {'LCtrl'}}},				down = device_commands.Button_18,  value_down = 1,	cockpit_device_id = devices.CPT_MECH,	name = _('Open/Close Left Blister'),			category = _('Systems')},

 

 

The first two refer to device_commands_Button_15 while default.lua uses _18  

It's clear that many of the default keybinds, are not calling the correct commands and are mismatched between the different lua's that reference them.

Link to comment
Share on other sites

Thanks Flappie.  

 

This is new ground for me.  

Are there any approved guides that I can read to give me greater insight as to how the dependencies work between the lua files?    

 

For instance, am I right in thinking that macro_sequences.lua is actually looking up clickabledata.lua when it makes a call to "device_commands.Button_15" or is it referencing a different lua ort even a dll?  

Just to save me barking up the wrong tree and spouting inaccurate claims in trying to resolve my issues.

Link to comment
Share on other sites

Further to my last posts on locating the error.  

 

All faulty keybinds are restricted to the devices defined by three determining factors:  

They all belong to the device class: cockpit_device_id = devices.ELEC_INTERFACE,  

They all have a 3 digit identifier as seen in default.lua :    device_commands.Button_120  

They are all multi-action commands (ON/OFF, rheostat axis, CCW/CW, Cover OPEN/CLOSE)

 

The identifier matches that found in the hash that is visible when you export the keyboard bindings to HTML. (export is of a default bind list)  

Example: 

d3120pnilunilcd1vd1vpnilvunil  assigned to the action AC Ground Power Switch - ON/OFF

 

Using that example, if we increment the device ID number in the hash identifier by 1, we get d3121pnilunilcd1vd-1vpnilvunil which is the hash for 115V Inverter Switch - Down action.   

Using the default keyboard binding for AC Ground Power Switch - ON/OFF which is LALT+LSHIFT+` then we notice the 115V Inverter Switch being activated instead.

 

The finding is thus that the default keybind is activating the interface listed by the hash incremented by 1 for some of the faulty keys.   

 

The first bound key to suffer from this is the binding:  

RCtrl - 0    Battery Heating Switch - ON/OFF    Right Side Panel    d3107pnilunilcd1vd1vpnilvunil  

 

106 is the first listed hash, but there is no device bound to it. 

Binding a key to it offers correct function as the d3106 hash is for the separate On or Off actions, and not the ON/OFF action for d3107.  

 

106 and 107 are also unique in the default.lua in that they are the only commands with "cb_start_cmd +" instead of "device_commands.Button_"

Additional findings were that while the keybinds were affecting hash+1, they were also affecting the TYPE of action for the interface as defined in clickabledata.lua   

The sequence of +1 is also not maintained strictly, indicating it is not merely an issue of decrementing some values to correct it.  

 

Example:  
LALT+LSHIFT+9, LALT+LSHIFT+0, LALT+LSHIFT+-, LALT+LSHIFT+= are for the Gen 1 Voltage Rheostats CCW, CW and Gen 2 Voltage Rheostat CCW, CW respectively.  
LALT+LSHIFT+9 (assigned hash d3124) instead activates the AC Voltage selector (hash d3123 device), but also causes it to turn like a rheostat (device_axis_limited in clickabledata.lua) instead of a clicking Position Switch (multiposition_switch in clickabledata.lua)

 

The same happens for the DC Voltage selector (hash d3116) when you use the commands for the DC Rheostat (hash 117; LCTRL+LSHIFT+ -or=)

 

This indicates that the command sent to the sim is activating the next or previous device according to hash number, but driving the action as per the correct hash identifier.  

What appears to be an anomaly is that the Multiposition_switch type action is not present.   

I suspect that the two multiposition switches (DC and AC Selector) in the devices.ELEC_INTERFACE are missing from where the sim looks up the desired action called by the keybind, and the other actions have "filled the gaps".    

Keybinds are calling the wrong action, but they are dragging their correct device behaviour with them.  

If the action they are calling can't perform the device behaviour, the action simply fails.  

 

This would also explain why keybinds for inputs assigned to hashes d3106-108 do not cause any action, and the same for hash d3126, and why the keys activate the hashes+1 before the DC selector, and hash-1 after the AC selector.

 

Keys bound to single actions in the command list work as intended, *except* for the CCW/CW actions on multi_selector devices.  Before and after these, multi action commands (ON/OFF) all fail.  

 

Sorry this is so round-about and not a short comment, but I'm hitting this blind and having to make assumptions about dependencies and references in the ED file structure.  

I don't know what role the hashes or device ID numbers play in this structure.  

Basically it's a "I think we should look here, and this is why." type of post.  

 

Good luck.

 

  • Thanks 1
Link to comment
Share on other sites

  • 1 month later...

I've found these issues so far. I've just added them to the bug report.

  • LCtrl + LShift + 1 is labeled "Battery 1" yet it actuates "Rectifier 3" switch.
  • LCtrl + LShift + 2 is labeled "Battery 2" yet it actuates "Battery 1" switch.
  • LCtrl + LShift + 3 is labeled "Standby Generator" yet it actuates "Battery 2" switch.
  • LCtrl + LShift + 4 is labeled "Rectifier 1" and doesn't seem to do anything.
  • LCtrl + LShift + 5 is labeled "Rectifier 2" yet it actuates "Rectifier 1" switch.
  • LCtrl + LShift + 6 is labeled "Rectifier 3" yet it actuates "Rectifier 2" switch.
  • LCtrl + LShift + 7 is labeled "DC Ground Power" yet it actuates "Standby Generator" switch.
  • LCtrl + LShift + 8 is labeled "Equipement test" yet it actuates "DC Ground Power" switch.
  • LCtrl + LShift + 9 is labeled "DC Voltmeter selector CCW" yet i actuates "Equipement test switch" switch.
  • LCtrl + LShift + 0 is labeled "DC Voltmeter selector CW" yet it actuates "Equipement test switch" switch as well.
  • LAlt + LShift + ` is labeled "AC Ground Power" yet it actuates "Generator 2" switch.
  • LAlt + LShift + 1 is labeled "Generator 1" yet it actuates "Standby Generator Voltage Adjustment" rheostat.
  • LAlt + LShift + 2 is labeled "Generator 2" yet it actuates "Generator 1" switch.
  • LAlt + LShift + 3 is labeled "115 V Inverter switch down" yet it actuates "AC Ground Power" switch.
  • LAlt + LShift + 4 is labeled "115 V Inverter switch up" yet it actuates "AC Ground Power" switch as well.
  • LAlt + LShift + 5 is labeled "36 V Inverter switch down" yet it actuates "115 V Inverter" switch down.
  • LAlt + LShift + 6 is labeled "36 V Inverter switch up" yet it actuates "115 V Inverter" switch up.
  • LAlt + LShift + 7 is labeled "AC Voltmeter Selector switch CCW" yet it actuates "36 V Inverter" switch down.
  • LAlt + LShift + 8 is labeled "AC Voltmeter Selector switch CW" yet it actuates "36 V Inverter" switch up.
  • LAlt + LShift + 9 is labeled "Generator 1 Voltage Adjustment Rheostat CCW" yet it actuates "AC Voltmeter selector CCW".
  • LAlt + LShift + 0 is labeled "Generator 1 Voltage Adjustment Rheostat CW" yet it actuates "AC Voltmeter selector CW".
  • LAlt + LShift + - is labeled "Generator 2 Voltage Adjustment Rheostat CCW" yet it actuates "Generator 1 Voltage Adjustment Rheostat CCW".
  • LAlt + LShift + = is labeled "Generator 2 Voltage Adjustment Rheostat CW" yet it actuates "Generator 1 Voltage Adjustment Rheostat CW".
  • LCtrl + Alt + F is labeled "36V Transformer Selector Switch - Down" and doesn't seem to do anything.
  • LCtrl + Alt + R is labeled "36V Transformer Selector Switch - Up" and doesn't seem to do anything.
  • LAlt + LWin + 8 is labeled "Anti-Icing System Amperemeter Selector CCW" yet it actuates "BypassSwitch Cover".
  • LAlt + LCtrl + S is labeled "Net on Rectifier Cover" switch and doesn't seem to do anything.
  • LAlt + LCtrl + D is labeled "Net on Rectifier" switch yet it actuates "Net on Rectifier Cover".
  • Thanks 1

Don't accept indie game testing requests from friends in Discord. Ever.

Link to comment
Share on other sites

  • 2 months later...

I'm working on an update for the keybinds project for the Mi-8 and have fixes for a lot of those if anyone is interested in dropping some LUA code in. The toggles, up/down, and CW/CCW commands starting with Button_108 are offset by one and should be incremented (ie, 'Rectifier 1 Switch - ON/OFF' uses 'device_commands.Button_108' but should be 'device_commands.Button_109').

I kind of lucked out that the up/down and CW/CCW ones still increment/decrement by 1, and toggle switches worked, with a value of 2 passed (to differentiate them from the default controls without having to edit the default files). I should have the full keybinds project update checked into github in the next few days (just finished up with all the circuit breakers).

@Flappie I haven't been able to find a fix for 'Battery Heating ON/OFF' toggle, and didn't see it on your list. Could you check/confirm if it's a candidate for your bug report?

Edit: Forgot to mention all the fixes have (Fixed) appended in the name and are in a new Electric Panels Fixes category.

-- Electric System Panels

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_119, value_down = 2, name = _('Generator 1 Switch - ON/OFF (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_15, up = device_commands.Button_15, value_down = 0, value_up = 1, name = _('Generator 1 Switch - OFF else ON (2-way Switch)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_15, up = device_commands.Button_15, value_down = 1, value_up = 0, name = _('Generator 1 Switch - ON else OFF (2-way Switch)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_120, value_down = 2, name = _('Generator 2 Switch - ON/OFF (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_16, up = device_commands.Button_16, value_down = 0, value_up = 1, name = _('Generator 2 Switch - OFF else ON (2-way Switch)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_16, up = device_commands.Button_16, value_down = 1, value_up = 0, name = _('Generator 2 Switch - ON else OFF (2-way Switch)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_121, value_down = 2, name = _('AC Ground Power Switch - ON/OFF (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_14, up = device_commands.Button_14, value_down = 0, value_up = 1, name = _('AC Ground Power Switch - OFF else ON (2-way Switch)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_14, up = device_commands.Button_14, value_down = 1, value_up = 0, name = _('AC Ground Power Switch - ON else OFF (2-way Switch)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_122, value_down = -2, name = _('115V Inverter Switch - Down (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_122, value_down = 2, name = _('115V Inverter Switch - Up (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_12, up = device_commands.Button_12, value_down = -1, value_up = 0, name = _('115V Inverter Switch - AUTO else OFF (3-way Switch Down)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_12, up = device_commands.Button_12, value_down = 1, value_up = 0, name = _('115V Inverter Switch - MANUAL else OFF (3-way Switch Up)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_123, value_down = -2, name = _('36V Inverter Switch - Down (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_123, value_down = 2, name = _('36V Inverter Switch - Up (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_13, up = device_commands.Button_13, value_down = -1, value_up = 0, name = _('36V Inverter Switch - AUTO else OFF (3-way Switch Down)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_13, up = device_commands.Button_13, value_down = 1, value_up = 0, name = _('36V Inverter Switch - MANUAL else OFF (3-way Switch Up)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 0, name = _('AC Voltmeter Selector Switch - OFF'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 0.1, name = _('AC Voltmeter Selector Switch - GENERATOR 1 I-II'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 0.2, name = _('AC Voltmeter Selector Switch - GENERATOR 1 II-III'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 0.3, name = _('AC Voltmeter Selector Switch - GENERATOR 1 III-I'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 0.4, name = _('AC Voltmeter Selector Switch - GENERATOR 2 I-II'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 0.5, name = _('AC Voltmeter Selector Switch - GENERATOR 2 II-III'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 0.6, name = _('AC Voltmeter Selector Switch - GENERATOR 2 III-I'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 0.7, name = _('AC Voltmeter Selector Switch - EXT PWR I-II'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 0.8, name = _('AC Voltmeter Selector Switch - EXT PWR II-III'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 0.9, name = _('AC Voltmeter Selector Switch - EXT PWR III-I'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 1, name = _('AC Voltmeter Selector Switch - 115V'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_124, value_down = -2, name = _('AC Voltmeter Selector Switch - CCW (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_124, value_down = 2, name = _('AC Voltmeter Selector Switch - CW (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_8, value_down = 0, name = _('DC Voltmeter Selector Switch - OFF (LEFT)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_8, value_down = 0.1, name = _('DC Voltmeter Selector Switch - BATTERY 1'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_8, value_down = 0.2, name = _('DC Voltmeter Selector Switch - BATTERY 2'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_8, value_down = 0.3, name = _('DC Voltmeter Selector Switch - STBY GEN'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_8, value_down = 0.4, name = _('DC Voltmeter Selector Switch - BUSES BATT'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_8, value_down = 0.5, name = _('DC Voltmeter Selector Switch - BUSES RECT'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_8, value_down = 0.6, name = _('DC Voltmeter Selector Switch - EXT PWR'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_8, value_down = 0.7, name = _('DC Voltmeter Selector Switch - OFF (RIGHT)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_117, value_down = -2, name = _('DC Voltmeter Selector Switch - CCW (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_117, value_down = 2, name = _('DC Voltmeter Selector Switch - CW (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_112, value_down = 2, name = _('Battery 1 Switch - ON/OFF (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_3, up = device_commands.Button_3, value_down = 0, value_up = 1, name = _('Battery 1 Switch - OFF else ON (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_3, up = device_commands.Button_3, value_down = 1, value_up = 0, name = _('Battery 1 Switch - ON else OFF (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_113, value_down = 2, name = _('Battery 2 Switch - ON/OFF (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_2, up = device_commands.Button_2, value_down = 0, value_up = 1, name = _('Battery 2 Switch - OFF else ON (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_2, up = device_commands.Button_2, value_down = 1, value_up = 0, name = _('Battery 2 Switch - ON else OFF (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_114, value_down = 2, name = _('Standby Generator Switch - ON/OFF (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_1, up = device_commands.Button_1, value_down = 0, value_up = 1, name = _('Standby Generator Switch - OFF else ON (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_1, up = device_commands.Button_1, value_down = 1, value_up = 0, name = _('Standby Generator Switch - ON else OFF (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_109, value_down = 2, name = _('Rectifier 1 Switch - ON/OFF (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_7, up = device_commands.Button_7, value_down = 0, value_up = 1, name = _('Rectifier 1 Switch - OFF else ON (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_7, up = device_commands.Button_7, value_down = 1, value_up = 0, name = _('Rectifier 1 Switch - ON else OFF (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_110, value_down = 2, name = _('Rectifier 2 Switch - ON/OFF (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_5, up = device_commands.Button_5, value_down = 0, value_up = 1, name = _('Rectifier 2 Switch - OFF else ON (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_5, up = device_commands.Button_5, value_down = 1, value_up = 0, name = _('Rectifier 2 Switch - ON else OFF (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_111, value_down = 2, name = _('Rectifier 3 Switch - ON/OFF (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_6, up = device_commands.Button_6, value_down = 0, value_up = 1, name = _('Rectifier 3 Switch - OFF else ON (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_6, up = device_commands.Button_6, value_down = 1, value_up = 0, name = _('Rectifier 3 Switch - ON else OFF (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_115, value_down = 2, name = _('DC Ground Power Switch - ON/OFF (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_4, up = device_commands.Button_4, value_down = 0, value_up = 1, name = _('DC Ground Power Switch - OFF else ON (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_4, up = device_commands.Button_4, value_down = 1, value_up = 0, name = _('DC Ground Power Switch - ON else OFF (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_116, value_down = 2, name = _('Equipment Test Switch - ON/OFF (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_9, up = device_commands.Button_9, value_down = 0, value_up = 1, name = _('Equipment Test Switch - OFF else ON (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_9, up = device_commands.Button_9, value_down = 1, value_up = 0, name = _('Equipment Test Switch - ON else OFF (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_127, value_down = 2, name = _('Net on Rectifier Switch Cover - OPEN/CLOSE (Fixed)'), category = {_('Center Console'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_21, up = device_commands.Button_21, value_down = 0, value_up = 1, name = _('Net on Rectifier Switch Cover - CLOSE else OPEN (2-way Switch)'), category = {_('Center Console'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_21, up = device_commands.Button_21, value_down = 1, value_up = 0, name = _('Net on Rectifier Switch Cover - OPEN else CLOSE (2-way Switch)'), category = {_('Center Console'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_128, value_down = 2, name = _('Net on Rectifier Switch - ON/OFF (Fixed)'), category = {_('Center Console'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_19, up = device_commands.Button_19, value_down = 0, value_up = 1, name = _('Net on Rectifier Switch - OFF else ON (2-way Switch)'), category = {_('Center Console'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_19, up = device_commands.Button_19, value_down = 1, value_up = 0, name = _('Net on Rectifier Switch - ON else OFF (2-way Switch)'), category = {_('Center Console'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_129, value_down = -2, name = _('36V Transformer Selector Switch - Down (Fixed)'), category = {_('Center Console'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_129, value_down = 2, name = _('36V Transformer Selector Switch - Up (Fixed)'), category = {_('Center Console'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_20, up = device_commands.Button_20, value_down = -1, value_up = 0, name = _('36V Transformer Selector Switch - AUXILIARY else OFF (3-way Switch Down)'), category = {_('Center Console'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_20, up = device_commands.Button_20, value_down = 1, value_up = 0, name = _('36V Transformer Selector Switch - MAIN else OFF (3-way Switch Up)'), category = {_('Center Console'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_118, value_pressed = -0.1,  name=_('Standby Generator Voltage Adjustment Rheostat - CCW/Decrease (Slow)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_118, value_pressed = 0.1, name=_('Standby Generator Voltage Adjustment Rheostat - CW/Increase (Slow)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_118, value_pressed = -0.2001,  name=_('Standby Generator Voltage Adjustment Rheostat - CCW/Decrease (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_118, value_pressed = 0.2001, name=_('Standby Generator Voltage Adjustment Rheostat - CW/Increase (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_118, value_pressed = -0.4,  name=_('Standby Generator Voltage Adjustment Rheostat - CCW/Decrease (Fast)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_118, value_pressed = 0.4, name=_('Standby Generator Voltage Adjustment Rheostat - CW/Increase (Fast)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_125, value_pressed = -0.1,  name=_('Generator 1 Voltage Adjustment Rheostat - CCW/Decrease (Slow)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_125, value_pressed = 0.1, name=_('Generator 1 Voltage Adjustment Rheostat - CW/Increase (Slow)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_125, value_pressed = -0.2001,  name=_('Generator 1 Voltage Adjustment Rheostat - CCW/Decrease (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_125, value_pressed = 0.2001, name=_('Generator 1 Voltage Adjustment Rheostat - CW/Increase (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_125, value_pressed = -0.4,  name=_('Generator 1 Voltage Adjustment Rheostat - CCW/Decrease (Fast)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_125, value_pressed = 0.4, name=_('Generator 1 Voltage Adjustment Rheostat - CW/Increase (Fast)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_126, value_pressed = -0.1,  name=_('Generator 2 Voltage Adjustment Rheostat - CCW/Decrease (Slow)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_126, value_pressed = 0.1, name=_('Generator 2 Voltage Adjustment Rheostat - CW/Increase (Slow)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_126, value_pressed = -0.2001,  name=_('Generator 2 Voltage Adjustment Rheostat - CCW/Decrease (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_126, value_pressed = 0.2001, name=_('Generator 2 Voltage Adjustment Rheostat - CW/Increase (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_126, value_pressed = -0.4,  name=_('Generator 2 Voltage Adjustment Rheostat - CCW/Decrease (Fast)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_126, value_pressed = 0.4, name=_('Generator 2 Voltage Adjustment Rheostat - CW/Increase (Fast)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},

 


Edited by Munkwolf
  • Thanks 1
Link to comment
Share on other sites

11 hours ago, Munkwolf said:

I'm working on an update for the keybinds project for the Mi-8 and have fixes for a lot of those if anyone is interested in dropping some LUA code in. The toggles, up/down, and CW/CCW commands starting with Button_108 are offset by one and should be incremented (ie, 'Rectifier 1 Switch - ON/OFF' uses 'device_commands.Button_108' but should be 'device_commands.Button_109').

I kind of lucked out that the up/down and CW/CCW ones still increment/decrement by 1, and toggle switches worked, with a value of 2 passed (to differentiate them from the default controls without having to edit the default files). I should have the full keybinds project update checked into github in the next few days (just finished up with all the circuit breakers).

@Flappie I haven't been able to find a fix for 'Battery Heating ON/OFF' toggle, and didn't see it on your list. Could you check/confirm if it's a candidate for your bug report?

Edit: Forgot to mention all the fixes have (Fixed) appended in the name and are in a new Electric Panels Fixes category.

-- Electric System Panels

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_119, value_down = 2, name = _('Generator 1 Switch - ON/OFF (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_15, up = device_commands.Button_15, value_down = 0, value_up = 1, name = _('Generator 1 Switch - OFF else ON (2-way Switch)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_15, up = device_commands.Button_15, value_down = 1, value_up = 0, name = _('Generator 1 Switch - ON else OFF (2-way Switch)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_120, value_down = 2, name = _('Generator 2 Switch - ON/OFF (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_16, up = device_commands.Button_16, value_down = 0, value_up = 1, name = _('Generator 2 Switch - OFF else ON (2-way Switch)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_16, up = device_commands.Button_16, value_down = 1, value_up = 0, name = _('Generator 2 Switch - ON else OFF (2-way Switch)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_121, value_down = 2, name = _('AC Ground Power Switch - ON/OFF (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_14, up = device_commands.Button_14, value_down = 0, value_up = 1, name = _('AC Ground Power Switch - OFF else ON (2-way Switch)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_14, up = device_commands.Button_14, value_down = 1, value_up = 0, name = _('AC Ground Power Switch - ON else OFF (2-way Switch)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_122, value_down = -2, name = _('115V Inverter Switch - Down (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_122, value_down = 2, name = _('115V Inverter Switch - Up (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_12, up = device_commands.Button_12, value_down = -1, value_up = 0, name = _('115V Inverter Switch - AUTO else OFF (3-way Switch Down)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_12, up = device_commands.Button_12, value_down = 1, value_up = 0, name = _('115V Inverter Switch - MANUAL else OFF (3-way Switch Up)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_123, value_down = -2, name = _('36V Inverter Switch - Down (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_123, value_down = 2, name = _('36V Inverter Switch - Up (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_13, up = device_commands.Button_13, value_down = -1, value_up = 0, name = _('36V Inverter Switch - AUTO else OFF (3-way Switch Down)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_13, up = device_commands.Button_13, value_down = 1, value_up = 0, name = _('36V Inverter Switch - MANUAL else OFF (3-way Switch Up)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 0, name = _('AC Voltmeter Selector Switch - OFF'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 0.1, name = _('AC Voltmeter Selector Switch - GENERATOR 1 I-II'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 0.2, name = _('AC Voltmeter Selector Switch - GENERATOR 1 II-III'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 0.3, name = _('AC Voltmeter Selector Switch - GENERATOR 1 III-I'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 0.4, name = _('AC Voltmeter Selector Switch - GENERATOR 2 I-II'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 0.5, name = _('AC Voltmeter Selector Switch - GENERATOR 2 II-III'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 0.6, name = _('AC Voltmeter Selector Switch - GENERATOR 2 III-I'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 0.7, name = _('AC Voltmeter Selector Switch - EXT PWR I-II'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 0.8, name = _('AC Voltmeter Selector Switch - EXT PWR II-III'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 0.9, name = _('AC Voltmeter Selector Switch - EXT PWR III-I'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_17, value_down = 1, name = _('AC Voltmeter Selector Switch - 115V'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_124, value_down = -2, name = _('AC Voltmeter Selector Switch - CCW (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_124, value_down = 2, name = _('AC Voltmeter Selector Switch - CW (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_8, value_down = 0, name = _('DC Voltmeter Selector Switch - OFF (LEFT)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_8, value_down = 0.1, name = _('DC Voltmeter Selector Switch - BATTERY 1'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_8, value_down = 0.2, name = _('DC Voltmeter Selector Switch - BATTERY 2'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_8, value_down = 0.3, name = _('DC Voltmeter Selector Switch - STBY GEN'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_8, value_down = 0.4, name = _('DC Voltmeter Selector Switch - BUSES BATT'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_8, value_down = 0.5, name = _('DC Voltmeter Selector Switch - BUSES RECT'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_8, value_down = 0.6, name = _('DC Voltmeter Selector Switch - EXT PWR'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_8, value_down = 0.7, name = _('DC Voltmeter Selector Switch - OFF (RIGHT)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_117, value_down = -2, name = _('DC Voltmeter Selector Switch - CCW (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_117, value_down = 2, name = _('DC Voltmeter Selector Switch - CW (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_112, value_down = 2, name = _('Battery 1 Switch - ON/OFF (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_3, up = device_commands.Button_3, value_down = 0, value_up = 1, name = _('Battery 1 Switch - OFF else ON (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_3, up = device_commands.Button_3, value_down = 1, value_up = 0, name = _('Battery 1 Switch - ON else OFF (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_113, value_down = 2, name = _('Battery 2 Switch - ON/OFF (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_2, up = device_commands.Button_2, value_down = 0, value_up = 1, name = _('Battery 2 Switch - OFF else ON (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_2, up = device_commands.Button_2, value_down = 1, value_up = 0, name = _('Battery 2 Switch - ON else OFF (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_114, value_down = 2, name = _('Standby Generator Switch - ON/OFF (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_1, up = device_commands.Button_1, value_down = 0, value_up = 1, name = _('Standby Generator Switch - OFF else ON (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_1, up = device_commands.Button_1, value_down = 1, value_up = 0, name = _('Standby Generator Switch - ON else OFF (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_109, value_down = 2, name = _('Rectifier 1 Switch - ON/OFF (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_7, up = device_commands.Button_7, value_down = 0, value_up = 1, name = _('Rectifier 1 Switch - OFF else ON (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_7, up = device_commands.Button_7, value_down = 1, value_up = 0, name = _('Rectifier 1 Switch - ON else OFF (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_110, value_down = 2, name = _('Rectifier 2 Switch - ON/OFF (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_5, up = device_commands.Button_5, value_down = 0, value_up = 1, name = _('Rectifier 2 Switch - OFF else ON (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_5, up = device_commands.Button_5, value_down = 1, value_up = 0, name = _('Rectifier 2 Switch - ON else OFF (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_111, value_down = 2, name = _('Rectifier 3 Switch - ON/OFF (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_6, up = device_commands.Button_6, value_down = 0, value_up = 1, name = _('Rectifier 3 Switch - OFF else ON (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_6, up = device_commands.Button_6, value_down = 1, value_up = 0, name = _('Rectifier 3 Switch - ON else OFF (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_115, value_down = 2, name = _('DC Ground Power Switch - ON/OFF (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_4, up = device_commands.Button_4, value_down = 0, value_up = 1, name = _('DC Ground Power Switch - OFF else ON (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_4, up = device_commands.Button_4, value_down = 1, value_up = 0, name = _('DC Ground Power Switch - ON else OFF (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_116, value_down = 2, name = _('Equipment Test Switch - ON/OFF (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_9, up = device_commands.Button_9, value_down = 0, value_up = 1, name = _('Equipment Test Switch - OFF else ON (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_9, up = device_commands.Button_9, value_down = 1, value_up = 0, name = _('Equipment Test Switch - ON else OFF (2-way Switch)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_127, value_down = 2, name = _('Net on Rectifier Switch Cover - OPEN/CLOSE (Fixed)'), category = {_('Center Console'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_21, up = device_commands.Button_21, value_down = 0, value_up = 1, name = _('Net on Rectifier Switch Cover - CLOSE else OPEN (2-way Switch)'), category = {_('Center Console'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_21, up = device_commands.Button_21, value_down = 1, value_up = 0, name = _('Net on Rectifier Switch Cover - OPEN else CLOSE (2-way Switch)'), category = {_('Center Console'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_128, value_down = 2, name = _('Net on Rectifier Switch - ON/OFF (Fixed)'), category = {_('Center Console'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_19, up = device_commands.Button_19, value_down = 0, value_up = 1, name = _('Net on Rectifier Switch - OFF else ON (2-way Switch)'), category = {_('Center Console'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_19, up = device_commands.Button_19, value_down = 1, value_up = 0, name = _('Net on Rectifier Switch - ON else OFF (2-way Switch)'), category = {_('Center Console'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_129, value_down = -2, name = _('36V Transformer Selector Switch - Down (Fixed)'), category = {_('Center Console'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_129, value_down = 2, name = _('36V Transformer Selector Switch - Up (Fixed)'), category = {_('Center Console'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_20, up = device_commands.Button_20, value_down = -1, value_up = 0, name = _('36V Transformer Selector Switch - AUXILIARY else OFF (3-way Switch Down)'), category = {_('Center Console'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, down = device_commands.Button_20, up = device_commands.Button_20, value_down = 1, value_up = 0, name = _('36V Transformer Selector Switch - MAIN else OFF (3-way Switch Up)'), category = {_('Center Console'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_118, value_pressed = -0.1,  name=_('Standby Generator Voltage Adjustment Rheostat - CCW/Decrease (Slow)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_118, value_pressed = 0.1, name=_('Standby Generator Voltage Adjustment Rheostat - CW/Increase (Slow)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_118, value_pressed = -0.2001,  name=_('Standby Generator Voltage Adjustment Rheostat - CCW/Decrease (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_118, value_pressed = 0.2001, name=_('Standby Generator Voltage Adjustment Rheostat - CW/Increase (Fixed)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_118, value_pressed = -0.4,  name=_('Standby Generator Voltage Adjustment Rheostat - CCW/Decrease (Fast)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_118, value_pressed = 0.4, name=_('Standby Generator Voltage Adjustment Rheostat - CW/Increase (Fast)'), category = {_('Right Side Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_125, value_pressed = -0.1,  name=_('Generator 1 Voltage Adjustment Rheostat - CCW/Decrease (Slow)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_125, value_pressed = 0.1, name=_('Generator 1 Voltage Adjustment Rheostat - CW/Increase (Slow)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_125, value_pressed = -0.2001,  name=_('Generator 1 Voltage Adjustment Rheostat - CCW/Decrease (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_125, value_pressed = 0.2001, name=_('Generator 1 Voltage Adjustment Rheostat - CW/Increase (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_125, value_pressed = -0.4,  name=_('Generator 1 Voltage Adjustment Rheostat - CCW/Decrease (Fast)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_125, value_pressed = 0.4, name=_('Generator 1 Voltage Adjustment Rheostat - CW/Increase (Fast)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},

{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_126, value_pressed = -0.1,  name=_('Generator 2 Voltage Adjustment Rheostat - CCW/Decrease (Slow)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_126, value_pressed = 0.1, name=_('Generator 2 Voltage Adjustment Rheostat - CW/Increase (Slow)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_126, value_pressed = -0.2001,  name=_('Generator 2 Voltage Adjustment Rheostat - CCW/Decrease (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_126, value_pressed = 0.2001, name=_('Generator 2 Voltage Adjustment Rheostat - CW/Increase (Fixed)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Electric Panels Fixes'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_126, value_pressed = -0.4,  name=_('Generator 2 Voltage Adjustment Rheostat - CCW/Decrease (Fast)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},
{cockpit_device_id = devices.ELEC_INTERFACE, pressed = device_commands.Button_126, value_pressed = 0.4, name=_('Generator 2 Voltage Adjustment Rheostat - CW/Increase (Fast)'), category = {_('Electrical Control Panel'), _('Electric Panels'), _('Custom')}},

HI, and WOW! That is a LOT oF Work done! thank you so much! Will install this as soon as I can. 

Saludos y gracias.

Saca111

 

 

  • Like 1
Link to comment
Share on other sites

10 hours ago, Sacarino111 said:

HI, and WOW! That is a LOT oF Work done! thank you so much! Will install this as soon as I can. 

Saludos y gracias.

Saca111

If you think that is a lot... I just put the full update up on github. I'm still testing it. Around 1300 lines of LUA:

https://github.com/Munkwolf/dcs-community-keybinds/blob/main/InputCommands/Mi-8MTV2/Input/Mi-8MTV2/joystick/default.lua

Please note that file is formatted for use with Quaggles mod: https://github.com/Quaggles/dcs-input-command-injector

+ Those electric panel fixes
+ Different speeds for rotaries/rheostats
+ ON else OFF and OFF else ON versions for switches
+ New axis for knobs and rheostats
+ Commands for all the individual circuit breakers


Edited by Munkwolf
  • Thanks 1
Link to comment
Share on other sites

On 1/8/2022 at 11:57 PM, Munkwolf said:

 

@Flappie I haven't been able to find a fix for 'Battery Heating ON/OFF' toggle, and didn't see it on your list. Could you check/confirm if it's a candidate for your bug report?

 

Thanks for the heads up. I can confirm it does not work right out of the box. I've just added it to the report.

I'm not sure it wll help you a lot, but I managed to make it "work" somehow... Edit "Mods\aircraft\Mi-8MTV2\Cockpit\Scriptsclickabledata.lua" and replace "75" by "76" below:

elements["PTR-RSPE-TMB-WRMAKK"]		= default_2_position_tumb(	_("Battery Heating Switch, ON/OFF"), devices.ELEC_INTERFACE, cb_start_cmd + 75, 522, {-90,0,0})

The switch will be moved up the first time you try the "Battery Heating Swich, ON/OFF" control, but then it won't go back down. It acts like a Battery Heating Switch ON" control.

  • Like 1

Don't accept indie game testing requests from friends in Discord. Ever.

Link to comment
Share on other sites

1 hour ago, Flappie said:

Thanks for the heads up. I can confirm it does not work right out of the box. I've just added it to the report.

I'm not sure it wll help you a lot, but I managed to make it "work" somehow... Edit "Mods\aircraft\Mi-8MTV2\Cockpit\Scriptsclickabledata.lua" and replace "75" by "76" below:

elements["PTR-RSPE-TMB-WRMAKK"]		= default_2_position_tumb(	_("Battery Heating Switch, ON/OFF"), devices.ELEC_INTERFACE, cb_start_cmd + 75, 522, {-90,0,0})

The switch will be moved up the first time you try the "Battery Heating Swich, ON/OFF" control, but then it won't go back down. It acts like a Battery Heating Switch ON" control.

Thanks @Flappie!

The ON and OFF commands do work ok, and they are on command 3106 (cb_start_cmd is set to 3031 in the command_defs.lua). It's just the Toggle version of it that is not working as expected.

I tried a bunch of different command values and couldn't find one that worked - there might not be a way to get that Toggle working, not just out-of-the-box but with LUA edits either.


Edited by Munkwolf
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...