Jump to content

Convert from DCS to FOXY (for TM Cougar)


Recommended Posts

When I first started with DCS World, I programmed my Thrustmaster Cougar using the sim's configuration screen, but I missed the advanced capabilities that programming with Foxy made possible, for example to have a button that pressed singly does one thing, but a press and hold does another thing.

 

So, I started to make my own Foxy profiles for the Cougar ... but realized that manually converting DCS keyboard shortcuts into Foxy macros was a long, boring and error prone task.

 

When Foxy was designed, most simulators had less than 100 keyboard commands, but on DCS it isn't uncommon to have more than 200, the latest Viggen has about 450 commands.

 

So, to speed up the creation of Macro files for Foxy, I wrote a small function in Excel VBA to automate this step as much as possible, and I want to share it here, in case it would help other Cougar owners.

 

Next I will describe the steps involved in converting from DCS to Foxy using this Excel function:

 

1.- Export from DCS to HTML file:

 

The first step, is exporting the keyboard commands of the DCS aircraft that interest us; for this example I will export the commands of the Viggen. We need to go to Options -> Controls and click on the "Make HTML" button:

 

dcs_foxy_01s.jpg

 

The button will take just a second to perform the export, the HTML file will be stored on this folder, within the Saved Games folder:

 

dcs_foxy_02.png

 

2.- Copy from HTML to Excel:

 

Even tough it is possible to import HTML from within Excel, I've found that it is quicker and easier to just copy the data. For that, we open the html file with a browser, by clicking on it:

 

dcs_foxy_03.png

 

Then we select all the rows and copy the text with CTRL + C; now we go to Excel, and paste it as text (not html), like this:

 

dcs_foxy_04.png

 

I've a blank spreadsheet that I use as a template, will put it on a link at the end of this post. When we paste, the spreadsheet immediately does the conversion for each row and put the converted Foxy macro definition on column E, like this:

 

dcs_foxy_05.png

 

3.- The convert function:

 

Here we can see how the convert is done on each cell by calling the Convert_DCS_to_Foxy function twice ... the first time it converts the Command Name and the second time it converts the keystrokes of that command:

 

dcs_foxy_06.png

 

The function is very straightforward, no complicated lookup tables :) ... it gets a bit long but works much quicker ... this is the part that converts the Command Name:

 

dcs_foxy_07.png

 

... and this converts the DCS keystrokes into a Foxy macro:

 

dcs_foxy_08s.png

 

Copy from Excel to Foxy:

 

Lastly, we have to manually copy the text from Excel into Foxy, but rather than copy all at once, I've found easier to copy Group by Group, for example here I've selected in Excel, using its filtering abilities, only the Navigation commands:

 

dcs_foxy_09.png

 

now, I copy and then go to Foxy and simply paste the text, like this:

 

dcs_foxy_10.png

 

once we have the command macros, assigning them to the Cougar's hats and buttons is a simple task:

 

dcs_foxy_11.png

 

So, thats all ... now I will see how to attach a Zip file with the template Excel sheet and modify this post :)

 

Cheers!

Convert DCS to Foxy.zip


Edited by Rudel_chw
Added Zip File with conversion Spreadsheet

 

For work: iMac mid-2010 of 27" - Core i7 870 - 6 GB DDR3 1333 MHz - ATI HD5670 - SSD 256 GB - HDD 2 TB - macOS High Sierra

For Gaming: 34" Monitor - Ryzen 3600X - 32 GB DDR4 2400 - nVidia GTX1070ti - SSD 1.25 TB - HDD 10 TB - Win10 Pro - TM HOTAS Cougar - Oculus Rift CV1

Mobile: iPad Pro 12.9" of 256 GB

Link to comment
Share on other sites

You did put a big smile on my face... :-)

I went like: YES!!!

Win11 Pro 64-bit, Ryzen 5800X3D, Corsair H115i, Gigabyte X570S UD, EVGA 3080Ti XC3 Ultra 12GB, 64 GB DDR4 G.Skill 3600. Monitors: LG 27GL850-B27 2560x1440 + Samsung SyncMaster 2443 1920x1200, HOTAS: Warthog with Virpil WarBRD base, MFG Crosswind combat pedals, TrackIR4, Rift-S.

Personal Wish List: A6 Intruder, Vietnam theater, decent ATC module, better VR performance!

Link to comment
Share on other sites

You did put a big smile on my face... :-)

I went like: YES!!!

 

 

I'm glad that you found it useful :)

Cheers!

 

For work: iMac mid-2010 of 27" - Core i7 870 - 6 GB DDR3 1333 MHz - ATI HD5670 - SSD 256 GB - HDD 2 TB - macOS High Sierra

For Gaming: 34" Monitor - Ryzen 3600X - 32 GB DDR4 2400 - nVidia GTX1070ti - SSD 1.25 TB - HDD 10 TB - Win10 Pro - TM HOTAS Cougar - Oculus Rift CV1

Mobile: iPad Pro 12.9" of 256 GB

Link to comment
Share on other sites

I still have one little problem though.

After the conversion i always have an extra space between the { and the key command.

 

Like this: { DEL} instead of this {DEL}

Win11 Pro 64-bit, Ryzen 5800X3D, Corsair H115i, Gigabyte X570S UD, EVGA 3080Ti XC3 Ultra 12GB, 64 GB DDR4 G.Skill 3600. Monitors: LG 27GL850-B27 2560x1440 + Samsung SyncMaster 2443 1920x1200, HOTAS: Warthog with Virpil WarBRD base, MFG Crosswind combat pedals, TrackIR4, Rift-S.

Personal Wish List: A6 Intruder, Vietnam theater, decent ATC module, better VR performance!

Link to comment
Share on other sites

  • 1 month later...
I still have one little problem though.

After the conversion i always have an extra space between the { and the key command.

 

Like this: { DEL} instead of this {DEL}

 

 

Sorry, here I've attached a new version of the speadsheet with the bug solved.

Greetings.

Convert_DCS_to_Foxy.zip

 

For work: iMac mid-2010 of 27" - Core i7 870 - 6 GB DDR3 1333 MHz - ATI HD5670 - SSD 256 GB - HDD 2 TB - macOS High Sierra

For Gaming: 34" Monitor - Ryzen 3600X - 32 GB DDR4 2400 - nVidia GTX1070ti - SSD 1.25 TB - HDD 10 TB - Win10 Pro - TM HOTAS Cougar - Oculus Rift CV1

Mobile: iPad Pro 12.9" of 256 GB

Link to comment
Share on other sites

Super...:-)

Win11 Pro 64-bit, Ryzen 5800X3D, Corsair H115i, Gigabyte X570S UD, EVGA 3080Ti XC3 Ultra 12GB, 64 GB DDR4 G.Skill 3600. Monitors: LG 27GL850-B27 2560x1440 + Samsung SyncMaster 2443 1920x1200, HOTAS: Warthog with Virpil WarBRD base, MFG Crosswind combat pedals, TrackIR4, Rift-S.

Personal Wish List: A6 Intruder, Vietnam theater, decent ATC module, better VR performance!

Link to comment
Share on other sites

  • Recently Browsing   0 members

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