JInput on MacOS doesn't recognize controllers

Hi there,

I want to get an Input from my old PlayStation 3 Controller on my MacBook (MacOS 10.15.3), but I didn’t even had a chance to interact with it.

I followed along some tutorials on this Forum as well as this https://www.bartneck.de/2017/08/14/tutorial-on-how-to-install-and-setup-jinput-on-mac-os-x-using-eclipse/ tutorial, but never got further than this Error-Message:

Feb 27, 2020 8:40:05 PM net.java.games.input.ControllerEnvironment log
INFORMATION: Failed to enumerate device: Device open failed: -536870174

This is caused by this line:

ControllerEnvironment.getDefaultEnvironment().getControllers();

I already tried the getControllers() method from RawInputEnvironmentPlugin, like it was done by others. I looked up in the source code and found out that the RawInputEnvironmentPlugin only works for Windows.

I hope we can get rid of this message together
DANDI

Jinput is long dead I’m afraid and wasn’t too reliable even when it was in its heyday - your best bet is to move to LWJGL3 and see if the GLFW binding works for you.

Cas :slight_smile:

Maybe one of the answers here might help with an alternative: https://stackoverflow.com/questions/14945058/using-usb-gamepad-from-java-app

Maybe this thread might help?

I had to import 2 JInput files to my program to get it to work. I can take a look which ones later if you want.