Controller, control method, and control program
The controller with a gripping mechanism and force sensor on a robot calculates direction vectors to accurately determine the approach position and posture of workpieces, addressing the challenge of precise fitting, thus improving assembly efficiency and reducing errors.
Patent Information
- Application Number
- JP2023021071
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2023-02-14
- Publication Date
- 2024-08-26
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Existing methods do not adequately address how to determine the appropriate position and posture of workpieces when fitting two workpieces together using a robot, particularly in the initial approach position before a searching operation.
A controller is used with a robot that includes a gripping mechanism and a force sensor to move a workpiece along the surfaces of a fitting hole while pressing it against the inner surfaces, calculating direction vectors based on movement information to determine the approach position, angle, and origin for fitting, minimizing errors due to elastic deformation and improving accuracy through interpolation and statistical methods.
The approach position is accurately determined, reducing errors and optimizing the fitting process, thereby enhancing the efficiency and precision of workpiece assembly.
Smart Images

Figure 2024115396000001
Abstract
Description
[Technical field]
[0001] The present invention relates to a controller, a control method, and a control program. [Background technology]
[0002] In the field of industrial automation, robots are used for various purposes, one of which is fitting two workpieces together.
[0003] For example, JP 2018-199172 A (Patent Document 1) discloses a method for efficiently inserting an inserting object into an inserted object without performing a probing motion. More specifically, the control method discloses a control method for bringing an inserting object into contact with an inserted object at a portion different from the contact portion in the first contact motion by performing force control in a second contact motion in which a component of a target force in a second direction perpendicular to the first direction is set to a value greater than 0. [Prior art documents] [Patent documents]
[0004] [Patent Document 1] JP 2018-199172 A Summary of the Invention [Problem to be solved by the invention]
[0005] For example, when fitting two workpieces using a robot, it is necessary to determine the appropriate position and posture of the workpieces through a probing operation. To start the probing operation, it is necessary to place one workpiece near the fitting hole provided in the other workpiece. It is necessary to appropriately determine the initial position and initial posture of the workpiece before starting the probing operation (hereinafter also referred to as the "approach position").
[0006] The above-mentioned prior art documents do not disclose a method for appropriately determining the approach position.
[0007] The present invention provides a method for appropriately determining at least a portion of an approach position when fitting two workpieces together. [Means for solving the problem]
[0008] According to an embodiment, a controller is provided for inserting a first workpiece into a fitting hole of a second workpiece using a robot. The robot has a gripping mechanism for gripping the first workpiece and a force sensor. The controller causes the robot to execute an operation of moving the first workpiece along a first surface, which is one of the inner surfaces of the fitting hole, while pressing the first workpiece against the first surface, and an operation of moving the first workpiece along a second surface, which is an inner surface adjacent to the first surface of the fitting hole, while pressing the first workpiece against a second surface. The controller executes a process of calculating a first direction vector corresponding to the first surface based on information on the movement of the first workpiece along the first surface, a process of calculating a second direction vector corresponding to the second surface based on information on the movement of the first workpiece along the second surface, and a process of determining at least one of a position and a posture of the first workpiece for fitting the first workpiece into the fitting hole based on at least one of the first direction vector and the second direction vector.
[0009] According to this configuration, the first direction vector or the second direction vector can be calculated based on information acquired by moving the first workpiece while pressing it against the first surface or the second surface of the fitting hole of the second workpiece. At least a part of information required for the approach position can be determined based on at least one of the calculated first direction vector and second direction vector.
[0010] The controller may determine the angle of the fitting hole based on at least one of the first direction vector and the second direction vector. With this configuration, the angle of the fitting hole can be determined based on a result of actually moving the first workpiece.
[0011] The controller may determine an origin that serves as a position reference for the fitting hole based on the first direction vector and the second direction vector. With this configuration, the origin that serves as a position reference for the fitting hole can be determined based on a result of actually moving the first workpiece.
[0012] The process of calculating the first direction vector may be based on the coordinates of a first position measurement point that is a predetermined distance before the position where the reaction force exceeding a predetermined value is received during the movement along the first surface of the first workpiece. The process of calculating the second direction vector may be based on the coordinates of a second position measurement point that is a predetermined distance before the position where the reaction force exceeding a predetermined value is received during the movement along the second surface of the first workpiece. With this configuration, the first direction vector and the second direction vector can be calculated using the widest possible section that defines the first surface and the second surface.
[0013] The controller may cause the robot to execute an operation of reducing a pressing force of the first workpiece against the first surface at the first position measurement point, and an operation of reducing a pressing force of the first workpiece against the second surface at the second position measurement point. With this configuration, it is possible to reduce errors due to elastic deformation that may occur in the robot.
[0014] The controller may cause the robot to execute an operation of stopping the pressing of the first workpiece against the first surface at the first position measurement point and moving the first workpiece away from the first surface so that a reaction force generated by the first workpiece contacting the first surface is equal to or less than a predetermined value, and an operation of stopping the pressing of the first workpiece against the second surface at the second position measurement point and moving the first workpiece away from the second surface so that a reaction force generated by the first workpiece contacting the second surface is equal to or less than a predetermined value. This configuration makes it possible to reduce errors due to elastic deformation that may occur in the robot.
[0015] The process of calculating the first direction vector may include a process of interpolating based on the coordinates of a plurality of position measurement points acquired during the movement along the first surface of the first workpiece. The process of calculating the second direction vector may include a process of interpolating based on the coordinates of a plurality of position measurement points acquired during the movement along the second surface of the first workpiece. This configuration can improve the calculation accuracy of the first direction vector and the second direction vector.
[0016] According to another embodiment, there is provided a control method for inserting a first workpiece into a fitting hole of a second workpiece using a robot. The control method includes the steps of: moving the first workpiece along a first surface, which is one of the inner surfaces of the fitting hole, while the first workpiece is pressed against the first surface; calculating a first direction vector corresponding to the first surface based on information of the movement along the first surface of the first workpiece; moving the first workpiece along the second surface, while the first workpiece is pressed against a second surface, which is an inner surface adjacent to the first surface of the fitting hole,; calculating a second direction vector corresponding to the second surface based on information of the movement along the second surface of the first workpiece; and determining at least one of a position and a posture of the first workpiece for fitting the first workpiece into the fitting hole based on at least one of the first direction vector and the second direction vector.
[0017] According to yet another embodiment, there is provided a control program for inserting a first workpiece into a fitting hole of a second workpiece using a robot. The control program causes a computer to execute the steps of: giving a command to the robot to move the first workpiece along a first surface, which is one of the inner surfaces of the fitting hole, while the first workpiece is pressed against a first surface, calculating a first direction vector corresponding to the first surface based on information on the movement of the first workpiece along the first surface, giving a command to the robot to move the first workpiece along the second surface, while the first workpiece is pressed against a second surface, which is an inner surface adjacent to the first surface of the fitting hole, calculating a second direction vector corresponding to the second surface based on information on the movement of the first workpiece along the second surface, and determining at least one of a position and a posture of the first workpiece for fitting the first workpiece into the fitting hole, based on at least one of the first direction vector and the second direction vector. Effect of the Invention
[0018] According to the present invention, at least a part of the approach position when fitting two workpieces together can be appropriately determined. [Brief description of the drawings]
[0019] [Figure 1] 1A to 1C are schematic diagrams showing an example of an assembly operation of the robot system according to the present embodiment. [Diagram 2] FIG. 11 is a schematic diagram showing an example of TCP settings in the robot system according to the present embodiment. [Diagram 3] FIG. 11 is a schematic diagram showing an example of TCP settings in the robot system according to the present embodiment. [Figure 4] FIG. 1 is a schematic diagram showing an example of a hardware configuration of a robot system according to an embodiment of the present invention. [Diagram 5] 10 is a flowchart showing a processing procedure for calibration processing of an approach position according to the present embodiment. [Figure 6] 11A and 11B are diagrams for explaining a positional relationship determined by the calibration process of the approach position according to the embodiment; [Figure 7] 11A to 11C are diagrams for explaining the processing contents of the Rx / Ry / Z calibration processing according to the present embodiment. [Figure 8] 11 is a diagram for explaining an example of setting TCP and measurement points in the Rx / Ry / Z calibration process according to the present embodiment. FIG. [Figure 9] 11 is a diagram for explaining an example of setting measurement points in the Rx / Ry / Z calibration process according to the present embodiment. FIG. [Figure 10] 13A and 13B are diagrams for illustrating the processing content when the distance from the receiving surface (design value) is used as an evaluation index in the Rx / Ry / Z calibration processing according to the present embodiment. [Figure 11] FIG. 13 is a schematic diagram showing an example of a control system for implementing force control about the Zt axis according to the present embodiment. [Figure 12] 13A to 13C are diagrams for illustrating processing contents when a Z position correction amount is used as an evaluation index in the Rx / Ry / Z calibration processing according to the present embodiment. [Figure 13] FIG. 13 shows an example of a processing result when the Z position correction amount is used as an evaluation index in the Rx / Ry / Z calibration processing according to the present embodiment. [Figure 14] 13 is a flowchart showing a more detailed procedure of the Rx / Ry / Z calibration process according to the present embodiment. [Figure 15] 11 is a diagram for explaining an example of operation when determining a Z calibration value of the Rx / Ry / Z calibration process according to the present embodiment. FIG. [Figure 16] 11 is a diagram for explaining an example of an operation when determining an Ry calibration value in the Rx / Ry / Z calibration process according to the present embodiment. FIG. [Figure 17] 11A to 11C are diagrams for explaining changes over time in the Z position correction amount in the Rx / Ry / Z calibration process according to the present embodiment. [Figure 18] 13 is a flowchart showing a processing procedure of a slow search included in the Rx / Ry / Z calibration processing according to the present embodiment. [Figure 19] 13 is a flowchart showing a processing procedure of a slow search included in the Rx / Ry / Z calibration processing according to the present embodiment. [Figure 20]It is a diagram for explaining the process of determining the Z calibration value in the Rx / Ry / Z calibration process according to this embodiment. [Figure 21] It is a diagram for explaining the process of determining the first direction vector in the X / Y / Rz calibration process according to this embodiment. [Figure 22] It is a diagram for explaining the process of determining the second direction vector in the X / Y / Rz calibration process according to this embodiment. [Figure 23] It is a diagram for explaining the process of determining the XtYt origin in the X / Y / Rz calibration process according to this embodiment. [Figure 24] It is a flowchart showing a more detailed processing procedure of the X / Y / Rz calibration process according to this embodiment. [Diagram 25] It is a flowchart showing a more detailed processing procedure of the X / Y / Rz calibration process according to this embodiment. [Figure 26] It is a diagram for explaining an example of a position measurement method for calculating the direction vector in the X / Y / Rz calibration process according to this embodiment. [Figure 27] It is a diagram for explaining a modified example of the calculation process of the direction vector in the X / Y / Rz calibration process according to this embodiment.
Embodiments for Carrying Out the Invention
[0020] Embodiments of the present invention will be described in detail with reference to the drawings. For the same or corresponding parts in the drawings, the same reference numerals are attached and the description thereof will not be repeated.
[0021] <A. Application Example> First, an example of a scenario to which the present invention is applied will be described.
[0022] FIG. 1 is a schematic diagram showing an example of the assembly operation of a robot system 1 according to this embodiment. Referring to FIG. 1, the robot system 1 includes an articulated robot (hereinafter, also simply referred to as "robot 10") and a controller 100 that controls the robot 10.
[0023] The robot system 1 fits the first workpiece 50 and the second workpiece 60 together. The first workpiece 50 and the second workpiece 60 are made of a rigid material. The second workpiece 60 has a fitting hole 62, and the first workpiece 50 is inserted into the fitting hole 62. That is, the robot system 1 inserts the first workpiece 50 into the fitting hole 62 of the second workpiece 60.
[0024] In this specification, "fitting" includes both the state in which another workpiece is inserted into a hole (fitting hole) having an arbitrary cross-sectional shape, and the action for achieving the inserted state. Note that when the action of inserting another workpiece into a hole (fitting hole) is intended, the expression "fitting action" is sometimes used. The fitting hole may have any cross-sectional shape, but in the following description, a rectangular cross-sectional shape is used as an example.
[0025] In the fitting operation, the second work 60 is usually placed at a predetermined position. The robot 10, while holding the first work 50, moves the first work 50 to an initial position and posture (approach position). Then, the probing operation and the inserting operation are performed.
[0026] In this specification, the "approach position" refers to the initial position and initial posture of the first work 50 (mating work) inserted into the mating hole 62 of the second work 60 (mated work). For convenience of explanation, it is described as the "approach position", but typically includes a total of six elements, namely, the position (three elements) and the posture (three elements).
[0027] In this specification, "gripping" includes any action for a robot or the like to hold a workpiece. Fig. 1 shows an example of holding a workpiece using multiple claws, but a method using magnetic force (e.g., electromagnets), a method using pressure difference (negative pressure), or any other method may be adopted.
[0028] 1 includes a base 11 and a plurality of movable parts 12, 13, 14, 15, 16, and 17. The movable parts 12, 13, 14, 15, 16, and 17 correspond to joints of the robot 10. Each of the movable parts 12, 13, 14, 15, 16, and 17 drives a link constituting the robot 10 along a rotation axis as shown in FIG.
[0029] A gripping mechanism 20 is provided at the tip of the arm of the robot 10. The gripping mechanism 20 has two claws 21, 22 for gripping a first workpiece 50. The first workpiece 50 is gripped and released by adjusting the distance between the claws 21 and 22. In the calibration process of the approach position described below, the first workpiece 50 is maintained in a state gripped by the gripping mechanism 20 of the robot 10.
[0030] A force sensor 18 is provided between the arm tip of the robot 10 and the gripping mechanism 20. The force sensor 18 outputs detection results including the magnitude and direction of the load acting on the gripping mechanism 20, etc. The detection results of the force sensor 18 may be output as vector values.
[0031] Thus, the robot 10 has a gripping mechanism 20 and a force sensor 18 in addition to multiple joints.
[0032] An information processing device 200 may be connected to the controller 100. The information processing device 200 is, for example, a general-purpose computer. The information processing device 200 presents information from the controller 100 to a user, and gives user instructions to the controller 100 in accordance with user operations.
[0033] In the example shown in Fig. 1, a robot coordinate system 2 is defined with the robot 10 as the reference. Also, a tool coordinate system 30 is defined with the arm tip as the reference. The tool coordinate system 30 includes an Xt axis and a Yt axis parallel to the surface of the arm tip, and a Zt axis perpendicular to the surface. Typically, the tool coordinate system 30 is defined so that the Xt axis and the Yt axis are perpendicular to each other, but the tool coordinate system 30 may be defined in any way as long as the Xt axis and the Yt axis are not parallel to each other.
[0034] A reference point for controlling the position and posture of the robot 10 is called a TCP (tool center point). As an example, the TCP is defined in the tool coordinate system 30. The TCP includes six elements: position (X, Y, Z) and posture (Rx, Ry, Rz). The position (X, Y, Z) is the position on the Xt, Yt, and Zt axes of the tool coordinate system 30. The posture (Rx, Ry, Rz) is the angle around the Xt, Yt, and Zt axes of the tool coordinate system 30.
[0035] The controller 100 controls the robot 10 (the angles of the movable parts 12, 13, 14, 15, 16, and 17) so that the TCP is in a target position and posture.
[0036] The controller 100 can calculate the position and posture of the TCP by correcting the position and posture of the tip of the arm of the robot 10 with an offset vector (position and posture). The TCP may be set at any position depending on the contents of the fitting operation. For example, the TCP may be set at a corner of the surface (hereinafter also referred to as the "tip surface 52") of the first work 50 that is inserted into the second work 60, or the center of the tip surface 52 of the first work 50 may be set as the TCP. In the example shown in FIG. 1, the TCP is set at the corner of the tip surface 52 of the first work 50.
[0037] 2 and 3 are schematic diagrams showing examples of TCP settings in the robot system 1 according to the present embodiment.
[0038] FIG. 2 shows, as an example, a setting example of TCP suitable for the operation of searching for the corner of the fitting hole 62 of the second workpiece 60. That is, by setting the corner of the front end surface 52 of the first workpiece 50 as TCP, based on the set TCP, the position and posture where the corner of the first workpiece 50 and the corner of the fitting hole 62 of the second workpiece 60 come into contact can be searched.
[0039] FIG. 3 shows, as an example, a setting example of TCP suitable for searching for the position of the fitting hole 62 of the second workpiece 60. That is, by setting the center of the front end surface 52 of the first workpiece 50 as TCP, based on the set TCP, the fitting hole 62 of the second workpiece 60 into which the first workpiece 50 should be inserted can be searched. Also, the contact between the first workpiece 50 and the second workpiece 60 can be searched.
[0040] <B. Hardware Configuration Example of Robot System 1> FIG. 4 is a schematic diagram showing a hardware configuration example of the robot system 1 according to the present embodiment. Referring to FIG. 4, the robot 10 includes motors 32, 33, 34, 35, 36, 37 respectively associated with the movable parts 12, 13, 14, 15, 16, 17, and drivers 42, 43, 44, 45, 46, 47 for driving the motors 32, 33, 34, 35, 36, 37 respectively.
[0041] The robot 10 includes a motor 38 for driving the claw parts 21, 22, and a driver 48 for driving the motor 38.
[0042] The drivers 42, 43, 44, 45, 46, 47, 48, the force sensor 18, and the teaching pendant 26 are electrically connected to the controller 100 via the interface 40.
[0043] The teaching pendant 26 performs teaching of the robot 10 and the like according to user operations. The teaching pendant 26 may be configured to be detachable from the robot 10.
[0044] The controller 100 is a type of computer, and includes, as its main hardware components, a processor 102, a memory 104, an interface 106, and a storage 110. These components are electrically connected via a bus 108.
[0045] The processor 102 is composed of, for example, a central processing unit (CPU) and a micro-processing unit (MPU). The memory 104 is composed of, for example, a volatile storage device such as a dynamic random access memory (DRAM) and a static random access memory (SRAM). The storage 110 is composed of a non-volatile storage device such as a solid state disk (SSD) and a flash memory. The storage 110 stores a system program 112 for implementing basic processing and a control program 114 for controlling the robot 10. The control program 114 includes computer-readable instructions for controlling the robot 10. The processor 102 reads out the system program 112 and the control program 114 stored in the storage 110, expands them in the memory 104, and executes them to implement processing for controlling the robot 10, as described below.
[0046] The interface 106 is responsible for exchanging signals and / or data between the controller 100 and the robot 10. In the robot system 1, commands for controlling the drivers 42, 43, 44, 45, 46, 47, and 48 are transmitted from the controller 100 to the robot 10, and detection results by the force sensor 18 are transmitted from the robot 10 to the controller 100.
[0047] FIG. 4 shows a configuration example in which the necessary processes are provided by the processor 102 executing a program. However, some or all of these provided processes may be implemented using a dedicated hardware circuit (for example, an ASIC (Application Specific Integrated Circuit), an FPGA (Field-Programmable Gate Array), etc.).
[0048] FIG. 4 shows an example in which the controller 100 is configured independently of the robot 10. However, some or all of the functions and processes provided by the controller 100 may be incorporated into the robot 10. The robot 10 may incorporate the controller 100. The controller 100 may be a controller dedicated to controlling the robot, or may be a general-purpose PLC (Programmable Logic Controller) or a personal computer.
[0049] Some or all of the functions and processes provided by the controller 100 may be realized using computing resources on a network called a so-called cloud.
[0050] As described above, the robot system 1 according to the present embodiment may be implemented in any configuration.
[0051] <C. Approach Position Calibration Process> Next, the approach position calibration process according to the present embodiment will be described.
[0052] FIG. 5 is a flowchart showing the processing procedure of the approach position calibration process according to the present embodiment. Each step shown in FIG. 5 may be realized by the processor 102 of the controller 100 executing the system program 112 and / or the control program 114.
[0053] Referring to FIG. 5, the controller 100 executes Rx / Ry / Z calibration processing (step S1). The Rx / Ry / Z calibration processing determines the angle Rx around the Xt axis, the angle Ry around the Yt axis, and the position Z on the Zt axis for defining the approach position.
[0054] Subsequently, the controller 100 executes X / Y / Rz calibration processing (step S2). The X / Y / Rz calibration processing determines the position X on the Xt axis, the position Y on the Yt axis, and the angle Rz around the Zt axis for defining the approach position.
[0055] Based on the information determined in the Rx / Ry / Z calibration processing and the information determined in the X / Y / Rz calibration processing, the controller 100 determines the position and orientation corresponding to the corner of the fitting hole 62 of the second workpiece 60 (hereinafter, also referred to as the "receiving workpiece corner position") (step S3). The controller 100 calculates the approach position by offsetting the predetermined clearances ΔXtc, ΔYtc, ΔZtc from the receiving workpiece corner position (step S4). Then, the process ends.
[0056] FIG. 6 is a diagram for explaining the positional relationship determined by the approach position calibration processing according to the present embodiment. Referring to FIG. 6, when the receiving workpiece corner position is (Xtl, Ytl, Ztl, Rxl, Ryl, Rzl), the approach position can be calculated as (Xtl + ΔXtc, Ytl + ΔYtc, Ztl + ΔZtc, Rxl, Ryl, Rzl). That is, the approach position can be determined by translating the receiving workpiece corner position parallel to each axis by the clearances ΔXtc, ΔYtc, ΔZtc.
[0057] <D.Rx / Ry / Z calibration processing> Next, the processing content of the Rx / Ry / Z calibration processing (step S1) in FIG. 5 will be described.
[0058] (d1: Basic concept) In the Rx / Ry / Z calibration process, angles Rx and Ry at which the first workpiece 50 and the second workpiece 60 are in a surface-matching state are searched for. A "surface-matching state" refers to a state in which one surface and the other surface are parallel. In the robot system 1 shown in FIG. 1, the surface-matching state is a state in which the tip surface 52 of the first workpiece 50 and the surface of the second workpiece 60 that receives the first workpiece 50 (hereinafter also referred to as the "receiving surface 64") are parallel.
[0059] In the Rx / Ry / Z calibration process, as an example, the surface conformity state is searched for using position information about the Zt axis.
[0060] Fig. 7 is a diagram for explaining the process contents of the Rx / Ry / Z calibration process according to the present embodiment. With reference to Fig. 7, the controller 100 performs force control for the Zt axis. More specifically, the controller 100 causes the robot to execute an operation of pressing the first workpiece 50 gripped by the gripping mechanism 20 against the second workpiece 60 with a predetermined force.
[0061] In the force control, the controller 100 adjusts the command for the position Z so that the force Fz generated in the Zt axis direction coincides with the target value. The controller 100 performs position control for the position X on the Xt axis and the position Y on the Yt axis. In this way, the controller 100 adjusts the position X and the position Y so that they coincide with their respective target values (target positions). The force control and the position control are performed based on an arbitrarily set TCP.
[0062] In a state where the above-mentioned force control and position control are being performed, when the angle Rx about the Xt axis or the angle Ry about the Yt axis is changed, the posture of the first workpiece 50 with respect to the second workpiece 60 changes. That is, the controller 100 causes the robot to execute an operation to change the posture of the first workpiece 50 with respect to the second workpiece 60 while pressing the first workpiece 50 against the second workpiece 60. At this time, a state where at least a part of the tip surface 52 of the first workpiece 50 is in contact with the receiving surface 64 of the second workpiece 60 is maintained by the force control about the Zt axis.
[0063] Based on an evaluation index related to the distance between the first workpiece 50 and the second workpiece 60, the controller 100 searches for a posture of the first workpiece 50 in which the tip surface 52 (first surface) of the first workpiece 50 that comes into contact with the second workpiece 60 and the receiving surface 64 (second surface) of the second workpiece 60 that comes into contact with the first workpiece 50 are parallel (i.e., surface tracing).
[0064] The evaluation index may be calculated based on a measurement point set on the leading end surface 52 of the first workpiece 50. The measurement point is set in association with the first workpiece 50. In this case, the evaluation index reflects position information of the measurement point on the Zt axis.
[0065] In the surface conforming state, the position Z (robot coordinate system 2) of the measurement point is at its minimum value. As shown in the graph of Fig. 7, when the amount of rotation of the angle Rx or the angle Ry is increased, the position Z is at its minimum value in the surface conforming state. As the first workpiece 50 moves away from the surface conforming state, the first workpiece 50 tilts, and the corner of the tip surface 52 of the first workpiece 50 comes into contact with the second workpiece 60, so that the position Z increases.
[0066] That is, since the position Z describes a V-shaped locus with respect to the angle Rx or the angle Ry, it can be determined that the angle Rx or the angle Ry at which the position Z is at an extreme value (peak) or a minimum value is in the surface conformance state. In this manner, the controller 100 collects the change in the position Z while changing the angle Rx or the angle Ry. The controller 100 determines the attitude (angle Rx or angle Ry) at which the position Z is at an extreme value as the surface conformance state.
[0067] Based on the position Z in the surface conformation state, the position on the Zt axis of the measurement point in the surface conformation state can also be determined.
[0068] (d2: TCP and measurement point configuration example) Next, a setting example of the TCP and the measurement points in the Rx / Ry / Z calibration process in FIG. 5 will be described.
[0069] The controller 100 controls the robot 10 based on the position and posture of the TCP. That is, the TCP is used to calculate target values (position and posture) for controlling the robot 10. The TCP and the measurement point may be coincident with each other, or the measurement point may be set at a position different from the TCP.
[0070] In order to search for the surface conforming state, it is advantageous for the amount of change in the position Z of the measurement point to be large in response to a change in the attitude (angle Rx or angle Ry) of the first workpiece 50. The amount of change in the Zt axis direction of the first workpiece 50 depends on the position of the TCP and the width (length) of the first workpiece 50 in the Xt axis direction and the width (length) of the first workpiece 50 in the Yt axis direction.
[0071] FIG. 8 is a diagram for explaining an example of setting the TCP and measurement points in the Rx / Ry / Z calibration process according to the present embodiment.
[0072] 8A shows a setting example in which the TCP and the measurement point coincide with each other. Referring to FIG. 8A, the TCP (and the measurement point) is set at the center of the tip surface 52 of the first workpiece 50. When the tip surface 52 of the first workpiece 50 is a rectangle, the TCP may be set at the intersection of a line connecting the midpoints of two opposing sides and a line connecting the midpoints of other two opposing sides, the intersection of two diagonals, the center of gravity of the rectangle, or the like. Alternatively, the TCP and the measurement point may be set at the intersection of the Zt axis of the tool coordinate system 30 and the tip surface 52 of the first workpiece 50.
[0073] Fig. 8B shows an example in which the measurement point is set at a position different from the TCP. In the setting example shown in Fig. 8B, the TCP is set at the center of the tip end surface 52 of the first workpiece 50. In this case, the measurement point may be set at the position of the force sensor 18.
[0074] A reference point (TCP) for controlling the position and posture of the robot 10 may be set inside the tip surface 52 of the first workpiece 50. Furthermore, the TCP may be set at the center of the tip surface 52 of the first workpiece 50, or at the intersection of the tip surface 52 and the Zt axis.
[0075] The measurement point of the first work 50 may be set between the two outermost sides (opposite sides) of the tip surface 52 that contacts the second work 60 in a tilted state when the attitude (angle Rx or angle Ry) of the first work 50 is changed. One of the outermost sides is determined by tilting the first work 50 in one direction relative to the second work 60, and the other outermost side is determined by tilting the first work 50 in the opposite direction relative to the second work 60.
[0076] FIG. 9 is a diagram for explaining an example of setting measurement points in the Rx / Ry / Z calibration process according to the present embodiment.
[0077] 9, for example, when the angle Rx is changed to tilt the first workpiece 50, the outermost sides 56, 57 become two sides parallel to the Xt axis and are defined by two positions on the Yt axis. In this case, the measurement point may be at any position on the Xt axis as long as it is between the two positions (settable range 58) corresponding to the outermost sides 56, 57 on the Yt axis. In other words, the measurement point may be set at a position where the first workpiece 50 is not present, as long as it is between the two outermost sides on the Yt axis.
[0078] On the other hand, when the angle Ry is changed to tilt the first workpiece 50, the outermost sides become two sides parallel to the Yt axis and are defined by two positions on the Xt axis. In this case, the measurement point may be at any position on the Yt axis as long as it exists between the two positions corresponding to the outermost sides on the Xt axis. In other words, the measurement point may be set at a position where the first workpiece 50 does not exist, as long as it is between the two outermost sides on the Xt axis.
[0079] Furthermore, the position of the measurement point on the Zt axis may be anywhere. Therefore, the measurement point may be set at a position other than the position on the front end surface 52 of the first workpiece 50.
[0080] In this way, the measurement point may be set so that when the measurement point is projected onto a plane including the tip surface 52, the projection position is within the range defined by the two outermost sides of the tip surface 52 that contact the receiving surface 64 during the operation of changing the posture of the first workpiece 50.
[0081] By setting the measurement points at such positions, it is possible to easily detect extreme values in the process of searching for the surface conformity state.
[0082] (d3: Evaluation index) Next, the evaluation index for searching the surface profile state will be described.
[0083] In FIG. 5 described above, the position Z of the measurement point is exemplified as the evaluation index for searching the surface conformation state, but the present invention is not limited to this and other evaluation indexes can be used.
[0084] For example, when the receiving surface 64 of the second workpiece 60 is not parallel to any axis of the robot coordinate system 2 (global coordinate system), calculation of the distance from the receiving surface 64 may become complicated. For this reason, a receiving surface (design value) 66 may be set for the second workpiece 60, and the distance from the receiving surface (design value) 66 (distance on the Zt axis) may be used as the evaluation index.
[0085] 10 is a diagram for explaining the process content when the distance from the receiving surface (design value) 66 is used as the evaluation index in the Rx / Ry / Z calibration process according to the present embodiment. Controller 100 performs force control about the Zt axis.
[0086] 10, the distance from the receiving surface (design value) 66 with respect to the angle Rx or the angle Ry describes a V-shaped locus, so that the angle Rx or the angle Ry at which the distance from the receiving surface (design value) 66 is at an extreme value can be determined to be in the surface conformance state. Based on the position Z in the surface conformance state, the position on the Zt axis in the surface conformance state can also be determined.
[0087] In this way, the evaluation index may be the distance from the receiving surface (design value) 66 preset on the second workpiece 60 to a measurement point set in the tool coordinate system 30 based on the arm tip of the robot 10. In other words, the evaluation index may be the distance between the receiving surface 64 of the second workpiece 60 and a measurement point set on the robot 10 in a direction perpendicular to the receiving surface 64.
[0088] When the position Z of the measurement point shown in Fig. 7 and the distance from the receiving surface (design value) 66 shown in Fig. 10 are used as the evaluation index, the surface conformance state is searched from the position information about the Zt axis, so that it is possible to reduce the influence caused by the fluctuation factors of the force control about the Zt axis. Also, when the distance from the receiving surface (design value) 66 (distance on the Zt axis) is used as the evaluation index, the value determined as the surface conformance state can be used as the approach position as it is.
[0089] Furthermore, when the distance from the receiving surface (design value) 66 is evaluated at a position on the Zt axis of the tool coordinate system 30, the position change of the TCP can be evaluated as it is at the position on the Zt axis without being converted to the robot coordinate system 2, so even if the placement orientation of the second workpiece 60 changes, the algorithm for searching the surface tracing state described above can be used as is.
[0090] As another evaluation index for searching the surface conformity state, information regarding the force control about the Zt axis may be used.
[0091] Fig. 11 is a schematic diagram showing an example of a control system for realizing force control about the Zt axis according to the present embodiment. Referring to Fig. 11, the controller 100 has a control system for pressing the first workpiece 50 against the second workpiece 60 with a predetermined force.
[0092] More specifically, the controller 100 includes a force sensor filter 120, a conversion processing module 122, a difference calculator 124, a sampler 126, a force control calculation module 128, a limiter 130, a holder 132, and an adder 134.
[0093] The force sensor filter 120 filters and outputs the force information from the force sensor 18. Filtering reduces noise components contained in the force information.
[0094] The conversion processing module 122 calculates a force and moment acting on a preset TCP based on the force sense information from the force sensor filter 120. The conversion processing module 122 outputs a force Fz acting in the Zt axis direction on the TCP.
[0095] The difference calculator 124 calculates a deviation that is the difference between the force Fz output from the conversion processing module 122 and the target value (target force) of the pressing force.
[0096] The sampler 126 samples the deviation output from the difference calculator 124 and inputs it to a force control calculation module 128 .
[0097] The force control calculation module 128 calculates an output value corresponding to the input deviation by PID calculation. The calculated output value corresponds to a command given to the robot 10 regarding the position on the Zt axis.
[0098] The limiter 130 limits the value output from the force control calculation module 128 to within predetermined upper and lower limit values before outputting the value.
[0099] The force control calculation module 128 calculates an output value in response to the discrete input of values from the sampler 126. Therefore, the value output from the limiter 130 is also discrete. Even if the output from the limiter 130 stops, the holder 132 holds and continues to output the value input immediately before. The value output from the holder 132 becomes the Z position correction amount (ΔZref).
[0100] The adder 134 adds the Z position correction amount (ΔZref) to the target position / behavior (Xref, Yref, Zref, Rxref, Ryref, Rzref) of the TCP to calculate a final command. That is, the adder 134 outputs a corrected target position / command (Xref, Yref, Zref+ΔZref, Rxref, Ryref, Rzref).
[0101] The Z position correction amount shown in Fig. 11 may be the evaluation index. That is, the evaluation index may be a correction amount for a command given to the robot 10 by the control system to press the first workpiece 50 against the second workpiece 60 with a predetermined force.
[0102] Fig. 12 is a diagram for explaining the process contents when the Z position correction amount is used as an evaluation index in the Rx / Ry / Z calibration process according to the present embodiment. With reference to Fig. 12, the Z position correction amount draws a V-shaped locus with respect to the angle Rx or the angle Ry, so it can be determined that the angle Rx or the angle Ry at which the Z position correction amount is an extreme value is in the surface conformation state. Based on the position Z in the surface conformation state, the position Z on the Zt axis in the surface conformation state can also be determined.
[0103] As shown in Fig. 12, if the first workpiece 50 is not in a surface-copying state, the first workpiece 50 will be inclined with respect to the receiving surface 64 of the second workpiece 60. The position of the tip surface 52 on the Zt axis changes depending on the inclination angle θ. Therefore, the Z position correction amount depends on the inclination angle θ.
[0104] If the width (in the Xt axis direction or the Yt axis direction) of the tip surface 52 of the first workpiece 50 is W, the Z position correction amount can be expressed as follows.
[0105] Z position correction amount = -(W / 2)sin(|Δθ|)cos(|Δθ|) In this way, the Z position correction amount depends on the square of the trigonometric function for the angle θ. Therefore, by using the Z position correction amount, the surface conformity state can be searched for with higher sensitivity than when position information about the Zt axis is used.
[0106] Fig. 13 is a diagram showing an example of a processing result when the Z position correction amount is used as an evaluation index in the Rx / Ry / Z calibration processing according to this embodiment. Fig. 13 shows a measurement example when the angle Rx around the Xt axis (or the angle Ry around the Yt axis) is changed. Fig. 13 shows an example in which processing is started from a state tilted by about -2[deg] from the surface conforming state. The rotation speed of the angle is -0.2[deg / s], and the target value of the force Fz is -1[N].
[0107] FIG. 13 shows the change over time in the Z position correction amount, the moment around the axis, the force Fz generated in the Zt axis direction, and the amount of rotation of the angle.
[0108] In Fig. 13, the angle at which the Z position correction amount is at its extreme value can be determined to be the surface conformance state. Although the force Fz generated in the Zt axis direction changes significantly before and after the surface conformance state, it contains relatively large noise, making it difficult to accurately detect the angle at which the surface conformance state occurs. In contrast, the Z position correction amount is only slightly affected by the change in force Fz, even if the force Fz changes significantly.
[0109] Since the change in the moment around the axis becomes small before and after the surface conformation state, it is difficult to accurately detect the angle at which the surface conformation state is reached based on the moment around the axis. In contrast, the Z position correction amount shows a relatively sharp peak in the surface conformation state, so the angle at which the surface conformation state is reached can be detected more accurately.
[0110] By using the Z position correction amount, it is not necessary to accurately calculate the position of the TCP on the Zt axis, and therefore the algorithm for searching for the surface conformation state can be simplified.
[0111] In addition, when a cascade control system in which a force control loop for the Zt axis is provided outside the position control loop is adopted instead of the control system shown in FIG. 11, a position correction amount, which is an operation amount of the force control, may be used as an evaluation index for searching the surface conformance state.
[0112] Regardless of which of the above-mentioned evaluation indices is used, the evaluation index takes an extreme value (a local maximum or minimum value, or a maximum or minimum value) in the surface profiling state. Therefore, the controller 100 determines the position and posture where the evaluation index takes an extreme value as the position and posture of the first workpiece 50 where the tip surface 52 (first surface) and the receiving surface 64 (second surface) of the first workpiece 50 are parallel (i.e., surface profiling).
[0113] (d4: Processing procedure) Next, the Rx / Ry / Z calibration process will be described in more detail.
[0114] 14 is a flowchart showing a more detailed procedure of the Rx / Ry / Z calibration process according to the present embodiment. Each step shown in FIG. 14 may be realized by the processor 102 of the controller 100 executing the system program 112 and / or the control program 114.
[0115] In the Rx / Ry / Z calibration process, a set of a process for determining an angle at which the surface conformation state is achieved by changing the angle Rx about the Xt axis (hereinafter also referred to as the "Rx calibration value") and a process for determining an angle at which the surface conformation state is achieved by changing the angle Ry about the Yt axis (hereinafter also referred to as the "Ry calibration value") is repeated a predetermined number of calibrations.
[0116] It is assumed that an initial position and initial posture (hereinafter also referred to as a "rough teaching position") at which the calibration process of the approach position is started are set in advance. The rough teaching position may be set by the user operating the teaching pendant 26, or may be calculated in advance based on information on the size and placement position of the second workpiece 60.
[0117] Referring to FIG. 14, the controller 100 initializes the current number of calibrations to 0 (step S101).
[0118] The controller 100 issues a command to the robot 10 to move the first workpiece 50 to the rough teaching position (step S102). After the movement is completed, the controller 100 removes the offset based on the force sense information output from the force sensor 18 (step S103). The controller 100 sets the state in which the first workpiece 50 has been moved to the rough teaching position as an initial state, and calculates the force Fz generated in the Zt axis direction according to the change from the initial state. The process of step S103 corresponds to the process of removing the offset of the force sense information.
[0119] The controller 100 sets the force information output from the force sensor 18 as an initial value when the first workpiece 50 and the second workpiece 60 are in a non-contact state. The controller 100 detects the posture of the first workpiece 50 after removing the offset of the force sensor 18. This removal of the offset is performed every time the search process is executed.
[0120] The controller 100 issues a command to the robot 10 to set the angle Rx of the TCP to the start angle (step S104). For example, an angle that is −11 [deg] with respect to the angle Rx of the current rough teaching position may be set as the start angle.
[0121] Next, the controller 100 issues a command to the robot 10 so that the force Fz generated in the Zt axis direction of the TCP coincides with the target value (step S105). This force control is continued until the Rx calibration value is determined.
[0122] The controller 100 issues a command to the robot 10 to change the angle Rx of the TCP from the start angle to the end angle (step S106), and collects the time change in the Z position correction amount (step S107).
[0123] After the TCP angle Rx changes to the end angle, the controller 100 determines the angle Rx at which the collected Z position correction amount is a maximum value (or a maximum value; this is the same in the following processes) as the Rx calibration value (step S108). The angle Rx of the rough teaching position is updated to the determined Rx calibration value.
[0124] Instead of changing the TCP angle Rx to the end angle, the rotation around the Xt axis may be stopped after a predetermined time has elapsed since the collected Z position correction amount reached a maximum value.
[0125] The Rx calibration value is determined by the processing of steps S103 to S108. Then, the controller 100 issues a command to the robot 10 to move the first workpiece 50 to the updated rough teaching position (step S109). Then, the processing of determining the Ry calibration value is started.
[0126] More specifically, the controller 100 removes the offset based on the force sense information output from the force sensor 18 (step S110). The process of step S110 corresponds to the process of removing the offset of the force sense information, similar to the process of step S103.
[0127] The controller 100 issues a command to the robot 10 to set the angle Ry of the TCP as the start angle (step S111). For example, an angle that is -11 [deg] with respect to the angle Ry of the current rough teaching position may be set as the start angle.
[0128] Next, the controller 100 issues a command to the robot 10 so that the force Fz generated in the Zt axis direction of the TCP coincides with the target value (step S112). This force control is continued until the Ry calibration value is determined.
[0129] The controller 100 issues a command to the robot 10 to change the angle Ry of the TCP from the start angle to the end angle (step S113), and collects the time change in the Z position correction amount (step S114).
[0130] After the TCP angle Ry changes to the end angle, the controller 100 determines the angle Ry at which the collected Z position correction amount is a maximum value as the Ry calibration value (step S115). The angle Ry of the rough teaching position is updated to the determined Ry calibration value.
[0131] Instead of changing the TCP angle Ry to the end angle, the rotation around the Yt axis may be stopped after a predetermined time has elapsed since the collected Z position correction amount reached a maximum value.
[0132] The Ry calibration value is determined by the processing of steps S110 to S115. Then, the controller 100 issues a command to the robot 10 to move the first workpiece 50 to the updated rough teaching position (step S116).
[0133] The controller 100 increments the number of calibrations by 1 (step S117), and determines whether the number of calibrations after the increment has reached a predetermined number of calibrations (step S118). If the number of calibrations after the increment has not reached the predetermined number of calibrations (NO in step S118), the processes from step S103 onwards are repeated.
[0134] If the number of calibrations after the increment has reached the predetermined number of calibrations (YES in step S118), the controller 100 determines the position Z (hereinafter also referred to as the "Z calibration value") where the first work 50 contacts the second work 60 (step S119), and the Rx / Ry / Z calibration process ends.
[0135] (d5: Example of Rx / Ry / Z calibration process) Next, an example of the operation of the Rx / Ry / Z calibration process will be described.
[0136] Fig. 15 is a diagram for explaining an example of an operation when determining a Z calibration value in the Rx / Ry / Z calibration process according to the present embodiment. Fig. 16 is a diagram for explaining an example of an operation when determining an Ry calibration value in the Rx / Ry / Z calibration process according to the present embodiment.
[0137] As shown in the processing procedure of Fig. 14, since the angles Rx and Ry cannot be calibrated simultaneously, they are calibrated one angle at a time in sequence. Note that the sensor error can be reduced by repeating the calibration of the angles Rx and Ry multiple times.
[0138] With reference to FIG. 15, the controller 100 moves the first workpiece 50 to the rough teaching position, and removes the offset of the force sense information output from the force sensor 18 ((A) of FIG. 15: steps S102 and S103 of FIG. 14).
[0139] Next, the controller 100 sets the angle Rx of the TCP to the start angle (FIG. 15(B): step S104 in FIG. 14). For example, the start angle may be set to -11 [deg] with respect to the angle Rx of the rough teaching position.
[0140] Next, the controller 100 moves (lowers) the first workpiece 50 in the Zt axis direction, and stops the movement when the force Fz generated in the Zt axis direction reaches the target value (FIG. 15(C): step S105 in FIG. 14). That is, the controller 100 presses the first workpiece 50 against the second workpiece 60. For example, the movement speed in the Zt axis direction may be 1 [mm / s], and the target value of the force Fz may be −3.5 [N].
[0141] Next, the controller 100 changes the angle Rx of the TCP from the start angle to the end angle while performing force control in the Zt axis direction (FIG. 15(D): step S106 in FIG. 14). That is, the controller 100 searches for the angle Rx that results in a surface conforming state. For example, the rotation speed (speed of change) of the angle Rx may be 0.4 [deg / s]. The angle Rx at which the Z position correction amount is at its maximum value becomes the Rx calibration value.
[0142] When the angle Rx reaches the end angle, the controller 100 stops the rotation around the Xt axis (step S106 in FIG. 14). Note that the rotation around the Xt axis may be stopped after a predetermined time has elapsed since the Z position correction amount became the maximum value.
[0143] Finally, the controller 100 updates the angle Rx of the rough teaching position to the Rx calibrated value, and moves the first workpiece 50 to the updated rough teaching position ((E) of FIG. 15: steps S108 and S109 of FIG. 14).
[0144] With reference to FIG. 16, the controller 100 moves the first workpiece 50 to the updated rough teaching position and removes the offset of the force sense information output from the force sensor 18 ((A) of FIG. 16: steps S109 and S110 of FIG. 14).
[0145] Next, the controller 100 sets the angle Ry of the TCP to the start angle (FIG. 16B: step S111 in FIG. 14). For example, the start angle may be set to -11 [deg] with respect to the angle Ry of the rough teaching position.
[0146] Next, the controller 100 moves (lowers) the first workpiece 50 in the Zt axis direction, and stops the movement when the force Fz generated in the Zt axis direction reaches the target value (FIG. 16(C): step S112 in FIG. 14). That is, the controller 100 presses the first workpiece 50 against the second workpiece 60. For example, the movement speed in the Zt axis direction may be 1 [mm / s], and the target value of the force Fz may be −3.5 [N].
[0147] Next, the controller 100 changes the TCP angle Rx from the start angle to the end angle while performing force control in the Zt axis direction (FIG. 16(D): step S113 in FIG. 14). That is, the controller 100 searches for the angle Ry that results in a surface conforming state. For example, the rotation speed (speed of change) of the angle Ry may be 0.4 [deg / s]. The angle Ry at which the Z position correction amount is at its maximum value becomes the Ry calibration value.
[0148] When the angle Ry reaches the end angle, the controller 100 stops the rotation around the Yt axis (step S113 in FIG. 14). Note that the rotation around the Yt axis may be stopped after a predetermined time has elapsed since the Z position correction amount became the maximum value.
[0149] Finally, the controller 100 updates the angle Ry of the rough teaching position to the Ry calibrated value, and moves the first workpiece 50 to the updated rough teaching position ((E) of FIG. 16: steps S115 and S116 of FIG. 14).
[0150] (d6: Change in Z position correction amount over time) Next, a description will be given of a time change in the Z position correction amount, which is an example of an evaluation index for searching for a surface profile state.
[0151] 17 is a diagram for explaining the change over time in the Z position correction amount in the Rx / Ry / Z calibration process according to the present embodiment. For convenience of explanation, the positional relationship between the first workpiece 50 and the second workpiece 60 is emphasized in FIG. 17, and does not necessarily coincide with the behavior of the actual workpieces.
[0152] 17A, in the initial state of the Rx / Ry / Z calibration process (the state where the TCP angle Rx is the start angle), the left end point of the first workpiece 50 is in contact with the second workpiece 60. In this state, the contact point moves due to the rotation of the first workpiece 50, so the pressing force Fz does not reach the target value. Therefore, the Z position correction amount is increased to make the force Fz match the target value.
[0153] 17B, even when the first workpiece 50 and the second workpiece 60 are in a surface-matching state, the contact between the first workpiece 50 and the second workpiece 60 is insufficient and the force Fz has not reached the target value. Therefore, the Z position correction amount continues to increase in order to make the force Fz match the target value.
[0154] 17C, when the first workpiece 50 tilts beyond the surface conforming state, the first workpiece 50 and the second workpiece 60 come into further contact with each other, so that the force Fz approaches the target value. Therefore, the increase in the Z position correction amount also becomes more gradual.
[0155] Finally, as shown in FIG. 17(D), when the right end point of the first workpiece 50 is in contact with the second workpiece 60, the pressing force becomes stable.
[0156] As described above, the timing at which the force Fz coincides with the target value may be delayed with respect to the timing at which the first workpiece 50 and the second workpiece 60 are in a surface conforming state. However, the delay time of the timing is considered to be substantially the same between the case where the first workpiece 50 is rotated clockwise and the case where the first workpiece 50 is rotated counterclockwise.
[0157] Therefore, by averaging the results of measurements taken while rotating the first workpiece 50 in both directions, the timing delay can be cancelled out. By reducing the effect of such a delay, the accuracy of the calibration results can be improved. Therefore, a slow search may be adopted, as described below.
[0158] (d7: Search for surface conformity state) FIG. 14 shows an example of a process in which a process of determining an Rx calibration value by rotating the first work 50 around the Xt axis and a process of determining an Ry calibration value by rotating the first work 50 around the Yt axis are alternately performed, but the process of determining the Rx calibration value and the Ry calibration value may be performed in two stages: a high-speed search and a low-speed search.
[0159] In the high-speed search shown in Fig. 14, a process of rotating the first workpiece 50 in one direction around the Xt axis and a process of rotating the first workpiece 50 in one direction around the Yt axis are repeatedly executed. In contrast, in the low-speed search shown in Fig. 18, a process of rotating the first workpiece 50 in both directions around the Xt axis and a process of rotating the first workpiece 50 in both directions around the Yt axis are repeatedly executed. That is, the Rx calibration value and the Ry calibration value are determined by rotating back and forth around the Xt axis and the Yt axis, respectively.
[0160] In low-speed search, an operation for changing the posture of the first work 50 relative to the second work 60 includes an operation (outward trip) of rotating the first work 50 in a first direction (e.g., clockwise) around an axis (Xt axis or Yt axis) perpendicular to the direction (Zt axis direction) in which the first work 50 is pressed against the second work 60, and an operation of rotating the first work 50 in a second direction (e.g., counterclockwise) that is opposite to the first direction.
[0161] That is, in the low-speed search, the rotation direction is changed and the approach position (Rx calibration value and / or Ry calibration value) is updated. More specifically, the first workpiece 50 is rotated in a first direction to search for a posture that results in a surface conforming state, and then the first workpiece 50 is rotated in a second direction to search for a posture that results in a surface conforming state, thereby updating the approach position (Rx calibration value and / or Ry calibration value).
[0162] In addition, in the low-speed search, the operation of rotating the first workpiece 50 in a first direction (e.g., clockwise) (outward trip) and the operation of rotating the first workpiece 50 in a second direction (e.g., counterclockwise) that is opposite to the first direction may be repeated multiple times.
[0163] In addition, in the low-speed search, the rotation speed (change speed) (absolute value) at which the first workpiece 50 is rotated may be made smaller than the rotation speed in the high-speed search. That is, in the low-speed search, the operation of changing the posture of the first workpiece 50 relative to the second workpiece 60 may include an operation of changing the posture of the first workpiece 50 relative to the second workpiece 60 at a first change speed, and an operation of changing the posture of the first workpiece 50 relative to the second workpiece 60 at a second change speed different from the first change speed. Note that the absolute value of the second change speed may be set to be smaller than the absolute value of the first change speed.
[0164] In this manner, the speed at which the posture of the first workpiece 50 is changed may be varied depending on the process of searching for the surface profile state. Typically, the speed of change may be reduced as the number of searches for the surface profile state increases.
[0165] 18 and 19 are flowcharts showing the procedure of the slow search included in the Rx / Ry / Z calibration process according to the present embodiment. The process shown in Fig. 18 and Fig. 19 may be performed after execution of step S116 shown in Fig. 14 or after YES in step S118.
[0166] 18, the controller 100 removes the offset based on the force information output from the force sensor 18 (step S120). Note that the first workpiece 50 is placed at the updated rough teaching position.
[0167] The controller 100 issues a command to the robot 10 to set the angle Rx of the TCP to the start angle (step S121). For example, an angle that is -2.5 [deg] with respect to the angle Rx of the current rough teaching position may be set as the start angle.
[0168] Next, the controller 100 issues a command to the robot 10 so that the force Fz generated in the Zt axis direction of the TCP coincides with the target value (step S122). This force control is continued until the Rx calibration value is determined.
[0169] The controller 100 issues a command to the robot 10 to rotate the angle Rx of the TCP at a predetermined rotation speed (step S123), and collects the time change of the Z position correction amount (step S124). For example, the rotation speed (change speed) of the angle Rx may be 0.28 [deg / s].
[0170] The controller 100 determines whether the Z position correction amount has reached the maximum value (step S125). If the Z position correction amount has reached the maximum value (YES in step S125), the controller 100 determines the angle Rx at which the Z position correction amount reaches the maximum value as the Rx calibration value (forward path) (step S126).
[0171] After a predetermined time has elapsed since the Z position correction amount became the maximum value, the controller 100 issues a command to the robot 10 to stop the rotation around the Xt axis (step S127).
[0172] The controller 100 issues a command to the robot 10 to rotate the angle Rx of the TCP in the reverse direction at a predetermined rotation speed (step S128), and collects the time change in the Z position correction amount (step S129). For example, the rotation speed (change speed) of the angle Rx may be set to -0.28 [deg / s].
[0173] The controller 100 determines whether the Z position correction amount has reached the maximum value (step S130). If the Z position correction amount has reached the maximum value (YES in step S130), the controller 100 determines the angle Rx at which the Z position correction amount reaches the maximum value as the Rx calibration value (return path) (step S131).
[0174] After a predetermined time has elapsed since the Z position correction amount became the maximum value, the controller 100 issues a command to the robot 10 to stop the rotation around the Xt axis (step S132).
[0175] The controller 100 determines the Rx calibration value (step S133) based on the Rx calibration value (forward path) (step S126) and the Rx calibration value (return path) (step S131). For example, the average of the Rx calibration value (forward path) and the Rx calibration value (return path) may be determined as the Rx calibration value. The angle Rx of the rough teaching position is updated to the determined Rx calibration value.
[0176] In this way, the controller 100 determines the average of the first attitude of the first work 50 determined by rotating the first work 50 in the first direction and the second attitude of the first work 50 determined by rotating the first work 50 in the second direction as the attitude of the first work 50 in which the tip surface 52 of the first work 50 and the receiving surface 64 of the second work 60 are parallel. That is, in the reciprocating operation, it is possible to determine whether or not the surface is conforming, and to determine the average of the attitude of the first work 50 determined on the outward path and the attitude of the first work 50 determined on the return path as the attitude corresponding to the surface conforming state.
[0177] The Rx calibration value is determined by the low-speed search through the processes of steps S120 to S133. Then, the controller 100 issues a command to the robot 10 to move the first workpiece 50 to the updated rough teaching position (step S134).
[0178] With reference to FIG. 19, the controller 100 removes the offset based on the force sense information output from the force sensor 18 (step S135).
[0179] The controller 100 issues a command to the robot 10 to set the angle Ry of the TCP to the start angle (step S136). For example, an angle that is -2.5 [deg] with respect to the angle Ry of the current rough teaching position may be set as the start angle.
[0180] Next, the controller 100 issues a command to the robot 10 so that the force Fz generated in the Zt axis direction of the TCP coincides with the target value (step S137). This force control is continued until the Ry calibration value is determined.
[0181] The controller 100 issues a command to the robot 10 to rotate the angle Ry of the TCP at a predetermined rotation speed (step S138), and collects the time change of the Z position correction amount (step S139). For example, the rotation speed (change speed) of the angle Ry may be 0.28 [deg / s].
[0182] The controller 100 determines whether the Z position correction amount has reached the maximum value (step S140). If the Z position correction amount has reached the maximum value (YES in step S140), the controller 100 determines the angle Ry at which the Z position correction amount reaches the maximum value as the Ry calibration value (forward path) (step S141).
[0183] After a predetermined time has elapsed since the Z position correction amount became the maximum value, the controller 100 issues a command to the robot 10 to stop the rotation around the Yt axis (step S142).
[0184] The controller 100 issues a command to the robot 10 to rotate the angle Ry of the TCP in the reverse direction at a predetermined rotation speed (step S143), and collects the time change in the Z position correction amount (step S144). For example, the rotation speed (change speed) of the angle Ry may be set to -0.28 [deg / s].
[0185] The controller 100 determines whether the Z position correction amount has reached the maximum value (step S145). If the Z position correction amount has reached the maximum value (YES in step S145), the controller 100 determines the angle Ry at which the Z position correction amount reaches the maximum value as the Ry calibration value (return path) (step S146).
[0186] After a predetermined time has elapsed since the Z position correction amount became the maximum value, the controller 100 issues a command to the robot 10 to stop the rotation around the Yt axis (step S147).
[0187] The controller 100 determines the Ry calibration value (step S148) based on the Ry calibration value (forward path) (step S141) and the Rx calibration value (return path) (step S146). For example, the average of the Ry calibration value (forward path) and the Ry calibration value (return path) may be determined as the Ry calibration value. The angle Ry of the rough teaching position is updated to the determined Ry calibration value.
[0188] In this way, the controller 100 determines the average of the first attitude of the first work 50 determined by rotating the first work 50 in a first direction and the second attitude of the first work 50 determined by rotating the first work 50 in a second direction as the attitude of the first work 50 in which the tip surface 52 of the first work 50 and the receiving surface 64 of the second work 60 are parallel.
[0189] The Ry calibration value is determined by the low-speed search through the processes in steps S135 to S148. Then, the controller 100 issues a command to the robot 10 to move the first workpiece 50 to the updated rough teaching position (step S149).
[0190] The controller 100 determines whether the slow search has been performed only the predetermined number of times for calibration (step S150). If the slow search has not been performed the predetermined number of times for calibration (NO in step S150), the process from step S120 onward is repeated.
[0191] If the slow search has been performed a predetermined number of times (YES in step S150), the slow search ends.
[0192] As described above, the approach position corresponding to the surface scanning state may be determined in two stages: a high-speed search which is a one-way search, and a low-speed search which is a round-trip search.
[0193] In the calibration process of the approach position combining the high-speed search and the low-speed search, the controller 100 determines the posture of the first workpiece 50 in which the tip surface 52 of the first workpiece 50 and the receiving surface 64 of the second workpiece 60 are parallel to each other based on the search result obtained by rotating the first workpiece 50 only in a first direction (e.g., clockwise) around an axis (Xt axis or Yt axis) perpendicular to the direction (Zt axis direction) in which the first workpiece 50 is pressed against the second workpiece 60. Next, the controller 100 updates the posture of the first workpiece 50 in which the tip surface 52 of the first workpiece 50 and the receiving surface 64 of the second workpiece 60 are parallel to each other based on the search result obtained by rotating the first workpiece 50 in the first direction and the search result obtained by rotating the first workpiece 50 in the second direction.
[0194] In addition, when the first workpiece 50 is rotated only in the first direction, the controller 100 rotates the first workpiece 50 at a first change speed, and when the first workpiece 50 is rotated in both the first and second directions, the controller 100 rotates the first workpiece 50 at a second change speed that is smaller than the first change speed.
[0195] (d8: Determination process of Z calibration value at which the first workpiece 50 contacts the second workpiece 60) Next, the process of determining the Z calibration value at which the first workpiece 50 contacts the second workpiece 60 (step S119 in FIG. 14) will be described.
[0196] In the process of determining the Rx calibration value and the process of determining the Ry calibration value, the position Z when the angle Rx and / or the angle Ry are used as the Rx calibration value and / or the Ry calibration value may be acquired as the Z calibration value. Note that since the Z calibration value is acquired multiple times, an average value or the like may be used.
[0197] Alternatively, after the Rx calibration value and the Ry calibration value are determined, the position Z (Z calibration value) where the first workpiece 50 contacts the second workpiece 60 may be searched for again.
[0198] Fig. 20 is a diagram for explaining a process for determining a Z calibration value of the Rx / Ry / Z calibration process according to the present embodiment. With reference to (A) of Fig. 20, in a state where the first workpiece 50 is placed at the updated rough teaching position, the offset is removed based on the force information output from the force sensor 18 (offset removal). Then, the controller 100 moves (lowers) the first workpiece 50 in the Zt axis direction.
[0199] With reference to (B) of FIG. 20, when the force Fz generated in the Zt axis direction reaches a target value, the position Z at that timing is determined as the Z calibration value at which the first work 50 contacts the second work 60. The determined Z calibration value indicates the position of the contact surface (receiving surface 64) of the second work 60. The Z calibration value corresponds to the work surface height. Then, with reference to (B) of FIG. 20, the first work 50 is moved (raised) in the Zt axis direction by a predetermined approach distance.
[0200] By the above-mentioned processing, the position Z (Z calibration value) at which the first workpiece 50 contacts the second workpiece 60 can be determined.
[0201] (d9: Variation) In the above-described Rx / Ry / Z calibration process, the angle Rx around the Xt axis (Rx calibration value), the angle Ry around the Yt axis (Ry calibration value), and the position Z on the Zt axis (Z calibration value) are determined, but it is also possible to determine only some of the calibration values.
[0202] For example, when the positional relationship is fixed for one of the Xt and Yt axes, the surface conformation state is searched for only for the movable axes. Therefore, only one of the process for determining the Rx calibration value (steps S103 to S108 in FIG. 14) and the process for determining the Ry calibration value (steps S110 to S115 in FIG. 14) may be executed once or multiple times.
[0203] Alternatively, even if a value is set in advance for one of the angle Rx around the Xt axis and the angle Ry around the Yt axis, only one of the process for determining the Rx calibration value and the process for determining the Ry calibration value may be executed one or more times.
[0204] Alternatively, the user may determine one of the angle Rx around the Xt axis and the angle Ry around the Yt axis by operating the teaching pendant 26.
[0205] Furthermore, a predetermined design value may be used for the position Z (Z calibration value) where the first workpiece 50 contacts the second workpiece 60. In this case, the process of step S119 in FIG. 14 can be omitted.
[0206] Furthermore, after determining the angle Rx around the Xt axis and / or the angle Ry around the Yt axis through the Rx / Ry / Z calibration process, the user may operate the teaching pendant 26 to bring the first workpiece 50 and the second workpiece 60 into contact with each other to determine the Z calibration value.
[0207] As described above, executing only a part of the processing included in the Rx / Ry / Z calibration processing is also within the technical scope of the present invention.
[0208] (d10:Small summary) In determining the approach position, if the angle Rx and / or the angle Ry is not correctly calibrated, the first work 50 and the second work 60 may not be able to be fully fitted together, and therefore the first work 50 may not be able to be inserted into the second work 60. Furthermore, if the angle Rx and / or the angle Ry is not properly calibrated, even if the position X, the position Y, and the angle Rz between the first work 50 and the second work 60 do not match, the first work 50 and the second work 60 may be erroneously detected as being fitted together due to deflection occurring in the robot 10.
[0209] Furthermore, when determining the approach position, if the position Z is not correctly calibrated to the receiving surface 64 of the second workpiece 60, the first workpiece 50 may be inserted too far, causing interference between the works. If the clearance is narrow, the first workpiece 50 may not be able to be inserted into the second workpiece 60.
[0210] The Rx / Ry / Z calibration process suppresses the occurrence of such interference between workpieces and false detection of the fitting condition.
[0211] As described above, the Rx / Ry / Z calibration process determines the surface conformance state based on the evaluation index, and calibrates the angle Rx, the angle Ry, and the position Z. In the Rx / Ry / Z calibration process, the posture of the first workpiece 50 is changed while maintaining the state in which the first workpiece 50 is pressed against the second workpiece 60 by force control. Then, based on the position change in the pressing direction of the first workpiece 50 or the relative distance between the first workpiece 50 and the second workpiece 60, the surface conformance state between the first workpiece 50 and the second workpiece 60 is determined, and at least one of the angle Rx, the angle Ry, and the position Z of the approach position is determined.
[0212] As an evaluation index, in addition to the height in the robot coordinate system, the Z position correction amount calculated in the force control may be used. When the Z position correction amount is used as the evaluation index, the timing at which the Z position correction amount becomes a maximum value (or a maximum value) is searched for. By using the Z position correction amount, coordinate conversion that takes into account the posture of the second workpiece 60 to calculate the height in the Zt axis direction is not required.
[0213] According to this embodiment, the approach position is calibrated to optimize the approach position from the rough teaching position, thereby reducing the time required for teaching. By optimizing the approach position, the time required for the probing operation can be reduced even if a positioning error occurs between the first workpiece 50 and the second workpiece 60 in actual operation.
[0214] In the determination of the surface imitation state, since the position information of the first workpiece 50 is used, it is less susceptible to the influence from factors of force fluctuations such as the offset and hysteresis of the force sensor 18, the magnitude of the target value (target force) of force control, and the magnitude of the rotation speed (change speed), and the calibration accuracy can be improved.
[0215] <E.X / Y / Rz Calibration Process> Next, the processing content of the X / Y / Rz calibration process (step S2) in FIG. 5 will be described.
[0216] (e1: Basic concept) In the X / Y / Rz calibration process, two direction vectors that define the inner surface of the fitting hole 62 of the second workpiece 60 are determined, and the position (coordinates) of the XtYt origin indicating the corner of the fitting hole 62 is determined from the two direction vectors. More specifically, with the first workpiece 50 in contact with two adjacent inner surfaces of the fitting hole 62 (hereinafter also referred to as the "first surface" and the "second surface"), the first workpiece 50 is moved on the Xt - Yt coordinates to determine the first direction vector corresponding to the first surface and the second direction vector corresponding to the second surface. Each of the first direction vector and the second direction vector includes components of the Xt axis and the Yt axis.
[0217] In this way, in the X / Y / Rz calibration process, based on the position where the first workpiece 50 and the second workpiece 60 are in contact, the direction vectors corresponding to the fitting hole 62 are calculated to calibrate the position X, the position Y, and the angle Rz. The first workpiece 50 is inserted into the fitting hole 62 while being tilted with respect to the receiving surface 64 of the second workpiece 60 and maintaining a non - contact state with the second workpiece 60. Subsequently, by bringing the first workpiece 50 into contact with one or more surfaces of the receiving surface 64, the coordinates of a plurality of position measurement points are obtained. Based on the coordinates of the obtained position measurement points, the direction vectors corresponding to each surface are calculated.
[0218] FIG. 21 is a diagram for explaining the process of determining the first direction vector of the X / Y / Rz calibration process according to the present embodiment.
[0219] First, the first work 50 is placed at a position on the Zt axis away from the second work 60 in the orientation of the Rx calibration value and the Ry calibration value determined by the Rx / Ry / Z calibration process. In this state, the tip surface of the first work 50 and the receiving surface 64 of the second work 60 are substantially parallel. Next, the first work 50 is tilted by a predetermined tilt angle from the Rx calibration value and also tilted by a predetermined tilt angle from the Ry calibration value. The tilt angles for the Xt axis and the Yt axis may be the same or different.
[0220] 21(A), the first workpiece 50 is inserted in an inclined state into the fitting hole 62 of the second workpiece 60. That is, the controller 100 causes the robot 10 to execute an operation of inserting the first workpiece 50 gripped by the gripping mechanism 20 into the fitting hole 62 while maintaining a non-contact state with the second workpiece 60. Note that the operation of inserting the first workpiece 50 in an inclined state into the fitting hole 62 of the second workpiece 60 may be performed by the user operating the teaching pendant 26.
[0221] Since the first workpiece 50 is tilted, one corner of the tip surface approaches the first surface 68 of the fitting hole 62 of the second workpiece 60. The controller 100 gives a command to the robot 10 to press one corner of the first workpiece 50 against the first surface 68 of the fitting hole 62 (for example, 3 [N]).
[0222] Next, as shown in (B) of FIG. 21, the controller 100 issues a command to the robot 10 to move the first workpiece 50 along the first surface 68 while pressing one corner of the first workpiece 50 against the first surface 68 of the mating hole 62.
[0223] When one corner of the first workpiece 50 approaches the second surface 69, the first workpiece 50 receives a reaction force from the second surface 69. When the controller 100 receives the reaction force from the second surface 69, it acquires coordinates (Xt-axis and Yt-axis components) indicating a position measurement point Loc1 (for example, 1 mm before) in front of the position where the reaction force is received.
[0224] Next, as shown in (C) of FIG. 21, the controller 100 issues a command to the robot 10 to move the first workpiece 50 along the first surface 68 in the opposite direction to the second surface 69 while pressing one corner of the first workpiece 50 against the first surface 68 of the mating hole 62.
[0225] When one corner of the first workpiece 50 approaches the surface facing the second surface 69, the first workpiece 50 receives a reaction force. When the reaction force is received, the controller 100 acquires coordinates (Xt-axis and Yt-axis components) indicating a position measurement point Loc2 (for example, 1 mm before) in front of the position where the reaction force is received.
[0226] In this manner, during movement along the first surface 68 of the first workpiece 50, the coordinates of position measurement points Loc1, Loc2 located a predetermined distance before the position where a reaction force exceeding a predetermined value is received are acquired.
[0227] Next, as shown in FIG. 21(D), the controller 100 calculates a first direction vector Vec1 (=Loc2-Loc1) based on the position measurement point Loc1 and the position measurement point Loc2.
[0228] In this manner, the controller 100 executes an operation of moving the first workpiece 50 along the first surface 68, while pressing the first workpiece 50 against the first surface 68, which is one of the inner surfaces of the fitting hole 62. Then, the controller 100 calculates a first direction vector Vec1 corresponding to the first surface 68, based on information about the movement of the first workpiece 50 along the first surface 68.
[0229] The angle Rz is corrected by the angle difference between the initially set direction of the first surface 68 of the fitting hole 62 and the direction indicated by the calculated first direction vector Vec1, and the corrected angle Rz is determined as the Rz calibration value. In this manner, the controller 100 determines the Rz calibration value based on the first direction vector Vec1. The Rz calibration value indicates a reference posture for fitting the first workpiece 50 into the fitting hole 62 of the second workpiece 60. The Rz calibration value can also be determined based on a second direction vector Vec2, which will be described later.
[0230] The angle between the reference direction of the angle Rz and the direction indicated by the first direction vector Vec1 may be determined as the Rz calibration value.
[0231] FIG. 22 is a diagram for illustrating the process of determining the second direction vector of the X / Y / Rz calibration process according to the present embodiment.
[0232] Next, as shown in FIG. 22(A), the first work 50 is placed at a position where one corner of the tip surface is close to the second surface 69 of the fitting hole 62 of the second work 60.
[0233] The controller 100 issues a command to the robot 10 to press one corner of the first workpiece 50 against the second surface 69 of the fitting hole 62 (for example, 3 [N]).
[0234] Next, as shown in (B) of FIG. 22, the controller 100 issues a command to the robot 10 to move the first workpiece 50 along the second surface 69 of the mating hole 62 while pressing one corner of the first workpiece 50 against the second surface 69.
[0235] When one corner of the first workpiece 50 approaches the surface facing the first surface 68, the first workpiece 50 receives a reaction force from the surface facing the first surface 68. When the controller 100 receives the reaction force from the surface facing the first surface 68, it acquires coordinates (Xt-axis and Yt-axis components) indicating a position measurement point Loc3 (for example, 1 mm before) in front of the position where the reaction force is received.
[0236] Next, as shown in (C) of FIG. 22, the controller 100 issues a command to the robot 10 to move the first workpiece 50 along the second surface 69 in the direction of the first surface 68 while pressing one corner of the first workpiece 50 against the second surface 69 of the mating hole 62.
[0237] When one corner of the first workpiece 50 approaches the first surface 68, the first workpiece 50 receives a reaction force. When the reaction force is received, the controller 100 acquires coordinates (Xt-axis and Yt-axis components) indicating a position measurement point Loc4 (for example, 1 mm before) in front of the position where the reaction force is received.
[0238] In this manner, during movement along the second surface 69 of the first workpiece 50, the coordinates of position measurement points Loc3, Loc4 located a predetermined distance before the position where a reaction force exceeding a predetermined value is received are acquired.
[0239] Next, as shown in FIG. 22(D), the controller 100 calculates a second direction vector Vec2 (=Loc4-Loc3) based on the position measurement point Loc3 and the position measurement point Loc4.
[0240] In this manner, the controller 100 executes an operation of moving the first workpiece 50 along the second surface 69, while pressing the first workpiece 50 against the second surface 69, which is an inner surface adjacent to the first surface 68 of the fitting hole 62. Then, the controller 100 calculates a second direction vector Vec2 corresponding to the second surface 69, based on information about the movement of the first workpiece 50 along the second surface 69.
[0241] 21 and 22, the first direction vector Vec1 and the second direction vector Vec2 can be calculated. That is, the controller 100 calculates the XtYt origin based on the first direction vector Vec1 and the second direction vector Vec2. The XtYt origin is a coordinate corresponding to a corner of the fitting hole 62, and indicates a position reference for fitting the first workpiece 50 into the fitting hole 62 of the second workpiece 60.
[0242] Fig. 23 is a diagram for explaining a process for determining the XtYt origin of the X / Y / Rz calibration process according to the present embodiment. With reference to Fig. 23, controller 100 calculates the intersection point between first direction vector Vec1 and second direction vector Vec2 on the Xt-Yt coordinate system, and determines the calculated intersection point as the XtYt origin.
[0243] That is, the controller 100 determines the position X on the Xt axis and the position Y on the Yt axis indicating the intersection of the first direction vector Vec1 and the second direction vector Vec2 as calibration values indicating the origin. The XtYt origin may be determined on the intersection line of the plane including the first direction vector Vec1 and the plane including the second direction vector Vec2. Hereinafter, the position X of the XtYt origin is also referred to as the "X calibration value," and the position Y of the XtYt origin is also referred to as the "Y calibration value."
[0244] As described above, the controller 100 determines at least one of the position and the orientation of the first workpiece 50 for fitting the first workpiece 50 into the fitting hole 62 based on at least one of the first direction vector Vec1 and the second direction vector Vec2.
[0245] More specifically, the controller 100 determines the Rz calibration value, which is the angle of the fitting hole, based on at least one of the first direction vector Vec1 and the second direction vector Vec2. Note that the controller 100 may determine the Rz calibration value (provisional value) based on the first direction vector Vec1 and also determine the Rz calibration value (provisional value) based on the second direction vector Vec2, and then finally output the average of the determined Rz calibration values (provisional values) as the Rz calibration value.
[0246] Furthermore, the controller 100 may determine the XtYt origin that serves as the position reference for the fitting hole 62, based on the first direction vector Vec1 and the second direction vector Vec2.
[0247] (e2: Processing procedure) Next, the X / Y / Rz calibration process will be described in more detail.
[0248] 24 and 25 are flowcharts showing a more detailed procedure of the X / Y / Rz calibration process according to the present embodiment. Each step shown in Fig. 24 and Fig. 25 may be realized by the processor 102 of the controller 100 executing the system program 112 and / or the control program 114.
[0249] 24, the controller 100 issues a command to the robot 10 to place the first workpiece 50 above the second workpiece 60 in a posture of the Rx calibration value and the Ry calibration value (step S201). Next, the controller 100 issues a command to the robot 10 to tilt the first workpiece 50 by a predetermined tilt angle from the Rx calibration value and also by a predetermined tilt angle from the Ry calibration value (step S202). Furthermore, the controller 100 issues a command to the robot 10 to insert the first workpiece 50 into the fitting hole 62 of the second workpiece 60 (step S203).
[0250] Next, the controller 100 issues a command to the robot 10 to press one corner of the first workpiece 50 against the first surface 68 of the fitting hole 62 (step S204), and move the first workpiece 50 along the first surface 68 toward the second surface 69 (step S205). The controller 100 determines whether or not a reaction force exceeding a predetermined value has been received (step S206).
[0251] When a reaction force exceeding a predetermined value is received (YES in step S206), the controller 100 returns the first workpiece 50 along the first surface 68 a predetermined distance in the opposite direction to the second surface 69 (step S207), and acquires the coordinates of the first position measurement point, assuming the returned position as a first position measurement point (step S208). When determining the first position measurement point, the force pressing one corner of the first workpiece 50 against the first surface 68 of the fitting hole 62 may be reduced to a predetermined value (for example, 1 [N]) (details will be described later. The same applies to determining other position measurement points).
[0252] The controller 100 issues a command to the robot 10 to move the first workpiece 50 along the first surface 68 in the opposite direction to the second surface 69 while pressing one corner of the first workpiece 50 against the first surface 68 of the fitting hole 62 (step S209). The controller 100 determines whether or not a reaction force exceeding a predetermined value has been received (step S210).
[0253] When a reaction force exceeding a predetermined value is received (YES in step S210), the controller 100 returns the first workpiece 50 a predetermined distance along the first surface 68 toward the second surface 69 (step S211), and acquires the coordinates of the second position measurement point, which is the returned position, as a second position measurement point (step S212).
[0254] The controller 100 calculates the first direction vector Vec1 based on the positions of the first position measurement point and the second position measurement point (step S213).
[0255] The controller 100 determines the Rz calibration value based on the first direction vector Vec1 (step S214). That is, the controller 100 corrects the angle Rz by the angle difference between the initially set direction of the first surface 68 of the fitting hole 62 and the direction indicated by the calculated first direction vector Vec1, and determines the corrected angle Rz as the Rz calibration value.
[0256] 25, the controller 100 then issues a command to the robot 10 to press another corner of the first workpiece 50 against the second surface 69 of the fitting hole 62 (step S215), and moves the first workpiece 50 along the second surface 69 in the opposite direction to the first surface 68 (step S216). The controller 100 determines whether or not a reaction force exceeding a predetermined value has been received (step S217).
[0257] When a reaction force exceeding a predetermined value is received (YES in step S217), the controller 100 returns the first workpiece 50 a predetermined distance along the second surface 69 toward the first surface 68 (step S218), and acquires the coordinates of the third position measurement point, which is the returned position, as the third position measurement point (step S219).
[0258] The controller 100 issues a command to the robot 10 to move the first workpiece 50 along the second surface 69 toward the first surface 68 while pressing one corner of the first workpiece 50 against the second surface 69 of the fitting hole 62 (step S220). The controller 100 determines whether or not a reaction force exceeding a predetermined value has been received (step S221).
[0259] When a reaction force exceeding a predetermined value is received (YES in step S221), the controller 100 returns the first workpiece 50 a predetermined distance along the second surface 69 in the direction opposite to the first surface 68 (step S222), and acquires the coordinates of the fourth position measurement point, which is the returned position, as the fourth position measurement point (step S223).
[0260] The controller 100 calculates the second direction vector Vec2 based on the positions of the third position measurement point and the fourth position measurement point (step S224).
[0261] Controller 100 calculates the XtYt origin based on first direction vector Vec1 and second direction vector Vec2 (step S225), and determines the X calibration value and the Y calibration value from the calculated XtYt origin (step S226), and then the process ends. (e3: High precision position measurement) Next, a modified example in which a position for calculating a direction vector is measured with higher accuracy will be described.
[0262] FIG. 26 is a diagram for explaining an example of a position measuring method for calculating a direction vector in the X / Y / Rz calibration processing according to the present embodiment.
[0263] 26, when one corner of the first work 50 is pressed against any surface of the fitting hole 62, if the target value of the force control is a predetermined value (e.g., 5 [N]) or more, the gripping mechanism 20 (see FIG. 1) may be elastically deformed on the order of several hundreds of μm. Such elastic deformation may reduce the accuracy of the measured position.
[0264] For example, at the position measurement point where the position is acquired, the target value of the force control may be lowered to a target value where no elastic deformation occurs (for example, about 1 [N]). Note that the target value is preferably set to a value with a predetermined margin with respect to the minimum value of force detectable from the force sense information from the force sensor 18. By changing the target value of the force control, the position measurement accuracy can be improved.
[0265] In this way, the controller 100 causes the robot 10 to perform an operation to reduce the pressing force of the first workpiece 50 against the first surface 68 at the position measurement points Loc1, Loc2, and also to perform an operation to reduce the pressing force of the first workpiece 50 against the second surface 69 at the position measurement points Loc3, Loc4.
[0266] By performing such an operation, errors caused by elastic deformation that may occur in the robot 10 can be reduced, and the accuracy of calculating the direction vector can be improved.
[0267] Also, when a certain degree of elastic deformation has occurred, the force control may be disabled and the first workpiece 50 may be moved in a direction away from the surface against which the corner of the first workpiece 50 was pressed. In this case, the first workpiece 50 may be moved until the reaction force detected by the force information from the force sensor 18 decreases to a predetermined value.
[0268] At this time, the controller 100 causes the robot 10 to stop pressing the first workpiece 50 against the first surface 68 at the position measurement points Loc1 and Loc2, and to move the first workpiece 50 away from the second surface 69 so that the reaction force generated by the first workpiece 50 contacting the first surface 68 becomes equal to or less than a predetermined value. Similarly, the controller 100 causes the robot 10 to stop pressing the first workpiece 50 against the second surface 69 at the position measurement points Loc3 and Loc4, and to move the first workpiece 50 away from the second surface 69 so that the reaction force generated by the first workpiece 50 contacting the second surface 69 becomes equal to or less than a predetermined value.
[0269] As described above, the position measurement accuracy can be improved by adjusting the position of the corner of the first workpiece 50 relative to any one of the faces of the fitting hole 62. This can reduce errors caused by elastic deformation that may occur in the robot 10, and improve the calculation accuracy of the direction vector.
[0270] (e4: Improved accuracy of directional vector calculation) In the above description, the process of calculating the direction vector from two positions has been exemplified, but the present invention is not limited to this. More positions may be measured to improve the calculation accuracy of the direction vector.
[0271] FIG. 27 is a diagram for explaining a modified example of the process of calculating a direction vector in the X / Y / Rz calibration process according to the present embodiment.
[0272] 27, for example, by repeating the above-mentioned position measurement multiple times, multiple positions can be obtained for the same surface. Alternatively, in a state where one corner of the first work 50 is pressed against any one of the surfaces of the fitting hole 62, the corner is moved along the surface, and the positions indicating the trajectory are sequentially stored, whereby multiple positions can be obtained.
[0273] The direction vector may be calculated by linearly approximating the acquired positions using a statistical method such as the least squares method. When applying the statistical method, if the acquired positions include outliers, the outliers may be excluded before calculating the direction vector. Any statistical method may be used as long as it can calculate the direction vector.
[0274] In this way, the controller 100 calculates the first direction vector Vec1 by interpolating based on the coordinates of multiple position measurement points acquired during the movement along the first surface 68 of the first workpiece 50. Similarly, the controller 100 calculates the second direction vector Vec2 by interpolating based on the coordinates of multiple position measurement points acquired during the movement along the second surface 69 of the first workpiece 50.
[0275] A more accurate direction vector can be calculated by statistical processing using the coordinates of a plurality of position measurement points.
[0276] (e5: Variation) In the above-mentioned X / Y / Rz calibration process, the position X of the XtYt origin (X calibration value), the position Y of the XtYt origin (Y calibration value), and the Rz calibration value are determined, but only some of the calibration values may be determined. For example, a predetermined design value may be used for the Rz calibration value. In this case, it is sufficient to determine only the X calibration value and the Y calibration value. Also, the Rz calibration value may be determined by the user operating the teaching pendant 26.
[0277] In addition, when the positional relationship is fixed for one side of the second workpiece 60, the direction vector may be calculated only for the other side. In this case, the XtYt origin is calculated using two direction vectors, but previously calculated information can be used for one of the direction vectors.
[0278] As described above, executing only a part of the processing included in the X / Y / Rz calibration processing is also within the technical scope of the present invention.
[0279] (e6:Summary) In determining the approach position, if a brute force search is performed, an appropriate position can be determined, but the time required for the search is excessive and this is not suitable for practical use. In addition, the method of searching by controlling the force and moment of the first workpiece 50 may cause errors due to moment errors caused by reaction forces, offsets and hysteresis of the force sensor 18, etc., which may reduce the calibration accuracy.
[0280] In the X / Y / Rz calibration process, the positions of multiple position measurement points are acquired for one surface, and the direction vector for that surface is calculated by interpolating the acquired positions. The angle Rz around the Zt axis is calibrated based on the calculated direction vector.
[0281] Since it is not necessary to use moment information for the calibration of the angle Rz, it is less affected by moment errors due to reaction forces, offsets and hysteresis of the force sensor 18, etc., and the calibration accuracy can be improved.
[0282] <F. Other Embodiments> As an example of the calibration process for the approach position, although a process example of performing Rx / Ry / Z calibration processing (step S1) and X / Y / Rz calibration processing (step S2) has been described, it may be possible to perform only the Rx / Ry / Z calibration processing or only the X / Y / Rz calibration processing.
[0283] For example, after determining the Rx calibration value and the Ry calibration value for making the first workpiece 50 and the second workpiece 60 in a face-following state by the Rx / Ry / Z calibration processing, the user may operate the teaching pendant 26 to determine other values.
[0284] Alternatively, after setting both the Rx calibration value and the Ry calibration value to initial values (for example, 0°), the X / Y / Rz calibration processing may be executed to determine the XtYt origin.
[0285] Furthermore, as described above, only some of the calibration values may be determined by the Rx / Ry / Z calibration processing, or only some of the calibration values may be determined by the X / Y / Rz calibration processing.
[0286] Thus, the technical scope of the present invention includes a process of determining at least one of the X calibration value, the Y calibration value, the Z calibration value, the Rx calibration value, the Ry calibration value, and the Rz calibration value.
[0287] <G. Supplementary Note> The above-described embodiments include the following technical ideas.
[0288] [Configuration 1] A controller (100) for inserting a first workpiece (50) into a fitting hole (62) of a second workpiece (60) using a robot (10), the robot having a gripping mechanism (20) for gripping the first workpiece and a force sensor (18), the controller controlling the robot to: An operation (S204, S205, S209) of moving the first workpiece along a first surface, which is one of the inner surfaces of the fitting hole, while pressing the first workpiece against the first surface; and executing an operation (S215, S216, S220) of moving the first workpiece along a second surface, which is an inner surface adjacent to the first surface of the fitting hole, while pressing the first workpiece against the second surface, The controller: A process (S213) of calculating a first direction vector corresponding to the first surface based on information of the movement of the first workpiece along the first surface; A process (S224) of calculating a second direction vector corresponding to the second surface based on information of the movement of the first workpiece along the second surface; and a process (S214; S225, S226) of determining at least one of a position and an attitude of the first work for fitting the first work into the fitting hole based on at least one of the first direction vector and the second direction vector.
[0289] [Configuration 2] The controller of configuration 1, wherein the controller determines an angle of the fitting hole based on at least one of the first direction vector and the second direction vector (S214).
[0290] [Configuration 3] The controller according to configuration 1 or 2, wherein the controller determines an origin that serves as a position reference for the fitting hole based on the first direction vector and the second direction vector (S225, S226).
[0291] [Configuration 4] The process of calculating the first direction vector includes, during the movement of the first workpiece along the first surface, based on coordinates of a first position measurement point (Loc1, Loc2) that is a predetermined distance before a position where a reaction force exceeding a predetermined value is received, The controller according to any one of configurations 1 to 3, wherein the process of calculating the second direction vector is based on the coordinates of a second position measurement point (Loc3, Loc4) that is a predetermined distance before the position where a reaction force exceeding a predetermined value is received during movement along the second surface of the first workpiece.
[0292] [Configuration 5] The controller controls the robot to: an operation of reducing a pressing force of the first workpiece against the first surface at the first position measurement point; and an operation of reducing a pressing force of the first workpiece against the second surface at the second position measurement point.
[0293] [Configuration 6] The controller controls the robot to: an operation of stopping the pressing of the first workpiece against the first surface at the first position measurement point and moving the first workpiece away from the first surface so that a reaction force generated by the first workpiece contacting the first surface becomes equal to or less than a predetermined value; The controller of configuration 4, further comprising: at the second position measurement point, stopping the pressing of the first workpiece against the second surface; and moving the first workpiece away from the second surface so that a reaction force generated by the first workpiece contacting the second surface is equal to or less than a predetermined value.
[0294] [Configuration 7] The process of calculating the first direction vector includes a process of interpolating based on coordinates of a plurality of position measurement points acquired during movement along the first surface of the first workpiece, The controller according to any one of configurations 1 to 6, wherein the process of calculating the second direction vector includes a process of interpolating based on coordinates of a plurality of position measurement points acquired during movement along the second surface of the first workpiece.
[0295] [Configuration 8] A control method for inserting a first workpiece (50) into a fitting hole (62) of a second workpiece (60) using a robot (10), comprising: A step (S204, S205, S209) of moving the first workpiece along a first surface, which is one of the inner surfaces of the fitting hole, while pressing the first workpiece against the first surface; Calculating a first direction vector corresponding to the first surface based on information of movement of the first workpiece along the first surface (S215, S216, S220); A step (S213) of moving the first workpiece along a second surface, which is an inner surface adjacent to the first surface of the fitting hole, while pressing the first workpiece against the second surface; Calculating a second direction vector corresponding to the second surface based on information of the movement of the first workpiece along the second surface (S224); and determining (S214; S225, S226) at least one of a position and an attitude of the first work for fitting the first work into the fitting hole based on at least one of the first direction vector and the second direction vector.
[0296] [Configuration 9] A control program (114) for a robot system (1) for inserting a first workpiece (50) into a fitting hole (62) of a second workpiece (60) using a robot (10), the control program including: A step of giving a command to the robot to move the first workpiece along a first surface, which is one of the inner surfaces of the fitting hole, in a state where the first workpiece is pressed against the first surface (S204, S205, S209); Steps (S215, S216, S220) of calculating a first direction vector corresponding to the first surface based on information on the movement along the first surface of the first workpiece Step (S213) of giving an instruction to the robot to move the first workpiece along a second surface which is an inner surface adjacent to the first surface of the fitting hole while pressing the first workpiece against the second surface Step (S224) of calculating a second direction vector corresponding to the second surface based on information on the movement along the second surface of the first workpiece A control program for executing steps (S214; S225, S226) of determining at least one of the position and orientation of the first workpiece for fitting the first workpiece into the fitting hole based on at least one of the first direction vector and the second direction vector
[0297] <H. Advantages> According to the present embodiment, a method for appropriately determining at least a part of the approach position when fitting two workpieces can be realized.
[0298] It should be considered that all the embodiments disclosed this time are illustrative in all respects and not restrictive. The scope of the present invention is shown not by the above description but by the claims, and it is intended that all modifications within the meaning and scope equivalent to the claims are included.
Explanation of Reference Numerals
[0299] 1 robot system, 2 robot coordinate system, 10 robot, 11 base, 12, 13, 14, 15, 16, 17 movable part, 18 force sensor, 20 gripping mechanism, 21, 22 claw part, 26 teaching pendant, 30 tool coordinate system, 32, 33, 34, 35, 36, 37, 38 motor, 40, 106 interface, 42, 43, 44, 45, 46, 47, 48 driver, 50 first workpiece, 52 tip surface, 56, 57 outermost edge, 58 settable range, 60 second workpiece, 62 fitting hole, 64 receiving surface, 66 receiving surface (design value), 68 first surface, 69 second surface, 100 controller, 102 processor, 104 memory, 108 bus, 110 storage, 112 system program, 114 Control program, 120 force sensor filter, 122 conversion processing module, 124 difference calculator, 126 sampler, 128 force control calculation module, 130 limiter, 132 holder, 134 adder, 200 information processing device, Loc1, Loc2, Loc3, Loc4 position measurement points, Vec1 first direction vector, Vec2 second direction vector.
Claims
1. A controller for inserting a first workpiece into a fitting hole of a second workpiece using a robot, the robot having a gripping mechanism for gripping the first workpiece and a force sensor, the controller controlling the robot to: an operation of moving the first workpiece along a first surface, which is one of the inner surfaces of the fitting hole, while pressing the first workpiece against the first surface; and moving the first workpiece along a second surface, which is an inner surface adjacent to the first surface of the fitting hole, while pressing the first workpiece against the second surface. The controller: calculating a first direction vector corresponding to the first surface based on information of movement of the first workpiece along the first surface; calculating a second direction vector corresponding to the second surface based on information of movement of the first workpiece along the second surface; and determining at least one of a position and an attitude of the first work for fitting the first work into the fitting hole based on at least one of the first direction vector and the second direction vector.
2. The controller of claim 1 , wherein the controller determines an angle of the fitting hole based on at least one of the first direction vector and the second direction vector.
3. The controller according to claim 1 , wherein the controller determines an origin that serves as a position reference for the fitting hole based on the first direction vector and the second direction vector.
4. The process of calculating the first direction vector includes, during the movement of the first workpiece along the first surface, based on coordinates of a first position measurement point that is a predetermined distance before a position where a reaction force exceeding a predetermined value is received, A controller as described in any one of claims 1 to 3, wherein the process of calculating the second direction vector is based on the coordinates of a second position measurement point that is a predetermined distance before the position where a reaction force exceeding a predetermined value is received during movement along the second surface of the first workpiece.
5. The controller controls the robot to: an operation of reducing a pressing force of the first workpiece against the first surface at the first position measurement point; The controller according to claim 4 , further comprising an operation of reducing a pressing force of the first workpiece against the second surface at the second position measurement point.
6. The controller controls the robot to: an operation of stopping the pressing of the first workpiece against the first surface at the first position measurement point and moving the first workpiece away from the first surface so that a reaction force generated by the first workpiece contacting the first surface becomes equal to or less than a predetermined value; 5. The controller according to claim 4, further comprising: at the second position measurement point, stopping the pressing of the first workpiece against the second surface; and moving the first workpiece away from the second surface so that a reaction force generated by the first workpiece contacting the second surface is equal to or less than a predetermined value.
7. The process of calculating the first direction vector includes a process of interpolating based on coordinates of a plurality of position measurement points acquired during movement along the first surface of the first workpiece, A controller according to any one of claims 1 to 3, wherein the process of calculating the second direction vector includes a process of interpolating based on coordinates of multiple position measurement points acquired during movement along the second surface of the first workpiece.
8. 1. A control method for inserting a first workpiece into a fitting hole of a second workpiece using a robot, comprising: a step of moving the first workpiece along a first surface, which is one of the inner surfaces of the fitting hole, while pressing the first workpiece against the first surface; calculating a first direction vector corresponding to the first surface based on information of movement of the first workpiece along the first surface; a step of moving the first workpiece along a second surface, which is an inner surface adjacent to the first surface of the fitting hole, while pressing the first workpiece against the second surface; calculating a second direction vector corresponding to the second surface based on information of movement of the first workpiece along the second surface; and determining at least one of a position and an attitude of the first work for fitting the first work into the fitting hole based on at least one of the first direction vector and the second direction vector.
9. A control program for inserting a first workpiece into a fitting hole of a second workpiece using a robot, the control program including: giving a command to the robot to move the first workpiece along a first surface, which is one of the inner surfaces of the fitting hole, in a state where the first workpiece is pressed against the first surface; calculating a first direction vector corresponding to the first surface based on information of movement of the first workpiece along the first surface; giving a command to the robot to move the first workpiece along a second surface, the second surface being an inner surface adjacent to the first surface of the fitting hole, in a state where the first workpiece is pressed against the second surface; calculating a second direction vector corresponding to the second surface based on information of movement of the first workpiece along the second surface; and a step of determining at least one of a position and an attitude of the first work for fitting the first work into the fitting hole based on at least one of the first direction vector and the second direction vector.
Citation Information
Patent Citations
Control device, robot, and robot system
JP2018199172A
Cited By
Shaft hole assembling method and device and electronic equipment
CN119748083A
