CN112923889B - Scanning method, device, three-dimensional scanning system, electronic device and storage medium - Google Patents

Scanning method, device, three-dimensional scanning system, electronic device and storage medium Download PDF

Info

Publication number
CN112923889B
CN112923889B CN202110101640.1A CN202110101640A CN112923889B CN 112923889 B CN112923889 B CN 112923889B CN 202110101640 A CN202110101640 A CN 202110101640A CN 112923889 B CN112923889 B CN 112923889B
Authority
CN
China
Prior art keywords
motion path
robot
point
path point
scanning
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.)
Active
Application number
CN202110101640.1A
Other languages
Chinese (zh)
Other versions
CN112923889A (en
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.)
Hangzhou Silidi Technology Co ltd
Original Assignee
Hangzhou Silidi Technology 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 Hangzhou Silidi Technology Co ltd filed Critical Hangzhou Silidi Technology Co ltd
Priority to CN202110101640.1A priority Critical patent/CN112923889B/en
Publication of CN112923889A publication Critical patent/CN112923889A/en
Application granted granted Critical
Publication of CN112923889B publication Critical patent/CN112923889B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01BMEASURING LENGTH, THICKNESS OR SIMILAR LINEAR DIMENSIONS; MEASURING ANGLES; MEASURING AREAS; MEASURING IRREGULARITIES OF SURFACES OR CONTOURS
    • G01B21/00Measuring arrangements or details thereof, where the measuring technique is not covered by the other groups of this subclass, unspecified or not relevant
    • G01B21/02Measuring arrangements or details thereof, where the measuring technique is not covered by the other groups of this subclass, unspecified or not relevant for measuring length, width, or thickness
    • G01B21/04Measuring arrangements or details thereof, where the measuring technique is not covered by the other groups of this subclass, unspecified or not relevant for measuring length, width, or thickness by measuring coordinates of points
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01BMEASURING LENGTH, THICKNESS OR SIMILAR LINEAR DIMENSIONS; MEASURING ANGLES; MEASURING AREAS; MEASURING IRREGULARITIES OF SURFACES OR CONTOURS
    • G01B21/00Measuring arrangements or details thereof, where the measuring technique is not covered by the other groups of this subclass, unspecified or not relevant
    • G01B21/20Measuring arrangements or details thereof, where the measuring technique is not covered by the other groups of this subclass, unspecified or not relevant for measuring contours or curvatures, e.g. determining profile

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Numerical Control (AREA)
  • Manipulator (AREA)

Abstract

The application relates to a scanning method, a scanning device, a three-dimensional scanning system, an electronic device and a storage medium. The method comprises the steps of obtaining a planned motion path of a robot, calculating to obtain a correction parameter according to point cloud data of a scanned surface when the robot actually reaches a current motion path point in an actual scanning process, and finally correcting the motion path of the robot according to the calculated correction parameter when the robot reaches the current motion path point and a preset optimal distance of a scanner, so that the distance between the scanner clamped at the tail end of the robot and the surface of a scanned object is kept near the optimal scanning distance of the scanner in the scanning process, and a clear scanning result is obtained.

Description

