A method and system for path planning in 3D surface printing

By employing a 3D curved surface 3D printing path planning method, and utilizing 3D laser scanning and point cloud data processing, high-precision circuit printing on unknown curved surfaces was achieved. This solves the limitations of traditional methods for curved surface printing and improves printing efficiency and accuracy.

CN117261232BActive Publication Date: 2026-05-26SOUTHEAST UNIV

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
SOUTHEAST UNIV
Filing Date
2023-10-31
Publication Date
2026-05-26

AI Technical Summary

Technical Problem

Traditional surface-mount circuit manufacturing techniques struggle to achieve high-precision printing on unknown curved surfaces, making it impossible to meet the printing requirements for complex shapes and curved surface features. Furthermore, traditional methods require dividing the curved surface into multiple planes for approximate printing, which affects accuracy and detail.

Method used

A three-dimensional curved surface 3D printing path planning method is adopted. Point cloud data is generated by a three-dimensional laser scanner. Through point cloud data preprocessing, surface mapping and path planning, a constant distance between the nozzle and the curved surface and continuous printing are achieved, and the printing path is adaptively adjusted.

Benefits of technology

It improves the flexibility and efficiency of circuit manufacturing, enabling high-precision printing on unknown curved surfaces, resulting in smoother and more continuous curved surfaces of printed objects, and enhancing printing accuracy and detail.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117261232B_ABST
    Figure CN117261232B_ABST
Patent Text Reader

Abstract

This invention discloses a method and system for path planning in 3D surface printing. The method includes: surface scanning, using a 3D laser scanner to scan the target surface; point cloud data preprocessing, preprocessing and optimizing the original point cloud data; model design, designing the model of the product to be printed and exporting it as point cloud data as the base point cloud data for registration; surface mapping, registering the base point cloud data of the model to be printed with the target point cloud data of the scanned surface model, mapping the planar model onto the surface; Z-axis coordinate change calculation, calculating the change of the Z-axis coordinate with the surface height during printing on the surface; and path planning, performing path planning processing on the point cloud data obtained after surface mapping, sorting the coordinates according to priority based on the required path to obtain the coordinates of each point on the complete printing path. This invention can improve the accuracy and detail of 3D printing.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of 3D printing technology, specifically relating to a path planning method and system for three-dimensional curved surface 3D printing. Background Technology

[0002] Surface mount circuit (SMT) printing is a key technology in the electronics manufacturing industry. Traditional SMT manufacturing techniques are mainly based on planar substrates, which limits its application in certain situations. Existing technologies are struggling to meet the growing market demands for more flexible, efficient, and precise circuit manufacturing methods.

[0003] Meanwhile, because traditional additive manufacturing technology relies on pre-established 3D models or planes, it is difficult to print on unknown curved surfaces, resulting in limitations in the printed shapes and failing to meet the printing requirements of some complex shapes and curved surface features. In addition, traditional printing technology stacks materials layer by layer, so for objects with curved shapes, it is usually necessary to divide the curved surface into multiple planes for approximate printing. The curved surface of the printed object is usually composed of many discrete horizontal planes, making it difficult to achieve smooth and continuous curved surfaces, which affects the printing accuracy and detail. Summary of the Invention

[0004] The main objective of this invention is to provide a curved surface 3D printing technology to overcome the limitations of traditional manufacturing methods, allowing electronic components to be printed and assembled with high precision on non-traditional substrates. Curved surface 3D printing technology is an innovative approach that provides a new way to achieve high-precision circuit printing on curved surfaces, irregular shapes, and three-dimensional structures. This technology utilizes high-precision 3D printing equipment and a three-dimensional laser contour sensor to create complex circuits and components on various surfaces.

[0005] This invention not only improves the flexibility and efficiency of circuit manufacturing, but also provides more innovative possibilities for emerging fields such as wearable technology, medical electronics, and automotive electronics.

[0006] To achieve the aforementioned objectives, the present invention employs the following solution: a path planning method for 3D surface printing, comprising the following steps:

[0007] S1: Surface scanning, using a 3D laser scanner to scan the target surface and generate raw point cloud data;

[0008] S2: Point cloud data preprocessing, preprocessing and optimizing the original point cloud data to generate target point cloud data;

[0009] S3: Model design, design the model of the product to be printed, and export it as point cloud data as the base point cloud data for registration;

[0010] S4: Surface mapping. By registering the base point cloud data of the model to be printed with the target point cloud data of the scanned surface model, the planar model is mapped onto the surface, resulting in surface-based model point cloud data.

[0011] S5: Z-axis coordinate change calculation. During the surface mapping process, the Z-axis coordinate changes with the surface height when printing on the surface. The height change information indicates that when printing on the surface, the printhead needs to rise and fall with the surface height to maintain a constant distance between the printhead and the surface.

[0012] S6: Path planning. The path planning process is performed on the point cloud data of the surface model obtained after surface mapping. The point cloud coordinates after surface mapping are sorted according to priority according to the required path to obtain the coordinates of each point on the complete printing path.

[0013] In step S2, the preprocessing and optimization of the original point cloud data includes point cloud noise reduction, specifically including:

