Program writing device, program writing method, and program

By generating teaching points on the robot's action trajectory until the error is below the allowable value, the problem of huge data volume and long calculations caused by the large number of teaching points in the prior art is solved, and more efficient program generation and calculation are achieved.

CN120051359APending Publication Date: 2025-05-27FANUC LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202280101179.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2022-12-27
Publication Date
2025-05-27

AI Technical Summary

Technical Problem

In the prior art, the number of teaching points in the program of the robot's action trajectory is large, resulting in a huge amount of data and a long time-consuming calculation. Especially when the action trajectory is complex, the calculation of the intermediate point is obvious.

Method used

The program writing device generates trajectory information indicating the movement trajectory of the robot's front end point, and generates teaching points on the trajectory until the error is below the allowable value, thereby reducing the number of teaching points.

Benefits of technology

It effectively reduces the number of teaching points in the program, reduces the amount of data and time-consuming calculation, and improves the program generation efficiency in complex paths of the robot's motion trajectory.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120051359A_ABST
    Figure CN120051359A_ABST
Patent Text Reader

Abstract

It is desirable to further reduce the number of teaching points in a program for operating a robot. A programming device for generating, as a program, trajectory information indicating an operation trajectory of a tip point of a robot, the programming device comprising: a first trajectory information generation unit for generating first trajectory information indicating the operation trajectory of the tip point of the robot on the basis of an operation command of the robot; a teaching point generation unit that generates a teaching point on the trajectory of the first trajectory information; a program generation unit that generates a program in which the first trajectory information of the teaching point has been generated; a second trajectory information generation unit that acquires second trajectory information indicating an operation trajectory of a tip point of the robot operated by the program; an error calculation unit that calculates an error between the first trajectory information and the second trajectory information; and a teaching point addition unit that adds a teaching point on the trajectory of the first trajectory information until the error is equal to or less than an allowable value.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to a program writing device, a program writing method, and a program. Background Art

[0002] Conventionally, a robot has been controlled not by a dedicated control device (hereinafter also referred to as a "robot control device") but by an external control device. In the case of controlling a robot by an external control device, for example, an operation command can be transmitted to the robot control device from the external control device at a short cycle, thereby controlling the robot. In this kind of robot control, there are not only cases where the robot is controlled in real time by the external control device, but also cases where the operation of the robot that has been executed once by the control of the external control device is repeated by the control of the robot control device. In this case, in the robot control device, it is necessary to store all the operation commands transmitted from the external control device at a short cycle, so the amount of data becomes huge.

[0003] In order to solve such a problem, a method of storing trajectory information representing the motion trajectory of a robot as a program has been proposed. For example, in Patent Document 1, a robot system is described that learns the error between an ideal trajectory and an actual trajectory when the robot is controlled to pass through a specific intermediate teaching point, and adds a teaching point at a position that will become the target trajectory, thereby realizing the target trajectory.

[0004] Prior Art Documents

[0005] Patent Documents

[0006] Patent Document 1: International Publication No. 2022 / 176761 Summary of the Invention

[0007] Problems to be Solved by the Invention

[0008] The operation commands transmitted from the external control device are difficult to be converted into a program due to the large number of data. In addition, as in Patent Document 1 above, even if it can be converted into a program, there is a problem that the number of teaching points in the program becomes huge. In particular, in the robot system of Patent Document 1, since predictive teaching is performed, there is a problem that the calculation of intermediate points (teaching points) takes time as the motion trajectory becomes complex.

[0009] Therefore, it is desired to further reduce the number of teaching points in the program for operating the robot.

[0010] Solutions to the Problems

[0011] The program writing device of the present disclosure is used to generate a program from trajectory information representing the motion trajectory of the front end point of a robot. The program writing device includes: a first trajectory information generation unit that generates first trajectory information representing the motion trajectory of the front end point of the robot according to the motion command of the robot; a teaching point generation unit that generates teaching points on the trajectory of the first trajectory information; a program generation unit that generates a program of the first trajectory information for which the teaching points have been generated; a second trajectory information generation unit that acquires second trajectory information representing the motion trajectory of the front end point of the robot that has moved according to the program; an error calculation unit that calculates the error between the first trajectory information and the second trajectory information; and a teaching point addition unit that adds teaching points on the trajectory of the first trajectory information until the error is below the allowable value.