Scanning method, scanning device, three-dimensional scanning system, electronic device and storage medium
Technical Field
The present application relates to the field of robotics, and in particular, to a scanning method, a scanning device, a three-dimensional scanning system, an electronic device, and a storage medium.
Background
In industrial production, it is a common workpiece scanning method to scan a workpiece by using a robot to carry a scanner. It is a common practice to fix the scanned object and use a teaching programming mode to record the scanning path of the object surface when the robot scans, but this manual teaching mode cannot ensure that the distance between the scanner carried by the robot and the scanned object is near the optimal scanning distance of the scanner, resulting in unclear scanning result.
In view of the above problem that it cannot be guaranteed that the distance between the scanner and the scanned object is kept at the optimal scanning distance, no effective solution has been proposed yet.
Disclosure of Invention
The embodiment of the application provides a scanning method, a scanning device, a three-dimensional scanning system, an electronic device and a storage medium, so as to at least solve the problem that the distance between a scanner and a scanned object cannot be guaranteed to be kept at an optimal scanning distance in the related art.
In a first aspect, an embodiment of the present application provides a scanning method for adjusting a motion path of a robot in an automated scanning process, where an end of the robot carries a scanner, the method including the following steps:
acquiring a planned motion path of the robot, wherein the planned motion path comprises a plurality of planned motion path points;
in the actual scanning process, calculating to obtain a correction parameter according to the point cloud data of the scanned surface when the robot actually reaches the current motion path point;
and correcting the next motion path point of the robot according to the correction parameter and the preset optimal scanning distance of the scanner.
In one embodiment, the acquiring the planned movement path of the robot includes:
determining planned movement path points of the robot in a teaching mode, and acquiring three-dimensional coordinates and posture data when the robot reaches each planned movement path point;
and determining the planned motion path according to the three-dimensional coordinates and the posture data when the robot reaches all the planned motion path points.
In one embodiment, the correcting the next motion path point of the robot according to the correction parameter and the preset optimal scanning distance of the scanner includes:
acquiring a corresponding planned motion vector when the robot reaches a current motion path point;
determining a compensation motion vector according to the optimal scanning distance and the correction parameter when the robot reaches the current motion path point;
and correcting the next motion path point of the robot according to the compensation motion vector and the plan motion vector.
In one embodiment, the correcting the next motion path point of the robot according to the compensated motion vector and the planned motion vector includes:
obtaining a corresponding planned motion vector when the robot reaches the current motion path point
Determining a compensation motion vector according to the optimal scanning distance and the correction parameter when the robot reaches the current motion path point;
and correcting the next motion path point of the robot according to the compensation motion vector and the plan motion vector corresponding to the current motion path point.
In one embodiment, the modifying the next motion path point of the robot according to the compensated motion vector and the planned motion vector corresponding to the current motion path point includes:
determining an actual motion vector of the robot from the current motion path point to a next motion path point according to the compensation motion vector and the plan motion vector;
and correcting the next motion path point of the robot according to the current motion path point and the actual motion vector.
In one embodiment, the correction parameters include an average distance between the scanner and the scanned surface and an average center point of the scanned surface when the robot reaches the current motion path point, and the calculation of the correction parameters according to the point cloud data of the scanned surface when the robot actually reaches each planned motion path point in the actual scanning process includes:
when the robot reaches the current motion path point, point cloud data of the scanned surface is obtained;
obtaining the average distance between the current scanner and the scanned surface according to each point cloud data on the current motion path point and the number of point cloud data on the current motion path point;
and obtaining the average center point of the current scanned surface according to the three-dimensional coordinates of each point cloud data on the current motion path point and the number of the point cloud data on the current motion path point.
In one embodiment, the determining a compensated motion vector according to the optimal scanning distance and the correction parameter when the robot reaches the current motion path point includes:
taking the difference value of the optimal scanning distance and the average distance as the size of a compensation motion vector;
and according to the magnitude relation between the optimal scanning distance and the average distance, the average center point points to the direction of the current motion path point, and the direction of the compensation motion vector is determined.
In a second aspect, an embodiment of the present application provides a scanning apparatus for adjusting a motion path of a robot in an automated scanning process, where the robot has a scanner mounted at an end thereof, the apparatus includes a planned motion module, a correction calculation module, and a path correction module:
the planned motion module is used for acquiring a planned motion path of the robot, and the planned motion path comprises a plurality of planned motion path points;
the correction calculation module is used for calculating to obtain correction parameters according to the point cloud data of the scanned surface when the robot actually reaches each planned motion path point in the actual scanning process;
and the path correction module is used for correcting the next motion path point of the robot according to the correction parameter and the preset optimal scanning distance of the scanner.
In a third aspect, an embodiment of the present application provides a three-dimensional scanning system, which includes a robot and a scanner, where a distal end of the robot carries the scanner, and the system further includes the scanning apparatus as described in the second aspect.
In a fourth aspect, an embodiment of the present application provides an electronic device, which includes a memory, a processor, and a computer program stored on the memory and executable on the processor, and the processor executes the computer program to implement the scanning method according to the first aspect.
In a fifth aspect, an embodiment of the present application provides a storage medium, on which a computer program is stored, and the program, when executed by a processor, implements the scanning method according to the first aspect.
According to the scanning method, the scanning device, the three-dimensional scanning system, the electronic device and the storage medium, the planned motion path of the robot is obtained, the correction parameters are obtained through calculation according to the point cloud data of the scanned surface when the robot actually reaches the current motion path point in the actual scanning process, and finally the motion path of the robot is corrected according to the correction parameters obtained through calculation when the robot reaches the current motion path point and the preset optimal distance of the scanner, so that the distance between the scanner clamped at the tail end of the robot and the surface of the scanned object is kept near the optimal scanning distance of the scanner in the scanning process, and a clear scanning result is obtained.
Drawings
The accompanying drawings, which are included to provide a further understanding of the application and are incorporated in and constitute a part of this application, illustrate embodiment(s) of the application and together with the description serve to explain the application and not to limit the application. In the drawings:
fig. 1 is a diagram of an application environment of a scanning method according to an embodiment of the present application;
FIG. 2 is a flow chart of a scanning method according to an embodiment of the present application;
FIG. 3 is a schematic structural diagram of a scanning device according to an embodiment of the present application;
FIG. 4 is a schematic structural diagram of an electronic device according to an embodiment of the present application;
fig. 5 is a schematic structural diagram of a computer device according to an embodiment of the present application.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more clearly understood, the present application is described and illustrated below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of and not restrictive on the broad application. All other embodiments obtained by a person of ordinary skill in the art based on the embodiments provided in the present application without any inventive step are within the scope of protection of the present application. Moreover, it should be appreciated that in the development of any such actual implementation, as in any engineering or design project, numerous implementation-specific decisions must be made to achieve the developers' specific goals, such as compliance with system-related and business-related constraints, which may vary from one implementation to another.
Reference in the specification to "an embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment can be included in at least one embodiment of the specification. The appearances of the phrase in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. Those of ordinary skill in the art will explicitly and implicitly appreciate that the embodiments described herein may be combined with other embodiments without conflict.
Unless defined otherwise, technical or scientific terms referred to herein shall have the ordinary meaning as understood by those of ordinary skill in the art to which this application belongs. The use of the terms "a" and "an" and "the" and similar referents in the context of describing the invention (including a single reference) are to be construed in a non-limiting sense as indicating either the singular or the plural. The present application is directed to the use of the terms "including," "comprising," "having," and any variations thereof, which are intended to cover non-exclusive inclusions; for example, a process, method, system, article, or apparatus that comprises a list of steps or modules (elements) is not limited to only those steps or elements but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus. Reference to "connected," "coupled," and the like in this application is not intended to be limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect. Reference herein to "a plurality" means greater than or equal to two. "and/or" describes an association relationship of associated objects, meaning that three relationships may exist, for example, "A and/or B" may mean: a exists alone, A and B exist simultaneously, and B exists alone. Reference herein to the terms "first," "second," "third," and the like, are merely to distinguish similar objects and do not denote a particular ordering for the objects.
FIG. 1 is a diagram of an exemplary scanning method. Referring to fig. 1, the method is applied to a three-dimensional scanning system. The system includes a robot 101 and a scanner 102. The scanner 102 is installed at the end of the robot 101, and scans a scanned workpiece 103 along with the movement of the robot 101. The robot 101 may specifically be an industrial robot or a cooperative robot, and the scanner 102 may specifically be a three-dimensional scanner.
In one embodiment, fig. 2 is a flowchart of a scanning method according to an embodiment of the present application, and as shown in fig. 2, the flowchart includes the following steps:
step S201, a planned motion path of the robot is obtained, wherein the planned motion path comprises a plurality of planned motion path points.
The planned movement path of the robot is specifically a planned movement path of the tip of the robot, and since the tip of the robot is mounted with the scanner, the movement path of the tip of the robot can be equivalent to the scanning path of the scanner. The obtaining of the planned movement path of the robot may generally be obtained by a teaching mode, and specifically, the movement of the end of the robot may be controlled by a manual teaching device, so as to determine the planned movement path of the robot, that is, the approximate scanning path of the scanner. The planned movement path can be determined by determining planned movement path points, specifically terminal pose information of the robot, and fitting the planned movement path points into the planned movement path, or directly inputting the planned movement path in a robot teach pendant in a teaching mode.
Step S202, in the actual scanning process, correction parameters are calculated according to the point cloud data of the scanned surface when the robot actually reaches the current motion path point.
The current motion path point reached by the robot may be the first discrete motion path point obtained by discretizing the planned motion path, or the motion path point actually reached by the robot after correction. Generally, when the motion path of the robot is adjusted, the first discrete motion path point is used as the first motion path point reached by the robot. In order to ensure the accuracy of the motion path adjustment, the discretization of the planned motion path is to ensure that the distance between the obtained adjacent discrete motion path points is as small as possible, and is generally less than or equal to 1mm, wherein the discretization of the planned motion path can be implemented by interpolating between the determined planned motion path points.
The scanned surface refers to the surface of the scanned object within the scanning range of the scanner when the robot reaches the current motion path point. The point cloud data of the scanned surface when the robot reaches the current motion path point refers to the point cloud data acquired from the scanned surface by a scanner carried at the tail end of the robot when the robot reaches the current motion path point. The point cloud data is used to describe points on the scanned surface, and may be specifically three-dimensional coordinates and normal data of various locations on the scanned surface. It is understood that the point cloud data on the scanned surface acquired by the scanner should be different when the robot is at different motion path points, and since the scanned surface is not necessarily a plane, the distances between all points on the scanned surface and the scanner are not necessarily equal when the robot reaches the current motion path point. Therefore, in order to control the distance between the motion path point of the robot and the surface to be scanned, correction parameters corresponding to the motion path point can be obtained by performing certain statistical processing on the point cloud data acquired from the motion path point.
The point cloud data mainly comprises three-dimensional coordinates and normal vectors, and reflects the actual situation of the scanned surface acquired by the scanner under the current motion path point, so the correction parameters are one or more parameters determined from the actual situation of the scanned surface, and can be correction distances and correction central points obtained by performing certain statistical processing on the point cloud data. The correction parameter determined according to the actual situation can be used as an actual reference parameter relative to the optimal scanning distance preset by the scanner as an ideal reference parameter, so that the motion path of the robot is corrected from two layers of the ideal scanning distance and the actual scanning distance. The statistical processing may specifically be solving an average value, a maximum value, a minimum value, and the like for distances between all three-dimensional coordinates and the scanner. Relatively speaking, the average distance between the scanner and the scanned surface and the average center point are used as correction parameters to solve the current motion path point, so that the method is more suitable for adjusting the motion path of the robot subsequently.
And calculating to obtain a correction parameter according to the point cloud data of the scanned surface when the robot actually reaches the current motion path point, wherein the correction parameter can reflect the actual distance between the scanner and the scanned surface. Therefore, the next motion path point of the robot is corrected according to the correction parameter and the preset optimal scanning distance of the scanner, so that more accurate scanning positioning can be obtained, and the scanning result is clearer.
And step S203, correcting the next motion path point of the robot according to the correction parameters and the preset optimal scanning distance of the scanner.
In the moving process of the robot, correcting the next moving path point of the robot means that the scanning effect of the scanner is optimal when the robot reaches each moving path point by adjusting the moving direction and the moving distance of the robot at the next time. The preset optimal scanner distance of the scanner belongs to the intrinsic parameters of the scanner hardware, and when scanning is performed, the scanner is kept close to the optimal scanning distance from the object, so that a good scanning effect can be obtained, therefore, when the robot reaches the current motion path point, the motion path point of the robot cannot be directly corrected according to the correction parameters obtained in the step S202, and the next motion path point of the robot needs to be corrected in real time by combining the preset optimal scanning distance of the scanner with the correction parameters. Specifically, the distance from the current motion path point to the next actual motion path point of the robot is corrected by the pair of the optimal scanning distance and the correction parameter.
In the scanning method provided by the above embodiment, the planned motion path of the robot is obtained, and in the actual scanning process, the correction parameter is obtained by calculation according to the point cloud data of the scanned surface when the robot actually reaches the current motion path point, and finally the motion path of the robot is corrected according to the correction parameter obtained by calculation when the robot reaches the current motion path point and the preset optimal distance of the scanner, so that the distance between the scanner clamped at the end of the robot and the surface of the scanned object is kept near the optimal scanning distance of the scanner in the scanning process, and a clear scanning result is obtained.
Further, based on the step S201, in an embodiment, acquiring a planned movement path of the robot includes the following steps:
step S301, determining planned movement path points of the robot in a teaching mode, and acquiring three-dimensional coordinates and posture data when the robot reaches each planned movement path point.
The three-dimensional coordinates describe the spatial position information when the robot reaches the planned movement path point, and the attitude data describe the pointing direction of the tail end of the robot, and can be expressed in the forms of Euler angles, rotation matrixes, quaternions or the like.
Step S302, determining a planned motion path according to the three-dimensional coordinates and the posture data when the robot reaches all the planned motion path points.
The determination of the planned motion path requires not only determining the spatial position of the robot motion through the three-dimensional coordinates on each path point, but also determining the pointing direction of the tail end of the robot on each path point, that is, the pointing direction of the scanner, according to the pose data, so that after the three-dimensional coordinates and the pose data corresponding to all the planned motion path points are obtained, the planned motion path can be determined through fitting and interpolating the three-dimensional coordinates and the pose data.
In one embodiment, based on the step S203, the correcting the next movement path point of the robot according to the correction parameter and the preset optimal scanning distance of the scanner includes:
step S401, acquiring a corresponding planned motion vector when the robot reaches the current motion path point.
After the discretization of the planned motion path is completed,the vector between two adjacent discrete motion path points may be taken as the planned motion vector corresponding to the current motion path point. The magnitude of the planned motion vector between two adjacent discrete motion path points can be the distance between two discrete motion paths, and the direction is from the discrete motion path point close to the starting point of the planned motion path to the discrete motion path point close to the end point of the planned motion path. For example, if the discrete motion path point obtained in the embodiment of the step S202 is N 1 ,N 2 ,...N m Since the current motion path point may be the first discrete motion path point, when the robot reaches the first discrete motion path point N 1 At this time, the corresponding planned motion vector is N 1 N 2 And when the robot reaches the next motion path point N' 2 Of N' 2 For the modified path point, the corresponding planned motion vector is
Figure BDA0002915924120000081
And S402, determining a compensation motion vector according to the optimal scanning distance and the correction parameters when the robot reaches the current motion path point.
The compensation motion vector is a vector for adjusting the size and direction of the originally planned motion vector of the robot to achieve a better scanning effect, and the size and direction of the compensation motion vector can be determined by the optimal scanning distance and the correction parameter. Specifically, the direction of the compensation motion vector may be determined by a correction center point and a current motion path point included in the correction parameter, and the magnitude of the compensation motion vector may be determined by a correction distance and an optimal scan distance included in the correction parameter.
And step S403, correcting the next motion path point of the robot according to the compensation motion vector and the plan motion vector.
Because the motion path of the robot is adjusted, the robot does not move on the current motion path point according to the original planned motion vector, but determines the next motion path point of the robot according to the obtained compensation motion vector on the basis of the original planned motion vector. The next motion path point can be determined by planning the direction and magnitude of the motion vector and compensating the direction and magnitude of the motion vector.
In one embodiment, modifying the next motion path point of the robot based on the compensated motion vector and the planned motion vector comprises:
and step S501, determining an actual motion vector of the robot from the current motion path point to the next motion path point according to the compensated motion vector and the planned motion vector.
The next motion path point represents the next motion path point that the robot will actually reach from the current motion path point according to the adjustment made in the above steps. The actual motion vector includes the distance and direction that the robot moved when reaching the next motion path point from the current motion path point. Specifically, the compensated motion vector and the planned motion vector are summed, or the compensated motion vector and the planned motion vector are summed according to a triangle method, so that an actual motion vector reaching a next motion path point from a current motion path point is obtained, or the actual motion vector is obtained according to an operation method among other vectors, so that the robot can keep a proper scanning distance with a scanned surface at the next motion path point, and a better scanning effect is achieved.
And step S502, correcting the next motion path point of the robot according to the current motion path point and the actual motion vector.
Specifically, after the robot reaches the next motion path point from the current motion path point along the actual motion vector, the currently reached motion path point is used as the current motion path point, and the next motion path point and the actual motion vector are determined according to the methods from step S202 to step S501, and so on until the robot completes the scanning work.
In one embodiment, the correction parameters include an average distance between the scanner and the scanned surface and an average center point of the scanned surface when the robot reaches the current motion path point, and in the actual scanning process, the correction parameters are calculated according to the point cloud data of the scanned surface when the robot actually reaches each planned motion path point, and the method includes the following steps:
step S601, when the robot reaches the current motion path point, acquiring point cloud data of the scanned surface.
Step S602, obtaining an average distance between the current scanner and the scanned surface according to each point cloud data on the current motion path point and the number of point cloud data on the current motion path point.
The average distance of the scanner from the scanned surface is equal to the average distance of the current path point from the scanned surface. And (4) obtaining the average distance between the scanner and the scanned surface by counting and averaging the distances between all the point cloud data and the scanner. The number of point cloud data on the current motion path point refers to the number of all point cloud data acquired by the scanner from the scanned surface when the robot reaches the current motion path point. And obtaining the average distance from the current scanner to the scanned surface according to each point cloud data on the current motion path point and the number of the point cloud data on the current motion path point, averaging the distances between all the point cloud data and the current path point according to the number of all the point cloud data, and obtaining the average distance by using other statistical methods.
Step S603, obtaining an average center point of the current scanned surface according to the three-dimensional coordinates of each point cloud data on the current motion path point and the number of point cloud data on the current motion path point.
In order to correct the motion path point of the robot, i.e. determine the next scanning position of the scanner, it is also necessary to calculate the average center point of the scanned surface when the robot reaches the current motion path point, which may be obtained by averaging the coordinate statistics of all the point cloud data. The three-dimensional coordinates of each point cloud data on the current motion path point refer to specific position information of the point cloud data acquired by the scanned surface when the robot reaches the current motion path point. To calculate the average center point of the currently scanned surface, the specific way may be: first, all the surfaces to be scanned are countedThree-dimensional coordinates of point cloud data, e.g. total of n point cloud data, e.g. (x) 1 ,y 1 ,z 1 ),(x 2 ,y 2 ,z 2 ),...,(x n ,y n ,z n ) Then the mean center point can be calculated as ((x) 1 +x 2 +...+x n )/n,(y 1 +y 2 +...+y n )/n,(z 1 +z 2 +...+z n ) And/n). It should be noted that, regarding the calculation method of the average center point of the scanned surface, the average center point may also be calculated in other statistical methods after obtaining the three-dimensional coordinates of all the point cloud data and the number of the point cloud data.
In one embodiment, based on the above steps S601 to S602, determining a compensated motion vector according to the optimal scanning distance and the correction parameter when the robot reaches the current motion path point, includes the following steps:
in step S701, the difference between the optimal scanning distance and the average distance is used as the magnitude of the compensation motion vector.
For example, if the optimal distance of the scanner is d1, and the average distance between the scanned surface and the current path point when the robot reaches the current motion path point is d2, the magnitude of the compensation motion vector is the absolute value of the subtraction between d1 and d 2.
Step S702, according to the magnitude relation between the optimal scanning distance and the average distance, the average center point points to the direction of the current motion path point, and the direction of the compensation motion vector is determined.
And when the average distance is smaller than the optimal scanning distance, the direction of the compensation motion vector points to the current motion path point from the average center point, otherwise, the direction of the compensation motion vector points to the average center point from the current motion path point.
For example, when the robot reaches the current motion path point N 1 When the average center point is obtained as P 1 Then if the average distance d2 is smaller than the optimal scanning distance d1, then the direction of the motion vector and the vector P are compensated 1 N 1 If d2 is greater than d1, then the direction of the motion vector and the vector N are compensated 1 P 1 And (5) the consistency is achieved.
The above steps, determining the planned motion path of the robot, and obtaining the planned motion vector of the robot to the current motion path point, so as to determine the planned direction and planned distance of the robot from the current motion path point to the next motion path point, and provide a basis for subsequent correction, and then in the actual scanning process, calculating the correction parameter when the robot reaches the current motion path point, and correcting the motion path of the robot according to the correction parameter calculated when the robot reaches the current motion path point, the planned motion vector, and the preset optimal distance of the scanner, wherein the average distance from the scanner to the scanned surface and the average center point of the scanned surface are also used as the correction parameters, so that the distance from the scanner clamped at the tail end of the robot to the surface of the scanned object in the scanning process is kept near the optimal scanning distance of the scanner, and a clear scanning result is obtained.
In one embodiment, as shown in fig. 3, there is provided a scanning apparatus 30 comprising: a planned movement module 32, a correction calculation module 34, and a path correction module 36, wherein:
a planned movement module 32, configured to obtain a planned movement path of the robot, where the planned movement path includes a plurality of planned movement path points;
a correction calculation module 34, configured to calculate, in an actual scanning process, a correction parameter according to point cloud data of a scanned surface when the robot actually reaches each planned movement path point;
and a path correction module 36, configured to correct a next motion path point of the robot according to the correction parameter and a preset optimal scanning distance of the scanner.
According to the scanning device provided by the embodiment, the planned motion path of the robot is obtained, the correction parameter is obtained through calculation according to the point cloud data of the scanned surface when the robot actually reaches the current motion path point in the actual scanning process, and finally the motion path of the robot is corrected according to the correction parameter obtained through calculation when the robot reaches the current motion path point and the preset optimal distance of the scanner, so that the distance between the scanner clamped at the tail end of the robot and the surface of the scanned object is kept near the optimal scanning distance of the scanner in the scanning process, and a clear scanning result is obtained.
In one embodiment, the planned movement module 32 is further configured to determine planned movement path points of the robot in a teaching manner, acquire three-dimensional coordinates and posture data when the robot reaches each planned movement path point, and determine a planned movement path according to the three-dimensional coordinates and posture data when the robot reaches all the planned movement path points.
In an embodiment, the path correcting module 36 is further configured to obtain a corresponding planned motion vector when the robot reaches the current motion path point, determine a compensated motion vector according to the optimal scanning distance and the correction parameter when the robot reaches the current motion path point, and correct the next motion path point of the robot according to the compensated motion vector and the planned motion vector.
In an embodiment, the path modification module 36 is further configured to determine an actual motion vector of the robot from the current motion path point to the next motion path point according to the compensated motion vector and the planned motion vector, and modify the next motion path point of the robot according to the current motion path point and the actual motion vector.
In one embodiment, the correction parameters include an average distance between the scanner and the scanned surface and an average center point of the scanned surface when the robot reaches the current motion path point, and the path correction module 36 is further configured to obtain point cloud data of the scanned surface when the robot reaches the current motion path point, obtain the average distance between the scanner and the scanned surface according to each point cloud data on the current motion path point and the number of point cloud data on the current motion path point, and obtain the average center point of the scanned surface according to the three-dimensional coordinates of each point cloud data on the current motion path point and the number of point cloud data on the current motion path point.
In an embodiment, the path modification module 36 is further configured to use a difference between the optimal scanning distance and the average distance as a size of the compensated motion vector, and determine a direction of the compensated motion vector according to a size relationship between the optimal scanning distance and the average distance, where the average center point points to a direction of the current motion path point.
For the specific definition of the scanning device, reference may be made to the above definition of the scanning method, which is not described herein again. The modules in the scanning device can be wholly or partially implemented by software, hardware and a combination thereof. The modules can be embedded in a hardware form or independent from a processor in the computer device, and can also be stored in a memory in the computer device in a software form, so that the processor can call and execute operations corresponding to the modules.
In an embodiment, a three-dimensional scanning system is provided, which includes a robot and a scanner, and the scanner is mounted at the end of the robot, and the system further includes the scanning apparatus provided in the foregoing embodiment, and for specific limitations of the apparatus, reference may be made to the above limitations on the scanning method, which is not described herein again. The three-dimensional scanning system described above may be implemented in whole or in part by software, hardware, and combinations thereof. The system can be embedded in a hardware form or independent from a processor in the computer device, and can also be stored in a memory in the computer device in a software form, so that the processor can call and execute the corresponding operation of the system.
In one embodiment, as shown in FIG. 4, an electronic device is provided that includes a memory and a processor. The memory has stored therein a computer program for providing computing and control capabilities to the processor of the electronic device. The memory of the electronic device comprises a nonvolatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of an operating system and computer programs in the non-volatile storage medium.
Optionally, the electronic apparatus may further include a transmission device and an input/output device, wherein the transmission device is connected to the processor, and the input/output device is connected to the processor.
Optionally, in this embodiment, the processor, when executing the computer program, implements the following steps:
acquiring a planned motion path of the robot, wherein the planned motion path comprises a plurality of planned motion path points;
in the actual scanning process, calculating to obtain a correction parameter according to the point cloud data of the scanned surface when the robot actually reaches the current motion path point;
and correcting the next motion path point of the robot according to the correction parameter and the preset optimal scanning distance of the scanner.
In one embodiment, the processor, when executing the computer program, further performs the steps of:
determining planned movement path points of the robot in a teaching mode, and acquiring three-dimensional coordinates and posture data when the robot reaches each planned movement path point;
and determining the planned motion path according to the three-dimensional coordinates and the attitude data when the robot reaches all the planned motion path points.
In one embodiment, the processor, when executing the computer program, further performs the steps of:
acquiring a corresponding planned motion vector when the robot reaches a current motion path point;
determining a compensation motion vector according to the optimal scanning distance and the correction parameters when the robot reaches the current motion path point;
and correcting the next motion path point of the robot according to the compensation motion vector and the plan motion vector.
In one embodiment, the processor, when executing the computer program, further performs the steps of:
determining the actual motion vector of the robot from the current motion path point to the next motion path point according to the compensation motion vector and the plan motion vector;
and correcting the next motion path point of the robot according to the current motion path point and the actual motion vector.
In one embodiment, the processor when executing the computer program further performs the steps of:
when the robot reaches the current motion path point, point cloud data of the scanned surface are obtained;
obtaining the average distance between the current scanner and the scanned surface according to the point cloud data on the current motion path point and the number of the point cloud data on the current motion path point;
and obtaining the average center point of the current scanned surface according to the three-dimensional coordinates of each point cloud data on the current motion path point and the number of the point cloud data on the current motion path point.
In one embodiment, the processor, when executing the computer program, further performs the steps of:
taking the difference value between the optimal scanning distance and the average distance as the size of a compensation motion vector;
and according to the magnitude relation between the optimal scanning distance and the average distance, the average center point points to the direction of the current motion path point, and the direction of the compensation motion vector is determined.
The processor included in the electronic device obtains the planned motion path of the robot, calculates and obtains a correction parameter according to the point cloud data of the scanned surface when the robot actually reaches the current motion path point in the actual scanning process, and corrects the motion path of the robot according to the calculated correction parameter when the robot actually reaches the current motion path point and the preset optimal distance of the scanner, so that the distance between the scanner clamped at the tail end of the robot and the surface of the scanned object is kept near the optimal scanning distance of the scanner in the scanning process, and a clear scanning result is obtained.
It should be noted that, for specific examples in this embodiment, reference may be made to examples described in the foregoing embodiments and optional implementations, and details of this embodiment are not described herein again.
In one embodiment, a computer device is provided, which may be a server, the internal structure of which may be as shown in fig. 5. The computer device includes a processor, a memory, a network interface, and a database connected by a system bus. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device comprises a nonvolatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of an operating system and computer programs in the non-volatile storage medium. The database of the computer device is used for storing a preset configuration information set. The network interface of the computer device is used for communicating with an external terminal through a network connection. Which computer program is executed by a processor to implement the scanning method described above.
It will be appreciated by those skilled in the art that the configuration shown in fig. 5 is a block diagram of only a portion of the configuration associated with the present application, and is not intended to limit the computing device to which the present application may be applied, and that a particular computing device may include more or less components than those shown, or may combine certain components, or have a different arrangement of components.
There is also provided in one embodiment a storage medium having stored thereon a computer program which when executed by a processor performs the steps of:
acquiring a planned motion path of the robot, wherein the planned motion path comprises a plurality of planned motion path points;
in the actual scanning process, calculating to obtain a correction parameter according to the point cloud data of the scanned surface when the robot actually reaches the current motion path point;
and correcting the next motion path point of the robot according to the correction parameter and the preset optimal scanning distance of the scanner.
In one embodiment, the processor when executing the computer program further performs the steps of:
determining planned movement path points of the robot in a teaching mode, and acquiring three-dimensional coordinates and posture data when the robot reaches each planned movement path point;
and determining a planned movement path according to the three-dimensional coordinates and the attitude data when the robot reaches all the planned movement path points.
In one embodiment, the processor, when executing the computer program, further performs the steps of:
acquiring a corresponding planned motion vector when the robot reaches a current motion path point;
determining a compensation motion vector according to the optimal scanning distance and the correction parameters when the robot reaches the current motion path point;
and correcting the next motion path point of the robot according to the compensation motion vector and the plan motion vector.
In one embodiment, the processor when executing the computer program further performs the steps of:
determining the actual motion vector of the robot from the current motion path point to the next motion path point according to the compensation motion vector and the plan motion vector;
and correcting the next motion path point of the robot according to the current motion path point and the actual motion vector.
In one embodiment, the processor when executing the computer program further performs the steps of:
when the robot reaches the current motion path point, point cloud data of the scanned surface are obtained;
obtaining the average distance between the current scanner and the scanned surface according to the point cloud data on the current motion path point and the number of the point cloud data on the current motion path point;
and obtaining the average center point of the current scanned surface according to the three-dimensional coordinates of each point cloud data on the current motion path point and the number of the point cloud data on the current motion path point.
In one embodiment, the processor when executing the computer program further performs the steps of:
taking the difference value between the optimal scanning distance and the average distance as the size of a compensation motion vector;
and according to the magnitude relation between the optimal scanning distance and the average distance, the average center point points to the direction of the current motion path point, and the direction of the compensation motion vector is determined.
The storage medium obtains the planned motion path of the robot, calculates and obtains a correction parameter according to the point cloud data of the scanned surface when the robot actually reaches the current motion path point in the actual scanning process, and finally corrects the motion path of the robot according to the calculated correction parameter when the robot reaches the current motion path point and the preset optimal distance of the scanner, so that the distance between the scanner clamped at the tail end of the robot and the surface of the scanned object is kept near the optimal scanning distance of the scanner in the scanning process, and a clear scanning result is obtained.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above may be implemented by hardware instructions of a computer program, which may be stored in a non-volatile computer-readable storage medium, and when executed, may include the processes of the embodiments of the methods described above. Any reference to memory, storage, database or other medium used in the embodiments provided herein can include non-volatile and/or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically Programmable ROM (EPROM), electrically Erasable Programmable ROM (EEPROM), or flash memory. Volatile memory can include Random Access Memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms such as Static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double Data Rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous Link DRAM (SLDRAM), rambus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
The technical features of the above embodiments can be arbitrarily combined, and for the sake of brevity, all possible combinations of the technical features in the above embodiments are not described, but should be considered as the scope of the present specification as long as there is no contradiction between the combinations of the technical features.
The above-mentioned embodiments only express several embodiments of the present application, and the description thereof is more specific and detailed, but not construed as limiting the scope of the invention. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the concept of the present application, and these are all within the scope of protection of the present application. Therefore, the protection scope of the present patent application shall be subject to the appended claims.

