Skip to content

27. Connec to Polaris Vega camera

Fa-Hsuan Lin edited this page Mar 14, 2023 · 18 revisions

There are steps and scripts to stream the tracker information from NDI Polaris VEGA ST to Matlab. These were helped by friends in the Dr. Aapo Nummenmma's lab at Martinos Center, Mass General Hospital.

1. Install NDI toolbox

Download and install NDI Toolbox

2. Test the connection to camera

Use Tracker software to see if the camera can be connected.

Load the ROM file for a tracking marker device. The ROM file with the label P1735 from Brainsight can be found here.

Tracker before and after loading the "tool" (a tracking marker), the window will become the following, respectively.

3. Install and activate Plus Server

3.1 install Plus Server download binaries [here]. While it seems that MAC version can be made, so far (August 2022) there are only binaries for Windows.

3.2 Start Plus Sever This needs 1) assign the folder for Plus Server definition (.xml) and sub-folders with device ROM files. An example can be found here. Important The definition file needs to provide the NetworkHost and Port if an ethernet cable is used to connect between the camera and the computer.

To track one device, you can try this server definition file. Some points worth of mentioning are:

  • Use the NDI configure tool to figure out the Bonjour name of the camera, if the camera is connected to the computer via an Ethernet cable. Here we used the host name "P9-10219". The port was 8765 from the configure tool. Thus, in the server definition file, we have the following section:
<Device
      Id="TrackerDevice"
      Type="NDITracker"
      NetworkHostname="P9-10219"
      NetworkPort="8765"
      ToolReferenceFrame="Tracker" >

  • The used tracker needs some definition in its own .rom file. Here we use two trackers with their rom files in the folder, with respective to specified device set configuration directory in Plus Server Launcher.
      <DataSources>
        <DataSource Type="Tool" Id="Tool" RomFile="NdiToolDefinitions/P1735.rom"  />
        <DataSource Type="Tool" Id="Ref" RomFile="NdiToolDefinitions/HeadBand.rom"  />
      </DataSources>
  • Here is the screenshot of the Plus Server Launcher. The device set configuration directory can be set by the graphic user interface. Then, the device set (Plus Server definition .xml file) needs to be specified.

NOTE At the lower right corner, there was a red (or green) circle, which can be clicked to show detailed information about the server.

To track two devices, you can try this server definition file.

When Plus server is launched successfully, you will see some info about the server. This info will be useful in the next step: streaming the data to Matlab.

4. Read transformation matrix in Matlab

Run this script to read the transformation matrices continuously.

NOTE : Make sure that maker is within the camera's field-of-view.

Clone this wiki locally