- I. Abstract
- II. Introduction
- III. Degrees of Freedom
- IV. Kinematic Diagram and D-H Frame Assignment
- V. D-H Parametric Table
- VI. Homogeneous Transformation Matrix
- VII. Inverse Kinematics
- VIII. Forward and Inverse Kinematics Calculator (Application)
- IX. References
- X. Group Members
The field of robotics is brimming with innovation, and our project delves into the fascinating world of spherical manipulators. This project explores the fascinating world of spherical manipulators, robots with three rotational degrees of freedom. We begin by explaining degrees of freedom in an engaging video, laying the groundwork for understanding the manipulator's abilities.
A clear kinematic diagram depicts the manipulator's structure, which aids in movement analysis. To systematically define the relationship between each joint and link, the Denavit-Hartenberg (D-H) convention is used. A D-H parameter table is then created, which contains a concise representation of the manipulator's key geometric parameters. The project delves deeper into the concept of transformation matrices, a powerful mathematical tool for representing the position and orientation of the end-effector relative to the base frame. A key focus is on solving the inverse kinematics problem, which determines the joint angles required to achieve the desired end-effector position. To bridge the gap between theory and practice, we present the creation of a user-friendly Graphical User Interface (GUI) calculator. This interactive tool allows users to perform forward and inverse kinematics calculations. The calculator calculates the end-effector position simply by inputting joint variables known as forward kinematics. In addition, the calculator allows users to solve the inverse kinematics of the spherical manipulator by specifying the position vertors to obtain the correspong joint variables.
This project provides a thorough examination of spherical manipulator kinematics, combining an educational video explanation with a practical and user-friendly GUI calculator. It aims to improve understanding and control of these versatile robots. So prepare to embark on a journey of discovery! Our project promises to reveal the inner workings of spherical manipulators, paving the way for more precise control and innovative uses.
Spherical Manipulator is a stationary manipulator featuring two revolute joints and one prismatic joint, with an arm attached to a robotic base, and a twisting joint. The spherical manipulator was also known as the Polar Manipulator. It has three mutually perpendicular axes and is well known in the history of robotics, because the first industrial robot, Unimate, was a spherical robot developed in the 1950s. It is also a type of robotic manipulator that operates with a spherical working envelope. Unlike traditional robotic arms that typically move in a planar or linear fashion, spherical manipulators can move in any direction within a three-dimensional space. These robots often consist of multiple joints arranged in a spherical configuration, allowing for movement along multiple axes simultaneously. This configuration enables them to reach points in 3D space with greater flexibility compared to traditional robotic arms.
Knowing that spherical manipulators have an arm which forms a spherical coordinate system. In mathematics, a spherical coordinate system is a three-dimensional coordinate system in which the position of a point is specified by three numbers: the radial distance from a fixed origin, the polar angle measured from a fixed zenith direction, and the azimuth angle of its orthogonal projection on a reference plane that passes through the origin and is orthogonal to the zenith, measured from a fixed reference direction. The radial distance is also known as the radius or radial coordinate. The polar angle is also known as the zenith angle, normal angle, colatitude, or inclination angle.
Spherical Manipulators perform three distinct movements: rotation, elevation, and extension from a stationary base–giving them a spherical/polar working envelope. This configuration allows the robot to move freely and with great flexibility, making it ideal for a variety of jobs. Here is a breakdown of the movements:
- Rotation: The robot can rotate around a vertical axis, which forms the base of the robot. This allows the robot to cover a wide horizontal range around its base.
- Elevation: The robot's arm can move up and down in a vertical plane, enabling it to reach different heights.
- Extension: The robot's arm can extend or retract, moving closer to or farther from the base.
In robotics, Degrees of Freedom (DOF) refer to the number of independent parameters that define the configuration or motion of a robot. Essentially, it indicates how many different ways a robot can move within its environment.The more the degree of freedom, the more flexible and adaptable the robot. A robot with high DOF can make more complex movements and perform a variety of tasks.
- A point in 2D: 2-DOF; in 3D space: 3-DOF
- A rigid body in 3D: 6-DOF
- Planar Manipulator: 3-DOF
- Spatial manipulator: 6-DOF
- Under-Actuated Manipulator
- Spatial Manipulator with less than 6-DOF
- Planar Manipulator with less than 3-DOF
- Ideal manipulator
- Spatial Manipulator with exactly 6-DOF
- Planar Manipulator with exactly 3-DOF
- Redundant manipulator
- Spatial Manipulator with more than 6-DOF
- Planar Manipulator with more than 3-DOF
Formula for the Mobility of Spatial Manipulator | Formula for the Mobility of Planar Manipulator |
---|---|
Joint type | DOF f | Constraints c between two planar rigid bodies | Constraints c between two spatial rigid bodies |
---|---|---|---|
Revolute (R) | 1 | 2 | 5 |
Prismatic (P) | 1 | 2 | 5 |
Helical (H) | 1 | N/A | 5 |
Cylindrical (C) | 2 | N/A | 4 |
Universal (U) | 2 | N/A | 4 |
Spherical (S) | 3 | N/A | 3 |
The illustration above is a simplified diagram of an RRP Spherical Manipulator. It is also shown above the written computation to get the Degrees of Freedom of Spherical Manipulator. Furthermore, a Spherical Manipulator is a robot or manipulator with two rotational joints and one prismatic joint and it is commonly used on industries that involves material handling and welding. Meanwhile, Degrees of Freedom, as discussed in our classes, is the minimum number of independent parameters or variables or coordinates required to fully describe a system. To get the degrees of freedom for spherical manipulator, the Grubler’s Criterion for Mobility or DOF of Spatial Manipulator is used as the spherical manipulator is a type of spatial manipulator. Based on the computations above, it can be concluded that this spherical manipulator is an Under-Actuated Spatial Manipulator with three degrees of freedom.
A Kinematic Diagram is a simplified representation of a mechanism that illustrates the motion of all the components without showing the forces or the physical dimensions that cause the motion. It is an important tool used in mechanical engineering to examine the motion of mechanisms. Typically, the diagram shows the mechanism's joints and links in schematic form. It is also a diagram that shows how the links and joints are connected together when all of the joint variables have a value of 0.
Links are the rigid parts of the mechanical manipulator. A link is defined as a single part that can be a resistant body or a composite of resistant bodies with inflexible connections and relative motion in relation to other machine components. Also, joints are considered links and the values are constant:
- If it is revolute or twisting, links are drawn from the center of the rotation.
- If it is prismatic, either linear or orthogonal, links are drawn from the center of translation.
- If it is from base, links are drawn from the center of gravity.
Joint Variables, are the values that change when the joint moves. It is a connection between two or more links that allows for some motion, or potential motion, between them. Joints are sometimes known as kinematic pairs. A joint variable has a two indicator which is the rotation of a counterclockwise arrow ↺ and the arrow with the flat line at the tail ↦. We use this symbol ↺ for the twisting and revolute joint and we label it as theta (
D-H Notation was introduced by Jacques Denavit and Richard Hartenberg in 1955 in order to standardize the coordinate frames for spatial linkages. D-H notation is used to solve the forward kinematics of a mechanical manipulator. The Frames in a Mechanical Manipulator are used to determine where they are and where they need to go. It also shows the movement of our mechanical manipulator. The frames are positioned at each part of the mechanical manipulator, including the base, joints, and end effector.
- Base (World) Frame
- User Frame
- Tool Frame
D-H Frame Assignment follow this rules in assigning frames in a kinematic diagram:
- Rule 1: The z axis must be the axis of rotation for a revolute/twisting joint, or the direction of translation for a prismatic joint.
- Rule 2: The x axis must be perpendicular both to its own Z axis, and the Z axis of the frame before it.
- Rule 3: Each axis must intersect the z axis of the frame before it. The rules for complying rule 3:
- Rotate the axis until it hits the other.
- Translate the axis until it hits the other.
- Rule 4: All frames must follow the right hand rule.
Following the rules for assigning D-H Frames, we obtained the kinematic diagram with D-H frame assignments shown at the illustration above. First is that the z-axis must be the axis of rotation for a revolute/twisting joint or the direction of translation for a prismatic joint. As observed in the illustration above, all of the blue arrows, which are the z-axis, point in the direction of the axis of rotation for the two revolute joints and the direction of translation for the single prismatic joint. The next rule is the x axis must be perpendicular both to its own z-axis, and the z-axis of the frame before it hence it is seen in the illustration that all the red arrows, an indicator for the x-axis, are all perpendicular to its own z-axis as well as to the z-axis of the frame prior to it. The next rule states that the x axis must be perpendicular to both its own z-axis and the z-axis of the frame preceding it. As can be seen in the illustration, all of the red arrows, which indicate the x-axis, are perpendicular to both its own z-axis and the z-axis of the frame prior to it. The third rule states that each axis must intersect the z-axis of the frame that preceded it. And the rules for complying with this rule are to rotate or translate the axis until it hits the other. Hence, the frame for the prismatic joint were translated into the joint before it so that it will comply with the third rule. The last rule of the D-H frame assignment is that all the frames must follow the right-hand rule. Thus, all the green arrows which indicate the y-axis are drawn with the right-hand rule in mind.
In this section, we are going to discover how to find the Denavit-Hartenberg Parametric Table for robotic arms. This approach is a shortcut to obtaining homogeneous transformation matrices and is frequently used in industrial robot documentation as well as research literature.
- Assign the frames according to the 4 D-H Frame Rules.
- Construct and fill out the D-H Parametric Table.
- Plug the table into the Homogeneous Transformation Matrix form.
- Multiply the matrices together.
Example of D-H Parametric Table
1 | ||||
2 | ||||
3 | ||||
4 |
The Four Parameters in the D-H Parametric are
" |
" |
" |
" |
The figure above is the D-H Parametric table for a Spherical Manipulator. Moreover, a D-H (Denavit-Hartenberg) Parametric Table is a method for organizing the four parameters generated by using the D-H frame assignment rules. These parameters are useful in determining the kinematic equations of a robotic manipulator. The four parameters are:
Homogeneous Transformation Matrix includes both the rotation matrix and the displacement vector in the same matrix. Homogeneous transformation matrices are described as matrices that specify an object's position and orientation. Rotation matrices can be combined using multiplication while Position vectors cannot be added or multiplied. In order to combine position vectors, we shall use the homogeneous transformation matrix denoted as
Homogeneous Transformation Matrix Formula
There are two ways to obtain the Homogeneous Transformation Matrix, by manual computation and using the D-H Parametric Table. We will guide you to a through discussion on how to get the Homogeneous transformation matrix in both wayys.
- To obtain
$H_{1}^{0}$ , concatenate the rotation matrix$R_{1}^{0}$ and the position vector$P_{1}^{0}$ , followed by the augmentation column 0 0 0 1 at the bottom that gives us this matrix presented below.
- Same as the previous matrix, to get the
$H_{2}^{1}$ , concatenate the rotation matrix$R_{2}^{1}$ and position vector$P_{2}^{1}$ , followed by the augmentation column 0 0 0 1 at the bottom that gives us this matrix presented below.
- Lastly, to obtain
$H_{3}^{2}$ , concatenate the rotation matrix$R_{3}^{2}$ and the position vector$P_{3}^{2}$ , followed by the augmentation column 0 0 0 1 at the bottom that gives us this matrix presented below.
- Finally, to determine the homogeneous transformation matrix from frame 0 (the base frame) to frame 3 (the end-effector), multiply all of the transformation matrices
$H_{1}^{0}$ ,$H_{2}^{1}$ , and$H_{3}^{2}$ together. Then we can obtain:
This method of obtaining the Homogeneous Transforamtion Matrix is a much easier way than the last one. This works by plugging in each paramater to this homogeneous transforamtion matrix formula.
Using the D-H parametric table we plugin the values of,
1 | ||||
2 | ||||
3 |
After you have plugin the values of the D-H Parametric Table, we can no obtain
After obtaining
Kinematics is the study of how bodies move in a robotic mechanism, regardless of the forces or torques that cause the motion. It also studies the relationship between a robot's joint coordinates and its spatial organization, which is a fundamental and classical topic in robotics.
Forward Kinematics | Inverse Kinematics |
---|---|
- The given inputs are the joint variables and the output is the position vector. | - The given is the position vector while the output is the joint variables. |
- For identifying the limits of your joint. | - For mimicking the motion of the human arm. |
- For obtaining the trajectory solution. | - For detailed positioning of the end-effector. |
- Easier to solve. | - Difficult to solve. |
Forward kinematics is the geometric problem of finding the position vector and orientation of the end effector using joint variables. It is also a technique for calculating the frames of a robot's links using a configuration and the robot's kinematic structure as input. While Inverse kinematics is utilized to move the mechanical manipulator. Inverse Kinematics is essentially the opposite operation: it calculates configurations to reach the desired workspace coordinate. This process is required for many robotics activities, including moving a tool along a specified path, manipulating items, and viewing situations from the correct perspective.
Kinematic Diagram with D-H Frame of a Spherical Manipulator
Inverse Kinematics using Graphical Method
Top View | Process |
---|---|
To solve for |
|
However, the hypotenuse is changing its length due to |
Front View | Process |
---|---|
|
And now in terms of the front view of the spherical manipulator, the Based on the illustration above, we can derive that, And so, we can now derive for the formula of Finally, to find the joint variable |
Summary of the Step-by-Step Process on How to Find the Inverse Kinematics of a Spherical Manipulator
- On the Top View:
- To solve for
$\theta$ 1, we use the inverse tangent because$Y_{3}^{0}$ and$X_{3}^{0}$ is given. - We can’t use
$a_{2} + a_{3} + d_{3}$ as hypotenuse that’s why we name our hypotenuse as$r_{1}$ .
- To solve for
- On the Front View:
-
$r_{1}$ is the length of the link of the prismatic joint and the end-effector that change if$\theta_{2}$ changes its orientation. - Then for the new side, which is the
$r_{2}$ to get the value of$Z_{3}^{0}$ , so the$r_{2}$ is equal to$Z_{3}^{0} - a_{1}$ . - To solve for
$\theta_{2}$ , we can use again the inverse tangent formula. - Then to solve for
$d_{3}$ , we will use the Pythagorean Theorem.
-
After the manual calculation of the requirements to build the spherical manipulator, the students applies it in a software based manner for better visualization and interpretation of the theories used in building the spherical manipulator. This was done using Python and other libraries that are essential to build the application.
These are the following libraries used for the application:
-
roboticstoolbox-python
This library was used to visually display the spherical manipulator model after forward and Inverse Kinematics Calculation was done. -
numpy
This library was used for mathematical expressions required in modelling the manipulator and express it in Python format. -
tkinter
This is a library included when you install python. This serves as the library for building the Graphical User Interface (GUI) of the application -
openpyxl
This library was used in order to save data in an excel file. This helps the user to track down results or serves as the history of results of the application. -
pyinstaller
This is used to convert the Python files to an Executable file that allows the application to run to other devices without the necessity to installation of libraries and Python. -
auto-py-to-exe
This library is a .py to .exe converter that uses a simple graphical interface and PyInstaller instead of converting the python file in a terminal.
Tkinter is known for its old school way of creating GUI in terms of its aesthetics. Tkinter Designer is a gui creator developed by ParthJadhav to create modern GUI using a design sofware Figma. Tkinter Designer uses the Figma API in reading the design file and generates the codes and resource files (assets) needed for the designed GUI. This still uses codes that is built in with tkinter.
Even though Tkinter Designer generates the code itself, code is still needed to be modify because some resources such as fonts and element alignment are not interpreted in the code properly. Troubleshooting and debugging is necessary.
The design of the Graphical User Interface focuses on a modern approach. The GUI uses the following colors for the design of the GUI.
-
#262626
- Background of the GUI. -
#51FF00
- Accent Color of the GUI. -
#D9D9D9
- Entry Boxes of the GUI. -
#FFFFFF
- Font Color of the GUI. -
#888888
- Buttons of the GUI.
However through out the design process and coding the application, we opted to add additional features such as saving the data to an excel file. Moreover, we also added a checkbutton that decides whether the Data will be recorded or not. Below is the final design of the application's GUI run in python.
Some circumstances such as the font used on the title are modified with what is available with tkinter. Otherwise, the design of the GUI was accomplished based on the user's specification.
Tkinter designer only generates the design of the GUI of application but does not directly bind the functionality of the application. With these, we defined functions and bind it with the buttons present in the GUI.
The reset deletes all the entries present in the all entry boxes. By clicking the reset button, it is expected to do the its function. Here is the demo of the function.
The forward button performs the forward kinematics of function of the calculator. The function of these button is to get entry values from entry boxes of the link lengths and the joint variable and do the computations of forward kinematics to obtain the position vector. It also saves the datas in an excel file when the Record Data Checkbox is checked. Additionally, it launches the roboticstoolbox
that visually shows the orientation of the manipulator based on the data entered and computation.
Just like the forward button, this button is binded to run a function for inverse kinematics calculation. Instead, this get entry values from the link lengths and position vector in order to obtain the values of the joint variables. This also record the data when the Record Data Checkbox is checked. Then it launches roboticstoolbox
to show the orientation of the manipulator.
When obtaining the data, it is nice to runback through the obtained results of from the calculator. Glad to help you with that because this calculator records your data instantaneously in an excel file. You also have an option to turn off this feature by unchecking the checkbox. You can also know if the data is recorded or not through an info message box that pop-up the screen. The video below shows the demonstration of turning off/on the record data checkbox.
As the data from previous session can be recorded, we created a button that is linked to access the excel file where all data are stored. Sheets for forward kinematics data is separated to the inverse kinematics formula. Additionally we add timestamp to better track the desired results.
When entering data, it is inevitable to encounter mistakes. We designed the application to be responsive to these mistake through an error message box showing the error that has occured. Errors are listed below.
- Please fill all required fields - this error will be encountered if the required entry boxes for either forward or inverse are not filled.
- Invalid Input - this error will be encountered when a non float value is detected in on the entry boxes. It will be prompt
- Undefined - this error occurs when
ZeroDivisionError
occured on the inverse kinematics computation. These is due to the Formula #1 of the inverse kinematics computation.
Installation of the application can be done in two ways: Installer, or Portable Software.
- Download and run the SphericalCalcApp_setup.exe file.
- During installation, install it in a directory such as Desktop or Document.
- Run Spherical_GUI.exe and enjoy the app.
- Download the zip file SphericalCalcApp.zip.
- Extract the file.
- Run Spherical_GUI.exe and enjoy the app.
- Polar/Spherical Robots. (2022, May 13). Midwest Engineered Systems. https://www.mwes.com/types-of-industrial-robots/polar-spherical-robots/
- Agnihotri, N. (2023, June 29). Understanding the degree of freedom in robots. Engineers Garage. https://www.engineersgarage.com/understanding-the-degree-of-freedom-in-robots/
- What is a kinematic diagram, and how does it help in understanding the motion of mechanisms? (n.d.). https://www.proprep.com/questions/what-is-a-kinematic-diagram-and-how-does-it-help-in-understanding-the-motion-of-mechanisms
- Lab, D. (2021, September 30). Kinematics in Robotics. https://www.linkedin.com/pulse/kinematics-robotics-decibelslab
- Automaticaddison, A. (2020, August 26). Find Homogeneous Transformation Matrices for a Robotic Arm – Automatic Addison. https://automaticaddison.com/find-homogeneous-transformation-matrices-for-a-robotic-arm/#:~:text=Homogeneous%20transformation%20matrices%20combine%20both,frame%200%20to%20frame%202
- Alojado, Stephen Gabriel S.
- Apostol, Jan Benedict D.
- Cardenas, Sofia Bianca J.
- Catapang, Jamil Darrius S.
- Umali, Ariane Mae D.