Gyroscope values to Joystick translate issue

I'm currently using a Leonardo to emulate xinput/joystick. I'm trying to using a BNO055 as a headtracker and use the gyroscope data translated to Right Joystick, which I already achieved. But the problem is I want 360 degree rotation around my body, and I'm using VR headset as my monitor, since I'm mapping heading values to joystick (+100 to -100) I will have to keep my head in my start position to have in-game camera stable.

After this, I tried comparing the previous heading value with current heading value and if there's a difference I send Xinput Joystick value. However I feel this method is not perfect as I have to set Joystick value to 0 each time after there's no difference between previous and current heading value?. I can solve the problem if I am using mouse emulation like 'Cinemizer'. But I want to do this with using xinput.

Also, I'm building this for non-vr games.

Is there any suggestion from any one of you?

Thanks!

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.