# Is there any code based approach for commanding a controlled motor halt in UR10e?

**URL:** <https://forum.universal-robots.com/t/is-there-any-code-based-approach-for-commanding-a-controlled-motor-halt-in-ur10e/32098>\
**Category:** Technical Questions\
**Created:** [January 12, 2024, 11:11am UTC](https://forum.universal-robots.com/t/is-there-any-code-based-approach-for-commanding-a-controlled-motor-halt-in-ur10e/32098 "2024-01-12T11:11:32Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![dheenadhayalan.r](https://avatars.discourse-cdn.com/v4/letter/d/48db29/32.png) [@dheenadhayalan.r](https://forum.universal-robots.com/u/dheenadhayalan.r)\
**Post date:** [January 12, 2024, 11:11am UTC](https://forum.universal-robots.com/t/is-there-any-code-based-approach-for-commanding-a-controlled-motor-halt-in-ur10e/32098/1 "2024-01-12T11:11:32Z")

</div>

Hello everyone,

I’m currently working with the UR10e robot and externally controlling it in velocity mode using ROS2 controller manager (Humble). I’m wondering if there’s a way to command a smooth halt through the code, essentially rapidly stopping each motor by implementing quick stop deceleration.

Ideally, I’m looking for a behavior similar to a safeguard stop, but without pausing the externalcontrol.urcap and without being triggered by a physical switch. Any insights or suggestions on achieving this would be greatly appreciated!

Thanks in advance.

---

<div class="post-metadata">

**Author:** ![tom.dutton](https://avatars.discourse-cdn.com/v4/letter/t/9d8465/32.png) [@tom.dutton](https://forum.universal-robots.com/u/tom.dutton)\
**Post date:** [January 12, 2024, 12:55pm UTC](https://forum.universal-robots.com/t/is-there-any-code-based-approach-for-commanding-a-controlled-motor-halt-in-ur10e/32098/2 "2024-01-12T12:55:55Z")

</div>

Would it be possible to use a stopj or stopl command via a UR script? The script manual should cover using those commands.
