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

Controller disconnects as soon as it's plugged in #773

Open
Kommynct opened this issue May 16, 2024 · 10 comments
Open

Controller disconnects as soon as it's plugged in #773

Kommynct opened this issue May 16, 2024 · 10 comments

Comments

@Kommynct
Copy link

Kommynct commented May 16, 2024

My controller isn't detected, if I unplug it and plug it back in, I get the notification that it's disconnected and connected at the same time.

image

It works in clone hero. I'm on archlinux using the aur package

@NicKoehler
Copy link

I'm on Arch Linux too, but the game is from the official AppImage launcher. I still have the same issue, but with another guitar.

image

@EliteAsian123
Copy link
Member

Did y'all follow the additional setup instructions needed for Linux in the readme?

@NicKoehler
Copy link

Yes.

  • Installed additional packages with pacman -S hidapi systemd-libs
  • Added the udev rule KERNEL=="hidraw*", TAG+="uaccess"

If there is something I can do to debug this issue, I'm willing to help!

@NicKoehler
Copy link

Clone hero:

  • PS2 GUITAR (connected using an usb adapter)
  • XBOX GUITAR (connected directly to the usb port)

Yarg:

  • PS2 GUITAR (connected using an usb adapter)
  • XBOX GUITAR (connected directly to the usb port)

@TheNathannator
Copy link
Collaborator

Xbox stuff isn't reliably supported currently on Linux, there's some hacks going on to disable the native Unity controller support and that's the "instant disconnect" you're seeing. I tried to make sure Xbox controllers would make it through, but unfortunately that doesn't work on all distros.

@Kommynct
Copy link
Author

Did y'all follow the additional setup instructions needed for Linux in the readme?

It wouldn't have worked in clone hero if I hadn't.

My controller isn't an xbox controller, i'd like an option to enable the native unity controller support because again, this works absolutely flawlessly in clone hero.

@EliteAsian123
Copy link
Member

As far as I know, Clone Hero uses Rewired and not the native Unity controller support, so unfortunately that wouldn't help with this problem.

@TheNathannator
Copy link
Collaborator

TheNathannator commented May 25, 2024

It wouldn't have worked in clone hero if I hadn't.

Yes it would have, CH doesn't use the same input system we use and has no dependencies on hidapi. We use the newer Unity input system and handle bindings more manually, while CH uses Rewired which is much more generic.

For now, if you want to re-enable the native Unity input support, uninstall hidapi, that'll make our custom backend not initialize. Just beware that it is not perfect, and will likely miss certain controls. The custom HID backend exists to fix these issues, there just isn't an equivalent for evdev devices on Linux yet.

@NicKoehler
Copy link

hidapi is required for a lot of other packages on my system. I tried to remove it temporarily to see if my guitar would be detected, but as you said, certain controls do not work, like the red button and the strums.

@AlenaEK
Copy link

AlenaEK commented Jul 12, 2024

I had this problem too. My solution was to just install the game on Windows instead lol.

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

No branches or pull requests

5 participants