Method and system for aligning a tool during programming of an industrial robot
11144043 · 2021-10-12
Assignee
Inventors
- Annika Hedlund (Västerås, SE)
- Ivan Lundberg (Västerås, SE)
- Jonathan Styrud (Västerås, SE)
- Martin Nordvall (Västerås, SE)
- Ralph Sjöberg (Västerås, SE)
- Tomas Groth (Västerås, SE)
Cpc classification
B25J9/1694
PERFORMING OPERATIONS; TRANSPORTING
G05B19/423
PHYSICS
International classification
G05B19/04
PHYSICS
Abstract
An industrial robot including a movable robot arm for supporting a tool, and a control unit configured to control the movement of the robot. The control unit is provided with an alignment function for aligning the tool with at least one specified axis. The control unit is configured to supervise the movement of the robot, and to automatically adjust the orientation of the tool so that the tool is aligned with the specified axis upon detecting that the movement of the robot has been stopped and the alignment function is activated. Also disclosed is a method for controlling the industrial robot, and to the use of the method for teaching a robot a path including a plurality of target points by lead-through programming.
Claims
1. A method for controlling an industrial robot having a movable robot arm for supporting a tool, wherein the robot is provided with an alignment function for aligning the tool with at least one specified axis (X.sub.w, Y.sub.w, Z.sub.w), wherein the method comprises: activating the alignment function, detecting movement of the robot, and automatically adjusting the orientation of the tool so that the tool is aligned with the specified axis upon detecting that the movement of the robot has been stopped.
2. The method according to claim 1, wherein the method includes adjusting the orientation (Z.sub.T) of the tool so that the tool is aligned with the specified axis (X.sub.w, Y.sub.w, Z.sub.w) upon detecting that the movement of the robot has been stopped for a defined time period.
3. The method according to claim 1, wherein the tool is kept aligned with the specified axis (X.sub.w, Y.sub.w, Z.sub.w) until detecting that the movement of the robot has been resumed.
4. The method according to claim 1, wherein the method includes releasing the alignment of the tool upon detecting that movement of the robot has been resumed.
5. The method according to claim 1, wherein the method includes: determining the angle (V.sub.x, V.sub.y, V.sub.z) of the tool in relation to the specified axis, and adjusting the orientation of the tool so that the tool is aligned with the specified axis (X.sub.w, Y.sub.w, Z.sub.w) if the angle of the tool in relation to the specified axis is less than a limit value.
6. The method according to claim 4, wherein the limit value is less than 45°, and preferably less than 30°.
7. The method according to claim 1, wherein a plurality of axes (X.sub.w, Y.sub.w, Z.sub.w) have been specified, and the method includes: computing the angles (V.sub.x, V.sub.y, V.sub.z) of the tool in relation to the specified axes, and adjusting the orientation of the tool so that the tool is aligned with the nearest of the specified axes upon detecting that the movement of the robot has been stopped.
8. The method according to claim 7, wherein the tool is aligned with the nearest of the specified axes (X.sub.w, Y.sub.w, Z.sub.w) if the angle (V.sub.x, V.sub.y, V.sub.z) of the tool in relation to the nearest axis is less than a limit value.
9. The method according to claim 1, wherein the method is repeated as long as the alignment function is activated.
10. The method according to claim 1, wherein the robot is taught a path including a plurality of target points, and the method includes: activating the alignment function, manually moving the robot with the tool towards a target point on the path, detecting when the movement of the robot has been stopped, automatically adjusting the orientation of the tool so that the tool is aligned with the specified axis (X.sub.w, Y.sub.w, Z.sub.w) upon detecting that the movement of the robot has been stopped, storing the position and orientation of the robot at the target point, manually moving the robot with the tool towards the next target point on the path, detecting when the movement of the robot has been resumed, releasing the alignment of the tool upon detecting that the movement of the robot has been resumed, and repeating the method until the last target point on the path has been taught.
11. A method of teaching a robot a path including a plurality of target points by lead-through programming, comprising the steps of: activating the alignment function, detecting movement of the robot, and automatically adjusting the orientation of the tool so that the tool is aligned with the specified axis upon detecting that the movement of the robot has been stopped.
12. An industrial robot comprising a movable robot arm for supporting a tool, and a control unit configured to control the movement of the robot, wherein the control unit is provided with an alignment function for aligning the tool with at least one specified axis (X.sub.w, Y.sub.w, Z.sub.w), wherein the control unit is configured to detect the movement of the robot, and to automatically adjust the orientation of the tool so that the tool is aligned with the specified axis upon detecting that the movement of the robot has been stopped and the alignment function is activated.
13. The robot according to claim 12, wherein the control unit is configured to keep the tool aligned with the specified axis until detecting that the movement of the robot has been resumed.
14. The robot according to claim 12, wherein the control unit is configured to release the alignment of the tool upon detecting that the movement of the robot has been resumed.
15. The robot according to claim 12, wherein the control unit is configured to determine the angle (V.sub.x, V.sub.y, V.sub.z) of the tool in relation to the specified axis (X.sub.w, Y.sub.w, Z.sub.w), and to adjust the orientation of the tool so that the tool is aligned with the specified axis if the angle of the tool in relation to the specified axis is less than a limit value.
16. The method according to claim 2, wherein the tool is kept aligned with the specified axis (X.sub.w, Y.sub.w, Z.sub.w) until detecting that the movement of the robot has been resumed.
17. The method according to claim 2, wherein the method includes releasing the alignment of the tool upon detecting that movement of the robot has been resumed.
18. The method according to claim 2, wherein the method includes: determining the angle (V.sub.x, V.sub.y, V.sub.z) of the tool in relation to the specified axis, and adjusting the orientation of the tool so that the tool is aligned with the specified axis (X.sub.w, Y.sub.w, Z.sub.w) if the angle of the tool in relation to the specified axis is less than a limit value.
19. The method according to claim 2, wherein the method is repeated as long as the alignment function is activated.
20. The robot according to claim 13, wherein the control unit is configured to release the alignment of the tool upon detecting that the movement of the robot has been resumed.
Description
BRIEF DESCRIPTION OF THE DRAWINGS
(1) The invention will now be explained more closely by the description of different embodiments of the invention and with reference to the appended figures.
(2)
(3)
(4)
(5)
(6)
DETAILED DESCRIPTION
(7)
(8) The control unit includes software as well as hardware, such as input and output means, a processor unit including one or more central processing units (CPU) for handling main functions of the robot controller, such as executing robot programs. The control unit has a storage medium for storing data, software and program code for controlling the movements of the manipulator.
(9) The movements of the joints are driven by motors. The positions of the joints are controlled by the control unit 2. The joints are equipped with position sensors, for example angle-measuring devices, to provide position feedback to the control unit 2. The position and orientation of the TCP is given by the positions of the joints of the robot, and can be calculated based on the position feedback from the position sensors of the robot.
(10) The robot may have a plurality of defined coordinate systems. A tool coordinate system X.sub.T, Y.sub.T, Z.sub.T is defined for the tool. If the tool is elongated, the Z-axis of the tool coordinate system is usually defined along a length axis of the tool. The origin of the tool coordinate system is located in the TCP. A robot base coordinate system X.sub.B, Y.sub.B, Z.sub.B is usually defined in the stationary base 4 of the robot. The relation between the tool coordinate system and the base coordinate system is known. The position and orientation of the TCP can be determined in the base coordinate system of the robot based on the position feed-back from the position sensors and the known relation between the tool coordinate system and the base coordinate system. A world coordinate system X.sub.W, Y.sub.W, Z.sub.W is defined somewhere in the surroundings of the robot. The Z.sub.W-axis of the world coordinate system is commonly aligned with the vertical line. The relation between the world coordinate system and the base coordinate system is known. Thus, it is possible to determine the position and orientation of the TCP in the world coordinate system. In some applications, the world coordinate system coincides with the base coordinate system of the robot. If the robot is to carry out work on a work object, an object coordinate system is defined for the object.
(11) The control unit 2 is provided with an alignment function for aligning the tool with at least one specified axis, in the following named alignment axis. The alignment axis is, for example, the Z.sub.W-axis of the world coordinate system or one of the axes in the object coordinate system. More than one alignment axes can be specified. For example, the X.sub.W, Y.sub.W, Z.sub.W axes of the world coordinate system can be specified as alignment axes, or one or more of the axes in the object coordinate system can be specified as the alignment axes. Preferably, the axis/axes are specified in advance and stored in the memory storage of the control unit 2. It is also selected which one of the axes in the tool coordinate system to be aligned with the alignment axis. For example, the Z.sub.T-axis of the tool coordinate system can be selected as the axis to be aligned with the alignment axis.
(12) Suitably, the alignment function is implemented as a software module executed by the processing unit of the control unit 2. The alignment function can be activated and deactivated. Suitably, the alignment function is activated during programming of the robot, and is turned off when the programming is finished. The alignment function can be activated manually by a user, for example, by clicking a button, or automatically, for example, when the robot is switched to teach mode or lead-through programming is initiated. In the same way, the alignment function can be deactivated manually or automatically when the teach mode has been switched off.
(13) According to the invention, the control unit 2 is configured to supervise the movement of the robot as long as the alignment function is activated, and to automatically adjust the orientation of the tool so that the tool is aligned with the selected axis when it has been detected that the movement of the robot has been stopped. In one embodiment of the invention, the control unit is configured to align the tool with the alignment axis upon detecting that the movement of the robot has been stopped for a defined time period. Suitably, the time period is a few seconds, for example, the time period is one second. The control unit is configured to keep the tool aligned with the selected axis as long as the robot is standing still. The alignment of the tool is, for example, released upon detecting that the movement of the robot has been resumed. Thus, the tool is not automatically aligned with the alignment axis when the robot is moving.
(14) In one embodiment of the invention, the control unit is configured to determine the angle of the tool in relation to the alignment axis, and to adjust the orientation of the tool so that the selected tool axis is aligned with the alignment axis if the angle between the selected tool axis and the alignment axis is less than a limit value. For example, the alignment is carried out if the angle between the tool and the alignment axis is less than 45°. In another example, the alignment is carried out if the angle between the tool and the alignment axis is less than 30°. Thus, the tool is automatically aligned to the alignment axis if the alignment function is activated, the movement of the robot has been stopped, and the angle between the selected tool axis and the alignment axis is less than the limit value. When a plurality of axes have been specified, the control unit is configured to compute the angles between the selected axis of the tool and the alignment axes, to determine which one of the alignment axes the tool is nearest, and to adjusting the orientation of the tool so that the tool is aligned with the nearest of the alignment axes. Thus, the tool “snaps” to the nearest of the alignment axes when it has been detected that the movement of the robot has been stopped. In one embodiment of the invention, the tool is aligned with the nearest of the alignment axes if the angle of the tool in relation to the nearest axis is less than a limit value.
(15)
(16)
(17) To be able to compute the angles V.sub.x, V.sub.y, V.sub.Z between the axis of the tool and the specified alignment axes, the axis of the tool and the alignment axes must be transformed to the same coordinate system. In this example, it is suitable to transform the axis of the tool to the world coordinate system. This can be done by reverse transformation of the robot kinematic and knowledge of the relation between the robot base coordinate system and the world coordinate system. The position of the tool in the tool coordinate system is given by the TCP. When the axis of the tool and the specified alignment axes have been transformed to the same coordinate system, the angles V.sub.x, V.sub.y, V.sub.Z can be computed with common vector mathematics.
(18)
(19) When it has been detected that the movement of the robot has been stopped, the angle between the tool axis and the alignment axis is computed, and it is determined how to control the movements of the robot so that the angle between the tool axis and the alignment axis becomes zero or at least close to zero. This may include to determine the positions of the robot joints and to generating motor references to the motors of the robot. The orientation of the tool is then adjusted so that the tool is aligned with the alignment axis, block 24. Optionally, the alignment is performed a certain period of time after it has been detected that the movement of the robot has been stopped, and the movement of the robot has not yet been resumed. The alignment of the tool axis is continued until it has been detected that the movement of the robot has been resumed, block 26. Thus, the supervision of the movements of the robot continues when the robot stands still in order to detect when the robot begins to move again. Upon detecting that the robot movement has been resumed, the alignment is ended, block 28. Thus, the operator is allowed to reorient the tool. The supervision of the movements of the robot continues until the next time the movement of the robot is stopped. The method steps 20-28 are repeated as long as the alignment function is activated, block 30.
(20)
(21) The method is started upon activation of the alignment function, and is repeated until the alignment function is deactivated. The movement of the robot is supervised as described above. As long as the robot is moving, there is no alignment of the tool, block 40. When it has been detected that the operator has stopped moving the robot, the method waits for a certain period of time, block 42, and if the robot has not been moved during this period of time, block 44, the angles between the axis of the tool and the alignment axes are determined, block 46. The determined angles are compared to the limit value, block 48. If none of the determined angles is less than the limit value, no tool alignment is performed, block 40. If one of the determined angles is less than the limit value, the tool axis is aligned with this axis, block 50. If more than one of the determined angles is less than the limit value, the tool is aligned with the nearest of the alignment axes.
(22) The alignment of the tool axis is continued until it has been detected that the operator moves the robot again, block 52. Upon detecting that the robot movement has been resumed, the alignment is ended, block 54. The operator can then choose to reorient the tool so that the axis of the tool is closer to any of the other alignment axes. The supervision of the movement of the robot continues until the next time the operator stops moving the robot. The tool is then aligned to the nearest of the alignment axes. Thus, the operator can choose which one of the axes the tool is to be aligned with. The operator can trigger the alignment by stop moving the robot for a certain timer period, and the tool is kept aligned with the alignment axis as long as the robot is not moving. This gives the operator time to record the position and orientation of the tool in the target point. When the target point has been recorded, the operator moves the robot arm with the tool to the next target point to be recorded. The method steps 20-52 are repeated as long as the alignment function is activated