Valve’s SteamVR Tracking system is great for VR but certainly not limited to it. For developers, hackers, researchers, and more who might have use for an inexpensive high accuracy, low latency, 6 DOF positional tracking system, it’s possible to use the new Vive Trackers or controllers (even with a single base station) without needing to shell out for the full $800 Vive system.

Guest Article by Luke Beno

luke-beno

Beno runs Triad Semiconductor’s Arctic VR Lab (aka Triad’s Green Bay Lab – Go Pack!). Triad Semiconductor worked with Valve Corporation to create the Light to Digital Converter ICs (TS3633) for SteamVR Tracking. Beno speaks Python and English and his office smells of solder and 3D printing. He spends his days and nights ensuring that SteamVR Tracking ICs and systems provide precision tracking and he supports SteamVR users around the globe with the development of Tracked Objects.

The purpose of this tutorial is to provide step by step guidance on how to get started with SteamVR Tracking 6DOF positional tracking for as little as $235. In this tutorial, the latest version of SteamVR Beta, is coupled with python 3.6, the pyopenvr library and the triad_openvr Python wrapper.

Minimum Hardware Needed:

  • One HTC Vive Basestation (Two Basestations also have advantages)
  • One of the following SteamVR compatible Tracked Objects:
  • x86-based PC

Software Required:

Note: Currently this is only tested on Windows but should also apply to Linux

Steps:

  1. Download and install the above software components
  2. Locate the following configuration file and open it with a text editor: <Steam Directory>steamappscommonSteamVRresourcessettingsdefault.vrsettings
  3. Search for the “requireHmd” key under “steamvr”, set the value of this key to “false”.  The following is a .vrsettings file that has been tested as functional:
    pasted-file-1-1
  4. If SteamVR is running, close and restart it
  5. When SteamVR restarts, you will see that it is now possible to connect a tracker or controller without the HMD.
    Note: “Not Ready” text is normal and does not impact this tutorial
  6. Open a command prompt and navigate to the folder where triad_openvr was unzipped
  7. If you are testing with a Vive Tracker, run the following script
    python tracker_test.py
  8. If you are testing with a Controller, run the following script
    python controller_text.py
  9. As the script executes, you will see numbers updating at 250Hz. These are the realtime 6DOF pose coordinates!
    pasted-file-3-1

The purpose of this tutorial was strictly to provide a quick proof of concept that demonstrates that an HMD is in fact not a requirement for use of SteamVR.

Python is an extremely extensible language and this example code may provide a basis for many derivative projects.  These same concepts also easily apply to other programming languages such as C, C++ C#, etc.

SEE ALSO
Closeup: Next-generation SteamVR Tracking Base Station is "Better in every way"

If you have any questions or would like to share your project based on this tutorial, please contact us at info@triadsemi.com.

Newsletter graphic

