It seems that you're using an outdated browser. Some things may not work as they should (or don't work at all).
We suggest you upgrade newer and better browser like: Chrome, Firefox, Internet Explorer or Opera

×
I've heard that a PS5 controller can be used on PC, but what API does it use? Is it compatible with XInput or DirectInput, or does it use its own?

If it uses its own then if I were to write code to utilize it, would users need to install any new drivers or new API just to be able to run the program?

Also, and this is pretty important, because it's kind of the whole reason why I want it in the first place: does the motion sensitivity work on PC, or does that only work on PS5?
This question / problem has been solved by EverNightXimage
This might help -
[url=https://www.pcgamingwiki.com/wiki/Controller:DualSense]Link[/url]

It says - The DualSense is a generic DirectInput controller

edit: can't get link to work correctly, just go to pcgamingwiki and search dualsense ;)
Post edited August 16, 2024 by triock
Interesting topic...
By a little research I did here, its neither. Not Xinput, nor Dinput.

But it can be connected with PCs,
It uses USB-C connection:

https://www.playstation.com/en-us/support/hardware/pair-dualsense-controller-bluetooth/#usb

As I don't own one, a curiosity, does it work with common Xinput or Dinput interfaces normally?
Or 'extra steps' are required to make it work?

*sigh* wish for an age where companies start doing open source hardware more often.
avatar
HeresMyAccount: I've heard that a PS5 controller can be used on PC, but what API does it use? Is it compatible with XInput or DirectInput, or does it use its own?

If it uses its own then if I were to write code to utilize it, would users need to install any new drivers or new API just to be able to run the program?

Also, and this is pretty important, because it's kind of the whole reason why I want it in the first place: does the motion sensitivity work on PC, or does that only work on PS5?
To use a PS5 controller on a PC you would need a program that translates its inputs to the corresponding XInput.

I have used such software with PS4 controllers in the past and they work quite well.

This software seems to be specialized for PS5 controllers. You might want to give this a try. I haven't tested this one though so I don't know if it will work for you.

DS4Windows probably won't work on a PS5 controller but you can also try X360CE if the above doesn't work.
Post edited August 16, 2024 by Geralt_of_Rivia
Well if it's DirectInput then it probably wouldn't even be able to use the analog triggers correctly. For example, if you emulate an XInput controller through DirectInput, it will combine the triggers onto two opposing sides of a single axis (the positive and negative), because that's generally more compatible with games than to keep each trigger as a single positive-only axis.

Also, I doubt anything haptic would work, considering that the only thing for DirectInput which can do that is Force Feedback, which is a superior, though sadly antiquated way of doing things, so nothing is really compatible with it anymore, anyway.

Also, what's USB-C, like the little port on my Kindle? I think I need an adapter then.

More importantly for my purposes, the motion sensitivity:

On the PCGamingWiki page in the link, there's a section called "Use with PC platforms" with a subsection called "Windows". At the beginning of that, just before a long list of pros and cons, there's a chart which lists the compatibility of features with what looks like various kinds of emulation software, but it doesn't even specify that (how's anyone supposed to know what it's talking about?). Anyway, one line says "Motion Control", and several of them have a check mark, so I guess it's compatible, but only with this emulation software, which is sort of a bummer, because that could complicate the process for end users.

Also, the line of text just above the chart says "Connecting the controller should automatically download and install latest drivers for the controller." What about if it's being run on an air-gapped computer, such as the one that I use for programming? There's no way to download anything onto it, so I'd have to manually download it from a different computer instead, which is fine, but it mentions no provision for that! So what am I supposed to do, or where can I download it?

EDIT: Honestly, when are OS companies like Microsoft going to realize that DirectInput and XInput are antiquated, and they need something new which will take into account motion sensitivity?!
Post edited August 16, 2024 by HeresMyAccount
avatar
HeresMyAccount: EDIT: Honestly, when are OS companies like Microsoft going to realize that DirectInput and XInput are antiquated, and they need something new which will take into account motion sensitivity?!
Truth be told, the gaming concept of motion don't sell well because gamers don't like to move.
...and this is not even a joke.

It works with casual gamers, but the gamer masses don't buy it.
At least it feels this way.
avatar
HeresMyAccount: EDIT: Honestly, when are OS companies like Microsoft going to realize that DirectInput and XInput are antiquated, and they need something new which will take into account motion sensitivity?!
It's my understanding that they did since introducing the Xbox One, it's a protocol called Game Input Protocol and it has a native driver on Windows 8 and up.
Supports motion/gyro and audio on Wireless and USB mode but the info online seem to be a bit weird due the naming of connection protocol and API. Did some digging some time back and was not easy to find a simple explanation for dumb people like myself.
avatar
.Keys: Truth be told, the gaming concept of motion don't sell well because gamers don't like to move.
...and this is not even a joke.

It works with casual gamers, but the gamer masses don't buy it.
At least it feels this way.
Tell that to the people playing on the Steam Deck, including competitive racing games, like Asseto Corsa :P
Post edited August 16, 2024 by Dark_art_
avatar
.Keys: Truth be told, the gaming concept of motion don't sell well because gamers don't like to move.
...and this is not even a joke.

It works with casual gamers, but the gamer masses don't buy it.
At least it feels this way.
avatar
Dark_art_: Tell that to the people playing on the Steam Deck, including competitive racing games, like Asseto Corsa :P
I was talking more about this kind of motion...

https://youtu.be/hTcSxXS5Jho
https://youtu.be/rw3qfJHruGM
https://youtu.be/IcmcKED8QWc

xD

So anyway, we are mostly PC gamers, I deduce.
Which has probably the most revolutionary motion control in personal computers history, right? :P
.Keys, if gamers don't like to move then why does PS5 have motion sensitivity? Your explanation has a logical fallacy, because it doesn't explain why it would be popular on console but not on PC.

Dark_Art_, I wasn't aware of GameInput, and I'm having trouble finding much information about it, but the one thing that I see everyone saying is that it's very unreliable and causes Windows to crash. They say that the best way to fix that is to disable and uninstall it. Well great, then how can I USE it?! Also, I don't think that it's something most people would have already installed, which kind of causes the same problem as the emulation software I mentioned before. And finally, I don't think it's compatible with Linux. I need something which is cross-platform.

EDIT: Also, it looks like GameInput might only be compatible with Unreal Engine, but I need something to use with from-scratch programming, cross-platform, and something that won't crash the system, if that's not too much to ask. ;)
Post edited August 16, 2024 by HeresMyAccount
avatar
HeresMyAccount: I've heard that a PS5 controller can be used on PC, but what API does it use?
The Linux kernel has had official drivers for PS5 controllers from Sony for about 4 years.
https://screenrant.com/ps5-dualsense-controller-linux-compatible-new-driver/

