isage / vixen

ViXEn - Vita X-input Enabler
MIT License
21 stars 4 forks source link

Please add support for PS1 NegCon #3

Open mightysashiman opened 1 year ago

mightysashiman commented 1 year ago

Hi there, I know my request is really specific. I love p1 and there are a couple of games (notably wipeout) that support this unique NegCon Namco controller. I have a couple PSX2USB adapters:

It would be absolutely marvelous vixen support this controller.

I am no dev so I can't help with the actual dev, but am pretty tech savvy and will very happily collaborate to capture USB & debug in anyway if it can help make this feature a reality!

Many thanks in advance for even considering my request :)

isage commented 1 year ago

If you know how to capture HID data (usbhid-dump might help) What i need: 1) Usb VID/PID 2) Device HID descriptor 3) HID reports for all buttons: don't press anything, capture HID stream, write down report. press and hold left, capture HID stream, write down report and button you were holding repeat for all buttons

mightysashiman commented 1 year ago

Here is a compilation of the outputs. Let me know if I can provide further info ! https://docs.google.com/spreadsheets/d/1--BC_0oofCTlyytQcqCfWWGlvi-8zLdPO_FAxIEUBGk/edit?usp=sharing

gamepad-tester website also works. If you want we can have a live chat and I can share my screen if it’s clearer :)

isage commented 1 year ago

looks good. but given how cursed that controller is, how would you map it to vita layout? A/B/1/2 to cross/circle/square/triangle? twist to left analog X? L/R to L/R?

mightysashiman commented 1 year ago

looks good. but given how cursed that controller is, how would you map it to vita layout? A/B/1/2 to cross/circle/square/triangle? twist to left analog X? L/R to L/R?

Didn’t know this controller was that cursed Ô_Ô

If you don’t mind my asking a few questions:

isage commented 1 year ago

you can use revita along with vixen. As for "from scratch part", ds34vita and x1vita and others target bluetooth controllers. They also do the same - parse bt packets into vita controls

As for negcon support in adrenaline - i don't think it cares (or ps1 cares), as far as i understand you just select that controller type in game. Which actually gives me an idea - I'll check how ds buttons are mapped if you select negcon and map negcon accordingly nvm, did some tests, and it looks like games have some way to auto-detect negcon

Also, given how I, II and L buttons are analog, we can't really map them to traditional buttons, as we'll lose analog inputs

isage commented 1 year ago

I guess i'll do mappings from here https://psx-spx.consoledev.net/controllersandmemorycards/#controllers-racing-controllers

mightysashiman commented 1 year ago

Also, given how I, II and L buttons are analog, we can't really map them to traditional buttons, as we'll lose analog inputs

How are DS4 joypad L2/R2 analog triggers dealt with currently? Are they just dropped? or are they mapped/mappable to virtual vita inputs (either mimmicking real buttons, or virtual front touch / back touch buttons like in Adrenaline) ?

mightysashiman commented 1 year ago

@isage by the way, is the Y-cable you mention on your other repo something that can be bought somewhere (amazon...) or does it have to be custom built? I don't have the skills or equipment to build my own (and frankly don't understand most of the technical details required)

mightysashiman commented 1 year ago

@isage if ever you have time to spare, I'd really like a chat to better understand how external joypad support (either bluetooth or wired) is achieved, vs the mapping to vita inputs? I can't help but wonder why these 2 tasks are not decorrelated from one each other, with numerous HW drivers progressively adding wider HW support and presents to some kind of "universal mapper" the set of mappable analog axis and digital buttons (that may vary from input device to another), and that "universal mapper" that would be able to map any axis/button to any vita input(s) like what reVita remapping does.

isage commented 1 year ago

@isage by the way, is the Y-cable you mention on your other repo something that can be bought somewhere (amazon...) or does it have to be custom built? I don't have the skills or equipment to build my own (and frankly don't understand most of the technical details required)

I think i saw something on amazon, but can't find rn.

isage commented 1 year ago

@isage if ever you have time to spare, I'd really like a chat to better understand how external joypad support (either bluetooth or wired) is achieved, vs the mapping to vita inputs? I can't help but wonder why these 2 tasks are not decorrelated from one each other, with numerous HW drivers progressively adding wider HW support and presents to some kind of "universal mapper" the set of mappable analog axis and digital buttons (that may vary from input device to another), and that "universal mapper" that would be able to map any axis/button to any vita input(s) like what reVita remapping does.

because that would require some external mapper, some well-established api and would complicate things.. and we already have reVita all input plugins work by either calling vita input emulation api (this works only for first gamepad) or by hooking vita input functions, so when app tries to read input - input plugin overwrites input values. reVita works same way - takes original input report and overwrites it according to mappings.

isage commented 1 year ago

btw, any chance you have original psx dualshock? It's better to support it (well, rather raphnet psx to usb completely), and negcon would/should be supported automatically

mightysashiman commented 1 year ago

btw, any chance you have original psx dualshock? It's better to support it (well, rather raphnet psx to usb completely), and negcon would/should be supported automatically

All my original PS1 gear is out of reach currently :( what would you be needing in the event I get hold of one?

isage commented 1 year ago

Same stuff you did for negcon (just reports part)

mightysashiman commented 1 year ago

I'll update you if/when I get hold of one. I'm pretty sure I only have the original non-digital gray one left :( I also had the SCPH-1150 pre-dualshock pad, but long gone too I think.

isage commented 1 year ago

Meanwhile i've asked raphnet if he can provide dualshock to HID mapping PSXtoUSB uses

isage commented 1 year ago

Got packet description from Raphael so i'll go with implementing it. It turns out, though, NegCon is slightly different: dualshock has "digital" left trigger, while negcon uses analog. So, negcon L maps to L2. I can work with that, though.

isage commented 1 year ago

can you check with latest release?

techsrus commented 1 year ago

How can the adapter pair without a PS button?

isage commented 1 year ago

How can the adapter pair without a PS button?

Pair with what?

techsrus commented 1 year ago

I was hoping to help here since I believe I have all the necessary components. I tried connecting my controllers with the raphnet adapter using vixen.skprx v1.4.1 on my PSTV but it doesn't seem to pair.

isage commented 1 year ago

There's nothing to pair, it's wired

techsrus commented 1 year ago

Ah. I have a PS2 to PS3 adapter wired adapter that I use that I still need to press the PS button on the adapter to start moving around. Wrong assumption, sorry.

techsrus commented 1 year ago

As for the controllers I tried connecting, I tried the original playstation controller, the dualshock 1 and 2, and the negcon (npc-101).

techsrus commented 1 year ago

vixen.txt DualShock 1 via raphnet PS1/PS2 controller to USB adapter. I was wondering why at first I was getting no output, it's because I had to comment out the vixen plugin. For "PS Button" during the test I pressed the "Analog" button on the controller.

isage commented 1 year ago

Report seems the same as Raphnet PSX to USB (even same VID/PID). It doesn't work at all with latest release of vixen?

techsrus commented 1 year ago

I've tried it with both regular and _ds3 versions and with both there is no output and it does not take up a controller slot. If I turn on my real DS3 afterwards it still takes up controller slot 1.

techsrus commented 5 months ago

Is there anything additional I could do to help in testing to get this to work?