Archive for December 2014

Combine multiple game controllers into a single logical one

Update April 2018:
Use vJoy GUI configuration instead of command line.
Added 64 bit version. (compatible with windows 8 & 10)

Sometimes, as I found it myself, PC games can handle only one controller. For example, the FreeSpace 2 Open (FSO) supports only a single HID input device.  This eliminate the possibility to use a separate throttle and joystick together in this type of games. To overcome this problem, we need to combine both physical controllers into one virtual controller to be used at this game. The virtual controller will combine  and provide all axis, POVs and buttons of both controllers.

VJOY Virtual controller

Fortunately there is a great free software called vJoy. VJoy lets you create a virtual HID controller with configurable number of axis, POVs and buttons. You then need to feed this vJoy controller with data you want to present to the game. An included SDK is letting you develop your own vJoy feeder.  Using this SDK, I have developed a feeder that takes input from both Suncom SFS Throttle and Suncom F15 Talon joystick (converted to work on USB by my previous projects) and feeds a single vJoy virtual controller. Following, I will explain how to install and use it. I will also publish the source code, so anybody who wants to make his own feeder or to join any other types of  joysticks can use it as a reference.

NOTE: vJoy is only for Windows platform.

Step 1: Install vJoy

Go to vJoy website, download and install the software. This will create a single default virtual controller.

Step 2: Configure vJoy

We now need to configure the vJoy controller to have all needed axes POVs and buttons.
Open the vJoy configuration utility “Configure vJoy”, and configure device #1 as follows:

vJoy configuration utility

Then Press “Apply”.

 

The vJoy controller should be now configured correctly. To make sure it is, Open windows control panel, and select Game Controllers. Select the vJoy controller and click properties. You should see something like this:

vJoy_cp

Step 3: Install the feeder.

Download the SuncomControllerMerge feeder  32bit version here or 64bit version here. It does not come with an installer, so you need to install it manually. Just extract the zip file to a directory of your choice and run the SuncomControllerMerge.exe file included.

Thats it! you are all set! All you need now id to plug the Suncom Throttle and joystick and the feeder will automatically detect them. To check if everything works correctly, go back to Game controllers in the control panel and click properties on the vJoy controller. Now play with both joystick and throttle and make sure both affect the vJoy controller.

Important notes:

1.  Some games, not only that they do not support multiple controllers, they even do not let you select which one to use. In this case, make sure the vJoy controller is the default one. you can do it by going back to the Game Controllers window in the control panel, and press the “advanced” button.

2. Though the vJoy controller will always be present, even after the system reboots, the feeder will not, and must be activated each time when needed. Without the feeder, the game will detect the vJoy controller, but will not receive any data from it.

Source code:

For those of you who wants to play with the software, or adapt it to other controllers,
Updated sources, good for windows 7, 8, 10 can be found at GitHub , and compiled with VS c# 2010 and up.

And here is the old source code. It can be compiled under MS Visual c# 2008 express and up.