# Keep TCP orientation when using object frame in vision system

**URL:** <https://tech-community.robotics.abb.com/t/keep-tcp-orientation-when-using-object-frame-in-vision-system/9663>\
**Category:** RAPID Programming\
**Tags:** object-frame, orientation, integrated-vision, rapid, tool\
**Created:** [August 21, 2020, 7:09am UTC](https://tech-community.robotics.abb.com/t/keep-tcp-orientation-when-using-object-frame-in-vision-system/9663 "2020-08-21T07:09:13Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![ceppo](https://avatars.discourse-cdn.com/v4/letter/c/c2a13f/32.png) [@ceppo](https://tech-community.robotics.abb.com/u/ceppo)\
**Post date:** [August 21, 2020, 7:09am UTC](https://tech-community.robotics.abb.com/t/keep-tcp-orientation-when-using-object-frame-in-vision-system/9663/1 "2020-08-21T07:09:13Z")

</div>

Hello,  
I’m using integrated vision to locate and pick up parts. Location of part is given to robot by moving the object frame like this: wCam.oframe:=camTarget.cframe; and then robot is moved to that position with Offs command: MoveL pPickObject,vFast,fine,tGripper\WObj:=wCam;

The problem is that as the parts I’m picking are round there is no need to rotate the tool when picking them up so how can I make it so that the tool won’t rotate? I want to keep it in specific angle to minimize change of collision.

---

<div class="post-metadata">

**Author:** ![lemster68](https://dub1.discourse-cdn.com/flex005/user_avatar/tech-community.robotics.abb.com/lemster68/32/1945_2.png) [@lemster68](https://tech-community.robotics.abb.com/u/lemster68)\
**Post date:** [August 21, 2020, 12:06pm UTC](https://tech-community.robotics.abb.com/t/keep-tcp-orientation-when-using-object-frame-in-vision-system/9663/2 "2020-08-21T12:06:05Z")

</div>

Break it down to just the pos: wCam.oframe.trans:=camtarget.oframe.trans;

---

<div class="post-metadata">

**Author:** ![ceppo](https://avatars.discourse-cdn.com/v4/letter/c/c2a13f/32.png) [@ceppo](https://tech-community.robotics.abb.com/u/ceppo)\
**Post date:** [August 21, 2020, 12:58pm UTC](https://tech-community.robotics.abb.com/t/keep-tcp-orientation-when-using-object-frame-in-vision-system/9663/3 "2020-08-21T12:58:44Z")

</div>

That gives error: Reference to unknown component oframe.

---

<div class="post-metadata">

**Author:** ![lemster68](https://dub1.discourse-cdn.com/flex005/user_avatar/tech-community.robotics.abb.com/lemster68/32/1945_2.png) [@lemster68](https://tech-community.robotics.abb.com/u/lemster68)\
**Post date:** [August 21, 2020, 1:03pm UTC](https://tech-community.robotics.abb.com/t/keep-tcp-orientation-when-using-object-frame-in-vision-system/9663/4 "2020-08-21T13:03:58Z")

</div>

In your post was this:  
wCam.oframe:=camTarget.cframe;

I assumed that camtarget.cframe; was a typo for .oframe, was I wrong? or is your data .cframe?

---

<div class="post-metadata">

**Author:** ![ceppo](https://avatars.discourse-cdn.com/v4/letter/c/c2a13f/32.png) [@ceppo](https://tech-community.robotics.abb.com/u/ceppo)\
**Post date:** [August 22, 2020, 8:25am UTC](https://tech-community.robotics.abb.com/t/keep-tcp-orientation-when-using-object-frame-in-vision-system/9663/5 "2020-08-22T08:25:39Z")

</div>

Yes it is cframe there is no typo.

---

<div class="post-metadata">

**Author:** ![ceppo](https://avatars.discourse-cdn.com/v4/letter/c/c2a13f/32.png) [@ceppo](https://tech-community.robotics.abb.com/u/ceppo)\
**Post date:** [August 24, 2020, 8:00am UTC](https://tech-community.robotics.abb.com/t/keep-tcp-orientation-when-using-object-frame-in-vision-system/9663/6 "2020-08-24T08:00:38Z")

</div>

I found the solution to this myself and it was quite a simple one. There was a possibility to send an constant angle to robot from integrated vision so that solved the problem.

---

<div class="post-metadata">

**Author:** ![slim1978](https://avatars.discourse-cdn.com/v4/letter/s/ba9def/32.png) [@slim1978](https://tech-community.robotics.abb.com/u/slim1978)\
**Post date:** [September 27, 2022, 1:16pm UTC](https://tech-community.robotics.abb.com/t/keep-tcp-orientation-when-using-object-frame-in-vision-system/9663/7 "2022-09-27T13:16:12Z")

</div>

We have the exact opposite going on ours is picking up detail the same every time out of a feeder bowl that isn’t very consistant and we would like to also pick up a detail at 180 degrees for faster pick ups