[0014] S211: Determine the filtering window and set a radius r to define the neighborhood of each point;

[0015] S212: Calculate statistical information for each point p. i (x i y i , z i ), where (x i y i , z i Let represent the coordinates of the i-th point; find all neighboring points within its radius r, and calculate the average coordinates of the neighboring points to the i-th point. in,

[0016]

[0017] Calculate the mean μ and standard deviation σ, where,

[0018]

[0019]

[0020] Calculate the threshold dis, dis = μ + k * σ, where k is a multiple of the standard deviation σ, σ is the standard deviation, and μ is the average distance from all neighboring points to the point. The smaller k is, the smaller the tolerance range, and more points will be removed.

[0021] S213: Determine noise points by judging whether the standard deviation σ exceeds the threshold dis. If it does, then the point is a noise point.

[0022] S214: Output the filtered point cloud, removing the noise points from the original point cloud data to obtain the filtered point cloud dataset.

[0023] In step S2, the preprocessing and optimization of the original point cloud data also includes point cloud downsampling, specifically including:

[0024] S221: Determine the voxel size and calculate the boundary values ​​(X, Y, Z) of all points in the X, Y, and Z directions. min X max ), (X min X max (Z) min Z max ), calculate the side length l of the grid cell in the point cloud dataset, where,

[0025]

[0026] S222: Divide the point cloud data into a voxel grid. Divide the point cloud data into voxel grids to obtain the center coordinates P(x) of the point cloud data within the voxel grid. c y c , z c ),in,

[0027]

[0028] Where m represents the number of points within the voxel grid, c represents the center of the voxel grid, (x i y i , z i () represents the coordinates of the i-th point;

[0029] S223: Point cloud aggregation: For each voxel grid, select the center coordinates of the grid as the center point, and map adjacent points in the original point cloud to the same grid.

[0030] S223: Output the downsampled point cloud.

[0031] The surface mapping in step S4 specifically includes:

[0032] S41: Set the coordinate system zero point based on the surface model obtained by the scan;

[0033] S42: Model the model to be printed using the coordinate system described above as a reference;

[0034] S43: Perform point cloud clipping. Define the vertices of the surface polygons sequentially by clicking in the point cloud. Connect the vertices to form a closed polygon, which represents the area to be mapped.

[0035] S44: Outputs the cropped point cloud, retaining the points inside the polygon to form a new point cloud.

[0036] The path planning in step S6 specifically includes:

[0037] S61: Import point cloud data. Import the point cloud data stored in the txt file into the point cloud processing tool CloudCompare. Each data point contains three-dimensional coordinate information X, Y, Z.

[0038] S62: Calculate the relative distance. Using the origin of the coordinate system as the reference point, calculate the relative distance of each point on the X, Y, and Z axes relative to the reference point.

[0039] S63: Calculate the Euclidean geometric distance. For each point, calculate the Euclidean geometric distance between each point and the reference point.

[0040] S64: Define priorities. When sorting, the relative distances and Euclidean geometric distances of the X, Y, and Z axes should be considered together. Set the relative distances of the X, Y, and Z axes as the first priority and the Euclidean geometric distance as the second priority. Adjust the order of the coordinates according to these priorities.

[0041] S65: Sort all points according to their priority from high to low, and generate an ordered list of coordinates to represent the order of the printed path;

[0042] S66: Gcode generation, which performs post-processing on the obtained path coordinates and converts them into a Gcode format that can be recognized by 3D printers;

[0043] S67: Start printing. Based on the surface adaptive printing control system, the printing device performs the printing process on the curved surface.

[0044] A path planning system for 3D surface printing includes:

[0045] The surface scanning module is used to scan the target surface using a 3D laser scanner to generate raw point cloud data;

[0046] The point cloud data preprocessing module is used to preprocess and optimize the raw point cloud data to generate target point cloud data;

[0047] The model design module is used to design the model of the product to be printed and export it as point cloud data as the base point cloud data for registration.

[0048] The surface mapping module is used to register the basic point cloud data of the model to be printed with the target point cloud data of the surface model obtained by scanning, and to map the planar model onto the surface.

[0049] The Z-axis coordinate change calculation module is used to calculate the Z-axis coordinate change information with the surface height when printing on the surface during the surface mapping process. The height change information indicates that when printing on the surface, the printhead needs to rise and fall with the surface height to maintain a constant distance between the printhead and the surface.

[0050] The path planning module is used to process the point cloud data obtained after surface mapping, sort the coordinates according to priority according to the required path, and obtain the coordinates of each point on the complete printing path.

[0051] The point cloud data preprocessing module preprocesses and optimizes the raw point cloud data, including point cloud noise reduction, specifically including:

[0052] Define the filtering window and set a radius r to define the neighborhood of each point;

[0053] Calculate statistical information for each point p. i (x i y i , z i Find all neighboring points within a neighborhood of radius r, and calculate the average coordinates of the neighboring points to that point. in,

[0054]

[0055] Calculate the mean μ and standard deviation σ, where,

[0056]

[0057]

[0058] Calculate the threshold dis, dis = μ + k * σ, where k is a multiple of the standard deviation σ, σ is the standard deviation, and μ is the average distance from all neighboring points to the point. The smaller k is, the smaller the tolerance range, and more points will be removed.

[0059] To identify noise points, determine whether the standard deviation σ exceeds the threshold dis. If it does, the point is a noise point.

[0060] The filtered point cloud is output, and the noise points are removed from the original point cloud data to obtain the filtered point cloud dataset.

[0061] The point cloud data preprocessing module further preprocesses and optimizes the raw point cloud data by including point cloud downsampling, specifically including:

[0062] Determine the voxel size and calculate the boundary values ​​(X, Y, Z) of all points in the X, Y, and Z directions. min X max ), (Xmin X max (Z) min Z max ), calculate the side length l of the grid cell in the point cloud dataset, where,

[0063]

[0064] Divide the point cloud data into a voxel grid, and obtain the center coordinates P(x) of the point cloud data within the voxel grid. c y c , z c ),in,