Claims (9)

1. A scanning method for adjusting a motion path of a robot having a scanner mounted at a distal end thereof in an automated scanning process, the method comprising:
acquiring a planned motion path of the robot, wherein the planned motion path comprises a plurality of planned motion path points;
in the actual scanning process, calculating to obtain correction parameters according to the point cloud data of the scanned surface when the robot actually reaches the current motion path point;
correcting the next motion path point of the robot according to the correction parameter and the preset optimal scanning distance of the scanner;
wherein the correction parameters comprise the average distance from the scanner to the scanned surface and the average center point of the scanned surface when the robot reaches the current motion path point; in the actual scanning process, a correction parameter is calculated according to the point cloud data of the scanned surface when the robot actually reaches the current motion path point, and the method comprises the following steps:
when the robot reaches the current motion path point, point cloud data of the scanned surface is obtained;
obtaining the average distance between the current scanner and the scanned surface according to the point cloud data on the current motion path point and the number of the point cloud data on the current motion path point;
and obtaining the average center point of the current scanned surface according to the three-dimensional coordinates of each point cloud data on the current motion path point and the number of the point cloud data on the current motion path point.
2. The method of claim 1, wherein the obtaining the planned motion path of the robot comprises:
determining the planned movement path points of the robot in a teaching mode, and acquiring three-dimensional coordinates and posture data when the robot reaches each planned movement path point;
and determining the planned motion path according to the three-dimensional coordinates and the posture data when the robot reaches all the planned motion path points.
3. The method of claim 1, wherein the correcting the next motion path point of the robot according to the correction parameter and the preset optimal scanning distance of the scanner comprises:
acquiring a corresponding planned motion vector when the robot reaches the current motion path point;
determining a compensation motion vector according to the optimal scanning distance and the correction parameter when the robot reaches the current motion path point;
and correcting the next motion path point of the robot according to the compensation motion vector and the plan motion vector.
4. The method of claim 3, wherein said modifying the next motion path point of the robot based on the compensated motion vector and the planned motion vector comprises:
determining an actual motion vector of the robot from the current motion path point to a next motion path point according to the compensation motion vector and the plan motion vector;
and correcting the next motion path point of the robot according to the current motion path point and the actual motion vector.
5. The method of claim 3, wherein determining a compensated motion vector according to the optimal scanning distance and the correction parameter when the robot reaches the current motion path point comprises:
taking the difference between the optimal scanning distance and the average distance as the size of the compensation motion vector;
and according to the size relation between the optimal scanning distance and the average distance, the average center point points to the direction of the current motion path point, and the direction of the compensation motion vector is determined.
6. A scanning device is used for adjusting the motion path of a robot in an automatic scanning process, and the tail end of the robot is provided with a scanner, and is characterized by comprising a planning motion module, a correction calculation module and a path correction module:
the planning motion module is used for acquiring a planning motion path of the robot, and the planning motion path comprises a plurality of planning motion path points;
the correction calculation module is used for calculating to obtain correction parameters according to the point cloud data of the scanned surface when the robot actually reaches the current motion path point in the actual scanning process; wherein the correction parameters comprise the average distance of the scanner from the scanned surface and the average center point of the scanned surface when the robot reaches the current motion path point; the correction calculation module is further configured to: when the robot reaches the current motion path point, point cloud data of the scanned surface are obtained; obtaining the average distance between the current scanner and the scanned surface according to the point cloud data on the current motion path point and the number of the point cloud data on the current motion path point; obtaining the average center point of the current scanned surface according to the three-dimensional coordinates of each point cloud data on the current motion path point and the number of the point cloud data on the current motion path point;
and the path correction module is used for correcting the next motion path point of the robot according to the correction parameter and the preset optimal scanning distance of the scanner.
7. A three-dimensional scanning system comprising a robot and a scanner, said robot having a distal end carrying said scanner, characterized in that said system further comprises a scanning apparatus as claimed in claim 6.
8. An electronic device comprising a memory and a processor, wherein the memory has stored therein a computer program, and wherein the processor is configured to execute the computer program to perform the scanning method of any one of claims 1 to 5.
9. A computer-readable storage medium, in which a computer program is stored, wherein the computer program is arranged to perform the scanning method of any one of claims 1 to 5 when executed.
CN202110101640.1A 2021-01-26 2021-01-26 Scanning method, device, three-dimensional scanning system, electronic device and storage medium Active CN112923889B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110101640.1A CN112923889B (en) 2021-01-26 2021-01-26 Scanning method, device, three-dimensional scanning system, electronic device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110101640.1A CN112923889B (en) 2021-01-26 2021-01-26 Scanning method, device, three-dimensional scanning system, electronic device and storage medium