As for an API I suppose it would be evdev. But that's not something you need to know about for gaming.
Post edited August 16, 2024 by EverNightX
But it is something I need to know about for programming.

EDIT: It mentions Steam, but that wouldn't be required, would it? It needs to run independently from Steam.
Post edited August 17, 2024 by HeresMyAccount
avatar
HeresMyAccount: But it is something I need to know about for programming.

EDIT: It mentions Steam, but that wouldn't be required, would it? It needs to run independently from Steam.
Steam is not required. The driver is part of the kernel. Evdev is part of Systemd.

Basically there will be an event file for the gamepad in /dev/input/ that you read from to receive events.

Or if you are not interested in the low level details you can use a library like SDL to handle it for you and give you a higher level to program against.

There's a command line tool called evtest you can get for most distros that can be helpful in testing/debugging gamepad inputs.
Post edited August 17, 2024 by EverNightX
Thanks, I'll look into that.
avatar
HeresMyAccount: .Keys, if gamers don't like to move then why does PS5 have motion sensitivity? Your explanation has a logical fallacy, because it doesn't explain why it would be popular on console but not on PC.
Not trying to turn this into a debate mate. :P
We do enjoy motion sensitivity as gamers, this is true.
But its not true that the majority of gamers want motion sensitivity in their games or even that most games require that.

