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

[Feature Request]: Nvidia Shield Controller - add rumble support. #846

Open
mrdude2478 opened this issue Aug 11, 2024 · 4 comments
Open
Labels
feature request New feature or request

Comments

@mrdude2478
Copy link

Feature Description

Currently Nvidia shield controller (0x0955, 0x7214) is supported for button presses, but there's no code for the rumble motors to work. This controller has 2 motors.

Rationale

Rumble support is good in games and adds to the game experience

Additional Details

I have a couple of these controllers and can test code mods/compile the source for minor changes and to help with testing. If you can point out to a capture program to log the motor commands I can let you know what readings I get if that information would be helpfull.

@mrdude2478 mrdude2478 added the feature request New feature or request label Aug 11, 2024
@mrdude2478 mrdude2478 changed the title [Feature Request]: Nividia Shield Controller - add rumble support. [Feature Request]: Nvidia Shield Controller - add rumble support. Aug 11, 2024
@ndeadly
Copy link
Owner

ndeadly commented Aug 11, 2024

You can capture packets on a PC using Wireshark. You can capture either USB or Bluetooth traffic, but you will need to make sure you install the optional USB capture driver during the initial setup (yes, for Bluetooth too). It might also be enough to grab the hid report descriptor, but this can probably be seen in the packet capture too.

@mrdude2478
Copy link
Author

Thanks for the fast reply, also in nvidia_shield_controller.cpp, you have A B mixed and Y X mixed - correct code:

m_buttons.A = src->input0x01.buttons.A;
m_buttons.B = src->input0x01.buttons.B;
m_buttons.X = src->input0x01.buttons.X;
m_buttons.Y = src->input0x01.buttons.Y;

There was no need to remap those, just changing the above fixes so the correct buttons are used.

I also have an Nvidia Shield TV, it might be faster just using an Android app to capture the hex values for the buttons as I think there's an app for that already made, I'll try wireshark though as I've not used it before.

@ndeadly
Copy link
Owner

ndeadly commented Aug 11, 2024

The mapping is intentional. It's supposed to mirror the relative location of the buttons on a Pro Controller, not what's printed on them.

@mrdude2478
Copy link
Author

OK, thanks - I actually prefer them to be what's printed on the buttons. Just a personal choice though so no worries.

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

No branches or pull requests

2 participants