Publications (2)

Publication Number Publication Date
CN112923889A CN112923889A (en) 2021-06-08
CN112923889B true CN112923889B (en) 2023-03-14

Family

ID=76165997

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110101640.1A Active CN112923889B (en) 2021-01-26 2021-01-26 Scanning method, device, three-dimensional scanning system, electronic device and storage medium

Country Status (1)

Country Link
CN (1) CN112923889B (en)

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002048522A (en) * 2000-05-22 2002-02-15 Mitsutoyo Corp Scanning type shape analyzer for analyzing space of wide inspection face
CN1747816A (en) * 2003-02-13 2006-03-15 Abb公司 A method and a system for programming an industrial robot to move relative to defined positions on an object, including generation of a surface scanning program
CN1816729A (en) * 2003-06-30 2006-08-09 本田技研工业株式会社 Three-dimensional shape measuring method and measuring apparatus thereof
CN104976950A (en) * 2014-04-08 2015-10-14 财团法人工业技术研究院 Object space information measuring device and method and image capturing path calculating method
CN106168475A (en) * 2015-05-22 2016-11-30 株式会社三丰 The control method of shape measuring apparatus and control device
CN107144236A (en) * 2017-05-25 2017-09-08 西安交通大学苏州研究院 A kind of robot automatic scanner and scan method
JP2018054430A (en) * 2016-09-28 2018-04-05 株式会社東芝 Inspection device and method of generating measurement trajectory path
CN109029453A (en) * 2018-07-13 2018-12-18 南方科技大学 Cladding head attitude path planning method, apparatus, terminal, storage medium and system
CN111238366A (en) * 2020-01-09 2020-06-05 北京天远三维科技股份有限公司 Three-dimensional scanning path planning method and device

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4595042B2 (en) * 2005-09-30 2010-12-08 コニカミノルタセンシング株式会社 Three-dimensional measurement method and system, and manipulator control method and apparatus
CN105824237B (en) * 2016-03-11 2018-10-09 西北工业大学 Adaptive offset control method based on line laser sensor

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002048522A (en) * 2000-05-22 2002-02-15 Mitsutoyo Corp Scanning type shape analyzer for analyzing space of wide inspection face
CN1747816A (en) * 2003-02-13 2006-03-15 Abb公司 A method and a system for programming an industrial robot to move relative to defined positions on an object, including generation of a surface scanning program
CN1816729A (en) * 2003-06-30 2006-08-09 本田技研工业株式会社 Three-dimensional shape measuring method and measuring apparatus thereof
CN104976950A (en) * 2014-04-08 2015-10-14 财团法人工业技术研究院 Object space information measuring device and method and image capturing path calculating method
CN106168475A (en) * 2015-05-22 2016-11-30 株式会社三丰 The control method of shape measuring apparatus and control device
JP2018054430A (en) * 2016-09-28 2018-04-05 株式会社東芝 Inspection device and method of generating measurement trajectory path
CN107144236A (en) * 2017-05-25 2017-09-08 西安交通大学苏州研究院 A kind of robot automatic scanner and scan method
CN109029453A (en) * 2018-07-13 2018-12-18 南方科技大学 Cladding head attitude path planning method, apparatus, terminal, storage medium and system
CN111238366A (en) * 2020-01-09 2020-06-05 北京天远三维科技股份有限公司 Three-dimensional scanning path planning method and device

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
"基于遗传算法的机翼壁板扫描路径优化";艾小祥 等;《浙江大学学报(工学版)》;20150331;第49卷(第3期);第450页 *

