Home Forums Unity SDK Failed Controller Bindings

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #19986
    Eric
    Participant

    Dear all,

    I’ve recently been exploring the potential of the Tobii SDK and I am enthusiastic about what I am finding. However, I am having trouble whenever the use of a controller is included in the scene, such as in the Hand Eye Coordination demo scene. Additionally, I am unable to open the ‘gear menu’ in Dev Tools for likely the same problem.

    If I download a showcase (i.e. The Hub, Mirrors, etc…) the program picks up my controller without a problem (both Vive native controllers and Steam Knuckle controllers).

    I realize that the XR Player Hand-Eye prefab has a controller manager, and also a controller prefab. Here, I see the TobiiController listed. I do not have this controller. How can I fix this problem? I’d love to start developing a bit more with these techniques.

    Lastly, is there any way to get the scenes for the showcase projects too in order to tap into some more advanced codes, or are these closed software?

    Thank you!

    #20014
    Grant [Tobii]
    Keymaster

    Hi @ejmde, the hand-eye coordination scene and Dev Tools should work, both with native Vive and Knuckles controllers (we just tried using both Unity 2018.2.5f1 and Unity 2019.4.12f1.

    We would suggest trying to re-import the SDK (deleting any old contents first) and then see if it works. Additionally please let us know what Unity version and pipeline you are using and if you receive any error messages.

    The Missing TobiiController is odd (hence re-importing, because if that is missing, other components might be too), but for clarity, this prefab is only for visualization purposes and nothing else. Lastly, I am afraid we don’t give out any source code for showcases right now, unfortunately. Best Wishes.

    #20016
    Eric
    Participant

    Hi Grant, thanks for the reply.
    Honestly, I’ve started new projects and deleted and reimported everything about 5 times now, so I am thinking this is not the problem.

    I’ve also tried both Unity 2019.4.12f1, and the newest version 2020.2.7f1

    I’ll outline my steps (using Unity 2019) and see if you can see somewhere where things go wrong:
    1. I have SteamVR in the background; and confirm that the Vive, controllers, base station are all working correctly.
    2. I then follow the steps 1-4 laid out here: https://vr.tobii.com/sdk/develop/unity/getting-started/vive-pro-eye/ … importing packages into my default ‘VR’ project. Packages are: TobiiXRSDK_2.0.0.174 and Vive-SRanipal-Unity-Plugin
    3. After, I load Example_HandEyeCoordination. I check in the XR Manager that Vive is supported and at the top of the list, and I check the box for supporting SRanipal.
    4. I can play the scene in Unity, but it does not even come into the view of my Vive.
    –> at this point, if I hit run I get a persistent error for duration of runtime that is:
    "DIINotFoundException: openvr_api Valve.VR.OpenVr.GetInitToken () (at Assessts/TobiiXR/Examples/Utilities/Controller/Plugins/openvr_api.cs...)"
    5. I close and restart Unity, problem persists.
    6. At this point, I go back to step 3 with a new project and figure I need to import the SteamVR asset package from asset store.
    7. It asks if I want legacy mode or Unity XR mode. I’ve tried both lines, and the legacy mode goes into a looping which simply never works. So I choose XR mode.
    8. Says it is successful, and may need to restart editor. So I do that.
    9. Upon restart, if I play the scene, I get an error seen only in my HMD “the action manifest for [Testing] “myProject” was not found. File path C:…/”myProject”/Assets/StreamingAssets/SteamVR/actions.json”
    10. Now, to fix this I go to “Window”, “Steam VR input”, and it says “It looks like your project is missing an actions.json, would you like to use the example files?”… OK. Compiled. Saved. I also open the bindings UI and see that they look fine.
    11. Back to scene. We run it now, and the camera is in a weird spot, halfway into the floor. I move the “Tobii XR Player Hand-Eye” transform from “0, 0, 0” to “0, 0.33, -0.33”. Now the camera is fine.
    12. I can see the ‘gaze outline’ in light blue around the blue ball, but the trigger pull does nothing. I also notice my controller is not where it should be, but rather somewhere above me to the left. However, it does move how I move it, so the transform information is getting through.

    Similarly, if I drag the Dev Tools prefab onto the main camera… my gaze does indicate I am looking at the settings gear, but the trigger does not open it.

    Any ideas?

    Thanks!

    #20025
    Grant [Tobii]
    Keymaster

    Hi @ejmdev, thanks for the detailed report. So, at step 4, it appears you forgot to enable VR which is why it’s not working.

    One way to enable it and to make the controller correctly transform, is to go to “Project Settings > Player”, enable “Virtual Reality Supported” and dragging OpenVR to the top. This way, it will work. This will work for 2019.4.12f1 or earlier but might be deprecated in the latest Unity version, where there is another approach to enable VR depending on platform.

    Try this out and let us know how you get on. Best Wishes.

    #20038
    Eric
    Participant

    Hi Grant,

    Thanks again for the input.

    So, this problem actually goes back to the usage of the Legacy XR system. Since the new packages (including a simple VR template from the first Unity project screen!!!) all include the new XR system, it appears they are incompatible with the Tobii showcases as is. It actually even says this in the player “Built-in XR is deprecated and will be retired in a future version of Unity. Use the new Unity XR Plugin System instead…”

    I was able to circumvent this by instead of choosing a ‘VR’ project, choosing a simple ‘3D’ project. Then the ability to enable the deprecated VR support was available in 2019.4.12f1. Then, following my steps above 1-3 (you don’t even need to import SteamVR), the scene works, and even the camera/controller is aligned.

    We solved it!

    However, I am wondering if Tobii will update the SDK to be compatible with the new XR plugins? This is quite useful for many applications… 🙂

    Thanks again,
    Eric

    #20053
    Grant [Tobii]
    Keymaster

    Hi Eric, great! Glad to hear you managed to get it all working, happy to help 🙂

    With regards to the new XR plugsin, we are aware of the issue and hope that we can allocate resources to this in the future.

    The Eye tracking still works as intended however, it is just our examples that might not be fully compatible without a re-write.

    Hopefully this does not cause you undue inconvenience. Best Wishes.

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.