This article may contain affiliate links. If you click an affiliate link and buy a product we may receive a small commission which helps support the publication. More information.


  • Sponge Bob

    “it’s possible to use the new Vive Trackers or controllers (even with a single base station)”

    Huh ???

    I’ve always thought that Lighthouse tracking system requires 2 basestations for accurate tracking UNIFORMLY in all directions

    Now the Vive controller is kind of large and it might be tracked with one just one basestation in the vicinity of that basestation maybe up to 1 m – i dunno (I have Rift not Vive)

    But this little tracker is small so me thinks not – You have to have 2 basestations to track it well

    Please confirm

    • Luke Beno

      Like you have identified and the doc-ok article also suggests, there are performance differences between one and two Basestation tracking. The point is that just one basestation is a valid configuration and is a way to get started.

      For some non-VR applications, possibly this performance is acceptable so as a minimum requirement, you could get started with just one.

      • Sponge Bob

        I’m sure it “works”, sort of…

        but practically speaking at some distance from basestation, say 12 feet, just how good is it to be useful with just one basestation ?

        If you get X and Y but Z has a horrible jitter of say 10 mm then I wouldn’t use it for anything

        same problem with Rift’s one camera – jumps a lot as you get further

        it is well known fact in the motion tracking industry than the minimal number of cameras is 2

        • Luke Beno

          Well out of curiosity I ran a test by mounting a tracker to a tripod and placed it 4060mm away from Basestation A and 3048mm away from Basestation B. I then used this triad_openvr python code to acquire 60 seconds of tracking data sampled at 250Hz.

          First run was with both basestations running, then again with only Basestation A running.

          I then calculate the magnitude of the position and magnitude of rotation for each same and do some statistics:

          2 Base Position Magnitude 3sigma: 0.3028mm
          1 Base Position Magnitude 3sigma: 0.7458mm

          2 Base Rotation Magnitude 3sigma: 0.01990 deg
          1 Base Rotation Magnitude 3sigma: 0.03216 deg

          2 Base Position Magnitude max-min excursion: 1.0407mm
          1 Base Position Magnitude max-min excursion: 1.6712mm

          2 Base Rotation Magnitude max-min excursion: 0.04535deg
          1 Base Rotation Magnitude max-min excursion: 0.07418deg

          So my conclusion is that the impact of Jitter for 1 basestation vs 2 could roughly be as much as double BUT that the overall tracking performance is still very useful for many applications and no where near 10mm.

          • NooYawker

            So in layman speak… .. this is.. good? bad?

          • Luke Beno

            Sorry… In my opinion both 1 Base and 2 Base performance is good!

          • Sponge Bob

            why do people pay for second base station then ?
            why would they want to pay for NoloVR ?
            why NoloVR exists in the first place ?

          • NooYawker

            For the reason you refuse to believe. When they’re turned away from the basestation the second one can see. Just face facts, you’re wrong.

          • Sponge Bob

            NO
            you are wrong
            with one basestation the error grows linearly with distance in x-y direction and quadratically in z direction
            go figure it out yourself

          • Eero Kuusi

            Would you happen to know whether you can set up a play space without the HMD with only the trackers? I mean setting up two base stations somewhere and getting tracking up and running with just one tracking puck.

          • Luke Beno

            Great question! I ran an experiment where I took a basic laptop (Win10, Core i5 with Intel Integrated Graphics). Installed Steam and SteamVR and tried exactly this.

            Room setup was not required at all. I believe that this is more for telling the Chaperone what direction to face, where the floor is and what the bounds of the room should be.

            In my experiment, it seems as simple turn on the basestation, turn on the tracker and start getting coordinates.

            When you do this, it seems that the origin of the coordinate system is the location of the Mode A basestation and the best I can tell, it tries to align orientation with with gravity.

            This probably means that for your application, you would have to have a scheme to pin this coordinate system to whatever you are wanting to track in the real world.

          • Eero Kuusi

            That’s great news, I was carefully optimistic that the calibration was exactly that, ie. just for knowing where the floor is and setting directions. Thanks a lot for testing this.

            triad_openvr seems really useful, too. I have played around with pyopenvr and got things running but anything making it more convenient is a huge plus. Thanks for the effort, hope you guys at Triad keep this great level of support for working with the tech up!

          • Luke Beno

            We’re happy to help and inspire more people to be innovative with use of the Tracking Technology.

            pyopenvr is a great start and an excellent base layer, the goal with triad_openvr is to make the interface more intuitive/natural to use and pythonic.

            You (and anyone else) are welcome to contribute to the github to add the features that you want too!

          • Sponge Bob

            dude, you don’t even have access to raw data
            lighthouse does not sample at 250 Hz – you are talking IMU merged data
            you really need to analyze raw position data for just one Z direction – the line from tracker to basestation
            which you cant do of course cause you don’t know how
            ask someone else to do it for you theninsetad of posting bs meaningless figures here

    • kontis

      The only real reason for two base station is occlusion (especially users’s body occlusion). There are some use cases for 6dof tracking that don’t involve humans, so oclussion may not be an issue.

      • Sponge Bob

        wrong answer

  • Sponge Bob

    135 + 135 + 100 = 370 $

    (not 235$ as this author suggests)

    Right ?

    • NooYawker

      135+100=235.

      • Sponge Bob

        Have you tried it with just one basestation (at 3 m distance)?

        I have Rift so can’t try it right now

        • NooYawker

          I would imagine it would work fine if I wasn’t turning around and around. it would be an interesting test. I read one works fine for sitting games, even Eve Valkyrie but I doubt it’ll be any good with say Arizona Sunshine.
          It would be an interesting test, I’ll try it when i get a chance.

          • Sponge Bob

            http://doc-ok.org/?p=1478

            with just one basestation the jitter is highly anisotropic (as expected)
            and > 2mm (at z direction) at 2 m distance with LARGE headset

            with small tracker I expect the jitter to be at least 10 mm – not good

            second basestation is a MUST

            second basestation is not just to prevent occlusion (contrary to what HTC Vive PR dudes want you to believe)

            It is for accurate tracking

          • NooYawker

            I thought you were actually interested if one light house works I didn’t realize you were an oculus fanboy just trying to tear down vive and lighthouses. But for reference here’s a video.

            https://www.youtube.com/watch?time_continue=112&v=GHFTyXoabK4

          • Sponge Bob

            I know how lighthouse tracking works in detail
            fact: it only measures X and Y angles to each photo diode
            fact: you need 2 for accurate triangulation

          • NooYawker

            You read one article and that’s all you’ll believe but real world tests seem to confuse and anger you.

          • Sponge Bob

            unlike you I studied math and physics really really well
            so I get the full picture and you do not

          • NooYawker

            Doesn’t change the fact you’re ignoring real world results. You’re a terrible researcher. Your professors would be ashamed of these posts.
            But I was premed so I took my fair share of physics and math courses.
            You did mean you have degrees in math and physics right? Not that you took some math and physics courses in college did you? Because that would be embarrassing on your part.

          • Jack H

            Could the timing between the laser line sweep hitting adjacent photodiodes be used to get Z, if the receivers are fast enough?

        • Luke Beno

          See my response below for actual test data.

  • Like it, since it makes people use this open device with lots of new possible applications, even non-VR related

  • Michael Speth

    The pricing the author lists is misleading. If you want a roomscale front facing experience, here is the actual cost.

    Cost for front facing room scale
    * 1 Base Station: $135 USD
    * 2 Controllers: $120 USD * 2 = $240 USD
    * 1 Tracker: $100 USD

    Total cost: $475 USD

    NoloVR will provide the same but at a faction of the cost. Only costs $149

    • Bob

      The pricing is just for tracking one object… just like it says if you could read.
      1 base station: $135
      1 tracker: $100

      Total Cost: $235… just like it says.

      • Sponge Bob

        135 + 135 + 100 = 370 $

        you do need second base station

    • Sponge Bob

      To be precise, NoloVR does not provide trackers – only hand-held controllers which may or may not be easily attached to objects
      they do use one “lighthouse like” base station, with some “extras” inside
      if one lighthouse basestation worked there would be no need for NoloVR in the first place

      This article is incorrect and totally misleading

  • virtualHC

    This is great info, thank you! Does anyone know if it is possible to use two Vive controllers with one Steam dongle or do I need one dongle per controller? I’m looking into using my two controllers without having to connect the HMD for non VR applications.

  • Donald Dunbar

    This is way overcomplicated. You can use the tracker, the controllers, even play whole VR games without using the headset. Just use your imagination, bro.

  • Nikolaj Bertelsen

    I Own the vive, but I’ve also ordered the pimax 4k. Does this allow me to strap the vive tracker to the pimax and track it just like the vive HMD?

    • Sponge Bob

      guess not… without LOOTS of hard work

      your best bet is nolovr

      or wait for pimax 8K kickstarter – it will come with lighthouse tracking (according to them)

  • Alex Ong

    A few notes since this is vaguely out of date.

    To install SteamVR with beta, install SteamVR using steam.
    Then right click SteamVR->Properties->Betas->Opt in

    To install pyopenvr, use
    pip install openvr
    Note that it is OPENVR not PYOPENVR

    Note that the instructions for the controller are slightly wrong:
    python controller_test.py
    there is a typo saying text rather than test.

    Also, you need to connect the controller via micro-usb for it to work. This is stated, but would be good in bold.

  • Will

    Does this still work?

    • Nick

      Yes

  • If I disconnect my HMD how will I get data from LightHouse stations and my controllers to my PC?

  • Hello there!

    I just tried this, this is very cool but still I dont get why, if I use the vive tracker, if I rotate it around the Y axis it changes my PITCH and not the YAW as it should be. Any idea?

  • Sergio Bromberg

    In case you want to do this in Unity, you may try this:

    https://github.com/sergiobd/ViveTrackerUtilities

  • jenyyshmaharjan

    I got one base station and one tracker connected to steam vr, but they are not tracking/being tracked.

    Also when I run tracker_test.py, it gives a NoneType error for v.devices[“tracker_1”].get_pose_euler() which confirms that the tracker is not being tracked. What can be the issue here?

    • Dmitry

      I have the same problem. Have you solved it?

      • arturo ku

        We have the same problem too. Did you find out any solution? Urgent!!!!!!!!!!!!!

  • Andrew Sharapko

    Thank you so much!!
    It works with Vive controller!

  • Lima_77

    Can someone please help me, I am running this tutorial with 1 base station and 1 controller. Both the controller and the base station are recognized by the Beta SteamVR, however I keep getting this error as below. Your help is much appreciated thank you!

    Found 1 Tracking Reference
    tracking_reference_1 (LHB-16B4664F, Mode HTC V2-XD/XE, HTC V2-XD/XE)
    Found 0 HMDs
    Found 1 Controller
    controller_1 (LHR-FDF3FFC7, Vive. Controller MV)
    Found 0 Trackers
    Traceback (most recent call last):
    File “controller_test.py”, line 20, in
    for each in v.devices[“controller_1”].get_pose_euler():
    TypeError: ‘NoneType’ object is not iterable

    • arturo ku

      We have the same problem too. Did you find out any solution? Urgent!!!!!!!!!!!!!!

    • Somesh Daga

      That happens when the controller is not in view of the basestations (even though the controller and the base stations are both recognized)

  • Kat

    Has anyone had success with this as of late? via these instructions I’m able to bypass the HMD, but in the SteamVR dashboard the base station shows up, the Tracker pairs with the dongle, but the base station does not see the tracker so the tracker icon is just flashing. I’ve also tried adding the lines to the steamvr.vrsettings file in the Steam/config folder but have the same result. Any help would be very appreciated!

    • Vincent Darkwood

      did you manage to solve it? I’m having the same issue

  • Cosmic

    The settings file is now under `/config/steamvr.vrsettings`

  • natlie

    I’ve got this script working with the HTC Vive trackers 3.0, and also made edits to the python script so it also records timestamp and saves it to a csv file. Was wondering if you had more information on what the origin is (ie. what the xyz,roll,pitch,yaw data was in reference to) some more research suggests it’s the lighthouse/base station, but wanted to check this. also to confirm what units are these measurements in?

    • Matteo

      Can your script be found somewhere? It would be really helpful for my research :D