[0065]

[0066] Where m represents the number of points within the voxel grid, c represents the center of the voxel grid, (x i y i , z i () represents the coordinates of the i-th point;

[0067] Point cloud aggregation: For each voxel grid, the center coordinates of the grid are selected as the center point, and adjacent points in the original point cloud are mapped to the same grid.

[0068] Output the downsampled point cloud.

[0069] The surface mapping module implements the surface mapping process as follows:

[0070] The coordinate system zero point is set based on the surface model obtained from the scan;

[0071] Model the model to be printed using the coordinate system as a reference;

[0072] Perform point cloud clipping by clicking in the point cloud to define the vertices of the surface polygon in sequence. The vertices are connected to form a closed polygon, which represents the area to be mapped.

[0073] Output the cropped point cloud, retaining the points inside the polygon to form a new point cloud.

[0074] The path planning module implements path planning through the following process:

[0075] Import point cloud data: Import the point cloud data stored in the txt file into the point cloud processing tool CloudCompare. Each data point contains three-dimensional coordinate information X, Y, Z.

[0076] Calculate the relative distances by taking the origin of the coordinate system as the reference point and calculating the relative distances of each point on the X, Y, and Z axes relative to the reference point.

[0077] Calculate the Euclidean geometric distance for each point, the Euclidean geometric distance between each point and the reference point;

[0078] Define priorities. When sorting, the relative distances and Euclidean geometric distances of the X, Y, and Z axes should be considered together. The relative distances of the X, Y, and Z axes should be set as the first priority for sorting, and the Euclidean geometric distances should be set as the second priority for sorting. The order of the coordinates should be adjusted according to these priorities.

[0079] Sort all points according to their priority from high to low, generating an ordered list of coordinates that represents the order in which the paths are printed.

[0080] Gcode generation, post-processing of the obtained path coordinates, and conversion of their format into Gcode format that can be recognized by 3D printers;

[0081] Printing begins. Based on the adaptive printing control system, the printing equipment performs the printing process on the curved surface.

[0082] Compared with the prior art, the present invention has at least the following advantages: (1) In view of the limitations of traditional additive manufacturing methods in printing complex curved surfaces, the present invention proposes a surface adaptive printing method, which integrates multiple technologies such as 3D scanning, point cloud processing, and surface mapping; (2) The present invention can print directly on unknown curved surfaces, and is not limited to the established three-dimensional model or plane; (3) Traditional manufacturing methods may require multiple steps and processes, while the surface adaptive printing technology in the present invention can complete the printing of complex curved surfaces in a single process, thereby improving production efficiency; (4) The surface adaptive printing technology in the present invention allows the nozzle to maintain a constant distance from the curved surface, making the surface of the printed object smoother and more continuous, thereby improving the printing accuracy and detail performance. Attached Figure Description

[0083] To more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0084] Figure 1 This is a schematic diagram of traditional 3D printing;

[0085] Figure 2 This is a schematic diagram of curved surface printing according to a typical embodiment of the present invention;

[0086] Figure 3 This is a schematic diagram of a serpentine line electrode printed on a spherical curved surface according to a typical embodiment of the present invention;

[0087] Figure 4 This is a typical embodiment of the curved surface adaptive printing effect of the present invention;

[0088] Figure 5 This is a typical embodiment of the curved surface adaptive printing sample Gcode of the present invention;

[0089] Figure 6 This is a flowchart of a typical embodiment of the surface adaptive printing method of the present invention. Detailed Implementation

[0090] To make the objectives, technical solutions, and advantages of the present invention clearer, specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings. Examples of these preferred embodiments are illustrated in the drawings. The embodiments of the present invention shown in and described with reference to the drawings are merely exemplary, and the present invention is not limited to these embodiments.

[0091] One aspect of the present invention provides a path planning method for 3D surface printing, comprising the following steps:

[0092] S1: Surface scanning, using a 3D laser scanner to scan the target surface and generate raw point cloud data;

[0093] S2: Point cloud data preprocessing, preprocessing and optimizing the original point cloud data to generate target point cloud data;

[0094] S3: Model design, design the model of the product to be printed, and export it as point cloud data as the base point cloud data for registration;