[0012] The program writing method of the present disclosure is used to generate a program from trajectory information representing the motion trajectory of the front end point of a robot. The program writing method includes the following steps: generating first trajectory information representing the motion trajectory of the front end point of the robot according to the motion command of the robot; generating teaching points on the trajectory of the first trajectory information; generating a program of the first trajectory information for which the teaching points have been generated; acquiring second trajectory information representing the motion trajectory of the front end point of the robot that has moved according to the program; calculating the error between the first trajectory information and the second trajectory information; and adding teaching points on the trajectory of the first trajectory information until the error is below the allowable value.

[0013] The program of the present disclosure is used to cause a computer to execute a program writing method including the steps described in the above program writing method. Description of the Drawings

[0014] Figure 1 It is a structural diagram of a robot control system 1 according to an embodiment of the present disclosure.

[0015] Figure 2 It is a block diagram showing the functional structure of a robot control device 4.

[0016] Figure 3 It is a block diagram showing the functional structure of a program writing unit 150.

[0017] Figure 4A It is a diagram showing the process of generating teaching points on the first trajectory information.

[0018] Figure 4B It is a diagram showing the process of generating teaching points on the first trajectory information.

[0019] Figure 4C It is a diagram showing the process of generating teaching points on the first trajectory information.

[0020] Figure 4D This is a diagram showing the process of generating a teaching point for the first trajectory information.

[0021] Figure 4E This is a diagram showing the process of generating a teaching point for the first trajectory information.

[0022] Figure 4F This is a diagram showing the process of generating a teaching point for the first trajectory information.

[0023] Figure 4G This is a diagram showing the process of generating a teaching point for the first trajectory information.

[0024] Figure 5A This is a diagram showing the process of making the second trajectory information approach the first trajectory information.

[0025] Figure 5B This is a diagram showing the process of making the second trajectory information approach the first trajectory information.

[0026] Figure 5C This is a diagram showing the process of making the second trajectory information approach the first trajectory information.

[0027] Figure 6 This is a flowchart showing the process of programming the first trajectory information executed by the program management unit 15.

[0028] Figure 7 This is a flowchart showing the process of programming the first trajectory information executed by the program management unit 15. Detailed implementation mode

[0029] Hereinafter, a programming device, a programming method, and a program according to an aspect of the present disclosure will be described. Figure 1 This is a structural diagram of the robot control system 1 according to an embodiment of the present disclosure. Figure 2 This is a block diagram showing the functional structure of the robot control device 4. Figure 3 This is a block diagram showing the functional structure of the programming unit 150.

[0030] As Figure 1 shown, the robot control system 1 of the embodiment includes a numerical control device 2 that controls the machine tool 3, a robot control device 4, and a robot 5. In the robot control system 1, the numerical control device 2, the robot control device 4, and the robot 5 are respectively connected via a communication line (the black solid line in the figure).

[0031] The numerical control device 2 generates a machine tool command signal and a robot command signal as commands for the machine tool 3 in accordance with a numerical control program, and transmits these machine tool command signals and robot command signals to the machine tool 3 and the robot 5, respectively. When the numerical control device 2 of the embodiment controls the robot 5 in real time, it transmits the robot command signal to the robot control device 4 at a short cycle (for example, 40 msec). The numerical control device 2 becomes an external control device when controlling the robot 5 via the robot control device 4. That is, the numerical control device 2 is a control device (second control device) different from the robot control device 4 (described later) that directly controls the robot.

[0032] The machine tool 3 processes a workpiece (not shown) based on the machine tool command signal transmitted from the numerical control device 2. The machine tool 3 is, for example, a lathe, a drill press, a milling machine, a grinding machine, a laser processing machine, an injection molding machine, etc., but is not limited thereto.

[0033] The robot control device 4 is a control device (first control device) that directly controls the operation of the robot 5. The robot control device 4 is communicably connected to the numerical control device 2 and controls the operation of the robot 5 based on the robot command signal transmitted from the numerical control device 2. The structure of the robot control device 4 will be described later.

[0034] The robot 5 is provided near the machine tool 3 and operates under the control of the robot control device 4. The robot 5, for example, performs a predetermined operation on a workpiece being processed inside a machine tool 3 such as a lathe. The robot 5 is, for example, an articulated robot. A tool 5b is attached to the front end portion 5a of the arm of the robot 5, and this tool 5b is used for gripping, processing, or inspecting the workpiece. In the embodiment, an example in which the robot 5 is a 6-axis articulated robot is described, but the number of axes of the joints of the robot 5 is not limited thereto.

