# Configuration Design of an Upper Limb Rehabilitation Robot with a Generalized Shoulder Joint
## 5 5R\({}_{a}\)1P Shoulder Joint Mechanism Configuration  
The configuration of 5R\({}_{a}\)1P is shown in Figure 9. In the figure, \(R^{2}_{a3}\), \(R^{2}_{a4}\) and \(R^{2}_{a5}\) are the three active rotation pairs of the main motion, and the three rotation axes are orthogonal to each other. \(R^{2}_{a1}\), \(R^{2}_{a2}\) are two active rotation pairs, and the rotation axes are orthogonal to each other, where \(R^{2}_{2}\), \(R^{2^{\prime}}_{2}\), \(R^{2^{\prime\prime}}_{2}\), \(R^{2^{\prime\prime}}_{2}\) and \(R^{2}_{a2}\) constitute a parallelogram structure, which translates a rotating pair in the human body \(U_{SC}\) to the back of the human body, which is convenient for installation and control in engineering. \(P^{2}_{6}\) is the passive moving pair, which is directly connected to the upper limb. A fixed coordinate system \(O^{2}_{b}-x^{2}_{b}y^{2}_{b}z^{2}_{b}\) is established on the SC \(U_{SC}\), a local fixed coordinate system \(O^{2}_{w}-x^{2}_{w}y^{2}_{w}z^{2}_{w}\) is established on the frame, and a connected coordinate system \(O^{2}_{i}-x^{2}_{i}y^{2}_{i}z^{2}_{i}\)\((i=1,2,\ldots,6)\) is established for each movement pair of the generalized shoulder joint mechanism, where the \(R^{2}_{a4}\), \(R^{2}_{a5}\) and \(R^{2}_{a6}\) motion axes intersect the machine at the axis of the arm shoulder joint. In the initial configuration of the mechanical arm, the coordinate origin \(O^{2}_{i}\)\((i=4,5,6)\) coincides with the origin \(O^{2}_{s}\) of the GH joint coordinate system. The origin \(O^{2}_{w}\) of the gantry coordinate system coincides with the movement centre \(O^{2}_{1}\) of the rotating pair \(R^{2}_{a1}\), as shown in Figure 9. The origin \(O^{2}_{w}\) of the frame local fixed coordinate system is \(\left(X^{2}_{w},Y^{2}_{w},Z^{2}_{w}\right)\) in the human body fixed coordinate system \(O^{2}_{b}-x^{2}_{b}y^{2}_{b}z^{2}_{b}\)According to the pose transformation matrix, the pose transformation matrix \({}^{b}T_{6}^{2}\) of the end coordinate system \(O_{6}^{2}-x_{6}^{2}y_{6}^{2}z_{6}^{2}\) of the mechanical arm branch chain relative to the fixed coordinate system \(O_{b}^{2}-x_{6}^{2}y_{6}^{2}z_{6}^{2}\) of the human body is:  
\[ \begin{split}{}^{b}T_{6}^{2}&={}^{b}T_{w}^{2}{}^{w}T_ {1}^{21}T_{2}^{22}T_{3}^{24}T_{5}^{25}T_{6}^{2}\\ &=\left(\begin{array}{cccc}n_{6x}^{2}&s_{6x}^{2}&a_{6x}^{2}&X_ {6}^{2}\\ n_{6y}^{2}&s_{6y}^{2}&a_{6y}^{2}&Y_{6}^{2}\\ n_{6z}^{2}&s_{6z}^{2}&a_{6z}^{2}&Z_{6}^{2}\\ 0&0&0&1\end{array}\right)\\ \end{split}  \tag{14}\]  
For the branch chain of the human shoulder joint equivalent mechanism, the end coordinate system of the mechanism can also be obtained, and the pose transformation matrix \({}^{b}T_{g}^{2}\) of \(O_{g}^{2}-x_{g}^{2}y_{g}^{2}z_{g}^{2}\) relative to the fixed coordinate system of the human body \(O_{b}^{2}-x_{b}^{2}y_{b}^{2}z_{b}^{2}\) is:  
\[{}^{b}T_{g}^{2}={}^{b}T_{s}^{2}T_{g}^{2}=\left( \begin{array}{cccc}n_{gx}^{2} &s_{gx}^{2}&a_{gx}^{2}&X_{g}^{2}\\ n_{gy}^{2}&s_{gy}^{2}&a_{gy}^{2}&Y_{g}^{2}\\ n_{gz}^{2}&s_{gz}^{2}&a_{gz}^{2}&Z_{g}^{2}\\ 0&0&0&1\end{array} \right)\\ \tag{15}\]  
where \({}^{b}T_{s}^{2}\) is the pose transformation matrix between adjacent coordinate systems, and \({}^{b}T_{g}^{2}\) is the pose transformation matrix of the new coordinate system \(O_{g}^{2}-x_{g}^{2}y_{g}^{2}z_{g}^{2}\) after the end coordinate system of the mechanism is rotated in space. \(n_{g}^{2}=\left[n_{gx}^{2},n_{gy}^{2},n_{gz}^{2}\right]^{T}\), \(s_{g}^{2}=\left[s_{gx}^{2},s_{gy}^{2},s_{gz}^{2}\right]^{T}\) and \(a_{g}^{2}=\left[a_{gx}^{2},a_{gy}^{2},a_{gz}^{2}\right]^{T}\) are the direction vectors of each axis end  
Figure 9: \(5R_{4}1P\) mechanism and upper limb closed chain. coordinate system \(a_{g}^{2}=\left[a_{gx}^{2},a_{gy}^{2},a_{gz}^{2}\right]^{T}\) in \(O_{b}^{2}-x_{b}^{2}y_{b}^{2}z_{b}^{2}\), and \(P_{g}^{2}=\left[X_{g}^{2},Y_{g}^{2},Z_{g}^{2}\right]^{T}\) is the position vector of the origin \(O_{g}^{2}\). Simultaneous to Equations (14) and (15), the kinematics constraint equation of the man-machine closed chain can be established as:  
\[\left\{