Closed coliss86 closed 1 month ago
My understanding:
I changed, where the modifiers are applied, from the centered data, to the resulting trans and rot data, as this worked way better for me. In the version by LivingTheDream, the calculations (in 4.) also only calculated some movements and forced the other values to zero. I find the modifiers much better, as they only minimize other movements, but don't ignore them. (Somehow ike the "dominant" mode in the settings by 3dconnexion, that I don't like)
I will test the debug3 output again and report back.
I have checked the debugOutput3() again and they work pretty well. Have you checked the array with the min and max Values which is used for the mapping?
I created a little semi-automatic script to get the values for the minVals and maxVals. You start this procedure with debug=20.
the debug=20 is really great :-)
I tried again with the current main version and here is the logs while doing a complete RY and RX:
AX:0,AY:0,BX:0,BY:0,CX:0,CY:0,DX:0,DY:0||TX:0,TY:0,TZ:0,RX:0,RY:0,RZ:0
AX:0,AY:0,BX:0,BY:0,CX:0,CY:0,DX:0,DY:0||TX:0,TY:0,TZ:0,RX:0,RY:0,RZ:0
AX:0,AY:0,BX:0,BY:0,CX:58,CY:0,DX:0,DY:0||TX:0,TY:0,TZ:0,RX:0,RY:0,RZ:0
AX:0,AY:0,BX:0,BY:0,CX:233,CY:0,DX:0,DY:0||TX:0,TY:0,TZ:0,RX:0,RY:0,RZ:0
AX:0,AY:0,BX:0,BY:0,CX:360,CY:0,DX:0,DY:0||TX:0,TY:0,TZ:0,RX:0,RY:0,RZ:0
AX:0,AY:0,BX:0,BY:0,CX:462,CY:0,DX:0,DY:0||TX:0,TY:0,TZ:0,RX:0,RY:0,RZ:0
AX:0,AY:0,BX:0,BY:0,CX:498,CY:0,DX:0,DY:0||TX:0,TY:0,TZ:0,RX:0,RY:0,RZ:0
AX:0,AY:0,BX:0,BY:0,CX:498,CY:0,DX:0,DY:0||TX:0,TY:0,TZ:0,RX:0,RY:0,RZ:0
AX:0,AY:0,BX:0,BY:0,CX:498,CY:0,DX:0,DY:0||TX:0,TY:0,TZ:0,RX:0,RY:0,RZ:0
AX:0,AY:0,BX:0,BY:0,CX:498,CY:0,DX:0,DY:0||TX:0,TY:0,TZ:0,RX:0,RY:0,RZ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:0,RZ:0
AX:500,AY:0,BX:207,BY:0,CX:0,CY:0,DX:0,DY:0||TX:0,TY:0,TZ:0,RX:0,RY:0,RZ:0
AX:500,AY:0,BX:0,BY:0,CX:0,CY:0,DX:0,DY:0||TX:0,TY:0,TZ:0,RX:0,RY:0,RZ:0
AX:500,AY:0,BX:0,BY:0,CX:0,CY:0,DX:0,DY:0||TX:0,TY:0,TZ:0,RX:0,RY:0,RZ:0
here is the minVals and maxVals:
int minVals[8] = {-524, -410, -493, -495, -56, -501, -524, -529};
int maxVals[8] = {499, 500, 530, 528, 498, 521, 28, 493};
and sensitivity:
float rotX_sensitivity = 1;
float rotY_sensitivity = 1;
as you can see, the values from sensors are reported but the rotation is still equals to 0
.
Your minVals CX is very small with -56 and your maxVal for DX with 28 is also very limited. You should confirm with debug=2 that you can not get a greater reading when moving the mouse.
I updated the script to map:
Bus this shouldn't be the problem... Which modFunc do you use? With modFunc=4 my values are also very often near to zero. I suggest modFunc = 3, but for debugging please put it to modFunc=0.
Thanks for your reply maybe one of my joystick is broken, I'll have to find another one and make more tests.
Hi,
On my mouse, when moving it nothing happen.
With
debug
set to 3, the output is set to 0:but when setting the debug output to 2, all values are updated :
After the v3, a new instruction has been added that seems to cause this issue:
When commenting this bloc, the mouse is working :)
I think this is incorrect because the upper and lower limits are used to constrain the values sent to the software, not those read by the sensor. This constraint should be applied after all the calculation are done.
WDYT ?