# Setting up the Optitrack Motive =\> PLUS =\> Slicer IGT Watchdog

**URL:** <https://discourse.slicer.org/t/setting-up-the-optitrack-motive-plus-slicer-igt-watchdog/20280>\
**Category:** Development\
**Tags:** slicerigt, openigtlink\
**Created:** [October 21, 2021, 8:33am UTC](https://discourse.slicer.org/t/setting-up-the-optitrack-motive-plus-slicer-igt-watchdog/20280 "2021-10-21T08:33:46Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![pll\_llq](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/pll_llq/32/9408_2.png) [@pll\_llq](https://discourse.slicer.org/u/pll_llq)\
**Post date:** [October 21, 2021, 8:33am UTC](https://discourse.slicer.org/t/setting-up-the-optitrack-motive-plus-slicer-igt-watchdog/20280/1 "2021-10-21T08:33:47Z")

</div>

Hi everyone 👋,  
We’re using Optitrack DUO for to track tools in our setup. The PLUS server is set up to attach to a running motive and send only valid transforms to Slicer.  
We see a problem that on the Slicer side that it continues to receive the last known transform of the tool even if the tool is out of the tracker camera’s sight.

[https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/9/9/99860466fef8a31b2b17700ba733fae2dc2c1dc1.mp4](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/9/9/99860466fef8a31b2b17700ba733fae2dc2c1dc1.mp4)

As showed in the video - in Motive itself when the tool is out of sight the icon dims, so I assume that the Motive knows that the tool is not visible. In Slicer the transform update stops only when I turn PLUS server off completely.

I guess there is either some setting on the Motive side that should be toggled to prevent these transforms from being sent or some additional setting for the PLUS server configuration. Has anyone had similar issues or can advice on how to establish this `MotiveToSlicer` connection correctly?

---

<div class="post-metadata">

**Author:** ![Sunderlandkyl](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/sunderlandkyl/32/79987_2.png) [@Sunderlandkyl](https://discourse.slicer.org/u/Sunderlandkyl)\
**Post date:** [October 21, 2021, 2:51pm UTC](https://discourse.slicer.org/t/setting-up-the-optitrack-motive-plus-slicer-igt-watchdog/20280/2 "2021-10-21T14:51:06Z")

</div>

In the config file, you can add "SendValidTransformsOnly=“TRUE” to the PlusOpenIGTLinkServer element, which should stop them from being sent.

```auto
<PlusOpenIGTLinkServer
  ...
  SendValidTransformsOnly="TRUE"
  ...

```

---

<div class="post-metadata">

**Author:** ![pll\_llq](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/pll_llq/32/9408_2.png) [@pll\_llq](https://discourse.slicer.org/u/pll_llq)\
**Post date:** [October 21, 2021, 2:55pm UTC](https://discourse.slicer.org/t/setting-up-the-optitrack-motive-plus-slicer-igt-watchdog/20280/3 "2021-10-21T14:55:14Z")

</div>

Thanks for the input. We see this behaviour when the `SendValidTransformsOnly` is `"TRUE"`. (in the video on the right side there is a text editor open with the config that we’re using. line 38). If the tool is lost we continue to receive the transform update that shows the last known tool position.

We saw that Motive and PLUS send invalid transforms only if the tool is not registered in Motive. We did try switching the `SendValidTransformsOnly` to “not TRUE” earlier today and validated this.

---

<div class="post-metadata">

**Author:** ![Sunderlandkyl](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/sunderlandkyl/32/79987_2.png) [@Sunderlandkyl](https://discourse.slicer.org/u/Sunderlandkyl)\
**Post date:** [October 21, 2021, 3:20pm UTC](https://discourse.slicer.org/t/setting-up-the-optitrack-motive-plus-slicer-igt-watchdog/20280/4 "2021-10-21T15:20:54Z")

</div>

I found this issue in PlusLib that is still open:

> <https://github.com/PlusToolkit/PlusLib/issues/436>
>
> When a tool is no longer visible by OptiTrack cameras in Motive (in at least v2.…0.2), PLUS still sends transforms of the last known location of the object in the transform (ie. watchdog does not know that the tool is hidden or not currently tracked).

And this PR that I think was meant to address the issue: [Otitrack valid tracking status by hgueziri · Pull Request #699 · PlusToolkit/PlusLib · GitHub](https://github.com/PlusToolkit/PlusLib/pull/699)

I can’t make it out in the video, what version of Plus are you using?

---

<div class="post-metadata">

**Author:** ![pll\_llq](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/pll_llq/32/9408_2.png) [@pll\_llq](https://discourse.slicer.org/u/pll_llq)\
**Post date:** [October 21, 2021, 3:28pm UTC](https://discourse.slicer.org/t/setting-up-the-optitrack-motive-plus-slicer-igt-watchdog/20280/5 "2021-10-21T15:28:41Z")

</div>

Thanks for pointing that out @Sunderlandkyl  
Plus App version is 2.8.0.20191105-Win64 (latest stable)  
I didn’t get from the discussion if it was fixed in 2020?

---

<div class="post-metadata">

**Author:** ![Sunderlandkyl](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/sunderlandkyl/32/79987_2.png) [@Sunderlandkyl](https://discourse.slicer.org/u/Sunderlandkyl)\
**Post date:** [October 21, 2021, 3:30pm UTC](https://discourse.slicer.org/t/setting-up-the-optitrack-motive-plus-slicer-igt-watchdog/20280/6 "2021-10-21T15:30:46Z")

</div>

Yes, the PR changed the transform to be invalid if it was out of view, so it should have the correct behavior in the latest nightly version. Let me know if it works in the nightly.

---

<div class="post-metadata">

**Author:** ![pll\_llq](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/pll_llq/32/9408_2.png) [@pll\_llq](https://discourse.slicer.org/u/pll_llq)\
**Post date:** [October 22, 2021, 1:05pm UTC](https://discourse.slicer.org/t/setting-up-the-optitrack-motive-plus-slicer-igt-watchdog/20280/7 "2021-10-22T13:05:09Z")

</div>

Hi @Sunderlandkyl ,

At first we’ve tried using the latest PLUS with the same config file and it failed to work with Motive. We’ve tried it with versions 2.1.1, 2.1.2, 2.2.0 and 2.3.0.

Previously we were using the combination of PLUS - Motive mentioned in the docs [here](http://perk-software.cs.queensu.ca/plus/doc/nightly/user/DeviceOptiTrack.html) (latest stable with 2.1.1).

I’ve uploaded the log file to [this gist](https://gist.github.com/piiq/deb5607b2ffd9a5c74b4087802d11f55)

After some poking around the logs, source code and the configs I have managed to launch the server by providing the `Calibration` parameter to the `Device` section of the configuration file like this:

```auto
Profile="MotiveProfile.motive"
Calibration="MotiveProfile.motive"

```

I suspect that the Calibration parameter became mandatory in [this commit](https://github.com/PlusToolkit/PlusLib/commit/d49e0cf58ab69a9742548e58c2acaa2326d2c452#diff-b835af89861c2db0a123645070ed5fb24fa9af6f1e2f2213362c0d4d5951525b).

I can’t yet test the setup but I’ll update you on the results.

---

<div class="post-metadata">

**Author:** ![pll\_llq](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/pll_llq/32/9408_2.png) [@pll\_llq](https://discourse.slicer.org/u/pll_llq)\
**Post date:** [October 25, 2021, 12:55pm UTC](https://discourse.slicer.org/t/setting-up-the-optitrack-motive-plus-slicer-igt-watchdog/20280/8 "2021-10-25T12:55:21Z")

</div>

Thanks, the latest nightly 2.9 works
