Set Robot Base Pose可打印版本 +- RoboDK Forum (//www.sinclairbody.com/forum) +-- Forum: RoboDK (EN) (//www.sinclairbody.com/forum/Forum-RoboDK-EN) +--- Forum: RoboDK API (//www.sinclairbody.com/forum/Forum-RoboDK-API) +--- Thread: Set Robot Base Pose (/Thread-Set-Robot-Base-Pose) |
Set Robot Base Pose-Jeremy.West-04-05-2023 Currently I am trying to set the pose of a robot base with reference to a reference frame. My current code sets the pose of the robot, but I would like the base of the robot to receive the x,y,z,a,b,c pose with reference to my reference frame. I have attemtped the getlink(0) function to call the robot base but receive the error "Exception: Invalid item provided: The item identifier provided is not valid or it does not exist." from robolink import * from robodk import * import numpy as np RDK = Robolink() Origin=RDK.Item('SpiralMeca') #program origin R1.setParent(Origin) R1 = RDK.Item('Mecademic Meca500 R3',ITEM_TYPE_ROBOT) RB1 = R1.getLink(0) # get the base link LED = RDK.Item('LED') #Reference frame pose = Pose(10,0,0,0,0,0) RB1.setPose(pose) RE: Set Robot Base Pose-Jeremy.West-04-05-2023 So I foundthis threadthat shows moving the base is possible only I am having trouble finding my base reference frame name. When I go to create a new base in modify robot I get 2 different robots. How do I find the name of my current robot base reference frame name? RE: Set Robot Base Pose-Sam-04-06-2023 The robot's parent should be the base frame. RB1 = R1.Parent() print(RB1.Name()) Note that R1.getLink(ITEM_TYPE_FRAME) returns the active reference frame, not the base frame (the frame with a green overlay in the tree). |