nsensfel / relabsd

Turns your input devices into joysticks by converting relative axes into absolute ones.
BSD 3-Clause "New" or "Revised" License
16 stars 1 forks source link

Device is created, but axes are not moving #4

Closed tfischer4765 closed 4 years ago

tfischer4765 commented 4 years ago

I've got a 3dconnexion space mouse connected. Running relabsd -? device gives me the correct number of axes and buttons. Running relabsd /device /configfile creates a joystick device. When I connect to it e.g. with jstest, I see the correct axes and buttons displayed, but moving the device does not show up on the axes. I'm using the standard spacemouse config file supplied with the sources.

I've tested that the system works in general with an usb mouse. When running relabsd on that, the joystick created shows movement when the mouse moves.

I've not found any relevant information in the wiki or the help text on how to debug this kind of problem. Is there any kind of switch that will make relabsd print debug output to the console? Does it write any log? Is there any way to "see what relabsd sees"?

nsensfel commented 4 years ago

All debug output is controlled in include/relabsd/debug.h. Just set all the 0s to 1s. and it will print a lot of additional information.

tfischer4765 commented 4 years ago

Thanks, it turns out another process was hogging the device.

How do I contribute to the wiki? I'd like to write this up.

Incedentially, exposing that functionality through a config option might be a good idea. Since -d for debug is spoken for, how do you feel about e.g. -v, -vv, -vvv?

nsensfel commented 4 years ago

Ah. I added a mention to the debug file in the wiki while you posted. Apparently, I already had set the permissions for anyone with a GitHub account to edit the wiki. Is it not working?

Yes, setting the debug verbosity through run-time parameters flags would indeed be preferable. Especially if this tool ever becomes distributed pre-compiled. I don't see it as that important for now, though, so I'm not going to change it now. I'll mark the ticket as a suggestion for later, in case I feel like it at some point or if anyone wants to do it and proposes a merge request

tfischer4765 commented 4 years ago

Yes, I found out how to edit the wiki, thanks. I'm writing something up right now. I don't know, my C is a little rusty, but maybe it's time I got back on the horse. If you gave me a quick rundown of the code I might be able to whip up a patch or three.

nsensfel commented 4 years ago

Well, thinking about it a bit more, I realized it was actually a very easy modification. It's added in: "-v/--verbose" now gives input/output info, "-vv/--very-verbose" also gives config file and program flow.

Closing the issue. Thank you for the suggestion and the offer.

tfischer4765 commented 4 years ago

Cool, thanks