#### Discussion

Back to discussions page
Posts: 11 Apprentice
hello,
i'm using UR5 for spraying(method of learning to generate the script ). I'm using one tcp and i need to make symmetry.
For position i don't have problems (the middle of my object is in the origin so i can easly get the position in the other part ) is it possible to inverse the orientation of tcp (rx,ry,rz) (rotation vector)? any suggestions?

• Posts: 34 Handy
Can you be more precise on the goal of the application?
Do you want to spray two part which are going one in another? Or are they both the same part for the same function but symetric like the a door handle ?
Depending of shape and orientation of your "mirror", you would need to change some axes but maybe not others.
• Posts: 11 Apprentice
this application aims to spray trousers.
i developed a script to move the robot and spray (spray in definite positions) a desired model on one  part of the trousers based on learning method. After accomplishing this part i need to make symmetry to make the model on the other part of the trousers) ( for position i can get the symmetry (*-1) . For tcp orientation when tcp is orientated to the right (example) it should be orientated to the left in the other part

• Posts: 41 Handy
If the rotation is about the an axis of the base frame then new rotation vector of the TCP is:

• Posts: 34 Handy
@noth This is actually a pretty tricky question. The robot arm isn't symmetric so you can't truly mirror to pose. But I think you can accomplish what you want especially if you are mirroring across the x or y axis and have a radial of bilaterally symmetric tool. This is a case that calculating it in quaternions is probably easier than axis-angle.

Caveat: I have not tested these thoroughly and think they only work on a subset of poses.

If you want to mirror across the y-axis you should be able to set the mirror position of r1 to
`p[r1[0], -r1[1], r1[2], -r1[3], r1[4], -r1[5]]`
I'm being a little sloppy as the rotation of the wrist3 won't be mirrored. I also considered
`p[r1[0], -r1[1], r1[2], r1[4], r1[3], r1[5]]`
but I don't think this will handle an axis-angle with all non-zero components. Maybe I'll find some time to get the full correct answer assuming lateral symmetry of the tool.