Jump to content

How do I add binds for axes to control lights?


Recommended Posts

You can create these axis commands if you are willing to edit the "default.lua" file under "...\Eagle Dynamics\DCS World OpenBeta\Mods\aircraft\A-10C_2\Input\A-10C_2\joystick"
In the "AxisCommands" section near the end of the file you need to insert these lines:

{action = 3001, cockpit_device_id = 49, name = _('Engine Instruments Lights Axis')},
{action = 3002, cockpit_device_id = 49, name = _('Flight Instruments Lights Axis')},
{action = 3003, cockpit_device_id = 49, name = _('Auxiliary Instruments Lights Axis')},
{action = 3005, cockpit_device_id = 49, name = _('Flood Light Axis')},
{action = 3006, cockpit_device_id = 49, name = _('Console Light Axis')},
{action = 3011, cockpit_device_id = 54, name = _('UHF Radio Volume Axis')},
{action = 3005, cockpit_device_id = 55, name = _('VHF AM Radio Volume Axis')},
{action = 3005, cockpit_device_id = 56, name = _('VHF FM Radio Volume Axis')},
{action = 3013, cockpit_device_id = 38, name = _('Yaw Trim Knob Axis')},

There is a little catch though: When we create these axis commands the program only uses half of the slider signal range and it is inverted.
My solution is to enter a user curve as shown in the attachment.

UserCurveCapture.JPG


Edited by LeCuvier

LeCuvier

Windows 10 Pro 64Bit | i7-4790 CPU |16 GB RAM|SSD System Disk|SSD Gaming Disk| MSI GTX-1080 Gaming 8 GB| Acer XB270HU | TM Warthog HOTAS | VKB Gladiator Pro | MongoosT-50 | MFG Crosswind Pedals | TrackIR 5

Link to comment
Share on other sites

Thank you. I also discovered that if I put those commands in a file named 'Arduino Leonardo.lua' with the appropriate syntax, then only the Arduino can be assigned to them. They seem to work fine without the need for curve editing too.

4930K @ 4.5, 32g ram, TitanPascal

Link to comment
Share on other sites

Yes, if you have a .lua for a specific game controller then the lines of code must be added into that file and will not be visible for other devices.
Seems that the Arduino board has different signal characteristics. I could only test the commands with the one slider on my Warthog throttle, one at a time. What a luxury to have so many analog inputs!

I suppose you are building a sim pit?


Edited by LeCuvier

LeCuvier

Windows 10 Pro 64Bit | i7-4790 CPU |16 GB RAM|SSD System Disk|SSD Gaming Disk| MSI GTX-1080 Gaming 8 GB| Acer XB270HU | TM Warthog HOTAS | VKB Gladiator Pro | MongoosT-50 | MFG Crosswind Pedals | TrackIR 5

Link to comment
Share on other sites

Not a real complicated one, but a rather generic one. My biggest failing is remembering the keybinds. To facilitate this I use another arduino connected to a tft display. 2 buttons cycle through hard coded lists of controller mappings. This way my button box labels can change w the aircraft. At present these two arduinos give me 6 axes each and 6 switches- I am limited by the size of the box.

4930K @ 4.5, 32g ram, TitanPascal

Link to comment
Share on other sites

I was thinking of something like that, but I'm not enough of a tinkerer. I use an Excel wrkbook for every aircraft to document the bindings (and more). This also helps if for some reason bindings got lost (happens very rarely for me).

LeCuvier

Windows 10 Pro 64Bit | i7-4790 CPU |16 GB RAM|SSD System Disk|SSD Gaming Disk| MSI GTX-1080 Gaming 8 GB| Acer XB270HU | TM Warthog HOTAS | VKB Gladiator Pro | MongoosT-50 | MFG Crosswind Pedals | TrackIR 5

Link to comment
Share on other sites

  • Recently Browsing   0 members

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