Detection methods, devices, electronic equipment, and storage media based on 3D printing equipment
By controlling the laser light source to scan the outline pattern in the 3D printing equipment and calculating the offset using the intersection of three printing lines, the problem of laser light source installation offset is solved, achieving high-precision automatic detection and reducing manual intervention.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-21
- Publication Date
- 2026-04-03
AI Technical Summary
The laser light source of 3D printing equipment may be misaligned during installation. Manual measurement is time-consuming and inaccurate, affecting the user experience.
By controlling the laser light source emission line to scan the contour pattern, and using the design of three printing lines intersecting at the same point, the offset of the laser light source in different directions is calculated, including the offset in the first preset direction and the second preset direction. Point cloud registration technology is used to obtain accurate spacing and angle data.
It enables automatic detection of laser source offset, reducing labor costs and improving measurement accuracy and user experience.
Smart Images

Figure CN119000147B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of 3D printing technology, and in particular to a detection method, apparatus, electronic device and storage medium based on 3D printing equipment. Background Technology
[0002] With the popularization of concepts such as intelligent manufacturing engineering and Industry 4.0, 3D printing technology is becoming increasingly widespread. 3D printing technology first appeared in the mid-1990s and is essentially a new rapid prototyping device utilizing techniques such as photopolymerization and paper lamination. Its working principle is basically the same as ordinary printing; the printer contains liquid or powder "printing materials," and after being connected to a computer, the computer controls the layering of these "printing materials" to ultimately transform the blueprint on the computer into a physical object. This printing technology is called 3D stereolithography.
[0003] In related technologies, the laser light source of 3D printing equipment may be misaligned during installation. Manually measuring the misalignment is time-consuming and has poor measurement accuracy, which leads to a poor user experience. Summary of the Invention
[0004] In view of this, this application provides a detection method, apparatus, electronic device and storage medium based on 3D printing equipment, which can automatically detect the offset of the laser light source installation, reduce labor costs and have high measurement accuracy.
[0005] The first aspect of this application provides a detection method based on a 3D printing device. The 3D printing device includes a laser source for emitting a line laser, a nozzle assembly, and a printing platform. The nozzle assembly is used to eject printing material onto the printing platform. The method includes: controlling the nozzle assembly to print a contour pattern on the printing platform, wherein the contour pattern includes at least three printing lines intersecting at the same point, and the included angle between adjacent printing lines is a preset angle; controlling the laser source to emit a line laser to scan the contour pattern, wherein the line laser intersects the three printing lines sequentially at a first intersection point, a second intersection point, and a third intersection point; obtaining a first distance between the first intersection point and the second intersection point in a first preset direction, and a second distance between the second intersection point and the third intersection point in the first preset direction, based on the scanning result of the laser source; calculating a first offset of the laser source in the first preset direction based on the first distance and the second distance, and calculating a second offset of the laser source in the second preset direction based on the first distance, the second distance, and the preset angle, wherein the second preset direction is perpendicular to the first preset direction.
[0006] Compared with related technologies, the embodiments of this application have at least the following advantages: By controlling the laser source to emit line lasers to scan the contour pattern, since the contour pattern includes at least three printed lines intersecting at the same point, the line laser can sequentially intersect the three printed lines at the first intersection point, the second intersection point, and the third intersection point. This allows the specific positions of the first, second, and third intersection points to be obtained based on the scanning results, and further enables the calculation of the first distance between the first and second intersection points in a first preset direction, and the second distance between the second and third intersection points in the same first preset direction. After calculating the first and second distances, the first offset of the laser source in the first preset direction can be determined based on the relationship between the first and second distances. Since the included angle between adjacent printed lines is a preset angle, the second offset of the laser source in the second preset direction can be calculated based on the first distance, the second distance, and the preset angle. This achieves automatic detection of the offset of the laser source in the first and second preset directions, reducing labor costs and increasing measurement accuracy, thus improving the user experience.
[0007] In some possible implementations, before controlling the printhead assembly to print the outline pattern on the printing platform, the method further includes: controlling the laser source to emit a linear laser to scan the printing platform before the outline pattern is printed, obtaining raw point cloud data of the printing platform at a preset position; the control of the laser source to emit a linear laser to scan the outline pattern includes: controlling the laser source to emit the linear laser and scan the outline pattern at the preset position to obtain target point cloud data of the printing platform; and calculating the first spacing and the second spacing based on the raw point cloud data and the target point cloud data.
[0008] In some possible implementations, the three printing lines include a first printing line, a second printing line, and a third printing line arranged sequentially along the first preset direction; the step of calculating the first spacing and the second spacing based on the original point cloud data and the target point cloud data includes: performing point cloud registration on the original point cloud data and the target point cloud data, and determining the difference point cloud data in the target point cloud data based on the point cloud registration result, wherein the difference point cloud data is the point cloud data of the first line segment, the second line segment, and the third line segment that the line laser intersects with the first printing line, the second printing line, and the third printing line, respectively; calculating the first coordinate of the first intersection point in the first preset direction based on the point cloud data of the first line segment, calculating the second coordinate of the second intersection point in the first preset direction based on the point cloud data of the second line segment, and calculating the third coordinate of the third intersection point in the first preset direction based on the point cloud data of the third line segment; using the difference between the second coordinate and the first coordinate as the first spacing, and using the difference between the third coordinate and the second coordinate as the second spacing.
[0009] In some possible implementations, the detection method further includes: establishing a Cartesian coordinate system, wherein the first preset direction is the direction of the x-axis in the Cartesian coordinate system, the second preset direction is the direction of the y-axis in the Cartesian coordinate system, the second printed line coincides with the y-axis, and both the original point cloud data and the target point cloud data are obtained based on the Cartesian coordinate system; the step of calculating the first offset of the laser source in the first preset direction according to the first spacing and the second spacing includes: calculating the first offset according to the following formula: dx=[Jx+(Ix+Kx) / 2] / 2, where dx is the first offset, Jx is the second coordinate, Ix is the first coordinate, and Kx is the third coordinate.
[0010] In some possible implementations, before calculating the second offset of the laser source in the second preset direction based on the first spacing, the second spacing, and the preset angle, the method further includes: obtaining the line length of the second printed line; the calculation of the second offset of the laser source in the second preset direction based on the first spacing, the second spacing, and the preset angle includes: calculating the second offset according to the following formula: dy=L / 2-2*d1*d2 / [(d1+d2)*tan(θ)]; where dy is the second offset, d1 is the first spacing, d2 is the second spacing, θ is the preset angle, and L is the line length.
[0011] In some possible implementations, controlling the laser source to emit the line laser and scan the contour pattern at the preset position to obtain the target point cloud data of the printing platform includes: controlling the laser source to emit the line laser according to the preset laser beam diameter, and controlling the laser source to move to the preset position to obtain the target point cloud data.
[0012] In some possible implementations, the outline pattern is an isosceles triangle with an altitude; the three printed lines are the two legs and the altitude of the isosceles triangle, the first intersection point and the third intersection point are the intersection points of the line laser with the two legs, and the second intersection point is the intersection point of the line laser with the altitude.
[0013] A second aspect of this application discloses a detection device based on a 3D printing equipment. The 3D printing equipment includes a laser source for emitting line lasers, a nozzle assembly, and a printing platform. The nozzle assembly is used to eject printing material onto the printing platform. The detection device includes a control module, a first calculation module, and a second calculation module. The control module is used to control the nozzle assembly to print a contour pattern on the printing platform, wherein the contour pattern includes at least three printing lines intersecting at the same point, and the included angle between adjacent printing lines is a preset angle. The control module is also used to control the laser source to emit line lasers to scan the contour pattern, wherein the line lasers... The light sequentially intersects the three printed lines at a first intersection point, a second intersection point, and a third intersection point. The first calculation module is used to obtain a first distance between the first intersection point and the second intersection point in a first preset direction, and a second distance between the second intersection point and the third intersection point in the first preset direction, based on the scanning result of the laser light source. The second calculation module is used to calculate a first offset of the laser light source in the first preset direction based on the first distance and the second distance, and to calculate a second offset of the laser light source in the second preset direction based on the first distance, the second distance, and the preset angle, wherein the second preset direction is perpendicular to the first preset direction.
[0014] A third aspect of this application discloses an electronic device, which includes a processor and a memory. The memory is used to store instructions, and the processor is used to call the instructions in the memory to cause the electronic device to execute the above-described detection method based on a 3D printing device.
[0015] The fourth aspect of this application discloses a computer-readable storage medium including computer instructions that, when executed on an electronic device, cause the electronic device to perform the aforementioned detection method based on a 3D printing device.
[0016] Understandably, the detection device based on 3D printing equipment in the second aspect, the electronic device in the third aspect, and the computer-readable storage medium in the fourth aspect all correspond to the method in the first aspect. Therefore, the beneficial effects they can achieve can be referred to the beneficial effects in the corresponding methods provided above, and will not be repeated here. Attached Figure Description
[0017] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings in the embodiments will be briefly described below. It should be understood that the following drawings only show some embodiments of this application and should not be regarded as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0018] Figure 1 A flowchart of a detection method based on a 3D printing device provided in an embodiment of this application.
[0019] Figure 2 This is a schematic diagram of the outline pattern and line laser provided in an embodiment of this application.
[0020] Figure 3 A flowchart of a detection method based on a 3D printing device provided in an embodiment of this application.
[0021] Figure 4 This is an application scenario diagram showing the original point cloud data and target point cloud data provided in an embodiment of this application when point cloud registration has not been performed.
[0022] Figure 5 An application scenario diagram showing the point cloud registration of the original point cloud data and the target point cloud data provided in an embodiment of this application.
[0023] Figure 6 This is an application scenario diagram of a line laser scanning contour pattern provided in an embodiment of this application.
[0024] Figure 7 This is a schematic diagram illustrating the calculation of a first offset and a second offset based on a contour pattern, provided as an embodiment of this application.
[0025] Figure 8 This is a schematic diagram of the functional modules of a detection device based on 3D printing equipment provided in an embodiment of this application.
[0026] Figure 9 This is a schematic diagram of the hardware structure of an electronic device provided in an embodiment of this application. Detailed Implementation
[0027] To better understand the above-mentioned objectives, features, and advantages of this application, the application will be described in detail below with reference to the accompanying drawings and specific embodiments. It should be noted that, unless otherwise specified, the embodiments and features described in these embodiments can be combined with each other.
[0028] The following description sets forth many specific details to provide a full understanding of this application. The described embodiments are only some, not all, of the embodiments of this application.
[0029] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used herein in the specification of this application is for the purpose of describing particular embodiments only and is not intended to be limiting of this application.
[0030] It should be further noted that, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element.
[0031] In this application, "at least one" means one or more, and "more than one" means two or more. "And / or" describes the relationship between related objects, indicating that there can be three relationships. For example, A and / or B can mean: A exists alone, A and B exist simultaneously, or B exists alone, where A and B can be singular or plural.
[0032] In the embodiments of this application, the terms "exemplary" or "for example" are used to indicate that something is an example, illustration, or description. Any embodiment or design that is described as "exemplary" or "for example" in the embodiments of this application should not be construed as being more preferred or advantageous than other embodiments or design. Specifically, the use of the terms "exemplary" or "for example" is intended to present the relevant concepts in a specific manner.
[0033] For ease of understanding, exemplary descriptions of some concepts related to the embodiments of this application are provided for reference.
[0034] 3D printing equipment, also known as three-dimensional printers or stereo printers, is a rapid prototyping process that typically uses digital technology to print materials. 3D printing equipment is commonly used in mold making, industrial design, and other fields to create models or parts.
[0035] Please refer to Figure 1 This is a flowchart of a detection method based on a 3D printing device according to an embodiment of this application. The 3D printing device includes a laser source for emitting line lasers and a printing platform. The method includes the following steps:
[0036] Step 101: Control the printhead assembly to print the outline pattern on the printing platform.
[0037] In some embodiments, the outline pattern includes at least three printed lines intersecting at the same point, and the included angle between two adjacent printed lines is a preset angle.
[0038] It is understood that this embodiment does not specifically limit the shape of the outline pattern, and can be set according to actual needs.
[0039] Step 102: Control the laser source to emit line lasers to scan the outline pattern, wherein the line lasers intersect the three printed lines sequentially at the first intersection point, the second intersection point, and the third intersection point.
[0040] In some embodiments, the outline pattern is an isosceles triangle with an altitude; the three printed lines are the two legs and the altitude of the isosceles triangle, the first intersection point and the third intersection point are the intersection points of the line laser with the two legs, and the second intersection point is the intersection point of the line laser with the altitude.
[0041] Please refer to Figure 2 This is a schematic diagram of the outline pattern provided in an embodiment of this application. From... Figure 2 As can be seen, the line laser A intersects the contour pattern at the first intersection point O1, the second intersection point O2, and the third intersection point O3, respectively.
[0042] In some embodiments, the 3D printing equipment further includes an illumination source; controlling the laser source emission line to laser scan the contour pattern includes: controlling the illumination source to irradiate the object under test with a preset light intensity, and then controlling the laser source emission line to laser scan the contour pattern.
[0043] It is understandable that ambient light can affect the scanning effect of laser light sources. By controlling the illumination source to illuminate the outline pattern with a preset light intensity, the ambient light can be changed, thereby improving the accuracy of laser scanning.
[0044] Step 103: Based on the scanning results of the laser light source, obtain the first distance between the first intersection point and the second intersection point in the first preset direction, and the second distance between the second intersection point and the third intersection point in the first preset direction.
[0045] It should be noted that the calculation of the first and second spacings is described in detail in subsequent embodiments, and will not be repeated here to avoid repetition.
[0046] Step 104: Calculate the first offset of the laser source in the first preset direction based on the first spacing and the second spacing, and calculate the second offset of the laser source in the second preset direction based on the first spacing, the second spacing and the preset angle, wherein the second preset direction is perpendicular to the first preset direction.
[0047] It should be noted that the calculation of the first offset and the second offset are described in detail in subsequent embodiments, and will not be repeated here to avoid repetition.
[0048] Compared with related technologies, the embodiments of this application have at least the following advantages: By controlling the laser source to emit line lasers to scan the contour pattern, since the contour pattern includes at least three printed lines intersecting at the same point, the line laser can sequentially intersect the three printed lines at the first intersection point, the second intersection point, and the third intersection point. This allows the specific positions of the first, second, and third intersection points to be obtained based on the scanning results, and further enables the calculation of the first distance between the first and second intersection points in a first preset direction, and the second distance between the second and third intersection points in the same first preset direction. After calculating the first and second distances, the first offset of the laser source in the first preset direction can be determined based on the relationship between the first and second distances. Since the included angle between adjacent printed lines is a preset angle, the second offset of the laser source in the second preset direction can be calculated based on the first distance, the second distance, and the preset angle. This achieves automatic detection of the offset of the laser source in the first and second preset directions, reducing labor costs and increasing measurement accuracy, thus improving the user experience.
[0049] Please refer to Figure 3 This is a flowchart illustrating a detection method based on a 3D printing device according to an embodiment of this application. This embodiment is a detailed description of the foregoing embodiments, further explaining how to calculate the first spacing and the second spacing, and how to calculate the first offset and the second offset.
[0050] This embodiment applies to the 3D printing equipment described in the previous embodiment and includes the following steps:
[0051] Step 201: Control the laser source to emit laser line to scan the printing platform without printed outline pattern, and obtain the original point cloud data of the printing platform at the preset position.
[0052] Step 202: Control the laser source to emit line laser and scan the contour pattern at a preset position to obtain the target point cloud data of the printing platform.
[0053] In some embodiments, the laser source emits a laser beam according to a preset laser beam diameter, and the laser source is controlled to move to a preset position to obtain target point cloud data.
[0054] In some embodiments, the diameter of the laser beam emitted by the laser source is not specifically limited and can be set according to actual needs.
[0055] Step 203: Calculate the first spacing and the second spacing based on the original point cloud data and the target point cloud data.
[0056] In some embodiments, the three printing lines include a first printing line, a second printing line, and a third printing line arranged sequentially along a first preset direction.
[0057] Specifically, the original point cloud data and the target point cloud data are registered, and the difference point cloud data in the target point cloud data is determined based on the registration result. The difference point cloud data are the point cloud data of the first line segment, the second line segment, and the third line segment that intersect the line laser with the first printing line, the second printing line, and the third printing line, respectively. Based on the point cloud data of the first line segment, the first coordinate of the first intersection point in the first preset direction is calculated; based on the point cloud data of the second line segment, the second coordinate of the second intersection point in the first preset direction is calculated; and based on the point cloud data of the third line segment, the third coordinate of the third intersection point in the first preset direction is calculated. The difference between the second coordinate and the first coordinate is used as the first spacing, and the difference between the third coordinate and the second coordinate is used as the second spacing.
[0058] It should be noted that this embodiment uses the ICP (Iterative Closest Point) algorithm to perform point cloud registration between the original point cloud data and the target point cloud data. The ICP algorithm is used to align two point cloud data sets to minimize the distance between them. The basic principle of the ICP algorithm is as follows:
[0059] 1. Initial estimation: It is assumed that there is already an initial alignment, which can usually be any reasonable initial transformation (such as translation, rotation, etc.).
[0060] 2. Nearest point matching: For each point in the source point cloud, find the point in the target point cloud that is closest to it, forming a pair of corresponding points.
[0061] 3. Calculate the transformation: Using these corresponding points, calculate an optimal rigid transformation (including rotation and translation) that aligns these source points as closely as possible with the target points.
[0062] 4. Apply the transformation: Apply the calculated transformation to the source point cloud.
[0063] 5. Check convergence: Calculate the alignment error between the current source point cloud and the target point cloud. If the error is less than the preset tolerance or the number of iterations reaches the upper limit, stop the iteration; otherwise, return to step 2 to continue the iteration.
[0064] 6. Final result: Output the final transformation matrix and the aligned source point cloud.
[0065] To facilitate understanding, the following will be combined with... Figures 4 to 5 This embodiment provides a specific example illustrating how the first and second spacings are calculated:
[0066] like Figure 4 The figure shown is an application scenario diagram of the original point cloud data and target point cloud data provided in the embodiments of this application when point cloud registration has not been performed. Figure 4 L1 represents the original point cloud data, and L2 represents the target point cloud data. Point cloud registration is performed between L1 and L2, as shown below. Figure 5 The diagram shown illustrates an application scenario after point cloud registration of the original point cloud data and target point cloud data provided in this embodiment of the application. Figure 5 As can be seen, after point cloud registration, the difference point cloud data consists of the point cloud data of the first line segment I1, the second line segment I2, and the third line segment I3. The center position of the first line segment I1 is taken as the first coordinate, the center position of the second line segment I2 as the second coordinate, and the center position of the third line segment I3 as the third coordinate. The difference between the second coordinate and the first coordinate is taken as the first spacing, and the difference between the third coordinate and the second coordinate is taken as the second spacing.
[0067] Step 204: Calculate the first offset of the laser source in the first preset direction based on the first spacing and the second spacing, and calculate the second offset of the laser source in the second preset direction based on the first spacing, the second spacing and the preset angle, wherein the second preset direction is perpendicular to the first preset direction.
[0068] In some embodiments, a Cartesian coordinate system is established, wherein the first preset direction is the direction of the x-axis in the Cartesian coordinate system, the second preset direction is the direction of the y-axis in the Cartesian coordinate system, the second printed line coincides with the y-axis, and both the original point cloud data and the target point cloud data are obtained based on the Cartesian coordinate system; calculating the first offset of the laser source in the first preset direction according to the first spacing and the second spacing includes: calculating the first offset according to the following formula:
[0069] dx = [Jx + (Ix + Kx) / 2] / 2, where dx is the first offset, Jx is the second coordinate, Ix is the first coordinate, and Kx is the third coordinate.
[0070] The second offset of the laser source in the second preset direction is calculated based on the first spacing, the second spacing, and the preset angle, including: obtaining the line length of the second printed line; and calculating the second offset according to the following formula:
[0071] dy=L / 2-2*d1*d2 / [(d1+d2)*tan(θ)]; where dy is the second offset, d1 is the first spacing, d2 is the second spacing, θ is the preset angle, and L is the line length.
[0072] To facilitate understanding, the following example uses an isosceles triangle with an altitude as its outline pattern. Figure 6 and Figure 7 This embodiment provides a detailed explanation of how the first offset and the second offset are calculated:
[0073] like Figure 6 The image shown illustrates an application scenario of the line laser scanning contour pattern provided in this embodiment of the application. Figure 7 The diagram shown is a schematic diagram of calculating the first offset and the second offset based on the contour pattern according to an embodiment of this application.
[0074] like Figure 7 As shown, the outline pattern is an isosceles triangle DBC and its height DE. Height DE coincides with the y-axis of the rectangular coordinate system. One side BC of the isosceles triangle DBC coincides with the x-axis of the rectangular coordinate system. Half of angle BDC is the preset angle θ. The first printed line is DB, the second printed line is DE, and the third printed line is DC. The line laser is AH. Line laser AH intersects the first printed line DB at the first intersection point I, the second printed line DE at the second intersection point J, and the third printed line DC at the third intersection point K.
[0075] Through the aforementioned steps, the x-coordinates of the first intersection point I (Ix), the second intersection point J (Jx), and the third intersection point K (Kx) can be obtained, thus yielding the first spacing d1 = Jx - Ix and the second spacing d2 = Kx - Jx. Figure 7 As can be seen from this, the length of line segment IL is equal to d1, and the length of line segment SK is equal to d2.
[0076] Since the abscissa Jx of the second intersection point J should be 0 when the laser source does not deviate in the first preset direction, that is, the x-axis direction, the value of Jx or the value of (Ix+Kx) / 2 is the offset error of the laser source in the x-axis direction. Thus, the first offset of the laser source in the x-axis direction is: dx=[Jx+(Ix+Kx) / 2] / 2, where dx is the first offset.
[0077] from Figure 7 As can be seen from this, the second offset is equal to the length of line segment JR, because the length of line segment JR is equal to the length of line segment DR minus the length of line segment DJ. Therefore, we can conclude that:
[0078] JR=DR-DJ=FR / tan(θ)-PJ / tan(θ)=(FR-PJ) / tan(θ); (1)
[0079] Since PJ = PU + UJ, and PU = IUtan(θ), UJ = IL = d1, IU = UJ * tan(β) = d1 * tan(β), we can obtain: PJ = d1 * (tan(β) * tan(θ) + 1), where tan(β) is the slope of the laser line AH;
[0080] Also, because FR=DR*tan(θ); and tan(β)=IO / OK=(NO / tan(θ)) / (d1+d2)=(d2-d1) / tan(θ)*(d1+d2); (2)
[0081] Substituting the calculation formulas for PJ and FR into formula (1), we get the second offset dy = (FR - PJ).
[0082] / tan(θ)=(DR*tan(θ)-d1*(tan(β)*tan(θ)+1)) / tan(θ); (3)
[0083] Substituting formula (2) into formula (3) yields:
[0084] The second offset dy = (DR*tan(θ)-d1*(((d2-d1) / tan(θ)*(d1+d2))*tan(θ)+1)) / tan(θ) = (DR*tan(θ)-d1*((d2-d1) / (d1+d2)+1) / tan(θ) = DR-2*d1*d2 / ((d1+d2)*tan(θ)). The length of DR is half the length of the second printed line DE, which is a known quantity, so the second offset can be calculated.
[0085] Compared with related technologies, the embodiments of this application have at least the following advantages: By controlling the laser source to emit line lasers to scan the contour pattern, since the contour pattern includes at least three printed lines intersecting at the same point, the line laser can sequentially intersect the three printed lines at the first intersection point, the second intersection point, and the third intersection point. This allows the specific positions of the first, second, and third intersection points to be obtained based on the scanning results, and further enables the calculation of the first distance between the first and second intersection points in a first preset direction, and the second distance between the second and third intersection points in the same first preset direction. After calculating the first and second distances, the first offset of the laser source in the first preset direction can be determined based on the relationship between the first and second distances. Since the included angle between adjacent printed lines is a preset angle, the second offset of the laser source in the second preset direction can be calculated based on the first distance, the second distance, and the preset angle. This achieves automatic detection of the offset of the laser source in the first and second preset directions, reducing labor costs and increasing measurement accuracy, thus improving the user experience.
[0086] Please refer to Figure 8 This is a functional module diagram of a detection device based on a 3D printing equipment provided in an embodiment of this application. The 3D printing equipment includes a laser source for emitting line lasers, a nozzle assembly, and a printing platform. The nozzle assembly is used to spray printing material onto the printing platform. The detection device 100 based on the 3D printing equipment includes: a control module 10, a first calculation module 20, and a second calculation module 30. The control module 10 is used to control the nozzle assembly to print a contour pattern on the printing platform, wherein the contour pattern includes at least three printing lines intersecting at the same point, and the included angle between two adjacent printing lines is a preset angle. The control module 10 is also used to control the laser source to emit line lasers to scan the contour pattern, wherein the line lasers sequentially intersect the three... The printed lines intersect at a first intersection point, a second intersection point, and a third intersection point; the first calculation module 20 is used to obtain a first distance between the first intersection point and the second intersection point in a first preset direction, and a second distance between the second intersection point and the third intersection point in the first preset direction, based on the scanning result of the laser light source; the second calculation module 30 is used to calculate a first offset of the laser light source in the first preset direction based on the first distance and the second distance, and to calculate a second offset of the laser light source in the second preset direction based on the first distance, the second distance, and the preset angle, wherein the second preset direction is perpendicular to the first preset direction.
[0087] Please refer to Figure 9 This is a schematic diagram of the hardware structure of the electronic device 1000 provided in an embodiment of this application. Figure 9As shown, the electronic device 1000 may include a processor 1001 and a memory 1002. The memory 1002 is used to store one or more computer programs 1003. The one or more computer programs 1003 are configured to be executed by the processor 1001. The one or more computer programs 1003 include instructions that can be used to implement the methods described above in the electronic device 1000.
[0088] It is understood that the structure illustrated in this embodiment does not constitute a specific limitation on the electronic device 1000. In other embodiments, the electronic device 1000 may include more or fewer components than illustrated, or combine some components, or split some components, or have different component arrangements.
[0089] Processor 1001 may include one or more processing units, such as application processors (APs), modems, graphics processing units (GPUs), image signal processors (ISPs), controllers, video codecs, digital signal processors (DSPs), baseband processors, and / or neural network processing units (NPUs). These different processing units may be independent devices or integrated into one or more processors.
[0090] The processor 1001 may also include a memory for storing instructions and data. In some embodiments, the memory in the processor 1001 is a cache memory. This memory can store instructions or data that the processor 1001 has just used or that are used repeatedly. If the processor 1001 needs to use the instruction or data again, it can retrieve it directly from this memory. This avoids repeated accesses, reduces the waiting time of the processor 1001, and thus improves the efficiency of the system.
[0091] In some embodiments, the processor 1001 may include one or more interfaces. Interfaces may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a SIM interface, and / or a USB interface, etc.
[0092] In some embodiments, memory 1002 may include high-speed random access memory, and may also include non-volatile memory, such as hard disk, memory, plug-in hard disk, smart media card (SMC), secure digital (SD) card, flash card, at least one disk storage device, flash memory device, or other volatile solid-state storage device.
[0093] This embodiment also provides a computer-readable storage medium storing computer instructions. When the instructions are executed on an electronic device, the electronic device performs the aforementioned method steps to implement the methods described in the above embodiments.
[0094] In this embodiment, the electronic device and computer storage medium are used to execute the corresponding methods provided above. Therefore, the beneficial effects they can achieve can be referred to the beneficial effects of the corresponding methods provided above, and will not be repeated here.
[0095] In practical applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above.
[0096] In the several embodiments provided in this application, the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are illustrative. For instance, the division of modules or units is a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another device, or some features may be ignored or not executed. Furthermore, the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between devices or units may be electrical, mechanical, or other forms.
[0097] The unit described as a separate component may or may not be physically separate. The component shown as a unit can be one physical unit or multiple physical units, that is, it can be located in one place or distributed in multiple different places. Some or all of the units can be selected to achieve the purpose of the solution in this embodiment according to actual needs.
[0098] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0099] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on this understanding, the technical solutions of the embodiments of this application, essentially or in other words, the parts that contribute to the prior art, or all or part of the technical solutions, can be embodied in the form of a software product. This software product is stored in a storage medium and includes several instructions to cause a device (which may be a microcontroller, chip, etc.) or processor to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0100] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any changes or substitutions within the technical scope disclosed in this application should be covered within the scope of protection of this application.
Claims
1. A detection method based on 3D printing equipment, characterized in that, The 3D printing equipment includes a laser source for emitting a line laser, a nozzle assembly, and a printing platform. The nozzle assembly is used to eject printing material onto the printing platform. The method includes: The nozzle assembly is controlled to print an outline pattern on the printing platform, wherein the outline pattern includes at least three printing lines intersecting at the same point, the included angle between two adjacent printing lines is a preset angle, and the three printing lines are arranged sequentially along a first preset direction; The laser source is controlled to emit a line laser to scan the contour pattern, wherein the line laser intersects the three printed lines sequentially at a first intersection point, a second intersection point, and a third intersection point; Based on the scanning results of the laser light source, a first distance between the first intersection point and the second intersection point in the first preset direction is obtained, as well as a second distance between the second intersection point and the third intersection point in the first preset direction; The first offset of the laser source in the first preset direction is calculated based on the first spacing and the second spacing, and the second offset of the laser source in the second preset direction is calculated based on the first spacing, the second spacing and the preset angle, wherein the second preset direction is perpendicular to the first preset direction; Before controlling the printhead assembly to print the outline pattern on the printing platform, the method further includes: The laser source emits laser lines to scan the printing platform where the outline pattern has not been printed, thereby obtaining the original point cloud data of the printing platform at a preset position; The control of the laser source emission line to laser scan the contour pattern includes: The laser source is controlled to emit the line laser and scan the contour pattern at the preset position to obtain the target point cloud data of the printing platform; The method of obtaining the first distance between the first intersection point and the second intersection point in the first preset direction, and the second distance between the second intersection point and the third intersection point in the first preset direction based on the scanning results of the laser source, includes: The original point cloud data and the target point cloud data are registered together, and the difference point cloud data in the target point cloud data is determined based on the result of the point cloud registration. Based on the difference point cloud data, calculate the first distance between the first intersection point and the second intersection point in the first preset direction, and the second distance between the second intersection point and the third intersection point in the first preset direction.
2. The detection method based on 3D printing equipment as described in claim 1, characterized in that, The three printing lines include a first printing line, a second printing line, and a third printing line arranged sequentially along the first preset direction; the difference point cloud data is the point cloud data of the first line segment, the second line segment, and the third line segment intersecting with the line laser and the first printing line, the second printing line, and the third printing line, respectively; the calculation of the first distance between the first intersection point and the second intersection point in the first preset direction, and the second distance between the second intersection point and the third intersection point in the first preset direction based on the difference point cloud data includes: Calculate the first coordinate of the first intersection point in the first preset direction based on the point cloud data of the first line segment, calculate the second coordinate of the second intersection point in the first preset direction based on the point cloud data of the second line segment, and calculate the third coordinate of the third intersection point in the first preset direction based on the point cloud data of the third line segment. The difference between the second coordinate and the first coordinate is used as the first spacing, and the difference between the third coordinate and the second coordinate is used as the second spacing.
3. The detection method based on 3D printing equipment as described in claim 2, characterized in that, The detection method further includes: A Cartesian coordinate system is established, wherein the first preset direction is the direction of the x-axis in the Cartesian coordinate system, the second preset direction is the direction of the y-axis in the Cartesian coordinate system, the second printing line coincides with the y-axis, and both the original point cloud data and the target point cloud data are obtained based on the Cartesian coordinate system. The step of calculating the first offset of the laser source in the first preset direction based on the first spacing and the second spacing includes: The first offset is calculated using the following formula: dx= [ Jx+(Ix+Kx) / 2 ] / 2 ,in, dx This is the first offset. Jx The second coordinate is... Ix Let the first coordinate be... Kx The third coordinate is given.
4. The detection method based on 3D printing equipment as described in claim 3, characterized in that, Before calculating the second offset of the laser source in the second preset direction based on the first spacing, the second spacing, and the preset angle, the method further includes: Obtain the length of the second printed line; The step of calculating the second offset of the laser source in the second preset direction based on the first spacing, the second spacing, and the preset angle includes: calculating the second offset according to the following formula: ;in, This is the second offset. For the first spacing, This is the second spacing. For the preset angle, The length of the line is given.
5. The detection method based on 3D printing equipment as described in claim 1, characterized in that, The process of controlling the laser source to emit the line laser and scanning the contour pattern at the preset position to obtain the target point cloud data of the printing platform includes: The laser source is controlled to emit the line laser according to the preset laser beam diameter, and the laser source is controlled to move to the preset position to obtain the target point cloud data.
6. The detection method based on 3D printing equipment as described in claim 1, characterized in that, The outline pattern is an isosceles triangle with height; The three printed lines are the two legs and the altitude of the isosceles triangle, respectively. The first intersection point and the third intersection point are the intersection points of the line laser with the two legs, and the second intersection point is the intersection point of the line laser with the altitude.
7. A detection device based on 3D printing equipment, characterized in that, The 3D printing equipment includes a laser source for emitting line lasers, a nozzle assembly, and a printing platform. The nozzle assembly is used to spray printing material onto the printing platform. The detection device includes a control module, a first calculation module, and a second calculation module. The control module is used to control the printhead assembly to print an outline pattern on the printing platform. The outline pattern includes at least three printing lines that intersect at the same point. The included angle between two adjacent printing lines is a preset angle. The three printing lines are arranged sequentially along a first preset direction. The control module is also used to control the laser source to emit line lasers to scan the contour pattern, wherein the line lasers intersect the three printed lines sequentially at a first intersection point, a second intersection point, and a third intersection point; The first calculation module is used to obtain, based on the scanning results of the laser source, a first distance between the first intersection point and the second intersection point in the first preset direction, and a second distance between the second intersection point and the third intersection point in the first preset direction; The second calculation module is used to calculate the first offset of the laser source in the first preset direction based on the first spacing and the second spacing, and to calculate the second offset of the laser source in the second preset direction based on the first spacing, the second spacing and the preset angle, wherein the second preset direction is perpendicular to the first preset direction; Before controlling the nozzle assembly to print the outline pattern on the printing platform, the control module is also used to control the laser light source to emit laser lines to scan the printing platform where the outline pattern has not been printed, so as to obtain the original point cloud data of the printing platform at a preset position. The control module controls the laser light source to emit laser light to scan the contour pattern, including: The laser source is controlled to emit the line laser and scan the contour pattern at the preset position to obtain the target point cloud data of the printing platform; The first calculation module obtains a first distance between the first intersection point and the second intersection point in the first preset direction, and a second distance between the second intersection point and the third intersection point in the first preset direction, based on the scanning results of the laser source, including: The original point cloud data and the target point cloud data are registered together, and the difference point cloud data in the target point cloud data is determined based on the result of the point cloud registration. Based on the difference point cloud data, calculate the first distance between the first intersection point and the second intersection point in the first preset direction, and the second distance between the second intersection point and the third intersection point in the first preset direction.
8. An electronic device, characterized in that, The electronic device includes a processor and a memory, the memory being used to store instructions, and the processor being used to invoke the instructions in the memory, causing the electronic device to execute the detection method based on the 3D printing device according to any one of claims 1 to 6.
9. A storage medium, characterized in that, The device includes computer instructions that, when executed on an electronic device, cause the electronic device to perform the detection method based on a 3D printing device as described in any one of claims 1 to 6.
Citation Information
Patent Citations
Automatic calibration method of 3D printing equipment, electronic equipment and storage medium
CN116901432A
Line laser thickness measuring method, device and equipment and storage medium
CN118274726A