Vive Trackers Randomly Flipping Axis.

Hello everyone! (First post, need some help!)

I’m using several vive trackers in a motion capture project which is going great other than the fact some or all of the trackers at times will just flip or invert axis somehow. I’m fairly sure UE4 is responsible for this since I am able to put on my HMD and see the trackers being tracked in the Vive lobby with the correct orientation - but in Unreal they will be flipped. In UE4 I’m using the motion controller component with the option that makes a visible debug mesh of the device, and I can see it is flipped, and the tracking offsets I set up when it isn’t giving me this problem end up making my character all contorted, so I know its not just the device debug mesh. I’m not certain what exactly is going on when the tracker gets flipped around, whether its an axis being rotated or inverted, I just haven’t bothered to check, but it seems to be an issue with UE4. It also seems to come up most if a tracker disconnects and re-connects, like if I walk out of range of the dongles or if a tracker goes to sleep and I wake it back up. A strange thing too is restarting UE4 doesn’t seem to fix it. Steam VR needs to be restarted. It seems to be a problem with how SteamVR and UE4 are communicating on a very fundamental level - but I may be completely wrong. I’ve dug around too though and haven’t seen anyone else online with this issue, which I thought was odd. I’m using UE4.22.2 and Steam VR 1.5.16 - The motion controller components are children or a VROrigin scene which is child of the character mesh in a character blueprint - pretty standard setup. I’ve also tried using the “get tracked device location and orientation” node in the animation blueprint too but thats giving me the same problem as well! I’ve also migrated my character BP to a fresh project, same issue. Would like to know of any way I could resolve this. Let me know if sharing more details on this issue are necessary. Thank you and all the best!

Welcome ,

I’m not aware of any workarounds - however we are tracking a similar issue at Unreal Engine Issues and Bug Tracker (UE-71635)

A temporary solution that I can imagine would be to create the ability to modify tracker orientation in-game.

I think I solved the issue. Using the Enumerate Tracked Devices and specifying different devices types I was able to realise that one of the trackers seems to be recognised as a motion controller. The vive tracker up axis and the controller up axis seem to be different.

All I had to do to get both working as trackers is going to the SteamVR overlay, right-clicking on the tracker icon (any will do) and clicking on Manage Vive Trackers.

[ATTACH=JSON]{“data-align”:“none”,“data-size”:“full”,“data-tempid”:“temp_173998_1570099911196_220”,“title”:“Manage.PNG”}[/ATTACH]
A window opens and in there make sure that for each tracker you select a role that isn’t Held in hand, in my case I choose waist for both.

[ATTACH=JSON]{“data-align”:“none”,“data-size”:“custom”,“data-tempid”:“temp_173999_1570100004026_675”,“height”:“406”,“title”:“Role.PNG”,“width”:“750”}[/ATTACH]

Now with that setup go back to UE4 and try to run the EnumerateTrackedDevices with the DeviceType enum set to Other. You should see the right number of devices (two in my case) and if you use either GetDeviceWorldPose or GetTrackedDevicePositionAndOrientation the trackers should face both in the same direction.

Hopefully, it also works for you.