1. 문제정의
주어진 6자유도계 로봇에 대하여 각 Joint들에 대한 Actuator Value가 주어졌을 때 이 값들에 따라 모터가 작동하게 되면 최종적으로 로봇의 손끝 TCP의 위치 및 방향을 계산한다. 이 과정을 Forward Kinematics라고 하며 이 때에는 각 theta 값들의 방향성이 존재하기 때문에 기구학적으로 각 모터들의 Configuration를 별도로 정의해 줄 필요가 없다.
TCP의 위치 및 방향이 주어졌을 때, 이곳으로 이동하기 위한 각 Actuator value를 계산한다. 이 과정을 Inverse Kinematics라고 하며 각의 Motor들에 대한 방향성이 주어지지 않기 때문에 이에 대한 Configuration을 구한다.
Forward Kinematics를 통하여 TCP의 위치가 정의되었을 때, 혹은 Inverse Kinematics를 통하여 각 Actuator Value를 정의하는 과정에서 필요한 1,3,5번 모터의 Configuration (ishould, ielbow, iwrist)을 계산 한다.
<중 략>
c1=cos(theta1); s1=sin(theta1);
c2=cos(theta2); s2=sin(theta2);
c3=cos(theta3); s3=sin(theta3);
c4=cos(theta4); s4=sin(theta4);
c5=cos(theta5); s5=sin(theta5);
c6=cos(theta6); s6=sin(theta6);
c23=cos(theta2+theta3); s23=sin(theta2+theta3);
T01=[c1,-s1,0,0;s1,c1,0,0;0,0,1,d1;0,0,0,1];
T12=[-s2,-c2,0,a1;0,0,-1,-d2;c2,-s2,0,0;0,0,0,1];
T23=[c3,-s3,0,a2;s3,c3,0,0;0,0,1,0;0,0,0,1];
T34=[c4,-s4,0,a3;0,0,-1,-d4;s4,c4,0,0;0,0,0,1];
T45=[c5,-s5,0,0;0,0,1,0;-s5,-c5,0,0;0,0,0,1];
T56=[c6,-s6,0,0;0,0,-1,0;s6,c6,0,0;0,0,0,1];
T6tcp=[1,0,0,0;0,1,0,0;0,0,1,d6;0,0,0,1;];