[0095] S4: Surface mapping, registering the basic point cloud data of the model to be printed with the target point cloud data of the surface model obtained by scanning, and mapping the planar model onto the surface;

[0096] S5: Z-axis coordinate change calculation. During the surface mapping process, the Z-axis coordinate changes with the surface height when printing on the surface. The height change information indicates that when printing on the surface, the printhead needs to rise and fall with the surface height to maintain a constant distance between the printhead and the surface.

[0097] S6: Path planning. The point cloud data obtained after surface mapping is processed for path planning. The coordinates are sorted according to priority according to the required path to obtain the coordinates of each point on the complete printing path.

[0098] In one embodiment, step S2, preprocessing and optimizing the original point cloud data, includes point cloud noise reduction, specifically including:

[0099] S211: Determine the filtering window and set a radius r to define the neighborhood of each point;

[0100] S212: Calculate statistical information for each point p. i (x i y i , z i Find all neighboring points within a neighborhood of radius r, and calculate the average coordinates of the neighboring points to that point. in,

[0101]

[0102] Calculate the mean μ and standard deviation σ, where,

[0103]

[0104]

[0105] Calculate the threshold dis, dis = μ + k * σ, where k is a multiple of the standard deviation σ, σ is the standard deviation, and μ is the average distance from all neighboring points to the point. The smaller k is, the smaller the tolerance range, and more points will be removed.

[0106] S213: Determine noise points by judging whether the standard deviation σ exceeds the threshold dis. If it does, then the point is a noise point.

[0107] S214: Output the filtered point cloud, removing the noise points from the original point cloud data to obtain the filtered point cloud dataset.

[0108] In one embodiment, step S2, the preprocessing and optimization of the original point cloud data, further includes point cloud downsampling, specifically including:

[0109] S221: Determine the voxel size and calculate the boundary values ​​(X, Y, Z) of all points in the X, Y, and Z directions. min X max ), (Y min Y max (Z) min Z max ), calculate the side length l of the grid cell in the point cloud dataset, where,

[0110]

[0111] S222: Divide the point cloud data into a voxel grid. Divide the point cloud data into voxel grids to obtain the center coordinates P(x) of the point cloud data within the voxel grid. c y c , z c ),in,

[0112]

[0113] Where m represents the number of points within the voxel grid, c represents the center of the voxel grid, (x i y i , z i () represents the coordinates of the i-th point;

[0114] S223: Point cloud aggregation: For each voxel grid, select the center coordinates of the grid as the center point, and map adjacent points in the original point cloud to the same grid.

[0115] S223: Output the downsampled point cloud.

[0116] In one embodiment, the surface mapping in step S4 specifically includes:

[0117] S41: Set the coordinate system zero point based on the surface model obtained by the scan;

[0118] S42: Model the model to be printed using the coordinate system described above as a reference;

[0119] S43: Perform point cloud clipping. Define the vertices of the surface polygons sequentially by clicking in the point cloud. Connect the vertices to form a closed polygon, which represents the area to be mapped.

[0120] S44: Outputs the cropped point cloud, retaining the points inside the polygon to form a new point cloud.

[0121] In one embodiment, the path planning in step S6 specifically includes:

[0122] S61: Import point cloud data. Import the point cloud data stored in the txt file into the program. Each data point contains three-dimensional coordinate information X, Y, Z.

[0123] S62: Calculate the relative distance. Using the origin of the coordinate system as the reference point, calculate the relative distance of each point on the X, Y, and Z axes relative to the reference point.

[0124] S63: Calculate the Euclidean geometric distance between each point and the reference point;

[0125] S64: Define priorities by combining the relative distances of the X, Y, and Z axes with Euclidean geometric distances, and adjust the relationship between the two by setting weights according to requirements;

[0126] S65: Sort all points according to priority from high to low, generating an ordered list of coordinates that represents the order of the printed path;

[0127] S66: Gcode generation, which performs post-processing on the obtained path coordinates and converts them into a Gcode format that can be recognized by 3D printers;

[0128] S67: Start printing. Based on the surface adaptive printing control system, the printing device performs the printing process on the curved surface.

[0129] Another aspect of the present invention provides a path planning system for 3D surface printing, the system comprising:

[0130] The surface scanning module is used to scan the target surface using a 3D laser scanner to generate raw point cloud data;

[0131] The point cloud data preprocessing module is used to preprocess and optimize the raw point cloud data to generate target point cloud data;

[0132] The model design module is used to design the model of the product to be printed and export it as point cloud data as the base point cloud data for registration.

[0133] The surface mapping module is used to register the basic point cloud data of the model to be printed with the target point cloud data of the surface model obtained by scanning, and to map the planar model onto the surface.

[0134] The Z-axis coordinate change calculation module is used to calculate the Z-axis coordinate change information with the surface height when printing on the surface during the surface mapping process. The height change information indicates that when printing on the surface, the printhead needs to rise and fall with the surface height to maintain a constant distance between the printhead and the surface.

[0135] The path planning module is used to process the point cloud data obtained after surface mapping, sort the coordinates according to priority according to the required path, and obtain the coordinates of each point on the complete printing path.

[0136] In one embodiment, the point cloud data preprocessing module preprocesses and optimizes the raw point cloud data, including point cloud noise reduction, specifically comprising:

[0137] Define the filtering window and set a radius r to define the neighborhood of each point;

[0138] Calculate statistical information for each point p. i (x i y i , z i Find all neighboring points within a neighborhood of radius r, and calculate the average coordinates of the neighboring points to that point. in,

[0139]

[0140] Calculate the mean μ and standard deviation σ, where,

[0141]

[0142]

[0143] Calculate the threshold dis, dis = μ + k * σ, where k is a multiple of the standard deviation σ, σ is the standard deviation, and μ is the average distance from all neighboring points to the point. The smaller k is, the smaller the tolerance range, and more points will be removed.

[0144] To identify noise points, determine whether the standard deviation σ exceeds the threshold dis. If it does, the point is a noise point.

[0145] The filtered point cloud is output, and the noise points are removed from the original point cloud data to obtain the filtered point cloud dataset.

[0146] In one embodiment, the point cloud data preprocessing module further preprocesses and optimizes the raw point cloud data by point cloud downsampling, specifically including:

[0147] Determine the voxel size and calculate the boundary values ​​(X, Y, Z) of all points in the X, Y, and Z directions. min X max ), (Y min Y max (Z) min Z max ), calculate the side length l of the grid cell in the point cloud dataset, where,

[0148]

[0149] Divide the point cloud data into a voxel grid, and obtain the center coordinates P(x) of the point cloud data within the voxel grid. c y c , z c ),in,

