Devs: Basic flow for recognising a device

Hi All,

I am trying to get JInput to recognise the SpaceNavigator on OSX.

With a bit of debugging code in the native libraries, I see that the native library is seeing the SpaceNavigator, and that java HIDDevice is being constructed for it. But it is not present in the array of Controllers that is passed to my user code.

So, what chain of events to I need to trace to find out where (and why) the SpaceNavigator HIDDevice is being discarded?

Cheers!
Nik

Ah, ok answering my own question: OSXEnvironmentPlugin…

Cheers!
Nik

Ok, so the problem is that the SpaceNavigator is being seen as a MULTI_AXIS_CONTROLLER (quite reasonable), and there isn’t any code for one.
Surely it’s not so easy as just adding a line of code in OSXEnvironmentPlugin?

Oh well, one way to find out… :o)

Cheers!
Nik

Guess what??

My app is now recognising the SpaceNavigator device.

Sadly, my program isn’t getting any events from it at all, so I need to debug that now :slight_smile:

Thanks for listening guys, and I’ll let you all know once I’ve got it working properly!

Cheers!
Nik

Ok,

Just to let people know, I’ve got the SpaceNavigator working with jinput under Mac OSX.

The change to the jinput Java code is almost trivial. Is there somewhere I should send a patch?

Looking at the issue, it seems to me that this aprt of the code could actually be parameterised and then changes suh as mine could be made to via a properties file, or through an API, rather than modifying the source and rebuilding the JAR.

Thanks again for this great library - you’ve just made a number of people really happy :slight_smile:

Cheers!
Nik

Hi,

Good news :). You can PM the patch to me, or upload it to a website and link it here, or email me, my username@dev.java.net. If you are expecting to make more changes we can sort out CVS access too.

Cheers

Endolf