Universal Robots Forum

Calculate orientation angle -> RPY versus Rotational vector


I have a question regarding the calculation of angles.
when i use the command ‘get_actual_tcp_pose’ , six elements get displayed. so i want to know what are the angles of last three Rotational elements in (Degrees). how to calculate those?

those are Rx,Ry,Rz in Radians. You can convert them to deg by multiplying with (180/Pi).
Degree values are also displayed in the advanced Move Tab when selecting one of the joint position values

1 Like

If you want to be super lazy, there’s a URScript method r2d(angle) which takes an angle in radians and returns the angle in degrees (there’s also the reverse method, d2r(angle))


thanks for the replies.

There is one .urp file i am attaching the link

So if i use a command get_actual_tcp_pose() . the values will be displayed as rotational vector (rv).
Am i correct?
so then i need to convert those radians into degree.

The command get_actual_tcp_pose() returns a 6-dimensional vector:

[X, Y, Z, Rx, Ry, Rz]

The first 3 components are the Cartesian coordinates of the TCP in 3D space, measured in m, so converting them to degrees is nonsensical (though you may wish to convert them to mm).

The 4th, 5th and 6th elements are that of the rotation, returned in radians. These are what you want to convert to degrees.

I’m not sure what the attached URP file converts the rotations into, but it’s definitely not degrees

1 Like