If we really analyse it, PS5 DualSense is a bloated controller with many functions that most games are not even programmed to use.
By it being mechanically complex with many mechanical parts with specific functions and many small pieces, it also makes it troublesome to fix if something breaks, requiring PS5 users to buy a new one, which, by what it seems to me, is not cheap for most.
I'm of the mind of 'keep it simple, keep it working'.
If by adding many functions that most games wont even use, its just a waste of money in the end for most consumers.

A solution to this problem would be for Sony to create two brands of controllers, as Nintendo did with its joycons.
Nintendo Switch users which play casually with the small joycons will notice that its ok for most games, but if you play too much, you will find out quickly that they break easily and start to drift, requiring the user to buy the pro controller, which is much better.
So Sony could create a 'normal' casual controller in the likes of PS2/PS3 classic and beloved DualShocks with basic pressure sensitivity and basic motion support and a 'pro' controller in the likes of the current gen PS5 DualSense with all its functions for specific games.

Of course in this case the price tag should match each product. It seems to me it would work. Problem is that they're forcing all consumers to buy the expansive PS5 controllers with, again, many functions most games don't even use in the end apparently.

Anyway, I'm glad you could find a satisfying answer to your question. Good luck!
Lets hope companies focus on open source hardware in the future and 'fix it yourself' products.
avatar
HeresMyAccount: Dark_Art_, I wasn't aware of GameInput, and I'm having trouble finding much information about it, but the one thing that I see everyone saying is that it's very unreliable and causes Windows to crash. They say that the best way to fix that is to disable and uninstall it. Well great, then how can I USE it?! Also, I don't think that it's something most people would have already installed, which kind of causes the same problem as the emulation software I mentioned before. And finally, I don't think it's compatible with Linux. I need something which is cross-platform.

EDIT: Also, it looks like GameInput might only be compatible with Unreal Engine, but I need something to use with from-scratch programming, cross-platform, and something that won't crash the system, if that's not too much to ask. ;)
It is compatible with Linux, I can't recall wich driver (xpad, xone or xpadneo) is used but is the default on Kernel 6.6 and above. Just tested on Linux Mint 22 and Antimicro (sudo apt install antimicrox) recognised the gamepad without issue. Batocera Linux also works flawlessly.

I actually found out about this because one of newly bought gamepad was not working under Linux, although it worked fine on Windows 8.1 and 10 out of the box. After a bit of digging I found out that the GIP (Game Input Protocol wich includes older drivers, like Xinput and Directinput and also WindowsGameInput) is used on Xbox One and now, some aftermarket controllers too. If I correctly recall, most of the non technical info I got was from a reddit post.

Regarding the reliability, I bought 4 of such controllers last year and on 2 cases, by some magical reason, the gamepads weren't working on several USB ports on 2 diferent computers. One of them was solved by plugging on a different USB port. The other computer didn't recognise at all, unless plugged on a USB Hub, instead of the USB ports of the computer itself, still works daily plugged like that. Don't know the reason and not sure if its related to the Protocol itself, some issue with the computer itself of just gnomes.

Sorry, none of this help with with the PS5 controller, I don't have one to test.
avatar
.Keys: I was talking more about this kind of motion...
I see, VR type of controllers. Many people had fun with the Wii, although was not exactly the same.

I believe the op was thinking more of the built in accelerometer and gyro, sometimes magnetometer (Inertial Measurement Unit) like in most cellphones. Nintendo consoles have used them for quite a while.
Post edited August 17, 2024 by Dark_art_