[0035] The numerical control device 2 and the robot control device 4 are, for example, computers having hardware resources such as an arithmetic processing unit such as a CPU (Central Processing Unit), an auxiliary storage unit such as an HDD (Hard Disk Drive) and an SSD (Solid State Drive) that store various computer programs, a main storage unit such as a RAM (Random Access Memory) that temporarily stores data when the arithmetic processing unit executes a computer program, an operation unit such as a keyboard and a mouse for the operator to input various instructions, information, etc., and a display unit such as a display that displays various information. The numerical control device 2 and the robot control device 4 are configured to be able to mutually transmit and receive various signals, for example, via a wired LAN.

[0036] Next, the structure of the robot control device 4 will be described. As Figure 2 shown, the robot control device 4 implements various functions such as the storage unit 11, the data transceiver unit 12, the analysis unit 13, the robot motion command generation unit 14, the program management unit 15, the trajectory control unit 16, the kinematics control unit 17, the servo control unit 18, etc. through the above-mentioned hardware resources. Specifically, the robot control device 4 controls the motion of the robot 5 according to various instruction signals sent from the numerical control device 2 by using the storage unit 11, the data transceiver unit 12, the analysis unit 13, the robot motion command generation unit 14, the program management unit 15, the trajectory control unit 16, the kinematics control unit 17, and the servo control unit 18.

[0037] The storage unit 11 stores various programs for making the robot move, information indicating the positions of various axes of the machine tool 3, information related to the positions and postures of the control points of the robot, information related to the teaching points of the robot, etc.

[0038] The data transceiver unit 12 receives the robot instruction signals sent from the numerical control device 2. In addition, the data transceiver unit 12 sequentially outputs the received robot instruction signals to the analysis unit 13.

[0039] The analysis unit 13 analyzes the robot instruction signals input from the data transceiver unit 12. In addition, the analysis unit 13 outputs its analysis result to the robot motion command generation unit 14.

[0040] The robot motion command generation unit 14 generates a robot motion command (hereinafter also referred to as "motion command") corresponding to the robot instruction signal according to the analysis result of the robot instruction signal input from the analysis unit 13. The robot motion command generation unit 14 outputs the generated motion command to the program management unit 15. In addition, the robot instruction signals are sent from the numerical control device 2 in a short cycle. Therefore, in the robot motion command generation unit 14, the motion commands are also generated in the same cycle and output to the program management unit 15.

[0041] By inputting the motion command from the robot motion command generation unit 14 to the program management unit 15, the program management unit 15 sequentially executes the motion command in real time. The program management unit 15 generates a motion plan for the robot 5 corresponding to the above-mentioned motion command and outputs the motion plan to the trajectory control unit 16. Thereby, the motion of the robot 5 can be controlled in real time. In addition, for example, when the program management unit 15 repeats the motion of the robot 5 that has been executed once, it makes the robot 5 move according to the program of the first trajectory information (described later) stored in the storage unit 11.

[0042] The program management department 15 has a program writing department (program writing device) 150. The program writing department 150 generates trajectory information representing the movement trajectory of the front end point of the robot 5 as a program based on the robot instruction signal sent from the numerical control device 2. In addition, when the robot 5 is moved by the program generated by the program writing department 150, the program management department 15 generates a motion plan based on the trajectory information of the robot described in the program, and outputs the motion plan to the trajectory control department 16. The function of the program writing department 150 will be described in detail later.

[0043] When a motion plan is input from the program management department 15 to the trajectory control department 16, the trajectory control department 16 calculates the time series data of the control points of the robot 5, and outputs the time series data to the kinematic control department 17.

[0044] The kinematic control department 17 calculates the target angles of the respective joints of the robot 5 based on the input time series data, and outputs the target angles to the servo control department 18.

[0045] The servo control department 18 performs feedback control on the respective servo motors of the robot 5 in order to achieve the target angles input from the kinematic control department 17, thereby generating a robot control signal for the robot 5, and inputting the robot control signal to the servo motors of the robot 5. Thus, the robot 5 moves according to the motion plan generated by the program management department 15.

[0046] Next, the program writing department 150 will be described.

[0047] The program writing department 150 generates trajectory information representing the movement trajectory of the front end point of the robot 5 as a program based on the robot instruction signal sent from the numerical control device 2, and stores it in the storage department 11. This program is used when the robot 5 is directly controlled not by the numerical control device 2 but by the robot control device 4. In the embodiment, the front end point of the robot 5 is, for example, the front end portion 5a of the arm of the robot 5 (refer to Figure 1 ).

