I'm having trouble creating a transformation matrix between two joints of a robot.
Background: I have a robot and these two joints represented by two different coordinate systems, 4 and 5 (4th and 5th joint). If I want to find the transform between the 4th joint's coordinate system and the 5th's is the following an appropriate transformation.
I know the transformation should follow roughly this format.
Rotation about the z-axis of coordinate system 4 by theta4
followed by a rotation about the x-axis of -90 degrees
I'm stuck on figuring out the displacement and how the rotations of theta4 and Rx(-90) affect d4, d5.
So I thought I could represent the translations in another way.
- If I rotated coordinate system 4 of coordinate system 4 by -90 degrees
- After the coordinate system has been rotated -90 about x then the translation vector becomes [Tx, Ty, Tz] = [0, d4, d5].
- Then I rotate about the y-axis by a rotation theta 4.
Would this give me an equivalent translation matrix?
My thought process was I could then append this translation to the rotation matrix in the first portion of my question.
Sum everything up:
R = [Rz Theta4][Rx-90][Unknown Translation]
T = [Rx-90][0,d4,d5][Ry Theta4]
Then combine the two to have a complete transformation matrix from coordinate system 4 to coordinate system 5.

Hint: It's easiest to work in homogeneous coordinates when you have a sequence of transformations that include translations.
When you want to perform an operation which transforms the point $(x,y,z)$ to the new point $(x^{\prime},y^{\prime},z^{\prime})$, write it as $$ \underbrace{\begin{pmatrix}a_{11} & a_{12} & a_{13} & a_{14}\\ a_{21} & a_{22} & a_{23} & a_{24}\\ a_{31} & a_{32} & a_{33} & a_{34}\\ 0 & 0 & 0 & 1 \end{pmatrix}}_{A}\begin{pmatrix}x\\ y\\ z\\ 1 \end{pmatrix}=\begin{pmatrix}x^{\prime}\\ y^{\prime}\\ z^{\prime}\\ 1 \end{pmatrix} $$ where $A$ is the transformation matrix.
For example, $$ \begin{pmatrix}1 & 0 & 0 & T_{x}\\ 0 & 1 & 0 & T_{y}\\ 0 & 0 & 1 & T_{z}\\ 0 & 0 & 0 & 1 \end{pmatrix}\begin{pmatrix}x\\ y\\ z\\ 1 \end{pmatrix}=\begin{pmatrix}x+T_{x}\\ y+T_{y}\\ z+T_{z}\\ 1 \end{pmatrix} $$ translates the point $(x,y,z)$ to the new point $(x + T_x,y + T_y,z + T_z)$.