# Problem when trying to use Collision Error Handling

**URL:** <https://tech-community.robotics.abb.com/t/problem-when-trying-to-use-collision-error-handling/11734>\
**Category:** IRC5\
**Created:** [December 11, 2024, 11:30am UTC](https://tech-community.robotics.abb.com/t/problem-when-trying-to-use-collision-error-handling/11734 "2024-12-11T11:30:34Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Simmu](https://avatars.discourse-cdn.com/v4/letter/s/e0b2c6/32.png) [@Simmu](https://tech-community.robotics.abb.com/u/Simmu)\
**Post date:** [December 11, 2024, 11:30am UTC](https://tech-community.robotics.abb.com/t/problem-when-trying-to-use-collision-error-handling/11734/1 "2024-12-11T11:30:34Z")

</div>

I have tried to add an error handler for a procedure where a robot picks up items from a conveyor. Since the height of the object is unknown I am using a SearchL instruction, searching for a signal from my Vacuum sensor on the gripper tool.

However, sometimes there is not enough vacuum (often due to debris left on part), then I don’t get any signal from the Vacuum Sensor and the robot has a collision. If this happens I would like to catch this in the error handler but I can’t get it to work.

This is an example code:

PROC PickPart()

MoveL Offs(pPickPart,0,0,250),v1000,z50,tGripper1\WObj:=wConveyor;  
MoveL Offs(pPickPart,0,0,50),v1000,z20,tGripper1\WObj:=wConveyor;  
VacuumOn;  
SearchL\Stop,diGripperSensor1,pSearchHit,pPickPart,v10,tGripper1\WObj:=wConveyor;  
MoveL Offs(pPickPart,0,0,50),v100,z10,tGripper1\WObj:=wConveyor;  
MoveL Offs(pPickPart,0,0,250),v1000,z50,tGripper1\WObj:=wConveyor;  
MoveL pFromPick,v2000,z50,tDefaultTool;

ERROR  
IF ERRNO=ERR\_COLL\_STOP THEN  
SkipWarn;  
TRYNEXT;  
ENDIF

ENDPROC

The problem is the Program Pointer never reaches the Error handler. The robot retracts from the collision and stops with the Motion Supervision error message. When I restart it continues with the SearchL instruction and has another collision.

What am I doing wrong? I have done the same thing in several robots before and gotten it to work. I am using RobotWare 6.15.08. The CollisionErrorHandler is enabled in the system parameters.

Thanks in advance!

---

<div class="post-metadata">

**Author:** ![matti](https://avatars.discourse-cdn.com/v4/letter/m/e480ec/32.png) [@matti](https://tech-community.robotics.abb.com/u/matti)\
**Post date:** [January 27, 2025, 12:11pm UTC](https://tech-community.robotics.abb.com/t/problem-when-trying-to-use-collision-error-handling/11734/2 "2025-01-27T12:11:48Z")

</div>

Hallo,  
have you tried to trigger it manually within a normal movement (MoveL, MoveJ)?  
Maybe it is not working with SearchL. I encountered a similar problem when using Arc-Movements - it was not working there at all and a new version of RW was required.
