Coordinate origin measurement method and device
By using a calibration block on a five-axis machine tool to obtain an image set, and using an image processing algorithm to determine the axial vector and calculate the machine origin, it solves the problems of high accuracy and environmental requirements for measuring equipment in the existing technology, and achieves convenient and efficient machine tool origin measurement. .
Patent Information
- Application Number
- CN202011174889.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Priority Date
- 2020-09-28
- Filing Date
- 2020-10-28
- Publication Date
- 2024-10-22
- Estimated Expiration
- 2040-10-28
AI Technical Summary
Existing machine tool coordinate origin measuring equipment has high requirements on sensor accuracy and detection environment, and needs to repeatedly adjust the relative position of the measuring instrument and the machine tool, making the measurement process cumbersome and making it difficult to determine the machine tool origin conveniently and effectively.
A calibration block is used to obtain an image set during rotation and translation on the axis of a five-axis machine tool. The axial vector is determined through an image processing algorithm and the machine origin is calculated based on the preset distance value. This simplifies the measurement process and reduces the requirements for sensors and the environment.
It achieves convenient and effective measurement and determination of the origin of the machine tool, improves measurement accuracy and efficiency, reduces the requirements for sensors and the environment, and simplifies the measurement process.
Smart Images

Figure CN112258578B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of machine tool measurement, and in particular to a coordinate origin measurement method and device. Background Art
[0002] With the increasing requirements for machine tool processing accuracy, efficient and accurate processing and reducing machine tool processing errors are the goals that people are tirelessly pursuing. However, in the actual processing process, determining the origin of the machine tool is the basis for establishing the machine tool coordinate system, and it also greatly affects the subsequent processing accuracy and efficiency of the machine tool; especially in five-axis machine tools, accuracy is the basis for its good work, and the accuracy of the machine tool largely determines the degree of refinement of the processed products. The accurate measurement of the origin of the machine tool coordinate is an important link to ensure its accuracy.
[0003] Before machining, the origin of the machine tool is determined, and the machine tool coordinate system can be established based on the origin of the machine tool to reduce the error of machine tool machining and improve the qualified rate of workpieces. Taking the five-axis machine tool with high precision requirements as an example, the current measurement equipment for the mechanical parameters and origin of each axis of the five-axis machine tool mainly includes laser followers, laser interferometers, ballbars, five-axis machine tool rotary axis error analyzers, ball disks, plane gratings, rotary axis calibrators, etc. However, the existing measurement equipment and methods generally have high requirements for the accuracy of the sensor and the detection environment; and the relative position of the measuring instrument and the machine tool needs to be repeatedly adjusted during the measurement process.
[0004] Therefore, how to conveniently and effectively measure and determine the origin of the machine tool is a problem that needs to be solved urgently in this application. Summary of the invention
[0005] The present application provides a coordinate origin measurement method, which can conveniently and effectively measure and determine the origin of a machine tool.
[0006] In a first aspect, an embodiment of the present invention provides a coordinate origin measurement method, which is applied to a machine tool and may include:
[0007] Acquire a first image set, a second image set, and a third image set of a calibration block fixed at a first position on a first axis; the first image set is a set of multiple first images during the rotation of the calibration block around the first axis; the second image set is a set of multiple second images during the translation of the calibration block along the second axis; the third image set is a set of multiple third images during the translation of the calibration block along the third axis;
[0008] determining a first direction vector of the first axis according to the first image set, determining a second direction vector of the second axis according to the second image set, and determining a third direction vector of the third axis according to the third image set;
[0009] The coordinate origin of the machine tool is determined according to the first direction vector, the second direction vector, the third direction vector and a preset distance value; the preset distance value is the distance value between the first position and the coordinate origin.
[0010] In the embodiment of the present invention, the calibration block is first fixed at a fixed position of the first axis (such as the x-axis of the five-axis machine tool in the embodiment of the present invention, which can rotate 360 degrees around the x-axis axis), and the image acquisition device used (the embodiment of the present invention is described by taking a camera as an example) is calibrated to obtain the intrinsic parameters and distortion parameters of the imaging model corresponding to the camera. The first axis is used as the rotation axis, and the images of the calibration block fixed on the first axis at different rotation angles are recorded. The center of the circular motion trajectory corresponding to each feature point is further determined by fitting the circular trajectory formed by the selected feature points on the calibration block during the rotation process; multiple centers are fitted to determine the direction vector of the first axis. The calibration block is moved along the second axis (such as the y-axis) and the third axis (such as the z-axis), and a certain number of images are taken; the coordinates of the position of the calibration block in the multiple images are calculated, so as to determine the direction vector of the second axis and the direction vector of the third axis respectively. After confirming the direction vectors of the three axes, the fixed position of the first axis can be determined; and the machine tool origin is determined on the first axis according to the preset distance parameter and the direction of the reference first direction vector. Different from the prior art, the device has high requirements on sensors and detection environment when measuring, and needs to repeatedly adjust the relative position of the measuring instrument and the machine tool. Compared with the prior art, the embodiment of the present invention uses a calibration block during the measurement process, and uses a camera to shoot the calibration block, and uses relevant image processing algorithms to infer the position of the coordinate origin of the five-axis machine tool.
[0011] In a possible implementation, before acquiring the first image set, the second image set, and the third image set by moving the calibration block fixed at the first position on the first axis, it also includes: calibrating the image acquisition device to determine the intrinsic parameters and distortion parameters of the imaging model corresponding to the image acquisition device; the intrinsic parameters and distortion parameters are used to convert the images captured by the image acquisition device into the first image set, the second image set, or the third image set.
[0012] In a possible implementation, the calibration block includes multiple feature points; the first axis is the x-axis; the step of acquiring a first image set of the movement of the calibration block fixed at a first position on the first axis includes: taking the multiple first images during a 360-degree rotation of the x-axis; the multiple first images include multiple images of the calibration block at different rotation angles.
[0013] In a possible implementation, determining the first direction vector of the first axis based on the first image set includes: determining the circular motion trajectories of the multiple feature points based on the multiple first images; determining the centers of the multiple circular motion trajectories respectively by fitting the circular motion trajectories of the multiple feature points; the centers of the circles are distributed on the first direction vector; and determining the first direction vector based on the multiple centers of the circles.
[0014] In a possible implementation, determining the second direction vector of the second axis based on the second image set includes: calculating the coordinates of the calibration block at different positions of each of the multiple second images; and determining the second direction vector based on the coordinates of the different positions of each of the second images.
[0015] In one possible implementation, determining the third direction vector of the third axis based on the third image set includes: calculating the coordinates of the calibration block at different positions of each of the multiple third images; and determining the third direction vector based on the coordinates of the different positions of each of the third images.
[0016] In a possible implementation, determining the coordinate origin of the machine tool based on the first direction vector, the second direction vector, the third direction vector and a preset distance value includes: determining a first plane based on the second direction vector and the third direction vector; determining the intersection of the first plane and the first direction vector as the first position; and determining a position that differs from the first position by a preset distance value along the opposite direction of the first direction vector as the coordinate origin of the machine tool.
[0017] In a second aspect, an embodiment of the present invention provides a coordinate origin measuring device, which is applied to a machine tool and may include:
[0018] An acquisition unit is used to acquire a first image set, a second image set and a third image set of a calibration block fixed at a first position on a first axis; the first image set is a set of multiple first images during the rotation of the calibration block around the first axis; the second image set is a set of multiple second images during the translation of the calibration block along the second axis; the third image set is a set of multiple third images during the translation of the calibration block along the third axis;
[0019] a vector unit, configured to determine a first direction vector of the first axis according to the first image set, determine a second direction vector of the second axis according to the second image set, and determine a third direction vector of the third axis according to the third image set;
[0020] The origin unit is used to determine the coordinate origin of the machine tool according to the first direction vector, the second direction vector, the third direction vector and a preset distance value; the preset distance value is the distance value between the first position and the coordinate origin.
[0021] In a possible implementation, the device also includes: a calibration unit, which is used to calibrate the image acquisition device before acquiring the first image set, the second image set and the third image set in which a calibration block fixed at a first position on the first axis moves, and determine the intrinsic parameters and distortion parameters of the imaging model corresponding to the image acquisition device; the intrinsic parameters and distortion parameters are used to convert the images captured by the image acquisition device into the first image set, the second image set or the third image set.
[0022] In a possible implementation, the calibration block includes multiple feature points; the first axis is the x-axis; the acquisition unit is specifically used to: take the multiple first images during a 360-degree rotation of the x-axis; the multiple first images include multiple images of the calibration block at different rotation angles.
[0023] In a possible implementation, the vector unit is specifically used to: determine the circular motion trajectories of the multiple feature points based on the multiple first images; determine the centers of the multiple circular motion trajectories respectively by fitting the circular motion trajectories of the multiple feature points; the centers are distributed on the first direction vector; and determine the first direction vector based on the multiple centers.
[0024] In a possible implementation, the vector unit is specifically used to: calculate the coordinates of the calibration block at different positions of each of the multiple second images; and determine the second direction vector according to the coordinates of the different positions of each of the second images.
[0025] In a possible implementation, the vector unit is specifically used to: calculate the coordinates of the calibration block at different positions of each of the multiple third images; and determine the third direction vector according to the coordinates of the different positions of each of the third images.
[0026] In a possible implementation, the origin unit is specifically used to: determine a first plane based on the second direction vector and the third direction vector; determine the intersection of the first plane and the first direction vector as the first position; and determine a position that differs from the first position by a preset distance value along the opposite direction of the first direction vector as the coordinate origin of the machine tool.
[0027] In a third aspect, an embodiment of the present invention provides a coordinate origin measurement device, which may include a processor, an input device, an output device, and a memory. The processor, the input device, the output device, and the memory are connected to each other. The memory is used to store a computer program, and the computer program includes program instructions; the processor is configured to call the program instructions and execute the step instructions as described in the first aspect of the embodiment of the present invention.
[0028] In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program for electronic data exchange; the aforementioned computer program enables a computer to execute part or all of the steps described in the first aspect of the embodiment of the present invention.
[0029] In a fifth aspect, an embodiment of the present invention provides a computer program product, wherein the computer program product includes a non-transitory computer-readable storage medium storing a computer program, and the computer program is operable to cause a computer to execute some or all of the steps described in the first aspect of the embodiment of the present invention. The computer program product may be a software installation package. BRIEF DESCRIPTION OF THE DRAWINGS
[0030] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings required for use in the embodiments or the description of the prior art are briefly introduced below.
[0031] Figure 1 It is a flow chart of a coordinate origin measurement method provided by an embodiment of the present invention;
[0032] Figure 2 is a schematic diagram of a fixed position of a calibration block provided by an embodiment of the present invention;
[0033] Figure 3 is a schematic diagram of determining a first direction vector provided by an embodiment of the present invention;
[0034] Figure 4 is a schematic diagram of determining a second direction vector provided by an embodiment of the present invention;
[0035] Figure 5 is a schematic diagram of determining a third direction vector provided by an embodiment of the present invention;
[0036] Figure 6 It is a schematic diagram of a method for determining an origin according to a direction vector and a preset distance provided by an embodiment of the present invention;
[0037] Figure 7 A coordinate origin measuring device provided by an embodiment of the present invention;
[0038] Figure 8It is a structural schematic diagram of a device provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0039] The technical scheme in the embodiment of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiment of the present invention. Obviously, the described embodiment is a part of the embodiment of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without making creative work should fall within the scope of protection of this application.
[0040] The terms "first", "second", "third" and "fourth" etc. in the specification and claims of the present application and the drawings are used to distinguish different objects, rather than to describe a specific order. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not limited to the listed steps or units, but optionally includes steps or units that are not listed, or optionally includes other steps or units inherent to these processes, methods, products or devices.
[0041] Reference to "embodiments" herein means that a particular feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present application. The appearance of the phrase in various locations in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It is explicitly and implicitly understood by those skilled in the art that the embodiments described herein may be combined with other embodiments.
[0042] First, some terms in the embodiments of the present invention are explained to facilitate understanding by those skilled in the art.
[0043] (1) Computer numerical control (CNC) is an automated machine tool equipped with a program control system. The control system can logically process programs specified by control codes or other symbolic instructions, decode them, express them in coded numbers, and input them into the numerical control device through information carriers. After calculation and processing, the numerical control device sends various control signals to control the movement of the machine tool and automatically process parts according to the shape and size required by the drawing.
[0044] See also Figure 1 , Figure 1 is a flow chart of a coordinate origin measurement method provided by an embodiment of the present invention; Figure 1As shown, the embodiment of the method takes a five-axis machine tool to which the coordinate origin measurement method is applied as an example of the execution subject, and is explained from the side of the five-axis machine tool, and specifically may include steps S101-step S104; the optional steps may include step S101. It should be noted that the five-axis machine tool in the embodiment of the present invention takes the x-axis of the machine tool as an example that can rotate 360 degrees. The x-axis, y-axis and z-axis of the machine tool in the embodiment of the present invention are based on the specific machine tool structure, and the x-axis, y-axis and z-axis mentioned subsequently are all the x-axis, y-axis and z-axis of the machine tool mentioned in the embodiment of the present invention, and may be inconsistent with the xyz-axis of the actual coordinate system.
[0045] Step S101: calibrate the image acquisition device to determine the intrinsic parameters and distortion parameters of the imaging model corresponding to the image acquisition device.
[0046] Specifically, before the machine tool origin measurement begins, the image acquisition device (camera or camera model) to be used is calibrated to determine the internal parameters and distortion parameters involved in the imaging model corresponding to the camera; the determined model internal parameters and distortion parameters are used to convert the imaging image acquired by the camera into a pixel image. In the subsequent image processing, the three-dimensional coordinates of the origin in the imaging image are determined by combining the parameters of the imaging model and the origin position in the pixel image.
[0047] Step S102: Acquire a first image set, a second image set and a third image set of a movement of a calibration block fixed at a first position on a first axis.
[0048] Specifically, the camera is used to take multiple images of a calibration block fixed on an axis in different motion conditions; wherein multiple motion images in the same motion condition are an image set; for example, an image set for determining a first axis direction vector is a first image set; an image set for determining a second axis direction vector is a second image set; an image set for determining a third axis direction vector is a third image set. The calibration block can be fixed at a first position on the first axis. Optionally, the calibration block can also be fixed on the second axis or the third axis; this is not limited in the embodiments of the present invention.
[0049] Optionally, the calibration block is set at a certain position on the x-axis of the five-axis machine tool; wherein the position where the calibration block is placed is fixed, and a groove or other fixture can be used to ensure the fixed position.
[0050] In a possible implementation, the calibration block includes multiple feature points; the first axis is the x-axis; the step of obtaining a set of first images of the movement of the calibration block fixed at the first position on the first axis includes: taking the multiple first images during a 360-degree rotation of the x-axis; the multiple first images include multiple images of the calibration block at different rotation angles. The multiple images may include one image for each angle, or multiple images for each angle are used to correct errors. See Figure 2 , Figure 2 is a schematic diagram of a fixed position of a calibration block provided by an embodiment of the present invention; Figure 2 As shown, the x-axis of the five-axis machine tool is the first axis, the cube is the calibration block, and the calibration block is fixed at the first position. The rotation angle of the calibration block shown in the figure is only an example angle display of the 360-degree rotation angle. The x-axis is controlled to rotate 360 degrees; during the rotation process, the position of the calibration block at different rotation angles is photographed to obtain multiple first images.
[0051] Step S103: determining a first direction vector of the first axis according to the first image set, determining a second direction vector of the second axis according to the second image set, and determining a third direction vector of the third axis according to the third image set.
[0052] Specifically, the moving trajectory of the feature points is determined based on the moving position of the feature points in the first image set; after obtaining the moving trajectories of multiple feature points, the center of the trajectory is determined and the first direction vector is fitted. Similarly, the moving trajectory of the feature points is determined based on the moving position of the feature points in the second image set to fit the second direction vector; and the moving trajectory of the feature points is determined based on the moving position of the feature points in the third image set to fit the third direction vector.
[0053] In a possible implementation, determining the first direction vector of the first axis according to the first image set includes: determining the circular motion trajectories of the plurality of feature points according to the plurality of first images; determining the centers of the plurality of circular motion trajectories respectively by fitting the circular motion trajectories of the plurality of feature points; the centers of the circles are distributed on the first direction vector; and determining the first direction vector according to the plurality of centers of the circles. For example, see Figure 3 , Figure 3 is a schematic diagram of determining a first direction vector provided by an embodiment of the present invention; Figure 3As shown, taking the x-axis as the first axis and the calibration block rotating 360 degrees around the x-axis as an example, the trajectories of the three vertices on the calibration block (points A, B, and C as shown in the figure) during the rotation process are selected for illustration. Point A on the calibration block rotates around the axis of the x-axis to form a closed circular trajectory A', and its center a is determined according to the circular trajectory A'. Similarly, the center b can be determined from trajectory B', and the center c can be determined from trajectory C'. Due to the three-dimensional structure of the calibration block, multiple centers that are not in the same plane can be obtained; the x-axis axis is determined by fitting calculations of multiple centers (a, b, c as shown in the figure). According to the preset moving direction of the machine tool x-axis, the positive direction of the x-axis is determined, thereby determining the x-axis direction vector (i.e., the first direction vector).
[0054] In a possible implementation, determining the second direction vector of the second axis according to the second image set includes: calculating the coordinates of the calibration block at different positions of each of the plurality of second images; and determining the second direction vector according to the coordinates of the different positions of each of the second images. For example, see Figure 4 , Figure 4 is a schematic diagram of determining a second direction vector provided by an embodiment of the present invention; Figure 4 As shown, with the z-axis as the second axis, the calibration block is fixed on the x-axis (first axis), and the second direction vector (i.e., the y-axis direction vector) is determined. The first position I can be the coordinate of the calibration block's initial position on the x-axis or a certain position in the z-axis direction. The second position II can be a position of the calibration block in the z-axis direction that is different from the first position I; the first position III can be a position of the calibration block in the z-axis direction that is different from the first two. Determine the first position coordinates of each position based on the aforementioned three positions; determine the second direction vector based on the coordinates of the three positions (or the coordinates of more positions) and the preset z-axis direction.
[0055] Optionally, in the process of determining the first axis direction vector, for each of the multiple feature points in the multiple first images, a circular trajectory is formed, and the least squares method can be used to fit each circle to obtain multiple center points; and the multiple center points are fitted to obtain the central axis, that is, the first axis direction vector.
[0056] In a possible implementation, determining the third direction vector of the third axis according to the third image set includes: calculating the coordinates of the calibration block at different positions of each of the plurality of third images; and determining the third direction vector according to the coordinates of the different positions of each of the third images. Figure 5 , Figure 5 is a schematic diagram of determining a third direction vector provided by an embodiment of the present invention; Figure 5As shown, the calibration block is fixed on the x-axis and moved along the y-axis (corresponding to the third axis) to determine the third direction vector. The first position IV is a position on the y-axis, the first position V is another position on the y-axis that is different from the aforementioned position, and the first position VI is another position on the y-axis that is different from the aforementioned two positions. By calculating the coordinates of the three positions, or by calculating the coordinates of more different positions on the y-axis, and the preset y-axis direction, the direction vector of the y-axis, that is, the third direction vector, is determined.
[0057] Step S104: determining the coordinate origin of the machine tool according to the first direction vector, the second direction vector, the third direction vector and a preset distance value.
[0058] Specifically, the first position of the calibration block is determined according to the first direction vector, the second direction vector and the third direction vector; according to the first direction vector and the first position, the position at a preset distance value from the first position is determined as the coordinate origin of the machine tool.
[0059] In a possible implementation, determining the coordinate origin of the machine tool according to the first direction vector, the second direction vector, the third direction vector and the preset distance value includes: determining a first plane according to the second direction vector and the third direction vector; determining the intersection of the first plane and the first direction vector as the first position; and determining a position that differs from the first position by a preset distance value along the reverse direction of the first direction vector as the coordinate origin of the machine tool. For example, see Figure 6 , Figure 6 Schematic diagram of a method for determining an origin according to a direction vector and a preset distance provided by an embodiment of the present invention; Figure 6 As shown, according to the z-axis direction vector and the y-axis direction vector determined above, the first plane (i.e., plane yO'z in the figure) is determined, and the direction vector of the x-axis passes through the plane yO'z, and the intersection with the plane yO'z is the first position of the calibration block fixed on the x-axis (here represented by O'). The x-axis direction vector is the positive direction of the x-axis. In the negative direction of the x-axis, the position with a distance d (i.e., the distance between the preset origin and the calibration block) from O' is determined as the machine tool origin.
[0060] In an embodiment of the present invention, the calibration block is first fixed at a fixed position on the first axis (such as the x-axis), and the camera used is calibrated to obtain the intrinsic parameters and distortion parameters of the imaging model corresponding to the camera. The first axis is used as the rotation axis, and the images of the calibration block fixed on the first axis at different rotation angles are recorded. The circular trajectory formed by the selected feature points on the calibration block during the rotation process is fitted to further determine the center of the circular motion trajectory corresponding to each feature point; multiple centers are fitted to determine the direction vector of the first axis. The calibration block is moved along the second axis (such as the y-axis) and the third axis (such as the x-axis), and a certain number of images are taken; the coordinates of the position of the calibration block in the multiple images are calculated, so as to determine the direction vector of the second axis and the direction vector of the third axis respectively. After confirming the direction vectors of the three axes, the fixed position of the first axis can be determined; and the machine tool origin is determined on the first axis according to the preset distance parameter and the direction of the reference first direction vector. Different from the prior art, the device has high requirements on sensors and detection environment when measuring, and the relative position of the measuring instrument and the machine tool needs to be adjusted repeatedly. Compared with the prior art, the embodiment of the present invention uses a calibration block during the measurement process, photographs the calibration block with a camera, and uses a related image processing algorithm to calculate the position of the coordinate origin of the five-axis machine tool.
[0061] The method embodiment involved in the embodiment of the present invention is described in detail above, and an apparatus embodiment involved is described below.
[0062] See also Figure 7 , Figure 7 is a coordinate origin measuring device provided by an embodiment of the present invention; Figure 7 As shown, the coordinate origin measurement device 70 may include an acquisition unit 701, a vector unit 702, an origin unit 703 and a calibration unit 704. The optional unit may also include the calibration unit 704.
[0063] An acquisition unit 701 is used to acquire a first image set, a second image set and a third image set of a calibration block fixed at a first position on a first axis; the first image set is a set of multiple first images during the rotation of the calibration block around the first axis; the second image set is a set of multiple second images during the translation of the calibration block along the second axis; the third image set is a set of multiple third images during the translation of the calibration block along the third axis;
[0064] a vector unit 702, configured to determine a first direction vector of the first axis according to the first image set, determine a second direction vector of the second axis according to the second image set, and determine a third direction vector of the third axis according to the third image set;
[0065] The origin unit 703 is used to determine the coordinate origin of the machine tool according to the first direction vector, the second direction vector, the third direction vector and a preset distance value; the preset distance value is the distance value between the first position and the coordinate origin.
[0066] In a possible implementation, the device also includes: a calibration unit 704, which is used to calibrate the image acquisition device before acquiring the first image set, the second image set and the third image set in which the calibration block fixed at the first position on the first axis moves, and determine the intrinsic parameters and distortion parameters of the imaging model corresponding to the image acquisition device; the intrinsic parameters and distortion parameters are used to convert the images captured by the image acquisition device into the first image set, the second image set or the third image set.
[0067] In a possible implementation, the calibration block includes multiple feature points; the first axis is the x-axis; the acquisition unit 701 is specifically used to: take the multiple first images during a 360-degree rotation of the x-axis; the multiple first images include multiple images of the calibration block at different rotation angles.
[0068] In a possible implementation, the vector unit 702 is specifically used to: determine the circular motion trajectories of the multiple feature points based on the multiple first images; determine the centers of the multiple circular motion trajectories respectively by fitting the circular motion trajectories of the multiple feature points; the centers are distributed on the first direction vector; and determine the first direction vector based on the multiple centers.
[0069] In a possible implementation, the vector unit 702 is specifically used to: calculate the coordinates of the calibration block at different positions of each of the multiple second images; and determine the second direction vector according to the coordinates of the different positions of each of the second images.
[0070] In a possible implementation, the vector unit 702 is specifically used to: calculate the coordinates of the calibration block at different positions of each of the multiple third images; and determine the third direction vector according to the coordinates of the different positions of each of the third images.
[0071] In a possible implementation, the origin unit 703 is specifically used to: determine a first plane based on the second direction vector and the third direction vector; determine the intersection of the first plane and the first direction vector as the first position; and determine a position that is a preset distance away from the first position along the opposite direction of the first direction vector as the coordinate origin of the machine tool.
[0072] It should be noted that the functions of the various functional units of the coordinate origin measurement device 70 described in the device embodiment of the present invention can be found in the above Figure 1-Figure 6 The relevant description of the division of the column workpiece in the method embodiment is not repeated here.
[0073] See also Figure 8 , Figure 8 is a schematic diagram of the structure of a device provided by an embodiment of the present invention. Figure 8 The device 8 may include at least one storage component 801, at least one communication component 802, and at least one processing component 803. In addition, the device may also include common components such as an antenna and a power supply, which will not be described in detail here.
[0074] The storage component 801 may be a read-only memory (ROM) or other types of static storage devices that can store static information and instructions, a random access memory (RAM) or other types of dynamic storage devices that can store information and instructions, or an electrically erasable programmable read-only memory (EEPROM), a compact disc (CD-ROM) or other optical disc storage, optical disc storage (which may include a compressed optical disc, a laser disc, an optical disc, a digital versatile disc, a Blu-ray disc, etc.), a magnetic disk storage medium or other magnetic storage devices, or any other medium that can be used to carry or store the desired program code in the form of an instruction or data structure and can be accessed by a computer, but is not limited thereto. The memory may exist independently and be connected to the processor via a bus. The memory may also be integrated with the processor.
[0075] The communication component 802 may be used to communicate with other devices or communication networks, such as an upgrade server, a key server, and in-vehicle devices.
[0076] The processing unit 803 may be a general-purpose central processing unit (CPU), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits for controlling the execution of the above program.
[0077] Figure 8When the device shown is a coordinate origin measuring device 80, the processing component 803 is used to obtain a first image set, a second image set and a third image set of the movement of a calibration block fixed at a first position on a first axis; the first image set is a set of multiple first images during the rotation of the calibration block around the first axis; the second image set is a set of multiple second images during the translation of the calibration block along the second axis; the third image set is a set of multiple third images during the translation of the calibration block along the third axis; the first direction vector of the first axis is determined according to the first image set, the second direction vector of the second axis is determined according to the second image set, and the third direction vector of the third axis is determined according to the third image set; the coordinate origin of the machine tool is determined according to the first direction vector, the second direction vector, the third direction vector and a preset distance value; the preset distance value is the distance value between the first position and the coordinate origin.
[0078] An embodiment of the present invention further provides a computer-readable storage medium, wherein the computer-readable storage medium may store a program, and when the program is executed, the program may include part or all of the steps of any one of the above method embodiments.
[0079] An embodiment of the present invention further provides a computer program or a computer program product. The computer program may include instructions. When the computer program is executed by a computer, the computer may execute part or all of the steps of any one of the above method embodiments.
[0080] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0081] It should be noted that, for the above-mentioned method embodiments, for the sake of simplicity, they are all described as a series of action combinations, but those skilled in the art should know that the present invention is not limited by the described order of actions, because according to the present invention, some steps may be performed in other orders or simultaneously. Secondly, those skilled in the art should also know that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the present invention.
[0082] In the several embodiments provided by the present invention, it should be understood that the disclosed device can be implemented in other ways. For example, the device embodiments described above are only schematic, such as the division of the above units, which is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. The units of the above device embodiments may or may not be physically separated, and some or all of the units may be selected according to actual needs to achieve the purpose of the embodiments of the present invention.
[0083] In addition, each functional unit in each embodiment of the present invention may be integrated into a processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of a software functional unit. If the above-mentioned integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it may be stored in a computer-readable storage medium.
[0084] Based on such understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium and can include several instructions to enable a computer device (which can be a personal computer, a server or a network device, etc., and can be a processor in a computer device) to perform all or part of the steps of the above methods of various embodiments of the present invention. Among them, the aforementioned storage medium can include: U disk, mobile hard disk, disk, optical disk, read-only memory (Read-Only Memory, abbreviated: ROM) or random access memory (Random Access Memory, abbreviated: RAM) and other media that can store program codes. As described above, the above embodiments are only used to illustrate the technical solution of the present invention, rather than to limit it; although the present invention is described in detail with reference to the aforementioned embodiments, ordinary technicians in the field should understand that: it is still possible to modify the technical solutions recorded in the aforementioned embodiments, or to replace some of the technical features therein by equivalent; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the various embodiments of the present invention.
Claims
1. A coordinate origin measurement method, applied to machine tools, It is characterized in that include: Acquire a first image set, a second image set and a third image set of a calibration block fixed at a first position on a first axis; the first image set is a set of multiple first images during the rotation of the calibration block around the first axis; the multiple first images include multiple images of the calibration block at different rotation angles; the second image set is a set of multiple second images during the translation of the calibration block along the second axis; the third image set is a set of multiple third images during the translation of the calibration block along the third axis; the calibration block includes multiple feature points; Determining circular motion trajectories of the plurality of feature points according to the plurality of first images; By fitting the circular motion trajectories of the plurality of feature points, the centers of the plurality of circular motion trajectories are respectively determined; the centers of the plurality of circular motion trajectories are distributed on the first direction vector; Determine the first direction vector according to the multiple circle centers; Calculating coordinates of the calibration block at different positions of each of the plurality of second images; Determining a second direction vector according to coordinates of different positions of each second image; Calculating coordinates of the calibration block at different positions of each of the plurality of third images; Determining a third direction vector according to coordinates of different positions of each third image; determining a first plane according to the second direction vector and the third direction vector; determining an intersection point of the first plane and the first direction vector as a first position; Along the opposite direction of the first direction vector, a position that differs from the first position by a preset distance value is determined as the coordinate origin of the machine tool; the preset distance value is the distance value between the first position and the coordinate origin.
2. The method according to claim 1, It is characterized in that Before acquiring the first image set, the second image set and the third image set of the movement of the calibration block fixed at the first position on the first axis, the method further includes: The image acquisition device is calibrated to determine the internal parameters and distortion parameters of the imaging model corresponding to the image acquisition device; the internal parameters and the distortion parameters are used to convert the images captured by the image acquisition device into the first image set, the second image set or the third image set.
3. The method according to claim 2, It is characterized in that The first axis is an x-axis; the step of acquiring a first image set of movement of a calibration block fixed at a first position on the first axis includes: During the 360-degree rotation of the x-axis, the plurality of first images are captured.
4. A coordinate origin measuring device, used in machine tools, It is characterized in that The device is used to implement the method according to any one of claims 1 to 3.
5. A computer program product, It is characterized in that The method comprises instructions which, when executed on a computer, cause the computer to execute the method according to any one of claims 1 to 3.
6. A computer-readable storage medium, It is characterized in that The computer storage medium stores program instructions, which, when executed by a processor, cause the processor to perform the method according to any one of claims 1 to 3.