[0048] As Figure 3 shown, the program writing department 150 includes a first trajectory information generation department 151, a teaching point generation department 152, a program generation department 153, a second trajectory information generation department 154, an error calculation department 155, and a teaching point addition department 156. The following describes the processes executed by each part constituting the program writing department 150 and specific examples thereof with reference to the drawings. Figures 4A to 4G is a diagram showing the process of generating a teaching point for the first trajectory information. Figures 5A to 5C is a diagram showing the process of making the second trajectory information approach the first trajectory information. Processes such as generating a virtual straight line for the trajectory information or generating a teaching point are, for example, executed on the virtual space of the storage department 11.

[0049] The first trajectory information generation unit 151 records the motion commands generated by the robot motion command generation unit 14 until the motion of the robot 5 ends. Then, the first trajectory information generation unit 151 generates three-dimensional first trajectory information representing the motion trajectory (including posture) of the front end point of the robot 5 based on the stored motion commands of the robot 5. Specifically, the first trajectory information generation unit 151 obtains the trajectory (point sequence) DL of the front end point of the robot 5 at each fixed time as shown in Figure 4A . In Figure 4A , for easy understanding, the size and interval of the points are schematically depicted.

[0050] In addition, in the embodiment, the three-dimensional trajectory information (first trajectory information, second trajectory information) is described as a two-dimensional curve. The posture of the front end point of the robot 5 is determined by, for example, the rotation angle of the axis for driving the front end portion 5a of the arm of the robot 5 (refer to Figure 1 ), and continuously changes from the start point to the end point of the motion trajectory.

[0051] Then, the first trajectory information generation unit 151 generates a spline curve (spline function) SC passing through the obtained trajectory as shown in Figure 4B . Hereinafter, the curve representing the motion trajectory of the front end point of the robot as shown in Figure 4B is also referred to as "first trajectory information" or "first trajectory information LO1". In addition, in the motion trajectory, there may be not only a curve portion but also a straight line portion, but in this specification, they are collectively referred to as "curve".

[0052] The teaching point generation unit 152 generates teaching points on the trajectory of the first trajectory information. Specifically, the teaching point generation unit 152 sets a start point p1 and an end point p2 on the first trajectory information LO1 as shown in Figure 4C , and further virtually generates a straight line L1 between the start point p1 and the end point p2 as shown in Figure 4D . Then, the teaching point generation unit 152 determines whether there is a point whose distance from the straight line L1 is equal to or greater than the threshold and is the farthest. In the case where there is a matching point, the teaching point generation unit 152 generates a teaching point t1 at that point as shown in Figure 4E . The threshold of the distance serving as the basis for the above determination is set, for example, by being input by the operator via an operation unit (not shown).

[0053] When teaching points are generated on the first trajectory information (when the teaching points are established), the teaching point generation unit 152 further as shown in Figure 4FAs shown, a virtual straight line L2 is newly generated between the starting point p1 and the teaching point t1, and a virtual straight line L3 is newly generated between the teaching point t1 and the ending point p2. Then, the teaching point generation unit 152 determines whether there is a point whose distance from each straight line is equal to or greater than the threshold value and is the farthest. If there is a corresponding point, a teaching point is generated at that point. In Figure 4G the following example is shown: a teaching point t2 is generated at a point whose distance from the straight line L2 is equal to or greater than the threshold value and is the farthest, and a teaching point t3 is generated at a point whose distance from the straight line L3 is equal to or greater than the threshold value and is the farthest. The teaching point generation unit 152 repeats the above process until there is no point whose distance from the straight line is equal to or greater than the threshold value.

[0054] As Figure 4G shown, when there are two or more teaching points generated between the starting point and the ending point, the teaching point generation unit 152 not only virtually generates straight lines between the starting point and the ending point and their adjacent teaching points, but also virtually generates straight lines between adjacent teaching points on the curve. When there is no point whose distance from the straight line is equal to or greater than the threshold value and is the farthest (when the teaching point is not established), the teaching point generation unit 152 ends the process of generating teaching points.

[0055] In Figure 4G the example shown, the teaching point generation unit 152 respectively generates virtual straight lines (not shown) between the starting point p1 and the teaching point t2, between the teaching points t2 and t1, between the teaching points t1 and t3, and between the teaching point t3 and the ending point p2, and determines whether there is a point whose distance from each straight line is equal to or greater than the threshold value and is the farthest. In Figure 4G the example shown, it is assumed that a new teaching point is not established in the determination based on the above straight line generated from the first trajectory information. In the embodiment, Figure 4G the curve shown becomes the first trajectory information of the initially generated teaching points.

