Calculate reltool offsets between two points
Hello,
what I'm looking for is some sort of an inverse of the Reltool function.
I want to calculate the pose variables needed for a reltool movement to go from a point pA to a point pB.
For example, if I want to move from a point pA, 5 mm along the X coordinate of the tool i can find the next point with:
pB:=RelTool(pA,5,0,0 \Rx:=0,\Ry:=0,\Rz:=0);
But if I have pA and pB, how can I find the offsets? For example:
PERS pose Offset;
Offset:=myFunc(pA, pB); ! Offset=[[5,0,0],[1,0,0,0]]
So I can do:
Kind regards,
Francesco
what I'm looking for is some sort of an inverse of the Reltool function.
I want to calculate the pose variables needed for a reltool movement to go from a point pA to a point pB.
For example, if I want to move from a point pA, 5 mm along the X coordinate of the tool i can find the next point with:
pB:=RelTool(pA,5,0,0 \Rx:=0,\Ry:=0,\Rz:=0);
But if I have pA and pB, how can I find the offsets? For example:
PERS pose Offset;
Offset:=myFunc(pA, pB); ! Offset=[[5,0,0],[1,0,0,0]]
So I can do:
Xrot:=EulerZYX(\X, Offset.rot);
Yrot:=EulerZYX(\Y, Offset.rot);
Zrot:=EulerZYX(\Z, Offset.rot);
Yrot:=EulerZYX(\Y, Offset.rot);
Zrot:=EulerZYX(\Z, Offset.rot);
MoveL pA,vmax,fine,tool0;
MoveL RelTool(pA, Offset.trans.x, Offset.trans.y, Offset.trans.z \Rx:=Xrot \Ry:=Yrot \Rz:=Zrot),vmax,fine,tool0;
Kind regards,
Francesco
0
Categories
- All Categories
- 5.5K RobotStudio
- 391 UpFeed
- 18 Tutorials
- 13 RobotApps
- 297 PowerPacs
- 405 RobotStudio S4
- 1.8K Developer Tools
- 249 ScreenMaker
- 2.7K Robot Controller
- 305 IRC5
- 59 OmniCore
- 7 RCS (Realistic Controller Simulation)
- 3 RobotStudio AR Viewer
- 776 RAPID Programming
- 17 Wizard Easy Programming
- 105 Collaborative Robots
- 4 Job listings