Also Published As

Publication number Publication date
CN112923889A (en) 2021-06-08

Similar Documents

Publication Publication Date Title
CN109285190B (en) Object positioning method and device, electronic equipment and storage medium
WO2022165973A1 (en) Three-dimensional scanning method and system, electronic device, and computer equipment
JP5850962B2 (en) Robot system using visual feedback
EP3157715B1 (en) Method for calibrating a robot and a robot system
CN113001535B (en) Automatic correction system and method for robot workpiece coordinate system
CN111438688B (en) Robot correction method, robot correction device, computer equipment and storage medium
CN111195897B (en) Calibration method and device for mechanical arm system
CN112659129B (en) Robot positioning method, device and system and computer equipment
CN110722558A (en) Origin correction method and device for robot, controller and storage medium
CN110682293A (en) Robot arm correction method, robot arm correction device, robot arm controller and storage medium
JP2011235400A (en) Calibration method of manipulator and robot control system
CN109531604B (en) Robot control device for performing calibration, measurement system, and calibration method
US8761936B2 (en) Teaching line correcting apparatus, teaching line correcting method, and program thereof
CN111915681B (en) External parameter calibration method, device, storage medium and equipment for multi-group 3D camera group
CN112923889B (en) Scanning method, device, three-dimensional scanning system, electronic device and storage medium
CN109909999B (en) Method and device for acquiring TCP (Transmission control protocol) coordinates of robot
KR102269776B1 (en) Calibration Method of Robot for Interventional treatment
CN117021113A (en) Mechanical arm cooperative positioning assembly method, system and medium
US20220402141A1 (en) Method and apparatus for calibrating position of robot using 3d scanner
CN113442144B (en) Optimal pose determining method and device under constraint, storage medium and mechanical arm
CN114310869B (en) Robot hand-eye calibration method, system and terminal
CN115401688A (en) Control method and device of mechanical arm, mechanical arm system and storage medium
CN110989581B (en) Method and device for controlling conveyance system, computer device, and storage medium
CN111699445A (en) Robot kinematics model optimization method and system and storage device
JP2022142376A (en) Robot system, and robot system control method

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
GR01 Patent grant
GR01 Patent grant