[0056] Return to Figure 3 , the program generation unit 153 generates a program for the first trajectory information with the generated or added teaching points, or generates a program for the first trajectory information whose distance error has become equal to or less than the allowable value. The program generation unit 153 uses an action command that causes the front end point of the robot 5 to pass through the positions of the teaching points to generate a program for the first trajectory information. Here, the action command that causes the front end point of the robot 5 to pass through the positions of the teaching points is a command for a program that is set to pass through the positions of all teaching points on the trajectory. For example, a spline interpolation action command can also be used.

[0057] The program management unit 15 operates the robot 5 according to the program of the first trajectory information generated by the program generation unit 153. In addition, by outputting the motion plan generated by the program management unit 15 to the trajectory control unit 16, the operation of the robot 5 is executed via the kinematic control unit 17 and the servo control unit 18. The process of generating the program of the first trajectory information having a teaching point on the trajectory in the program generation unit 153 is repeatedly executed whenever a teaching point is added in the teaching point addition unit 156 (described later).

[0058] The second trajectory information generation unit 154 acquires the second trajectory information indicating the motion trajectory of the front end point of the robot 5 that has moved according to the program of the first trajectory information in the program management unit 15. The process of acquiring the second trajectory information in the second trajectory information generation unit 154 is repeatedly executed whenever a teaching point is added to the first trajectory information in the teaching point addition unit 156 (described later).

[0059] The error calculation unit 155 calculates the error between the first trajectory information and the second trajectory information. Figure 5A It is a diagram in which the curve of the second trajectory information is superimposed on the curve of the first trajectory information. In Figure 5A it, the solid line represents the curve of the first trajectory information LO1. The dashed line represents the curve of the second trajectory information LO2 when the robot 5 actually moves. The error calculation unit 155 calculates the error e between the first trajectory information LO1 and the second trajectory information LO2, for example, in the interval between the teaching point t3 and the end point p2 shown in Figure 5A . In addition, between the start point p1 and the teaching point t2, between the teaching points t2 and t1, and between the teaching points t1 and t3, the error between the first trajectory information LO1 and the second trajectory information LO2 is calculated in these intervals.

[0060] The error calculated by the error calculation unit 155 includes not only the error in the distance between the two curves but also the error in the posture. The error in the posture is the error between the two curves in the three-dimensional coordinate space. As shown in the flowchart (after step S19) described later, the error calculation unit 155 calculates the error in the posture of the two curves when the error in the distance between the two curves has become below the allowable value.

[0061] The error calculation in the error calculation unit 155 can be performed, for example, using the following method. First, project the curves of the two pieces of trajectory information onto the X plane respectively to obtain two-dimensional (X-Y) curves. Then, compare the two two-dimensional curves and compare the difference in the Z-axis values and the difference in the wrp angles at specific Y-axis values. This process is also performed not only for the X plane but also for the Y plane and the Z plane. In addition, the curve can be segmented at the positions of the teaching points, the plane passing through the straight line connecting the start point and the end point of the segmented curve and the point farthest from the straight line can be calculated, and the error between the curves of the two pieces of trajectory information can be calculated for this plane. Alternatively, points that divide the curves into specified equal parts can be set on the curves of the two pieces of trajectory information, and the distances between the points of the two curves can be calculated as the error of the curves.

[0062] The teaching point addition unit 156 determines whether the distance or pose error calculated by the error calculation unit 155 is below the allowable value. The allowable value of the distance or pose error is input by the operator to the program management unit 15 in advance. In the case where there is an interval in which the distance or pose error exceeds the allowable value, for example, when the distance error e exceeds the allowable value in the interval between the teaching point t3 and the end point p2 of the first trajectory information LO1 as shown in Figure 5B , the teaching point addition unit 156 adds a teaching point tX at the point (position) where the error e is the largest. In other intervals, a teaching point is also added when the distance error e exceeds the allowable value. The teaching point addition unit 156 adds a teaching point at at least one position in the point sequence (refer to Figure 4A ) that forms the basis of the first trajectory information. Although not shown, the teaching point addition unit 156 adds a teaching point at the point where the pose error is the largest in the first trajectory information LO1. After the teaching point addition unit 156 adds a teaching point, the program generation unit 153 generates a program for the first trajectory information with the added teaching point.

[0063] The teaching point addition unit 156 repeats the process of adding teaching points on the trajectory of the first trajectory information until the distance or pose error is below the allowable value. Each time a teaching point is added in the teaching point addition unit 156, the distance or pose error becomes smaller. Thus, the second trajectory information can be made to approach the first trajectory information. On the other hand, when the teaching point addition unit 156 determines that the distance or pose error is below the allowable value, as will be described later, the program of the first trajectory information is stored in the storage unit 11 as a program representing the motion trajectory of the front end point of the robot 5.

[0064] As described above, the program generation unit 153 generates a program of the first trajectory information with the teaching points added by the teaching point addition unit 156. The program management unit 15 operates the robot 5 according to the program of the first trajectory information newly generated by the program generation unit 153. The second trajectory information generation unit 154 acquires the second trajectory information, which represents the movement trajectory of the front end point of the robot 5 that has moved according to the program of the newly created first trajectory information. In addition, when the robot 5 is operated according to the program of the first trajectory information with the teaching points added, not only the part where the teaching points are added but also the whole curve of the second trajectory information changes. In the error calculation unit 155, the distance or pose error between the first trajectory information and the second trajectory information is calculated. Further, in the teaching point addition unit 156, it is determined whether the distance or pose error becomes equal to or less than the allowable value.

[0065] The program writing unit 150 repeats the process of adding teaching points to the trajectory of the first trajectory information in the teaching point addition unit 156 until it is determined that the distance or pose error is equal to or less than the allowable value. Thus, for example, as Figure 5C shown, it is possible to converge the distance or pose error between the first trajectory information LO1 and the second trajectory information LO2 to be equal to or less than the allowable value in each interval. Figure 5C The program of the first trajectory information shown is stored in the storage unit 11 by the program management unit 15 as a program of trajectory information representing the movement trajectory of the front end point of the robot 5.

[0066] Next, a specific example of the program writing process of the first trajectory information in the embodiment will be described. Figure 6 And Figure 7 are flowcharts showing the process of the program writing process of the first trajectory information executed by the program management unit 15. In addition, before the program writing process in the embodiment, the program management unit 15 generates an operation command according to the robot instruction signal sent from the numerical control device 2 and operates the robot 5 through this operation command.

[0067] In Figure 6 step S11 shown, the first trajectory information generation unit 151 records the operation commands generated by the robot operation command generation unit 14 until the operation of the robot 5 ends. Then, the first trajectory information generation unit 151 generates the first trajectory information representing the movement trajectory of the front end point of the robot 5 according to the operation commands of the robot 5.

[0068] In step S12, the teaching point generation unit 152 generates teaching points on the trajectory of the first trajectory information according to the threshold value.

[0069] In step S13, the program generation unit 153 generates a program of the first trajectory information with the generated or added teaching points.

[0070] In step S14, the program management unit 15 operates the robot 5 according to the program of the first trajectory information.

[0071] In step S15, the second trajectory information generation unit 154 acquires second trajectory information, which represents the movement trajectory of the front end point of the robot 5 that has moved according to the program of the first trajectory information.

[0072] In step S16, the error calculation unit 155 calculates the error of the distance between the first trajectory information and the second trajectory information.

[0073] In step S17, the teaching point addition unit 156 determines whether the error of the distance becomes equal to or less than the allowable value. When it is determined by the teaching point addition unit 156 in step S17 that the error of the distance is equal to or less than the allowable value, the process proceeds to step S19 (refer to Figure 7 ). On the other hand, when it is determined by the teaching point addition unit 156 in step S17 that the error of the distance exceeds the allowable value, the process proceeds to step S18.

[0074] In step S18 (step S17: No), the teaching point addition unit 156 adds a teaching point to the first trajectory information. After step S18, the process returns to step S13, and the above-described processes of steps S13 to S17 are performed according to the first trajectory information to which the teaching point has been added. The teaching point addition unit 156 repeatedly executes the process of adding a teaching point to the trajectory of the first trajectory information until the error of the distance becomes equal to or less than the allowable value in step S17.

[0075] In Figure 7 In step S19 (step S17: Yes) shown, the program generation unit 153 generates a program of the first trajectory information for which the error of the distance has become equal to or less than the allowable value (hereinafter also referred to as "corrected program").

[0076] In step S20, the program management unit 15 operates the robot 5 according to the corrected program of the first trajectory information.

[0077] In step S21, the second trajectory information generation unit 154 acquires second trajectory information, which represents the movement trajectory of the front end point of the robot 5 that has moved according to the corrected program of the first trajectory information.

[0078] In step S22, the error calculation unit 155 calculates the error of the posture between the first trajectory information for which the error of the distance has become equal to or less than the allowable value and the second trajectory information acquired in step S21.

[0079] In step S23, the teaching point addition unit 156 determines whether the error in the posture is equal to or less than the allowable value. When it is determined by the teaching point addition unit 156 in step S23 that the error in the posture is equal to or less than the allowable value, the processing of this flowchart ends. On the other hand, when it is determined by the teaching point addition unit 156 in step S23 that the error in the posture exceeds the allowable value, the processing proceeds to step S24.

[0080] In step S24 (step S23: No), the teaching point addition unit 156 adds a teaching point to the first trajectory information. After step S24, the processing returns to step S19. Thereafter, the above-described processing of steps S20 to S23 is performed based on the first trajectory information to which the teaching point has been added. The teaching point addition unit 156 repeatedly executes the process of adding a teaching point to the trajectory of the first trajectory information until the error in the posture is equal to or less than the allowable value in step S23. When it is determined in step S23 that the error in the posture is equal to or less than the allowable value, the processing of this flowchart ends.

[0081] According to the robot control device 4 of the above-described embodiment, for example, the following effects can be exhibited.

[0082] The robot control device 4 includes a program writing unit 150 that compares the first trajectory information generated based on the motion command from the external numerical control device 2 with the second trajectory information that becomes the motion trajectory of the robot that has moved according to the program of the first trajectory information, and adds a teaching point to the first trajectory information until the distance and the error in the posture between the two are equal to or less than the allowable value. Thereby, the robot control device 4 can generate a program of the first trajectory information having the same motion trajectory (including the posture) as the case of controlling the robot in real time by the motion command from the numerical control device 2 as a program with fewer teaching points.

[0083] The program generation unit 153 generates a program of the first trajectory information using a motion command that causes the front end point of the robot to pass through the position of the teaching point. Thus, there is no need to set a target trajectory with points that are not on the ideal trajectory as intermediate points and perform the operation of previously learning the error when controlling the robot as in Patent Document 1. Therefore, when the path of the motion trajectory of the robot is complex, since there is no need to perform a large amount of learning operations in advance, the program of the robot can be generated in a shorter time.

[0084] The first trajectory information generated in the first trajectory information generation unit 151 is composed of a point sequence representing the position of the front end point of the robot. Therefore, when executing the program of the first trajectory information generated by the program generation unit 153, the motion in the case of controlling the robot by the numerical control device 2 can be reproduced more faithfully.

[0085] The teaching point addition unit 156 adds a teaching point at at least one position of the point sequence (reference Figure 4A ) that is the basis of the first trajectory information. Therefore, compared with the case of adding teaching points at positions far from the curve as in Patent Document 1, the trajectory when actually moving the robot can be made closer to the trajectory of the first trajectory information with a smaller number of teaching points.

[0086] The program generation unit 153 generates a program for the first trajectory information based on the teaching points generated on the trajectory of the first trajectory information. Therefore, in the program generation unit 153, by applying methods such as spline interpolation to the teaching points on the trajectory, a program that reproduces an action closer to the actual action of the robot can be generated.

[0087] The first trajectory information generation unit 151 obtains an operation instruction of the robot 5 from a numerical control device 2 (second control device) different from the robot control device 4 (first control device) that directly controls the robot. Therefore, when the robot control device 4 desires to repeat the operation of the robot that has been performed once, the robot can operate in the same manner as when the robot is controlled in real time.

[0088] (Modified embodiment)

[0089] The above-described embodiments of the present disclosure have been described, but the present disclosure is not limited to the above-described embodiments. These embodiments can be variously added, replaced, changed, partially deleted, etc. within the scope not departing from the gist of the present disclosure or within the scope not departing from the spirit of the present disclosure derived from the content described in the claims and its equivalents. In addition, these embodiments can also be implemented in combination. For example, in the above-described embodiments, the order of each action and the order of each process are shown as an example and are not limited to these orders.

[0090] In the embodiment of the present disclosure, the robot control device 4 may configure all hardware resources in the same housing, or may be dispersedly configured in a plurality of housings.

[0091] In the embodiment of the present disclosure, an example in which one robot control device 4 is connected to one numerical control device 2 is shown, but it is not limited thereto. It may also be configured such that a plurality of robot control devices 4 are connected to one or a plurality of numerical control devices 2.

[0092] Regarding the above-described embodiments, the following additional notes are further disclosed.

[0093] (Additional note 1)

[0094] A program writing device (150) generates a program from trajectory information representing the motion trajectory of the front end point of a robot. The program writing device includes: a first trajectory information generation unit (151) that generates first trajectory information representing the motion trajectory of the front end point of the robot according to the motion command of the robot; a teaching point generation unit (152) that generates teaching points on the trajectory of the first trajectory information; a program generation unit (153) that generates a program of the first trajectory information for which the teaching points have been generated; a second trajectory information generation unit (154) that acquires second trajectory information representing the motion trajectory of the front end point of the robot that has moved according to the program; an error calculation unit (155) that calculates the error between the first trajectory information and the second trajectory information; and a teaching point addition unit (156) that adds teaching points on the trajectory of the first trajectory information until the error is below an allowable value.

[0095] (Supplementary Note 2)

[0096] The program generation unit (153) generates a program of the first trajectory information using a motion command that causes the front end point of the robot to pass through the positions of the teaching points.

[0097] (Supplementary Note 3)

[0098] The first trajectory information is composed of a point sequence representing the positions of the front end points of the robot.

[0099] (Supplementary Note 4)

[0100] The teaching point addition unit (156) adds teaching points at at least one position in the point sequence.

[0101] (Supplementary Note 5)

[0102] The program generation unit (153) generates a program of the first trajectory information according to the teaching points generated on the trajectory of the first trajectory information.

[0103] (Supplementary Note 6)

[0104] The first trajectory information generation unit (151) acquires the motion command of the robot from a second control device (2) different from a first control device (4) that directly controls the robot.

[0105] (Supplementary Note 7)

[0106] A program writing method for generating a program from trajectory information representing the motion trajectory of the front end point of a robot, the program writing method comprising the following steps: generating first trajectory information representing the motion trajectory of the front end point of the robot according to a motion command of the robot; generating teaching points on the trajectory of the first trajectory information; generating a program of the first trajectory information on which the teaching points have been generated; obtaining second trajectory information representing the motion trajectory of the front end point of the robot that has moved by the program; calculating the error between the first trajectory information and the second trajectory information; and adding teaching points to the trajectory of the first trajectory information until the error is below an allowable value.

[0107] (Appendix 8)

[0108] A program for causing a computer to execute a program writing method including each step described in the above program writing method.

[0109] Description of reference numerals

[0110] 1: Robot control system; 2: Numerical control device; 3: Machine tool; 4: Robot control device; 5: Robot; 5a: Arm tip; 11: Storage unit; 12: Data transceiver; 13: Analysis unit; 14: Robot motion command generation unit; 15: Program management unit; 16: Trajectory control unit; 17: Kinematics control unit; 18: Servo control unit; 51: First trajectory information production unit; 150: Program writing unit; 151: First trajectory information generation unit; 152: Teaching point generation unit; 153: Program generation unit; 154: Second trajectory information generation unit; 155: Error calculation unit; 156: Teaching point addition unit.

Claims

1. A program writing device for generating a program from trajectory information representing the motion trajectory of the front end point of a robot, the program writing device comprising: A first trajectory information generation unit that generates first trajectory information representing the motion trajectory of the front end point of the robot according to the motion command of the robot; A teaching point generation unit that generates teaching points on the trajectory of the first trajectory information; A program generation unit that generates a program of the first trajectory information for which the teaching points have been generated; A second trajectory information generation unit that acquires second trajectory information representing the motion trajectory of the front end point of the robot that has moved according to the program; An error calculation unit that calculates the error between the first trajectory information and the second trajectory information; and A teaching point addition unit that adds teaching points to the trajectory of the first trajectory information until the error is below the allowable value.

2. The program writing device according to claim 1, wherein, The program generation unit generates a program of the first trajectory information using a motion command that causes the front end point of the robot to pass through the position of the teaching point.

3. The program writing device according to claim 1 or 2, wherein, The first trajectory information is composed of a point sequence representing the position of the front end point of the robot.

4. The program writing device according to claim 3, wherein, The teaching point addition unit adds teaching points at at least one position of the point sequence.

5. The program writing device according to any one of claims 1 to 4, wherein, The program generation unit generates a program of the first trajectory information according to the teaching points generated on the trajectory of the first trajectory information.

6. The program writing device according to any one of claims 1 to 5, wherein, The first trajectory information generation unit acquires the motion command of the robot from a second control device different from the first control device that directly controls the robot.

7. A program writing method for generating a program from trajectory information representing the motion trajectory of the front end point of a robot, the program writing method comprises the following steps: Generating first trajectory information representing the motion trajectory of the front end point of the robot according to the motion command of the robot; Generating teaching points on the trajectory of the first trajectory information; Generating a program of the first trajectory information for which the teaching points have been generated; Acquiring second trajectory information representing the motion trajectory of the front end point of the robot that has moved according to the program; Calculating the error between the first trajectory information and the second trajectory information; and Adding teaching points to the trajectory of the first trajectory information until the error is below the allowable value.

8. A program for causing a computer to execute the program writing method including the steps according to claim 7.

Citation Information

Patent Citations

  • Control device, robot system, learning device, control method, and program

    WO2022176761A1