[0150]

[0151] Where m represents the number of points within the voxel grid, c represents the center of the voxel grid, (x i y i , z i () represents the coordinates of the i-th point;

[0152] Point cloud aggregation: For each voxel grid, the center coordinates of the grid are selected as the center point, and adjacent points in the original point cloud are mapped to the same grid.

[0153] Output the downsampled point cloud.

[0154] In one embodiment, the surface mapping module implements surface mapping by including:

[0155] The coordinate system zero point is set based on the surface model obtained from the scan;

[0156] Model the model to be printed using the coordinate system as a reference;

[0157] Perform point cloud clipping by clicking in the point cloud to define the vertices of the surface polygon in sequence. The vertices are connected to form a closed polygon, which represents the area to be mapped.

[0158] Output the cropped point cloud, retaining the points inside the polygon to form a new point cloud.

[0159] In one embodiment, the path planning module implements path planning by including:

[0160] Import point cloud data: Import the point cloud data stored in the txt file into the program. Each data point contains three-dimensional coordinate information X, Y, Z.

[0161] Calculate the relative distances by taking the origin of the coordinate system as the reference point and calculating the relative distances of each point on the X, Y, and Z axes relative to the reference point.

[0162] Calculate the Euclidean geometric distance for each point, the Euclidean geometric distance between each point and the reference point;

[0163] Define priorities by combining the relative distances of the X, Y, and Z axes with Euclidean geometric distances, and adjust the relationship between the two by setting weights according to requirements;

[0164] Sort all points according to priority, from highest to lowest, to generate an ordered list of coordinates that represents the order in which the paths are printed.

[0165] Gcode generation, post-processing of the obtained path coordinates, and conversion of their format into Gcode format that can be recognized by 3D printers;

[0166] Printing begins. Based on the adaptive printing control system, the printing equipment performs the printing process on the curved surface.

[0167] The present invention proposes a surface-adaptive additive manufacturing method as follows:

[0168] 1. Surface Scanning: The target surface is scanned using a 3D laser scanner. The scanner captures the surface information of the surface as a large amount of point cloud data, which records the 3D coordinate information of the surface.

[0169] 2. Point Cloud Processing: After acquiring the point cloud data, it is processed and optimized, including noise reduction and filtering, to ensure the quality and accuracy of the point cloud data. The processed point cloud data will become the basis for subsequent surface mapping and printing.

[0170] Optimization methods are mainly divided into two types: point cloud denoising and downsampling.

[0171] (1) Point cloud denoising mainly uses statistical filtering algorithms. Its main idea is based on the statistical distribution characteristics of points in point cloud data. By calculating the statistical information of points in the neighborhood of each point, points that do not conform to certain statistical rules are marked as noise or outliers, thereby achieving denoising of point cloud data.

[0172] The steps are as follows:

[0173] 1) Determine the filtering window and set a radius r to define the neighborhood of each point;

[0174] 2) Calculate statistical information for each point p. i (x i y i , z i For each point, find all its neighboring points within its radius r, and calculate the average coordinates of the neighboring points to that point.

[0175]

[0176] Calculate the mean μ and standard deviation σ

[0177]

[0178]

[0179] Calculate threshold

[0180] dis=μ+k*σ

[0181] k is a multiple of the standard deviation σ, where σ is the standard deviation and μ is the average distance from all neighboring points to that point. The smaller k is, the smaller the tolerance range, and the more points will be removed.

[0182] 3) Determine noise points by using a threshold to determine if the standard deviation exceeds the threshold. If it does, the point is considered a noise point.

