You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've been working on something and I need my robot to move in a new plane, but .set_csys wont allow me that. The csys in wich robot moves stays the same (base csys). Here is the code:
def robot_setup():
TCP_Robot = "192......." # IP address of the robot I will not showe it here but this works
TCP_PORT = 30002
# Connecting to the robot
robot = urx.Robot(TCP_Robot)
robot.set_tcp((0, 0, 0.120, 0.0, 0.0, 0.0)) # Position of the Tool Center Point relative to the end of the robot (x,y,z,Rx,Ry,Rz)
# (in m and radians)
robot.set_payload(1, (0, 0, 0.1)) # Weight of the tool and position of its center of gravity (in kg and mm)
Set the coordinate system
p0=m3d.Vector([0,0.500,0.500])
px=m3d.Vector([-0.100,0.500,0.500])
py=m3d.Vector([0,0.500,0.600])
#new_csys=m3d.Transform.new_from_xyp(px-p0,py-p0,p0)
new_csys=m3d.Transform.new_from_xyp(px,py,p0)
print(new_csys)
robot.set_csys=(new_csys)
# Movement characteristics
acc = 0.4 # Maximum joint acceleration
vel = 0.4 # Maximum joint speed
return robot,acc,vel
I've been working on something and I need my robot to move in a new plane, but .set_csys wont allow me that. The csys in wich robot moves stays the same (base csys). Here is the code:
import urx
import math3d as m3d
import numpy as np
pi=np.pi
def main():
Robot,acc,vel=robot_setup()
send_commands_to_robot(Robot,acc,vel)
def robot_setup():
TCP_Robot = "192......." # IP address of the robot I will not showe it here but this works
Set the coordinate system
def send_commands_to_robot(Robot,acc,vel):
if name=="main":
main()
The text was updated successfully, but these errors were encountered: