CN116736797A - Four-axis equipment interpolation calibration method and device, computer equipment and storage medium thereof - Google Patents

Four-axis equipment interpolation calibration method and device, computer equipment and storage medium thereof Download PDF

Info

Publication number
CN116736797A
CN116736797A CN202310546210.XA CN202310546210A CN116736797A CN 116736797 A CN116736797 A CN 116736797A CN 202310546210 A CN202310546210 A CN 202310546210A CN 116736797 A CN116736797 A CN 116736797A
Authority
CN
China
Prior art keywords
vector
rotation
interpolation
rotating shaft
center
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202310546210.XA
Other languages
Chinese (zh)
Inventor
黄爱林
李国庆
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Shizong Automation Equipment Co Ltd
Original Assignee
Shenzhen Shizong Automation Equipment Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Shizong Automation Equipment Co Ltd filed Critical Shenzhen Shizong Automation Equipment Co Ltd
Priority to CN202310546210.XA priority Critical patent/CN116736797A/en
Publication of CN116736797A publication Critical patent/CN116736797A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B19/00Programme-control systems
    • G05B19/02Programme-control systems electric
    • G05B19/18Numerical control [NC], i.e. automatically operating machines, in particular machine tools, e.g. in a manufacturing environment, so as to execute positioning, movement or co-ordinated operations by means of programme data in numerical form
    • G05B19/41Numerical control [NC], i.e. automatically operating machines, in particular machine tools, e.g. in a manufacturing environment, so as to execute positioning, movement or co-ordinated operations by means of programme data in numerical form characterised by interpolation, e.g. the computation of intermediate points between programmed end points to define the path to be followed and the rate of travel along that path
    • G05B19/4103Digital interpolation
    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B2219/00Program-control systems
    • G05B2219/30Nc systems
    • G05B2219/34Director, elements to supervisory
    • G05B2219/34117Machine workpiece along, parallel to largest dimension

Landscapes

  • Engineering & Computer Science (AREA)
  • Computing Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Manufacturing & Machinery (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Automation & Control Theory (AREA)
  • Numerical Control (AREA)

Abstract

The invention discloses a four-axis equipment interpolation calibration method, a device, computer equipment and a storage medium thereof, wherein the calibration method comprises the following steps: controlling a rotating shaft of the four-axis device to rotate, and enabling an executing piece to be aligned to a characteristic point on a calibration piece, wherein the calibration piece is arranged on the rotating shaft; acquiring coordinate data of an executing piece when the rotating shaft rotates each time and aligning with a feature point, and determining a center coordinate and a rotating vector of the rotating shaft according to the coordinate data, wherein the rotating shaft rotates at least three times to acquire at least three coordinate data of the feature point; and calculating interpolation coordinates according to the coordinate data, the central coordinates of the rotating shaft and the rotating vector, and obtaining the actual coordinates of each interpolation line segment. According to the four-axis equipment interpolation calibration method provided by the embodiment of the invention, the automatic calibration of the rotating shaft of the numerical control system is realized, the calibration process can be realized rapidly and automatically, and the calibration result is accurate and reliable.

Description

Four-axis equipment interpolation calibration method and device, computer equipment and storage medium thereof
Technical Field
The invention relates to the technical field of multi-axis machining, in particular to a four-axis equipment interpolation calibration method, a device, computer equipment and a storage medium thereof.
Background
A four-axis machining apparatus is an advanced numerical control machining apparatus having three linear axes and one rotational axis, which can perform machining or dispensing in a plurality of directions, thereby achieving more complex, finer machining requirements. However, to fully exploit the potential of a four-axis machining device, it is necessary to accurately calibrate it, which is the importance of rotation axis calibration technology.
The purpose of the rotation axis calibration is to find the rotation center and the rotation vector of a single rotation axis, thereby realizing the RTCP function. RTCP, rotated Tool Center Point, is a nose point follower function. In the four-axis machining process, the tool nose point locus and the posture between the tool and the workpiece are pursued. Because the rotary motion causes additional motion of the tool nose point, the control point of the numerical control system is often not overlapped with the tool nose point, so that the numerical control system needs to automatically correct the control point to ensure that the tool nose point moves according to the set track of the instruction. Various parameters of the four-axis device must be known in order to implement the RTCP function.
In the field of rotation shaft calibration of four-axis processing equipment, there are several main calibration methods.
Direct measurement: this method is calibrated by directly measuring the position and orientation of the rotating shaft. This typically requires the use of high precision measurement equipment such as a laser interferometer or ball grid dividing head. Direct measurement has the advantage of being simple and intuitive, but has the disadvantage that measurement errors can be large, especially when measuring large machine tools. In addition, such methods may be affected by environmental factors such as temperature, humidity, etc.
Indirect measurement: the method is to indirectly determine the position and direction of the rotation axis by measuring the locus of the point of the knife on the workpiece. This typically requires the use of a trigger probe or an optical measurement system. The indirect measurement method has the advantage of being capable of calibrating in the actual machining process, but has the defect of being possibly influenced by factors such as cutter abrasion, probe errors and the like.
The machine vision-based calibration method comprises the following steps: the method is to capture the track of the tool tip point on the workpiece by installing a camera or other visual sensors, and then to calibrate by using a computer visual algorithm. The calibration method based on machine vision has the advantages that a non-contact and real-time calibration process can be realized, but the method has the defects of being possibly influenced by factors such as illumination conditions, camera resolution and the like, and in addition, the calibration is complex and long in time.
Disclosure of Invention
The present invention aims to solve at least one of the technical problems in the related art to some extent. Therefore, the invention aims to provide a four-axis device interpolation calibration method, a device, a computer device and a storage medium thereof.
To achieve the above object, in a first aspect, a four-axis device interpolation calibration method according to an embodiment of the present invention includes:
controlling a rotating shaft of the four-axis device to rotate, and enabling an executing piece to be aligned to a characteristic point on a calibration piece, wherein the calibration piece is arranged on the rotating shaft;
acquiring coordinate data of an executing piece when the rotating shaft rotates each time and aligning with a feature point, and determining a center coordinate and a rotating vector of the rotating shaft according to the coordinate data, wherein the rotating shaft rotates at least three times to acquire at least three coordinate data of the feature point;
and calculating interpolation coordinates according to the coordinate data, the central coordinates of the rotating shaft and the rotating vector, and obtaining the actual coordinates of each interpolation line segment.
According to an embodiment of the present invention, determining the center coordinates of the rotation axis from the coordinate data includes:
fitting a spherical surface by adopting a least square method according to the coordinate data;
calculating the spherical center coordinates of the sphere according to the fitting sphere;
wherein, the space sphere equation: (X-a) 2+ (Y-b) 2+ (Z-c) 2=r 2 R is the radius of the sphere;
expanding the space sphere equation to obtain: x2+y2+z2-2aX-2 bY-2cz+a2+b2+c2=r 2
Setting: a=2a; b=2b; c=2c; d=a2+b2+c2-R 2
Then: x2+y2+z2-AX-BX-cx+d=0;
the least squares fit sphere: v=Σ (x2+y2+z2-AX-BX-cx+d) 2, calculating V as the minimum value, and obtaining A, B, C value, then obtaining the spherical center coordinates: a=a/2; b=b/2; c=c/2.
According to one embodiment of the invention, the rotation vector is calculated using the following formula:
rotation vector ijk=
Vector A1(X1-centerX,Y1-centerY,Z1-centerZ);
Vector A2(X2-centerX,Y2-centerY,Z2-centerZ);
Vector A3(X3-centerX,Y3-centerY,Z3-centerZ);
Vector A5=A2-A1;
Vector A6=A3-A1;
Vector a7=a5.cross (A6); /(cross multiplication)
Double len=sqrt(A7.X^+A7.Y^+A7.Z^);
Double i=A7.X/len;
Double j=A7.Y/len;
Double k=A7.Z/len;
Where center X, center Y, center Z is the calculated center coordinates a, b, c, X1, X2, X3Y 1, Y2, Y3, Z1, Z2, Z3 are the coordinates of three points on the sphere that are not collinear.
According to one embodiment of the present invention, performing interpolation coordinate calculation according to the coordinate data, the center coordinates of the rotation axis, and the rotation vector, to obtain the actual coordinates of each interpolation line segment includes:
according to the coordinate data, the center coordinates of the rotating shaft and the rotating vector, an inverse solution is obtained through the following kinematic formula;
Quaterniond q(rotation_vector);
Vector target=q*(rotationPos-centerV)+centerV;
the rotation_vector is a rotation vector IJK and comprises a designated angle gesture, and q is a quaternion of the rotation vector and the angle gesture contained in the rotation_vector;
target is the actual coordinate point after the inverse solution, rotation pos is the interpolation point vector before the inverse solution, and center v is the spherical center coordinate.
In a second aspect, a four-axis device interpolation calibration apparatus according to an embodiment of the present invention includes:
the control unit is used for controlling the rotation of the rotating shaft of the four-axis equipment and enabling the executing piece to be aligned to the characteristic point on the calibration piece, and the calibration piece is arranged on the rotating shaft;
the determining unit is used for acquiring coordinate data of the rotating shaft when the executing piece is aligned to the feature point after each rotation, and determining a center coordinate and a rotation vector of the rotating shaft according to the coordinate data, wherein the rotating shaft rotates at least three times to acquire at least three coordinate data of the feature point;
and the interpolation calculation unit is used for calculating interpolation coordinates according to the coordinate data, the central coordinates of the rotating shaft and the rotating vector to obtain the actual coordinates of each interpolation line segment.
According to an embodiment of the invention, the determining unit comprises:
the fitting module is used for fitting a spherical surface by adopting a least square method according to the coordinate data;
the calculation module is used for calculating the spherical center coordinates of the sphere according to the fitting sphere;
wherein, the space sphere equation: (X-a) 2+ (Y-b) 2+ (Z-c) 2=r 2 R is the radius of the sphere;
expanding the space sphere equation to obtain: x2+y2+z2-2aX-2 bY-2cz+a2+b2+c2=r 2
Setting: a=2a; b=2b; c=2c; d=a2+b2+c2-R 2
Then: x2+y2+z2-AX-BX-cx+d=0;
the least squares fit sphere: v=Σ (x2+y2+z2-AX-BX-cx+d) 2, calculating V as the minimum value, and obtaining A, B, C value, then obtaining the spherical center coordinates: a=a/2; b=b/2; c=c/2.
According to one embodiment of the invention, the rotation vector is calculated using the following formula:
rotation vector ijk=
Vector A1(X1-centerX,Y1-centerY,Z1-centerZ);
Vector A2(X2-centerX,Y2-centerY,Z2-centerZ);
Vector A3(X3-centerX,Y3-centerY,Z3-centerZ);
Vector A5=A2-A1;
Vector A6=A3-A1;
Vector a7=a5.cross (A6); /(cross multiplication)
Double len=sqrt(A7.X^+A7.Y^+A7.Z^);
Double i=A7.X/len;
Double j=A7.Y/len;
Double k=A7.Z/len;
Where center X, center Y, center Z is the calculated center coordinates a, b, c, X1, X2, X3Y 1, Y2, Y3, Z1, Z2, Z3 are the coordinates of three points on the sphere that are not collinear.
According to one embodiment of the present invention, the interpolation calculation unit is specifically configured to calculate an inverse solution according to the coordinate data, a center coordinate of the rotation axis, and a rotation vector by using the following kinematic formula;
Quaterniond q(rotation_vector);
Vector target=q*(rotationPos-centerV)+centerV;
the rotation_vector is a rotation vector IJK and comprises a designated angle gesture, and q is a quaternion of the rotation vector and the angle gesture contained in the rotation_vector;
target is the actual coordinate point after the inverse solution, rotation pos is the interpolation point vector before the inverse solution, and center v is the spherical center coordinate.
In a third aspect, an embodiment of the present invention provides a computer device, including a memory, a processor, and a computer program stored on the memory and executable on the processor, where the processor implements the four-axis device interpolation calibration method as described above when executing the computer program.
In a fourth aspect, an embodiment of the present invention provides a computer storage medium having stored thereon a computer program which, when executed by a processor, implements a four-axis device interpolation calibration method as described above.
According to the four-axis equipment interpolation calibration method, the device, the computer equipment and the storage medium thereof, the calibration piece is arranged on the rotating shaft, the calibration piece is provided with at least three characteristic points, the coordinate data of the execution piece on the at least three characteristic points are obtained, the central coordinate and the rotating vector of the rotating shaft are determined according to the coordinate data, the interpolation coordinate calculation is carried out according to the coordinate data, the central coordinate and the rotating vector of the rotating shaft, and the actual coordinate of each interpolation line segment is obtained.
Additional aspects and advantages of the invention will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of the invention.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings that are required in the embodiments or the description of the prior art will be briefly described, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and other drawings may be obtained according to the structures shown in these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flow chart of one embodiment of a four-axis device interpolation calibration method of the present invention;
FIG. 2 is a schematic illustration of the alignment of an actuator with a calibration member in a four-axis device interpolation calibration method of the present invention;
FIG. 3 is a flow chart of one embodiment of a four-axis device interpolation calibration apparatus of the present invention;
FIG. 4 is a schematic diagram of one embodiment of a computer device of the present invention.
The achievement of the objects, functional features and advantages of the present invention will be further described with reference to the accompanying drawings, in conjunction with the embodiments.
Detailed Description
Embodiments of the present invention are described in detail below, examples of which are illustrated in the accompanying drawings, wherein like or similar reference numerals refer to like or similar elements or elements having like or similar functions throughout. The embodiments described below by referring to the drawings are illustrative only and are not to be construed as limiting the invention.
Referring to fig. 1, fig. 1 shows a flowchart of an embodiment of a four-axis device interpolation calibration method according to an embodiment of the present invention, and for convenience of description, only a portion related to the embodiment of the present invention is shown. Specifically, the four-axis equipment interpolation calibration method comprises the following steps:
s101, controlling the rotation shaft R of the four-axis device to rotate, and aligning the actuator 11 to the feature point 101 on the calibration member 10, on which the calibration member 10 is mounted.
The purpose of this step is to align the actuator 11 to the feature point 101 on the calibration member 10 for subsequent acquisition of coordinate data and determination of the center coordinates and rotation vector of the rotation axis R. The calibration member 10 needs to be mounted on the rotating shaft R, the calibration member 10 is provided with the feature points 101, the rotating shaft R is controlled to rotate, the feature points 101 on the calibration member 10 rotate along with the rotating shaft R, coordinate data of the feature points 101 are different at different positions, and the feature points 101 at the different positions are sequentially aligned by controlling the executing member 11, so that coordinate data of the feature points 101 at the different positions are obtained.
It should be noted that, the executing piece 11 may be different according to the use of the four-axis processing apparatus, for example, the executing piece 11 may be a cutter or a dispensing needle, where the cutter is used for machining, and the dispensing needle is used for dispensing at a predetermined position of the product. The actuator 11 is typically mounted on a three-axis robot or other multi-axis motion mechanism to drive the actuator 11 to a target position for performing a machining or dispensing operation.
S102, acquiring coordinate data of the execution piece 11 when the rotation shaft R is aligned with the feature point 101 after each rotation, and determining a center coordinate and a rotation vector of the rotation shaft R according to the coordinate data, wherein the rotation shaft R rotates at least three times to acquire at least three coordinate data of the feature point 101.
Illustratively, when the rotation axis R rotates by a first angle, the feature point 101 is located at a first position, and at this time, the control actuator 11 is aligned with the feature point 101 at the first position, and coordinate data of the feature point 101 at the first position can be obtained according to data of the actuator 11 on the X, Y, Z axis. Then, when the rotation axis R rotates by a second angle, the feature point 101 is located at the second position, and at this time, the control actuator 11 aligns with the feature point 101 at the second position, so that coordinate data of the feature point 101 at the second position can be obtained, and when the rotation axis R rotates by a third angle, the feature point 101 is located at the third position, and at this time, the control actuator 11 aligns with the feature point 101 at the third position, so that coordinate data of the feature point 101 at the third position can be obtained, so that coordinate data of three positions of the feature point 101 can be obtained, and the three positions are not collinear.
Since the obtained at least three coordinate data are obtained by collecting the feature points 101 when the rotation axis R rotates at least three different positions, a three-dimensional coordinate system and a rotation matrix may be used to describe the movement locus and rotation angle of the rotation axis R, and further calculate the center coordinate point, rotation vector, and the like of the rotation axis R.
It can be understood that the more positions are acquired, the more coordinate data of the feature points 101 are obtained, and the more accurate the result of the center coordinates and the rotation vectors of the rotation axis R is obtained.
And S103, calculating interpolation coordinates according to the coordinate data, the central coordinates of the rotating shaft R and the rotating vector, and obtaining the actual coordinates of each interpolation line segment.
In this step, the inverse solution can be obtained by a kinematic algorithm from the four-axis structural parameters (including the center coordinates of the rotation axis R, the rotation vector, the coordinate data of the feature points 101 at different positions, and the like) obtained in the previous step. A long line segment (comprising curves and circular arcs) is split into N micro line segments for interpolation, and the position where the equipment is actually required to walk, namely the actual coordinate, can be obtained only by solving the inverse solution of the coordinate and the gesture information of each interpolation through a kinematic algorithm.
According to the four-axis equipment interpolation calibration method provided by the embodiment of the invention, the calibration piece 10 is arranged on the rotating shaft R, at least three characteristic points 101 are arranged on the calibration piece 10, the coordinate data of the execution piece 11 at the at least three characteristic points 101 are obtained, the central coordinate and the rotating vector of the rotating shaft R are determined according to the coordinate data, and the interpolation coordinate calculation is carried out according to the coordinate data, the central coordinate and the rotating vector of the rotating shaft R to obtain the actual coordinate of each interpolation line segment.
In one embodiment of the present invention, determining the center coordinates of the rotation axis R according to the coordinate data in step S102 includes:
fitting a spherical surface by adopting a least square method according to the coordinate data;
calculating the spherical center coordinates of the sphere according to the fitting sphere;
wherein, the space sphere equation: (X-a) 2+ (Y-b) 2+ (Z-c) 2=r 2 R is the radius of the sphere;
expanding the space sphere equation to obtain: x2+y2+z2-2aX-2 bY-2cz+a2+b2+c2=r 2
Setting: a=2a; b=2b; c=2c; d=a2+b2+c2-R 2
Then: x2+y2+z2-AX-BX-cx+d=0;
the least squares fit sphere: v=Σ (x2+y2+z2-AX-BX-cx+d) 2, calculating V as the minimum value, and obtaining A, B, C value, then obtaining the spherical center coordinates: a=a/2; b=b/2; c=c/2.
In this embodiment, a sphere is fitted using the least squares method from given coordinate data. The least squares method is a mathematical optimization technique that finds the best fit curve or surface by minimizing the square difference between the predicted and actual values. And calculating the spherical center coordinates of the sphere according to the fitting sphere. The spherical center coordinates are points on the sphere where all points are equidistant from the center of the sphere, and can be obtained by solving a space sphere equation.
The calculation of the center coordinate of the rotation axis R by the least square method in this embodiment has the following advantages: 1) Accuracy: the least square method finds a best-fit curve or curved surface by minimizing the square difference between the predicted value and the actual value, and thus it can provide higher accuracy in calculating the center coordinates of the rotation axis R. This is critical for precision machining or dispensing operations. 2) Stability: the least squares method is a stable mathematical optimization method that can still provide reliable results in the presence of noise or data imperfections. This means that the least squares method can find a relatively stable center coordinate of the rotation axis R even if there is a certain degree of error in the input data. 3) Calculation efficiency: the calculation process of the least square method is relatively simple, and the least square method can be efficiently solved by matrix operation, iterative solution and other methods. The least square method has higher calculation efficiency in calculating the center coordinates of the rotating shaft R, and is beneficial to improving the speed of the whole processing or dispensing process. 4) Fault tolerance: the least square method has certain fault tolerance, and even if some abnormal values exist in the input data, the least square method can still find a reasonable central coordinate of the rotating shaft R. This helps to improve the robustness of the machining or dispensing operation.
In a word, the least square method for calculating the center coordinate of the rotating shaft R has the advantages of high accuracy, good stability, wide applicability, high calculation efficiency, strong fault tolerance and the like. These advantages make the least square method the preferred method for calculating the center coordinates of the rotation axis R, which is helpful for realizing accurate processing or dispensing operation.
In one embodiment of the present invention, the rotation vector in step S102 is calculated using the following formula:
rotation vector ijk=
Vector A1(X1-centerX,Y1-centerY,Z1-centerZ);
Vector A2(X2-centerX,Y2-centerY,Z2-centerZ);
Vector A3(X3-centerX,Y3-centerY,Z3-centerZ);
Vector a5=a2-A1; calculating the relative vector of A2 with respect to A1;
vector a6=a3-A1; calculating the relative vector of A3 with respect to A1;
vector a7=a5.cross (A6); the cross product of A5 and A6 is calculated by using the cross product, and a vector perpendicular to A5 and A6 is obtained;
double len=sqrt (a7.xj+a7.yj+a7.zj); vector length of A7 is calculated;
double i=a7.x/len; obtaining an i unit vector through unitization;
double j=a7.y/len; obtaining j unit vectors through unitization;
double k=a7.z/len; obtaining k unit vectors through unitization;
i, j and k form an IJK coordinate system, and the origin is A1 point.
Ijk is a rotation unit vector.
Where center X, center Y, center Z is the calculated center coordinates a, b, c, X1, X2, X3Y 1, Y2, Y3, Z1, Z2, Z3 are the coordinates of three points on the sphere that are not collinear.
In this embodiment, three space vectors A1, A2, A3 are defined, two relative vectors A5 and A6 are obtained by calculating A2-A1 and A3-A1, a unit vector A7 perpendicular to A5 and A6 is obtained by calculating A5 and A6 using cross products, and i, j, k unit vectors are calculated from the coordinates of A7. The i, j, k unit vectors form the IJK axis with A1 as the origin. The function of the process is to construct a coordinate system with A1 as an origin and IJK as an axial direction through three space points A1, A2 and A3.
It should be noted that by calculating the rotational relationship of three points on the sphere that are not collinear, it is possible to find an axis of rotation R perpendicular to the plane in which these points lie, which is critical because it allows the rotation operation to be performed accurately in three dimensions. And by normalizing the rotation vector, a rotation unit vector is obtained. This unit vector has the characteristic of length 1 in the same direction as the rotation axis R, so that the rotation operation can be more conveniently handled while avoiding calculation errors due to the variation of the vector length.
Furthermore, the above algorithm of the rotation vector provides a simple method to handle rotation operations in three-dimensional space. By calculating the rotation vector, the rotation operation can be more easily understood and realized, thereby improving the accuracy of interpolation calibration.
In one embodiment of the present invention, performing interpolation coordinate calculation according to the coordinate data, the center coordinate of the rotation axis R, and the rotation vector, to obtain the actual coordinate of each interpolation line segment includes:
according to the coordinate data, the center coordinate of the rotation axis R and the rotation vector, an inverse solution is obtained through the following kinematic formula;
Quaterniond q(rotation_vector);
Vector target=q*(rotationPos-centerV)+centerV;
the rotation_vector is a rotation vector IJK and comprises a designated angle gesture, and q is a quaternion of the rotation vector and the angle gesture contained in the rotation_vector;
target is the actual coordinate point after the inverse solution, rotation pos is the interpolation point vector before the inverse solution, and center v is the spherical center coordinate.
In the present embodiment, a Quaternion (Quaternion) is used to represent the rotation operation so as to perform interpolation coordinate calculation in the three-dimensional space. First, a quaternion q needs to be created from a given rotation vector IJK and angular pose. Quaternion is a mathematical representation for representing and manipulating three-dimensional rotations, which has the advantage of better numerical stability and avoidance of gimbal locks. Next, it is necessary to calculate a vector of the interpolation point vector (rotation pos) before the inverse solution with respect to the center coordinates (center v). This can be achieved by subtracting center v from the rotation pos. This relative vector is then rotated using the quaternion q. The quaternion rotation operation may be achieved by multiplying the quaternion with the vector. In this example, q is multiplied by (rotations pos-center v). Finally, the rotated vector is added with the spherical center coordinates (center v) to obtain an inverse-solved actual coordinate point (target), and the actual coordinate point represents the actual position of the interpolation line segment.
The interpolation coordinate calculation by adopting the kinematic formula has the following effects: 1) Efficient rotation operation: by expressing the rotation operation using the quaternion, interpolation coordinate calculation can be performed more efficiently. The quaternion has the advantages of numerical stability and avoiding universal joint lock, so that the calculation efficiency and accuracy are improved. 2) Simplifying the coordinate transformation: by rotating the interpolation point vector before inverse solution relative to the vector of the sphere center coordinates, the coordinate transformation process is simplified, so that the interpolation coordinate calculation can be more easily understood and realized. 3) The interpolation result is accurate: by performing the rotation operation using the quaternion, a more accurate interpolation result can be obtained. The method can effectively reduce calculation errors, thereby improving the accuracy of interpolation coordinate calculation.
Referring to fig. 3, fig. 3 is a schematic structural diagram of an embodiment of a four-axis device interpolation calibration apparatus according to an embodiment of the present invention, and for convenience of description, only a portion related to the embodiment of the present invention is shown. Specifically, this four-axis equipment interpolation calibration device includes:
a control unit 201 for controlling the rotation of the rotation axis R of the four-axis device such that the actuator 11 is aligned to a characteristic point 101 on a calibration piece 10, said calibration piece 10 being mounted on said rotation axis R and said calibration piece 10 having at least three said characteristic points 101 which are not collinear.
A determining unit 202, configured to acquire coordinate data of the actuator 11 at least three of the feature points 101, and determine a center coordinate and a rotation vector of the rotation axis R according to the coordinate data.
The interpolation calculation unit 203 is configured to perform interpolation coordinate calculation according to the coordinate data, the center coordinate of the rotation axis R, and the rotation vector, and obtain an actual coordinate of each interpolation line segment.
In one embodiment of the invention, the determining unit comprises:
and the fitting module is used for fitting the spherical surface by adopting a least square method according to the coordinate data.
And the calculation module is used for calculating the spherical center coordinates of the sphere according to the fitting spherical surface.
Wherein, the space sphere equation: (X-a) 2+ (Y-b) 2+ (Z-c) 2=r 2 R is the radius of the sphere;
expanding the space sphere equation to obtain: x2+y2+z2-2aX-2 bY-2cz+a2+b2+c2=r 2
Setting: a=2a; b=2b; c=2c; d=a2+b2+c2-R 2
Then: x2+y2+z2-AX-BX-cx+d=0;
the least squares fit sphere: v=Σ (x2+y2+z2-AX-BX-cx+d) 2, calculating V as the minimum value, and obtaining A, B, C value, then obtaining the spherical center coordinates: a=a/2; b=b/2; c=c/2.
In one embodiment of the invention, the rotation vector is calculated using the following formula:
rotation vector ijk=
Vector A1(X1-centerX,Y1-centerY,Z1-centerZ);
Vector A2(X2-centerX,Y2-centerY,Z2-centerZ);
Vector A3(X3-centerX,Y3-centerY,Z3-centerZ);
Vector A5=A2-A1;
Vector A6=A3-A1;
Vector a7=a5.cross (A6); /(cross multiplication)
Double len=sqrt(A7.X^+A7.Y^+A7.Z^);
Double i=A7.X/len;
Double j=A7.Y/len;
Double k=A7.Z/len;
Where center X, center Y, center Z is the calculated center coordinates a, b, c, X1, X2, X3Y 1, Y2, Y3, Z1, Z2, Z3 are the coordinates of three points on the sphere that are not collinear.
In one embodiment of the present invention, the interpolation calculation unit is specifically configured to calculate an inverse solution according to the coordinate data, the center coordinate of the rotation axis R, and the rotation vector by using the following kinematic formula;
Quaterniond q(rotation_vector);
Vector target=q*(rotationPos-centerV)+centerV;
the rotation_vector is a rotation vector IJK and comprises a designated angle gesture, and q is a quaternion of the rotation vector and the angle gesture contained in the rotation_vector;
target is the actual coordinate point after the inverse solution, rotation pos is the interpolation point vector before the inverse solution, and center v is the spherical center coordinate.
According to the four-axis equipment interpolation calibration device provided by the embodiment of the invention, the calibration piece 10 is arranged on the rotating shaft R, at least three characteristic points 101 are arranged on the calibration piece 10, the coordinate data of the execution piece 11 at the at least three characteristic points 101 are obtained, the central coordinate and the rotating vector of the rotating shaft R are determined according to the coordinate data, and the interpolation coordinate calculation is carried out according to the coordinate data, the central coordinate and the rotating vector of the rotating shaft R to obtain the actual coordinate of each interpolation line segment.
Referring to fig. 4, an embodiment of the present invention further provides a computer device 300, including a memory 302, a processor 301, and a computer program 3021 stored in the memory 302 and capable of running on the processor 301, where the processor 301 implements the four-axis device interpolation calibration method as described above when executing the computer program 3021.
By way of example, the computer program 3021 may be split into one or more modules/units that are stored in the memory and executed by the processor 301 to accomplish the present invention. The one or more modules/units may be a series of computer program instruction segments capable of performing the specified functions, which instruction segments describe the execution of the computer program in the computer device.
The embodiment of the invention also provides a computer storage medium, on which a computer program is stored, which when being executed by a processor, realizes the four-axis device interpolation calibration method.
It should be noted that, in the present specification, each embodiment is described in a progressive manner, and each embodiment is mainly described as different from other embodiments, and identical and similar parts between the embodiments are all enough to be referred to each other. For device or system class embodiments, the description is relatively simple as it is substantially similar to method embodiments, with reference to the description of method embodiments in part.
It is further noted that relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Moreover, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
The steps of a method or algorithm described in connection with the embodiments disclosed herein may be embodied directly in hardware, in a software module executed by a processor, or in a combination of the two. The software modules may be disposed in Random Access Memory (RAM), memory, read Only Memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
The previous description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the invention. Thus, the present invention is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (10)

1. The four-axis equipment interpolation calibration method is characterized by comprising the following steps of:
controlling a rotating shaft of the four-axis device to rotate, and enabling an executing piece to be aligned to a characteristic point on a calibration piece, wherein the calibration piece is arranged on the rotating shaft;
acquiring coordinate data of an executing piece when the rotating shaft rotates each time and aligning with a feature point, and determining a center coordinate and a rotating vector of the rotating shaft according to the coordinate data, wherein the rotating shaft rotates at least three times to acquire at least three coordinate data of the feature point;
and calculating interpolation coordinates according to the coordinate data, the central coordinates of the rotating shaft and the rotating vector, and obtaining the actual coordinates of each interpolation line segment.
2. The four-axis device interpolation calibration method according to claim 1, wherein determining the center coordinates of the rotation axis from the coordinate data includes:
fitting a spherical surface by adopting a least square method according to the coordinate data;
calculating the spherical center coordinates of the sphere according to the fitting sphere;
wherein, the space sphere equation: (X-a) 2+ (Y-b) 2+ (Z-c) 2=r 2 R is the radius of the sphere;
expanding the space sphere equation to obtain: x2+y2+z2-2aX-2 bY-2cz+a2+b2+c2=r 2
Setting: a=2a; b=2b; c=2c; d=a2+b2+c2-R 2
Then: x2+y2+z2-AX-BX-cx+d=0;
the least squares fit sphere: v=Σ (x2+y2+z2-AX-BX-cx+d) 2, calculating V as the minimum value, and obtaining A, B, C value, then obtaining the spherical center coordinates: a=a/2; b=b/2; c=c/2.
3. The four-axis device interpolation calibration method according to claim 2, wherein the rotation vector is calculated using the following formula:
rotation vector ijk=
Vector A1(X1-centerX,Y1-centerY,Z1-centerZ);
Vector A2(X2-centerX,Y2-centerY,Z2-centerZ);
Vector A3(X3-centerX,Y3-centerY,Z3-centerZ);
Vector A5=A2-A1;
Vector A6=A3-A1;
Vector a7=a5.cross (A6); /(cross multiplication)
Double len=sqrt(A7.X^+A7.Y^+A7.Z^);
Double i=A7.X/len;
Double j=A7.Y/len;
Double k=A7.Z/len;
Where center X, center Y, center Z is the calculated center coordinates a, b, c, X1, X2, X3Y 1, Y2, Y3, Z1, Z2, Z3 are the coordinates of three points on the sphere that are not collinear.
4. The four-axis equipment interpolation calibration method according to claim 1, wherein performing interpolation coordinate calculation according to the coordinate data, the center coordinates of the rotation axis, and the rotation vector, obtaining the actual coordinates of each interpolation line segment includes:
according to the coordinate data, the center coordinates of the rotating shaft and the rotating vector, an inverse solution is obtained through the following kinematic formula;
Quaterniond q(rotation_vector);
Vector target=q*(rotationPos-centerV)+centerV;
the rotation_vector is a rotation vector IJK and comprises a designated angle gesture, and q is a quaternion of the rotation vector and the angle gesture contained in the rotation_vector;
target is the actual coordinate point after the inverse solution, rotation pos is the interpolation point vector before the inverse solution, and center v is the spherical center coordinate.
5. The utility model provides a four-axis equipment interpolation calibration device which characterized in that includes:
the control unit is used for controlling the rotation of the rotating shaft of the four-axis equipment and enabling the executing piece to be aligned to the characteristic point on the calibration piece, and the calibration piece is arranged on the rotating shaft;
the determining unit is used for acquiring coordinate data of the rotating shaft when the executing piece is aligned to the feature point after each rotation, and determining a center coordinate and a rotation vector of the rotating shaft according to the coordinate data, wherein the rotating shaft rotates at least three times to acquire at least three coordinate data of the feature point;
and the interpolation calculation unit is used for calculating interpolation coordinates according to the coordinate data, the central coordinates of the rotating shaft and the rotating vector to obtain the actual coordinates of each interpolation line segment.
6. The four-axis device interpolation calibration apparatus according to claim 6, wherein the determination unit includes:
the fitting module is used for fitting a spherical surface by adopting a least square method according to the coordinate data;
the calculation module is used for calculating the spherical center coordinates of the sphere according to the fitting sphere;
wherein, the space sphere equation: (X-a) 2+ (Y-b) 2+ (Z-c) 2=r 2 R is the radius of the sphere;
expanding the space sphere equation to obtain: x2+y2+z2-2aX-2 bY-2cz+a2+b2+c2=r 2
Setting: a=2a; b=2b; c=2c; d=a2+b2+c2-R 2
Then: x2+y2+z2-AX-BX-cx+d=0;
the least squares fit sphere: v=Σ (x2+y2+z2-AX-BX-cx+d) 2, calculating V as the minimum value, and obtaining A, B, C value, then obtaining the spherical center coordinates: a=a/2; b=b/2; c=c/2.
7. The four-axis device interpolation calibration apparatus according to claim 6, wherein the rotation vector is calculated using the following formula:
rotation vector ijk=
Vector A1(X1-centerX,Y1-centerY,Z1-centerZ);
Vector A2(X2-centerX,Y2-centerY,Z2-centerZ);
Vector A3(X3-centerX,Y3-centerY,Z3-centerZ);
Vector A5=A2-A1;
Vector A6=A3-A1;
Vector a7=a5.cross (A6); /(cross multiplication)
Double len=sqrt(A7.X^+A7.Y^+A7.Z^);
Double i=A7.X/len;
Double j=A7.Y/len;
Double k=A7.Z/len;
Where center X, center Y, center Z is the calculated center coordinates a, b, c, X1, X2, X3Y 1, Y2, Y3, Z1, Z2, Z3 are the coordinates of three points on the sphere that are not collinear.
8. The four-axis equipment interpolation calibration device according to claim 5, wherein the interpolation calculation unit is specifically configured to calculate an inverse solution according to the coordinate data, a center coordinate of a rotation axis, and a rotation vector by using a kinematic formula as follows;
Quaterniond q(rotation_vector);
Vector target=q*(rotationPos-centerV)+centerV;
the rotation_vector is a rotation vector IJK and comprises a designated angle gesture, and q is a quaternion of the rotation vector and the angle gesture contained in the rotation_vector;
target is the actual coordinate point after the inverse solution, rotation pos is the interpolation point vector before the inverse solution, and center v is the spherical center coordinate.
9. A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor implements the four-axis device interpolation calibration method according to any of claims 1 to 4 when executing the computer program.
10. A computer storage medium having stored thereon a computer program, which when executed by a processor implements the four-axis device interpolation calibration method according to any one of claims 1 to 4.
CN202310546210.XA 2023-05-15 2023-05-15 Four-axis equipment interpolation calibration method and device, computer equipment and storage medium thereof Pending CN116736797A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310546210.XA CN116736797A (en) 2023-05-15 2023-05-15 Four-axis equipment interpolation calibration method and device, computer equipment and storage medium thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310546210.XA CN116736797A (en) 2023-05-15 2023-05-15 Four-axis equipment interpolation calibration method and device, computer equipment and storage medium thereof

Publications (1)

Publication Number Publication Date
CN116736797A true CN116736797A (en) 2023-09-12

Family

ID=87914165

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310546210.XA Pending CN116736797A (en) 2023-05-15 2023-05-15 Four-axis equipment interpolation calibration method and device, computer equipment and storage medium thereof

Country Status (1)

Country Link
CN (1) CN116736797A (en)

Similar Documents

Publication Publication Date Title
CN107995885B (en) Coordinate system calibration method, system and device
CN110640747B (en) Hand-eye calibration method and system for robot, electronic equipment and storage medium
CN108748159B (en) Self-calibration method for tool coordinate system of mechanical arm
US6941192B2 (en) Robot machining tool position and orientation calibration
JP5448634B2 (en) Machine error identification method and program
Santolaria et al. Laser tracker-based kinematic parameter calibration of industrial robots by improved CPA method and active retroreflector
JP2005300230A (en) Measuring instrument
CA2828856A1 (en) Robotic work object cell calibration device, system, and method
US20070242073A1 (en) Robot simulation apparatus
KR101797122B1 (en) Method for Measurement And Compensation of Error on Portable 3D Coordinate Measurement Machine
CN110883774A (en) Robot joint angle zero calibration system, method and storage medium
Santolaria et al. Self-alignment of on-board measurement sensors for robot kinematic calibration
WO2018199947A1 (en) Robotic structure calibrations
Xiao et al. A new fixed axis-invariant based calibration approach to improve absolute positioning accuracy of manipulators
JP2006289580A (en) Teaching point correcting method of program and teaching point correcting device of program
CN112476435B (en) Calibration method and calibration device for gravity acceleration direction and storage medium
CN116736797A (en) Four-axis equipment interpolation calibration method and device, computer equipment and storage medium thereof
CN114734436B (en) Robot encoder calibration method and device and robot
JP2000055664A (en) Articulated robot system with function of measuring attitude, method and system for certifying measuring precision of gyro by use of turntable for calibration reference, and device and method for calibrating turntable formed of n-axes
CN113325430B (en) Method, device and equipment for measuring mounting precision of end effector and storage medium
CN110561387B (en) Method for determining a rotatable workpiece in an industrial robot system
Nieves et al. Laser beam multi-position alignment approach for an automated industrial robot calibration
JP2021186929A (en) Control method for multi-axis robot
CN113334383B (en) Robot tail end tool offset calibration method based on line laser measuring instrument
CN116038721B (en) Hand-eye calibration method and system without kinematic participation

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination