Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added new buttonmap for PS4 controller (both v1 and v2) #117

Merged
merged 3 commits into from
Jul 13, 2017

Conversation

arucard21
Copy link

After updating my system, it seems like the PS4 (both v1 and v2) controllers are detected a bit differently. I created a new buttonmap for it, which I'm providing in this PR. It seems like both v1 and v2 are detected as the same type of controller now, so only 1 buttonmap is required.

I think this may be because I updated to the linux 4.11 kernel which now has support for the PS4v2 controller. In earlier kernel versions, the PS4v2 controller wasn't explicitly supported, it seemed to partially work because of the PS4v1 controller code.

@garbear
Copy link
Member

garbear commented Jul 13, 2017

Great, thanks for the button map. Can you map the remaining controller profiles? There's a bunch that will show up if you select "Get More".

@arucard21
Copy link
Author

You mean the Playstation, SNES, etc. profiles? Should I create a new PR for that or just add it to this one?

@garbear
Copy link
Member

garbear commented Jul 13, 2017

This PR is fine

@arucard21
Copy link
Author

I added the profiles. Note that some of the controllers didn't really have an obvious mapping for all buttons (especially the 6-button genesis controller), so I just made something up. I don't know if this matches what you've done for the other controllers as it's not really easy to read from the buttonmap files.

The biggest deviation with the genesis controller is mapped like this:
A -> square
B -> X
C -> O
X -> triangle
Y -> L1
Z -> R1
If there's some standard/preferred mapping for these controllers, let me know and I'll map them again.

<configuration />
<configuration>
<axis index="2" center="-1" range="1" />
<axis index="5" center="-1" range="1" />

This comment was marked as spam.

@arucard21
Copy link
Author

I manually emptied the <configuration> block now.

I actually noticed this before and remapped for the Kodi profile, but that didn't remove it so I thought it might be intended. Not sure when and how it got added.

@garbear
Copy link
Member

garbear commented Jul 13, 2017

Thanks. Looks good now.

@garbear garbear merged commit 6e07043 into xbmc:master Jul 13, 2017
@garbear
Copy link
Member

garbear commented Jul 13, 2017

Thanks for the button maps. They'll be included in my next round of test builds.

@garbear
Copy link
Member

garbear commented Apr 29, 2022

5 years later I noticed that my PS4 controller uses digital buttons instead of analog axes for the triggers. Improvement sent in #235

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants