I'm trying to make a program that behaves similarly to the collaborative Touch-skip function. So far I've set up a skip condition that should stop the movement as soon as the part is recognized (as soon as the force sensor detects a Z force higher than 5N), but from all the runs I've done the robot stops way further down, when the force reaches as high as 80N, triggering the Contact force limit error and Push to Escape.
The code is as follows:
If I try to stop the robot with my hand, as soon as the force goes above 5.1 it detects it. If I place the part where it should be, the robot no longer stops and keeps going until it eventually collides.
Am I doing something wrong? Is there something that I can change or must add to the motion instruction to make it stop earlier?
Is there a way to set a maximum force for the motion instruction, so it doesn't try to mash the part into the table?