I try to solve forward kinematics problem for OpenManipulator X from Robotis by using standard DH convention. The figure and dimension of the robot like this pic
To match frame assignment requirement, I move frame 2 to the left 0.024m. But when I verify the forward kinematics result, the position of end effector is wrong when I move joint 3. For example if I move joint 3 to 90 degree, the position of end effector should be X = 0.024m, Y = 0, and Z = 0.455M. But I got from the software X = 0, Y = 0, and Z = 0.455. It is because of I move the centre of frame 3 to the left. But if I dont move it, the DH frame assignment rule doesn't match.
How to figure out this problem?
Here is my code to find forward kinematics
def std_DH(theta, alpha, a, d): DH = np.array([[np.cos(theta), -np.sin(theta)*np.cos(alpha), np.sin(theta)*np.sin(alpha), a*np.cos(theta)], [np.sin(theta), np.cos(theta)*np.cos(alpha), -np.cos(theta)*np.sin(alpha), a*np.sin(theta)], [0, np.sin(alpha), np.cos(alpha), d], [0, 0, 0, 1]]) return DH
def forward_kinematics(q1, q2, q3, q4): _0T1 = std_DH(q1, np.pi/2, 0, 0.077) _1T2 = std_DH(q2+np.pi/2, 0, 0.128, 0) _2T3 = std_DH(q3-np.pi/2, 0, 0.124, 0) _3T4 = std_DH(q4, 0, 0.126, 0) _0T4 = _0T1.dot(_1T2).dot(_2T3).dot(_3T4) return _0T4
Is there any method to find forward kinematics without using DH convention?