Forums » MacOS X

Changing the joystick repsonse curve

May 13, 2020 Domdron link
I'm using a Logitech Extreme 3D Pro and find it too sensitive in the near-center values, making it hard to target especially in pvp. (I know I could use the mouse instead, but I find using the stick much more fun if it works.)

I tried changing the axis from linear to square root, but that didn't seem to do anything? Anyway that would actually make the response more sensitive at near-center values, not less. For my purposes, I'd rather need a plain square curve.

So I found this tool ControllerMate and used it to implement this curve (by mapping the physical onto a virtual joystick, which is then used by VO):

y = ((x-k)^3 / (k * |x-k|)) + k

where k = max(joystick range) / 2.

ControllerMate also has a calibrator building block which can be plugged between the physical joystick output and the formula input, which gives a 0-255 range by default; so with this, k = 128.

Unfortunately, the ControllerMate website doesn't seem to be maintained anymore, and the purchase page doesn't load. So one is restricted to max. 6 outputs in the free version, which isn't enough to map all the buttons. So I only map the 3 axis (X, Y, Rz) to the virtual joystick, and then configured VO to map the virtual joystick's axis to turn, pitch and roll, but use the buttons from the pyhsical joystick.

So this works, but is a bit cumbersome to set up, and also that ControllerMate doesn't seem to be maintained anymore is worrying and probably means that it will stop working in future MacOS versions. And then there's the issue that one has to install driver-level software (kernel extension) which is not open source.

It would be much greater to be able to do such adjustments in-game. I know that Incarnate has mentioned a few times that he'd like to add a curve editor, but it's not such high prio and so there's no dev time for it.

However maybe creating a hook that a plugin could use might be an option? E.g. a function joystickCurve(x), which by default is just the identity (y=x), but a plugin could put any formula there (with well-defined input/output ranges), or even provide a GUI editor? Or would it be a performance issue to route the controller readings through Lua?