# Move until tool contact in UR Script

**URL:** <https://forum.universal-robots.com/t/move-until-tool-contact-in-ur-script/13046>\
**Category:** URScript\
**Created:** [March 18, 2021, 3:51pm UTC](https://forum.universal-robots.com/t/move-until-tool-contact-in-ur-script/13046 "2021-03-18T15:51:14Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![anon62124634](https://avatars.discourse-cdn.com/v4/letter/a/7ea924/32.png) [@anon62124634](https://forum.universal-robots.com/u/anon62124634)\
**Post date:** [March 18, 2021, 3:51pm UTC](https://forum.universal-robots.com/t/move-until-tool-contact-in-ur-script/13046/1 "2021-03-18T15:51:14Z")

</div>

When programming UR e-series from the pendant, there is a convenient command option for the `move` command, that adds “until tool contact” condition. Is there a corresponding counterpart in UR Script, or should one implement it oneself similarly as is done on page 63 of the [manual](https://s3-eu-west-1.amazonaws.com/ur-support-site/105198/scriptManual_SW5.10.pdf) - section **14.1.49 tool\_contact\_examples**?

---

<div class="post-metadata">

**Author:** ![sko](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.universal-robots.com/sko/32/573_2.png) [@sko](https://forum.universal-robots.com/u/sko)\
**Post date:** [March 19, 2021, 4:21pm UTC](https://forum.universal-robots.com/t/move-until-tool-contact-in-ur-script/13046/2 "2021-03-19T16:21:27Z")

</div>

Hi Marek,

no, there is no direct correspondent Script function available.

To get an insight in the script equivalent, you can program the functionality in Polyscope and save the Program. Then take a look at the generated script code, which you can use as a basis for your approach.

Often do Poylscope Features require quite a bit of Script code in the background to contain all the needed functionality. The Manual you have linked is the correct place to go in cases like yours.

sko

---

<div class="post-metadata">

**Author:** ![anon62124634](https://avatars.discourse-cdn.com/v4/letter/a/7ea924/32.png) [@anon62124634](https://forum.universal-robots.com/u/anon62124634)\
**Post date:** [June 21, 2021, 1:58pm UTC](https://forum.universal-robots.com/t/move-until-tool-contact-in-ur-script/13046/3 "2021-06-21T13:58:01Z")

</div>

I forgot to reply, sorry. I looked into the generated script and indeed it is lengthy, anyway, we solved the problem by programming the functionality in urscript by hand.

---

<div class="post-metadata">

**Author:** ![system](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.universal-robots.com/system/32/1_2.png) [@system](https://forum.universal-robots.com/u/system)\
**Post date:** [June 25, 2021, 7:04am UTC](https://forum.universal-robots.com/t/move-until-tool-contact-in-ur-script/13046/4 "2021-06-25T07:04:38Z")

</div>

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.
