05-10-2023, 11:21 AM
Hello! I am working with a station where the information about the robot speeds and moves comes from an XML, and I am having problems when setting the speed to the robot. I am using the RoboDK API for python so when I run a program on python, it is reflected in the RoboDK Screen through the robolink connection.
The XML file gives me :
<TCPSpeed>800</TCPSpeed>
<PTPPercent>80</PTPPercent>
<AccelerationTime>500</AccelerationTime>
TCPSpeed is the linear movement controlling the TCP in mm/s.
PTPPercent is the movement Point to Point (moving the joints) which is in % of the joint max. speed which is (180deg/s).
AccelerationTime is the linear acceleration time in mm/s.
I need to change the robot's speed inside every movement when calling it, and I have made this code (attached image). Later in the main program when I want to use the function I have defined I use
movesreal.picktarget(T) # (movesreal is the class)
I've tried to use all the possibilities, using things like: setSpeed(800, 144, 500, accel_joints=- 1). And changing the arguments, erasing the accel_joints, using the setSpeedJoints...
But I can't manage to solve it, because it does not correlate with the real speed movements, and I don't know if I am using bad the speed functions or whatever, because the XML speeds are correct, and if I put really low/high speeds, the robot moves slow/fast, but not with the XML speeds.
Any help is appreciated, thank you all! Have a nice day.
Miguel
The XML file gives me :
<TCPSpeed>800</TCPSpeed>
<PTPPercent>80</PTPPercent>
<AccelerationTime>500</AccelerationTime>
TCPSpeed is the linear movement controlling the TCP in mm/s.
PTPPercent is the movement Point to Point (moving the joints) which is in % of the joint max. speed which is (180deg/s).
AccelerationTime is the linear acceleration time in mm/s.
I need to change the robot's speed inside every movement when calling it, and I have made this code (attached image). Later in the main program when I want to use the function I have defined I use
movesreal.picktarget(T) # (movesreal is the class)
I've tried to use all the possibilities, using things like: setSpeed(800, 144, 500, accel_joints=- 1). And changing the arguments, erasing the accel_joints, using the setSpeedJoints...
But I can't manage to solve it, because it does not correlate with the real speed movements, and I don't know if I am using bad the speed functions or whatever, because the XML speeds are correct, and if I put really low/high speeds, the robot moves slow/fast, but not with the XML speeds.
Any help is appreciated, thank you all! Have a nice day.
Miguel