[0183] 4) Output the filtered point cloud. Remove the points that are identified as noise points from the original point cloud to obtain the filtered point cloud dataset.

[0184] (2) Point cloud downsampling mainly uses the voxel grid downsampling algorithm. This is a commonly used and efficient downsampling algorithm, which is more suitable for dense point cloud data. Its main idea is to divide the point cloud space into regular three-dimensional grids, retaining one point in each grid or calculating its mean. It can effectively reduce the number of points while preserving the overall characteristics of the data.

[0185] The main steps are as follows:

[0186] 1) Determine the voxel size and calculate the boundary values ​​of all points in the X, Y, and Z directions (X... min X max ), (X min X max (Z) min Z max ), calculate the side length of the grid cell in the point cloud dataset.

[0187]

[0188] 2) Divide the data into voxel grids, then divide the point cloud data according to the voxels, and obtain the center coordinates P(x) of these points within the voxel grid. c y c , z c )

[0189]

[0190]

[0191]

[0192] Where m represents the number of points within the voxel grid, c represents the center of the voxel grid, (x i y i , z i ) represents the coordinates of the i-th point.

[0193] 3) Point cloud aggregation: For each voxel grid, only the center coordinates of the grid are selected as the center point. In this way, adjacent points in the original point cloud will be mapped to the same grid.

[0194] 4) Output the downsampled point cloud.

[0195] 3. Model Design: Use modeling software such as UG and 3D MAX to design the printed product model and export it as point cloud data as the reference data for registration;

[0196] 4. Surface mapping: The point cloud data of the model to be printed is registered with the point cloud data of the scanned surface model, and the intersection of the two is taken. In this way, the planar model can be mapped onto the surface. This step can ensure the accurate correspondence between the printed model and the surface.

[0197] First, the coordinate system zero point is set based on the surface model obtained from the scan. Then, the model to be printed is modeled based on this coordinate system, so that it can achieve precise matching within a coordinate system.

[0198] The surface mapping method differs from the model slicing method used in traditional 3D printing. It obtains the surface model based on the pre-modeled planar model. Unlike other surface 3D printing methods, traditional surface 3D printing divides the structure to be printed into layers after slicing, resulting in segmented printing paths that can easily damage the integrity of the product and cause quality problems. The surface mapping method does not require slicing the model, and the printing path is always continuous, allowing for a smooth printing process.

[0199] The surface mapping method primarily utilizes the point cloud clipping function of CloudCompare software. By clicking within the point cloud, the vertices of the surface polygon are defined sequentially. Connecting these vertices forms a closed polygon, representing the area to be mapped. The clipped point cloud is then output, retaining the points inside the polygon to form a new point cloud.

[0200] 5. Z-axis coordinate change calculation: During surface mapping, the calculation shows how the Z-axis coordinate changes with the surface height when printing on the surface. This information indicates that when printing on the surface, the printhead needs to rise and fall with the surface height to maintain a constant distance between the printhead and the surface.

[0201] Compared to planar models, surface models mainly involve changes in the Z-axis coordinate. Therefore, the main task of this step is to obtain the Z-axis coordinates of the mapped surface point cloud data. In other words, the mapped point cloud data is used to replace the planar model data.

[0202] 6. Path planning: Perform path planning on the obtained point cloud data, sort the coordinates according to priority based on the required path, and obtain the coordinates of each point on the complete printing path.

[0203] The main difference lies in the printing path planning. Since traditional 3D printing is done by layering, existing slicing software cuts the 3D model into a series of thin slices, with each layer representing a horizontal cross-section in the printing process. Therefore, the Z-axis coordinate cannot be flexibly changed.

[0204] Figure 1 This is a schematic diagram of traditional 3D printing. Each layer is horizontal, and they can only be stacked vertically. Moreover, printing can only be done on a flat surface.

[0205] Figure 2 It is a schematic diagram of curved surface printing, which can print continuously in non-horizontal directions, adapt the printing path according to the shape of the curved surface, ensure the smoothness of the path, and can perform printing operations on various irregular curved surfaces.

[0206] Figure 3 The serpentine electrode is printed on a spherical surface with a continuous path and smooth joints.

[0207] In addition, the accuracy is greatly improved compared to traditional printing methods. Traditional printing methods inevitably have some clamping errors when installing the printing cylinder, while this method uses a three-dimensional laser contour laser sensor to scan and compensate for armor errors, thus achieving higher printing accuracy.

[0208] This invention proposes a novel surface path planning algorithm. Using the origin as a reference, it calculates the relative distances and Euclidean geometric distances from each point to the reference point along the X, Y, and Z axes. Since the point cloud data is saved as a txt file, containing only the 3D coordinates, there is no need for slicing like in traditional models. Simply sorting the 3D coordinates according to the priority of the relative distances and Euclidean geometric distances from each point to the reference point along the X, Y, and Z axes generates a smooth printing path.

[0209] The main steps are as follows:

[0210] 1) Import point cloud data: Import the point cloud data stored in the txt file into the program. Each data point contains three-dimensional coordinate information X, Y, Z.

