Cleric-K / vJoySerialFeeder

Feed Virtual Joystick driver with data from a serial port
GNU General Public License v3.0
252 stars 55 forks source link

How can I use 2 controllers using the same Arduino? #51

Closed DanielSurf10 closed 3 years ago

DanielSurf10 commented 3 years ago

I would like to use 2 PS2 controllers in same Arduino, I managed to do it with 1 controller, but how I do to the vJoySerialFeeder emulate 2 controllers? I'm using vBox with 1 PS2 controller.

Cleric-K commented 3 years ago

I don't understand very well. Can you explain with more details what hardware are you using? You want to emulate two different virtual joysticks, the data for which come from the same Arduino board?

DanielSurf10 commented 3 years ago

Oh, sorry me, my English is bad. I'm using an Arduino Mega board and a PS2 Controller. :video_game: In the vJoySerialFeeder software I used vXbox to emulate the joystick. All worked perfectly with only one PS2 Controller (except the POV, because I have no Ideia how to do it).

I want to emulate two virtual joysticks using two PS2 Controllers, the data come from the same Arduino board. :video_game: :video_game: In Arduino code is easy to do (I guess). But how do I do that?

Cleric-K commented 3 years ago

One way to do it is to use program like https://freeserialportsplitter.com/ Let's say Arduino is seen as COM3. With such a program you can make virtual COM4 which will duplicate the same data as COM3. Now you can open second vJoySerialFeeder select COM4 and the second vXbox. Obviously the mappings in the two vjsf instances will be different. You need the virtual COM because Windows will not allow you to open the same COM3 from more than one application.

It's not a pretty solution but it should work. Otherwise, at this point it is impossible in vjsf to send data to more than one virtual joystick.

DanielSurf10 commented 3 years ago

Ah ok thank you. I'm going to try later.