08-29-2023, 08:27 AM
Code:
ins_event_attach = {'Type': INS_TYPE_EVENT, 'Behavior': EVENT_ATTACH,'ToolPtr':str(RDK.Item("Tool1").item)}
program.setParam("Add", ins_event_attach )
Hello,
with the Code above, i was trying to attach an object to my tool "debugGreifer"
When I debug the instruction in the GUI, I get a message in the lower left corner that "no object is close enough to Tool1".
The coordinate origin is in the lower right corner of the object. The contact point of the object surface and the tool is less than 1-2mm away from each other. The distance between the contact point and the coordinate origin of the object is more than 1m.
The reference frame in which the object is located is subordinate to the reference frame of the robot base.
I have tried it with different distances up to the collision. always the same.
If I modify the instruction manually, I have to change "Measure distanve as: " from "Default" to "TCP vs Object Position" or "TCP vs Object Surface" and select the corresponding object manually. Then it works.
How do I do this now if I want to generate an instruction automatically?
best regards
Jonas