[0211] 2) Calculate the relative distance. Using the origin of the coordinate system as the reference point, for each point, calculate its distance relative to the reference point on the X, Y, and Z axes.

[0212] 3) Calculate the Euclidean geometric distance. For each point, calculate its Euclidean geometric distance to the reference point. That is...

[0213]

[0214] 4) Define priorities by combining the relative distances of the X, Y, and Z axes with Euclidean geometric distances, and set certain weights to adjust the relationship between them according to requirements.

[0215] 5) Sort all points according to priority, from highest to lowest. This will generate an ordered list of coordinates, representing the order in which the paths will be printed.

[0216] 6) Gcode generation: Post-process the obtained path coordinates and change their format to Gcode format that can be recognized by the 3D printer;

[0217] 7) Start Printing: Based on the adaptive printing control system, the printing equipment performs the printing process on the curved surface. During this process, the printhead will achieve adaptive control according to the changes in the Z-axis coordinate, thereby obtaining a printing effect that precisely matches the shape of the curved surface.

[0218] Figure 4 The illustration shows an adaptive printing effect on a curved surface, which is a spiral line printed on a spherical curved surface, enabling adaptive lifting and lowering along the Z-axis; Figure 5 A diagram showing the Gcode path for a surface-adaptive printing sample; Figure 6 The overall flowchart for adaptive printing of curved surfaces.

[0219] It should be understood that although this specification describes embodiments, not every embodiment contains only one independent technical solution. This way of describing the specification is only for clarity. Those skilled in the art should regard the specification as a whole, and the technical solutions of each embodiment can also be appropriately combined to form other embodiments that can be understood by those skilled in the art.

Claims

1. A path planning method for 3D surface printing, characterized in that, Includes the following steps: S1: Surface scanning, using a 3D laser scanner to scan the target surface and generate raw point cloud data; S2: Point cloud data preprocessing, preprocessing and optimizing the original point cloud data to generate target point cloud data; S3: Model design, design the model of the product to be printed, and export it as point cloud data as the base point cloud data for registration; S4: Surface mapping, which performs point cloud registration between the base point cloud data of the model to be printed and the target point cloud data of the scanned surface model, thereby mapping the planar model onto the surface to obtain the surface-based model point cloud data; S5: Z-axis coordinate change calculation. During the surface mapping process, the Z-axis coordinate changes with the surface height when printing on the surface. The height change information indicates that when printing on the surface, the printhead needs to rise and fall with the surface height to maintain a constant distance between the printhead and the surface. S6: Path planning. The path planning process is performed on the surface-based model point cloud data obtained after surface mapping. The point cloud coordinates after surface mapping are sorted according to priority according to the required path to obtain the coordinates of each point on the complete printing path.

2. The three-dimensional curved surface 3D printing path planning method according to claim 1, characterized in that, In step S2, the preprocessing and optimization of the original point cloud data includes point cloud noise reduction, specifically including: S211: Determine the filtering window and set a radius r to define the neighborhood of each point; S212: Calculate statistical information for each point. Find all neighboring points within a neighborhood of radius r, and calculate the average coordinates of the neighboring points to the given point. ,in, , Calculate the mean μ and standard deviation σ, where, , , Calculate the threshold dis, dis = μ + k × σ, where k is the standard deviation factor. The smaller k is, the smaller the tolerance range, and more points will be removed. S213: Determine noise points by judging whether the standard deviation σ exceeds the threshold dis. If it does, then the point is a noise point. S214: Output the filtered point cloud, removing the noise points from the original point cloud data to obtain the filtered point cloud dataset.

3. The three-dimensional curved surface 3D printing path planning method according to claim 2, characterized in that, In step S2, the preprocessing and optimization of the original point cloud data also includes point cloud downsampling, specifically including: S221: Determine the voxel size and calculate the boundary values ​​of all points in the X, Y, and Z directions. ), ( ), ( ), calculate the side length I of the grid cell in the point cloud dataset, where, , S222: Divide the point cloud data into a voxel grid. Based on the voxels, divide the point cloud data into sub-grids and obtain the center coordinates P(of the point cloud data) within the voxel grid. ),in, , Where m represents the number of points within the voxel grid, ( () represents the coordinates of a point; S223: Point cloud aggregation: For each voxel grid, select the center coordinates of the grid as the center point, and map adjacent points in the original point cloud to the same grid. S224: Output the downsampled point cloud.

4. The three-dimensional curved surface 3D printing path planning method according to claim 1, characterized in that, The surface mapping in step S4 specifically includes: S41: Set the coordinate system zero point based on the surface model obtained by scanning; S42: Model the model to be printed using the coordinate system described above as a reference; S43: Perform point cloud clipping. Define the vertices of the surface polygons sequentially by clicking in the point cloud. Connect the vertices to form a closed polygon, which represents the area to be mapped. S44: Outputs the cropped point cloud, retaining the points inside the polygon to form a new point cloud.

5. The three-dimensional curved surface 3D printing path planning method according to claim 1, characterized in that, The path planning in step S6 specifically includes: S61: Import point cloud data. Import the point cloud data stored in the txt file into the point cloud processing tool CloudCompare. Each data point contains three-dimensional coordinate information X, Y, Z. S62: Calculate the relative distance. Using the origin of the coordinate system as the reference point, calculate the relative distance of each point on the X, Y, and Z axes relative to the reference point. S63: Calculate the Euclidean geometric distance between each point and the reference point; S64: Define priorities. When sorting, the relative distances and Euclidean geometric distances of the X, Y, and Z axes should be considered together. Set the relative distances of the X, Y, and Z axes as the first priority and the Euclidean geometric distance as the second priority. Adjust the coordinate order according to these priorities. S65: Sort all points according to their priority from high to low, and generate an ordered list of coordinates to represent the order of the printed path; S66: Gcode generation, which performs post-processing on the obtained path coordinates and converts them into a Gcode format that can be recognized by 3D printers. S67: Start printing. Based on the surface adaptive printing control system, the printing device performs the printing process on the curved surface.

6. A path planning system for 3D surface printing, characterized in that, include: The surface scanning module is used to scan the target surface using a 3D laser scanner to generate raw point cloud data; The point cloud data preprocessing module is used to preprocess and optimize the raw point cloud data to generate target point cloud data; The model design module is used to design the model of the product to be printed and export it as point cloud data as the base point cloud data for registration. The surface mapping module is used to register the base point cloud data of the model to be printed with the target point cloud data of the scanned surface model, thereby mapping the planar model onto the surface and obtaining the surface-based model point cloud data. The Z-axis coordinate change calculation module is used to calculate the Z-axis coordinate change information with the surface height when printing on the surface during the surface mapping process. The height change information indicates that when printing on the surface, the printhead needs to rise and fall with the surface height to maintain a constant distance between the printhead and the surface. The path planning module is used to perform path planning processing on the surface-based model point cloud data obtained after surface mapping. It sorts the coordinates of the surface-mapped point cloud according to the required path and priority to obtain the coordinates of each point on the complete printing path.

7. The three-dimensional curved surface 3D printing path planning system according to claim 6, characterized in that, The point cloud data preprocessing module preprocesses and optimizes the raw point cloud data, including point cloud noise reduction, specifically including: Define the filtering window and set a radius r to define the neighborhood of each point; Calculate statistical information for each point. Find all neighboring points within a neighborhood of radius r, and calculate the average coordinates of the neighboring points to the given point. ,in, , Calculate the mean μ and standard deviation σ, where, , , Calculate the threshold dis, dis = μ + k × σ, where k is the standard deviation factor. The smaller k is, the smaller the tolerance range, and more points will be removed. To identify noise points, determine whether the standard deviation σ exceeds the threshold dis. If it does, the point is a noise point. The filtered point cloud is output, and the noise points are removed from the original point cloud data to obtain the filtered point cloud dataset.

8. The three-dimensional curved surface 3D printing path planning system according to claim 7, characterized in that, The point cloud data preprocessing module further preprocesses and optimizes the raw point cloud data by including point cloud downsampling, specifically including: Determine the voxel size and calculate the boundary values ​​of all points in the X, Y, and Z directions. ), ( ), ( ), calculate the side length I of the grid cell in the point cloud dataset, where, , Divide the point cloud data into a voxel grid, and obtain the center coordinates P(of the point cloud data within the voxel grid) based on the voxels. ),in, , Where m represents the number of points within the voxel grid, ( () represents the coordinates of a point; Point cloud aggregation: For each voxel grid, the center coordinates of the grid are selected as the center point, and adjacent points in the original point cloud are mapped to the same grid. Output the downsampled point cloud.

9. The three-dimensional curved surface 3D printing path planning system according to claim 6, characterized in that, The surface mapping module implements the surface mapping process as follows: Set the coordinate system zero point based on the surface model obtained from the scan; Model the model to be printed using the coordinate system as a reference; Perform point cloud clipping by clicking in the point cloud to define the vertices of the surface polygon in sequence. The vertices are connected to form a closed polygon, which represents the area to be mapped. Output the cropped point cloud, retaining the points inside the polygon to form a new point cloud.

10. The three-dimensional curved surface 3D printing path planning system according to claim 6, characterized in that, The path planning module implements path planning through the following process: Import point cloud data: Import the point cloud data stored in the txt file into the point cloud processing tool CloudCompare. Each data point contains three-dimensional coordinate information X, Y, Z. Calculate the relative distances by taking the origin of the coordinate system as the reference point and calculating the relative distances of each point on the X, Y, and Z axes relative to the reference point. Calculate the Euclidean geometric distance for each point, the Euclidean geometric distance between each point and the reference point; Define priorities. When sorting, the relative distances and Euclidean geometric distances of the X, Y, and Z axes should be considered together. Set the relative distances of the X, Y, and Z axes as the first priority and the Euclidean geometric distance as the second priority. Adjust the order of the coordinates according to this priority. Sort all points according to their priority from high to low, generating an ordered list of coordinates that represents the order in which the paths are printed. Gcode generation, post-processing of the obtained path coordinates, and conversion of their format into Gcode format that can be recognized by 3D printers; Printing begins. Based on the adaptive printing control system, the printing equipment performs the printing process on the curved surface.