Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
control rz axis seperately
#1
Hi sirs, 
I have another question, is there a python function (command) to control Rz axis separately? 

In my project, I need to turn the tool(gripper) to a certain angle.  I will turn the Rz(every time will be in different angle) after I move the robot to a coordinate (eg (x,y,z, -30, -30, Rz)).   But when I turn the Rz the robot went to other coordinate.  
I tried to move the track-bar of θ6 manually.  Although the rx,ry is changed, the movement is exactly what I want.

if I can't turn Rz without affect the position of the other two axes, can I calculate the angles?  When I move the θ6, the other axes changed, I think it must according to some formula.

thank you
#2
I think you are looking for RelTool(). This sample code should help you fix your issue.

Code:
robot = RDK.Item('',ITEM_TYPE_ROBOT)
pos1 = robot.Pose()
pos2= RelTool(pos1,0,0,0,rz=90)
robot.MoveJ(pose2)
More about the RelTool() method here: https://robodk.com/doc/en/PythonAPI/robo...dk.RelTool
#3
It's a very helpful solution for me, Thank you very much!
  




Users browsing this thread:
1 Guest(s)