Three-dimensional quality control automation method based on shared memory
By using shared memory to transmit data between the three-dimensional scanning device and the three-dimensional detection software, the problems of large delay and low efficiency in traditional scanning data transmission methods are solved, and efficient data transmission and compact control process are achieved.
Patent Information
- Application Number
- CN202411890416.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-20
- Publication Date
- 2025-04-15
AI Technical Summary
The traditional scanning data transmission method has the problems of large data transmission delay and low transmission efficiency.
The three-dimensional quality control automation method based on shared memory is adopted to realize data transmission between the three-dimensional scanning device and the three-dimensional detection software through shared memory. The specific steps include the three-dimensional scanning device storing the scanned data into shared memory, the three-dimensional detection software storing the data from the shared memory, and storing the detection results back to the shared memory.
It improves data transmission efficiency, reduces data transmission delay, and achieves a high degree of compactness and simplicity of scanning, detection and control.
Smart Images

Figure CN119835369A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the field of scanning data transmission, and in particular to a three-dimensional quality control automation method based on shared memory. Background Art
[0002] The traditional scanning data transmission method mainly relies on network transmission, which has the problems of large data transmission delay and low transmission efficiency. In order to solve these problems, the present invention proposes a three-dimensional quality control automation method based on shared memory. Summary of the invention
[0003] The purpose of the present invention is to provide a three-dimensional quality control automation method based on shared memory, which realizes data transmission between a three-dimensional scanning device end and a three-dimensional detection software end through shared memory, improves data transmission efficiency, and reduces data transmission delay.
[0004] To achieve the above object, the present invention provides a three-dimensional quality control automation method based on shared memory, comprising the following steps: Step 1: The 3D scanning device stores the scanned data into the shared memory; Step 2: The 3D detection software reads the scan data from the shared memory; Step 3: The 3D detection software detects the scanned data and stores the detection results in the shared memory; Step 4: The 3D scanning device reads the detection results from the shared memory.
[0005] Preferably, the present invention also includes the following technical solutions: Scheme 1: Step 1 comprises the following steps: Step 1.1: The 3D scanning device encodes the scanned data according to a preset data format; Step 1.2: The 3D scanning device stores the encoded scan data in the shared memory.
[0006] Preferably, in scheme 2, step 2 comprises the following steps: Step 2.1: The 3D detection software reads the encoded scan data from the shared memory; Step 2.2: The 3D detection software decodes the encoded scan data to obtain the scan data.
[0007] Preferably, in scheme 3, step 3 comprises the following steps: Step 3.1: The 3D detection software detects the scanned data and obtains the detection results; Step 3.2: The 3D detection software encodes the detection results according to a preset data format; Step 3.3: The 3D detection software stores the encoded detection results in the shared memory.
[0008] Preferably, in scheme 4, step 4 comprises the following steps: Step 4.1: The 3D scanning device reads the encoded detection results from the shared memory; Step 4.2: The three-dimensional scanning device decodes the encoded detection result to obtain the detection result.
[0009] The present invention also includes the following equipment: Device 1: A three-dimensional scanning device based on shared memory, characterized by comprising: A three-dimensional scanning module, used for scanning to obtain scanning data; A data processing module is used to encode the scanned data obtained by scanning according to a preset data format, and store the encoded scanned data in a shared memory; The reading module is used to read the detection results from the shared memory.
[0010] Device 2: 3D detection software based on shared memory, characterized by comprising: The reading module is used to read the scan data from the shared memory; A data processing module is used to decode the scanned data to obtain the scanned data; A detection module is used to detect the scanned data and obtain the detection result; The data storage module is used to encode the detection results according to a preset data format and store the encoded detection results in a shared memory.
[0011] The present invention can achieve the following effects: Shared memory data transmission protocol, real-time monitoring mechanism of shared memory data, high-speed transmission of scanned data, high compactness and simplicity of scanning, detection and control.
[0012] Data transmission between the 3D scanning device and the 3D detection software is achieved through shared memory, which improves data transmission efficiency and reduces data transmission delay. BRIEF DESCRIPTION OF THE DRAWINGS
[0013] Figure 1 This is a transmission flow chart of a three-dimensional scanning device based on shared memory of the present invention; Figure 2 The present invention is a three-dimensional detection software end transmission flow chart based on shared memory; Figure 3 A flowchart of a program for transmitting scan data to a shared memory according to the present invention; Figure 4 A flowchart of a program for reading scan data from a shared memory according to the present invention; Figure 5 A flowchart of a program for transmitting and returning a detection result to a shared memory according to the present invention; Figure 6 The present invention is a flowchart of a program for reading and returning detection results from a shared memory. DETAILED DESCRIPTION
[0014] The present invention will be further described below in conjunction with the accompanying drawings and embodiments.
[0015] Example A three-dimensional quality control automation method based on shared memory comprises the following steps: Step 1: The 3D scanning device stores the scanned data into the shared memory; Step 2: The 3D detection software reads the scan data from the shared memory; Step 3: The 3D detection software detects the scanned data and stores the detection results in the shared memory; Step 4: The 3D scanning device reads the detection results from the shared memory.
[0016] The following technical solutions are also included: Scheme 1: Step 1 comprises the following steps: Step 1.1: The 3D scanning device encodes the scanned data according to a preset data format; Step 1.2: The 3D scanning device stores the encoded scan data in the shared memory.
[0017] This scheme 2: Step 2 includes the following steps: Step 2.1: The 3D detection software reads the encoded scan data from the shared memory; Step 2.2: The 3D detection software decodes the encoded scan data to obtain the scan data.
[0018] This solution 3: Step 3 includes the following steps: Step 3.1: The 3D detection software detects the scanned data and obtains the detection results; Step 3.2: The 3D detection software encodes the detection results according to a preset data format; Step 3.3: The 3D detection software stores the encoded detection results in the shared memory.
[0019] This scheme 4: Step 4 includes the following steps: Step 4.1: The 3D scanning device reads the encoded detection results from the shared memory; Step 4.2: The three-dimensional scanning device decodes the encoded detection result to obtain the detection result.
[0020] A three-dimensional scanning device based on shared memory includes: a three-dimensional scanning module, used for scanning to obtain scanning data; The data processing module is used to encode the scanned data according to a preset data format, encode it into a data sequence number, and store the encoded scanned data in a shared memory; the reading module is used to read the detection result from the shared memory; A three-dimensional detection software based on shared memory includes: a reading module for reading scan data from the shared memory; a data processing module for decoding the read scan data to obtain scan data; The detection module is used to detect the scanned data read to obtain the detection result; the data storage module is used to encode the detection result according to a preset data format and store the encoded detection result in the shared memory; A shared memory based automated method for 3D quality control, see Figure 1 As shown; When the automation system is activated, The specific implementation steps are as follows: 101: Start the three-dimensional scanning device program in sequence; 201: Then proceed to the three-dimensional detection software.
[0021] References Figure 1 The transmission process of the scanning device end; When the scanning device is started, it goes to step 102: first scanning; 103: Start scanning the current detection object. 104: Determine the end of scanning. 105: If the judgment is yes, a shared memory is opened according to the memory key of the scanned data according to the transmission protocol; 106: Update scan data serial number; 107: Write the scanned data into the shared memory; 108: After writing the scan data, the device monitors the return data memory key of the detection result in real time. In order to monitor, first connect to the return result memory key; 109: monitor the new return result sequence number judgment; 110: If a new return result sequence number is detected and judged as no, the return result memory key is connected in a loop; 111: If the new return result sequence number is detected and judged to be yes, the return result is successfully read from the shared memory; 112: Then start scanning and return to 103; 103: Next detection object until the scanning stops.
[0022] See also Figure 2 As shown; 201: After running the 3D detection software; 202: Shared memory key for connecting scan data; 203: monitoring new scan data sequence number determination; 204: monitor the new scan data sequence number and if it is determined to be negative, return the shared memory key for connecting the scan data; 205: If the new scan data sequence number is monitored and judged to be yes, the scan data is successfully read from the shared memory; 206: After reading the replacement scan data, recalculate the detection feature items; 207: After checking the batch of scanned data, press the memory key of the returned result to open the shared memory; 208: Upgrade return result sequence number; 209: Write the returned result to the shared memory.
[0023] See also Figure 3 As shown; 301: When the device scan is completed; 302: Write the scan data serial number in sequence; 303: Write scan data type; 304: Write whether the patch data (Boolean type) is written; 305: if it is determined to be yes, start writing the scanned data in the patch data format, and first write the number of patches n; 306: The initial value of the loop statement is judged from i=1; 307: If the judgment is yes, then perform i≤n judgment; 316: If judged as no, then end; 308: If the judgment is yes, write the normal information of the facet; 309: Perform j=1 judgment; 310: If the judgment is yes, then the judgment of j<=3 is performed; 311-312: If the judgment is yes, write the coordinate values of the three vertices in sequence; 314: If j<=3 is not determined, the current patch is written and the loop increments i++; 315: Continue writing the next patch; after writing n patches; 316: If i≤n is judged to be negative, the shared memory transmission of the scanned data of the batch is completed; 317: Execute 304 to write whether to write patch data. If the judgment is no, then write point cloud data, start writing the scan data in point cloud format, and first write the point cloud quantity n; 318: Write whether there is a normal direction (Boolean); 319: The initial value of the loop statement starts from i=1; 320: Execute 319. If the judgment is yes, loop to the judgment of i<=n; 321: If i≤n is true, write the vertex coordinate point value; 322: Check whether there is normal direction judgment; 323: If the normal direction is determined to be yes in 322, the normal direction information is written; 324: loop increment i++; 325: Execute 322. If the normal direction is judged as no, the loop increments i++; 326: Continue writing the next point; make a judgment on i≤n; 327: Execute 320 to determine if i≤n. If not, then after writing n point clouds, the shared memory transmission of the batch of scan data is completed; See also Figure 4 As shown; 401: The 3D detection software detects a new scan data sequence number; 402: Read the scan data sequence number; 403: Read scan data type, check scan data type; 404: Determine whether it is patch data; 405: If the face data is judged to be yes, the face quantity n is read; 406: Perform i=1 judgment; 407: If the result of 406 is yes, then the judgment of i<=n is performed; 416: Execute 407. If the result is negative, then end; 408: If the result of 407 is yes, the normal information of the face is read; 409: Perform j=1 judgment; 410: Execute 409 to determine if j <= 3; 411: If the result of 410 is yes, the vertex coordinates are read; 412: Perform j++; 413: Return to the j<=3 judgment. If the j<=3 judgment is not executed, read the vertex coordinate point and loop increment j++ until the three vertex coordinate values are read in sequence. 414: If j<=3 is not judged, the loop increments i++; 415: Continue writing the next patch; after writing n patches; 416: If the judgment i ≤ n is false, then end; 417: If the judgment whether 404 is patch data is false, then read the number of point clouds n; 418: Read whether there is a normal vector (Boolean type); 419: Make a judgment i = 1; 420: If the judgment in 419 is true, then make a judgment i <= n; 421: If the judgment in 420 is true, then read the vertex coordinate points; 422: Make a judgment whether there is a normal vector; 423: If the judgment in 422 is true, then read the normal vector information; 424: Perform j++; 425: If the judgment in 422 is false, then perform j++; 426: Return to the judgment j < n; 427: If the judgment in 420 is false, then the shared memory transfer of the scanned data in this batch ends; See Figure 5 as shown in 501: When the three-dimensional detection software replaces the scanned data and recalculation is completed; 502: Immediately write the detection result as the data to be returned into the shared memory, and first return the result serial number; 503: For the mutual matching management of the scanned data and the data to be returned, the serial number of the data to be returned directly uses the serial number of the scanned data in this batch, and write the number of geometric tolerances n; 504: Make a judgment i = 1; 505: If the judgment in 504 is true; then make a judgment i <= n; 506: If the judgment in 505 is true, then first write the geometric tolerance name; 507: Write the number of geometric tolerance attribute values m; 508: Make a judgment j = 1; 509: If the judgment in 508 is true, then start to make a judgment j <= m; 510: Write all the attribute values; 511: Perform j++; 512: Return to step 509 j <= m; 513: If the judgment in 509 is false, then write the current geometric tolerance loop increment i++; 514: Return to step 505 i <= n judgment; 515: If the judgment i <= n is true, then end after writing the data to be returned.
[0024] See Figure 6 as shown in 601: When the scanning device or the master control end reads the returned result, a new returned result sequence number is monitored from the shared memory; 602: First read the returned result sequence number; 603: Read the geometric tolerance quantity n; 604: Perform i=1 judgment; 605: If the judgment in 604 is yes, then check i≤n; 606: If the judgment in 605 is yes, the geometric tolerance name is read first; 607: Read the number m of geometric tolerance attribute values; 608: Perform j=1 judgment; 609: Execute step 608 and if the result is yes, then perform the judgment of j<=m; 610: If the judgment in 609 is yes, all geometric tolerance attribute values are read; 611:j++; 612: Return to step 609; 613: If the judgment is no in step 609, increment i++ after reading the current geometric tolerance information; 614: Return to step 605 i<=n; 615: If the judgment is no in step 605, the process ends after all the returned results are read.
Claims
1. A three-dimensional quality control automation method based on shared memory, characterized in that: The following steps are involved: Step 1: The 3D scanning device stores the scanned data into the shared memory; Step 2: The 3D detection software reads the scan data from the shared memory; Step 3: The 3D detection software detects the scanned data and stores the detection results in the shared memory; Step 4: The 3D scanning device reads the detection results from the shared memory.
2. The three-dimensional quality control automation method based on shared memory according to claim 1, characterized in that: The step 1 comprises the following steps: Step 1.1: The 3D scanning device encodes the scanned data according to a preset data format; Step 1.2: The 3D scanning device stores the encoded scan data in the shared memory.
3. The three-dimensional quality control automation method based on shared memory according to claim 1, characterized in that: The step 2 comprises the following steps: Step 2.1: The 3D detection software reads the encoded scan data from the shared memory; Step 2.2: The 3D detection software decodes the encoded scan data to obtain the scan data.
4. The three-dimensional quality control automation method based on shared memory according to claim 1, characterized in that: The step 3 comprises the following steps: Step 3.1: The 3D detection software detects the scanned data and obtains the detection results; Step 3.2: The 3D detection software encodes the detection results according to a preset data format; Step 3.3: The 3D detection software stores the encoded detection results in the shared memory.
5. The three-dimensional quality control automation method based on shared memory according to claim 1, characterized in that: The step 4 comprises the following steps: Step 4.1: The 3D scanning device reads the encoded detection results from the shared memory; Step 4.2: The three-dimensional scanning device decodes the encoded detection result to obtain the detection result.
6. A three-dimensional scanning device based on shared memory, characterized in that: include: A three-dimensional scanning module, used for scanning to obtain scanning data; A data processing module is used to encode the scanned data obtained by scanning according to a preset data format, and store the encoded scanned data in a shared memory; The reading module is used to read the detection results from the shared memory.
7. Three-dimensional detection software based on shared memory, characterized in that: include: The reading module is used to read the scan data from the shared memory; A data processing module is used to decode the scanned data to obtain the scanned data; A detection module is used to detect the scanned data and obtain the detection result; The data storage module is used to encode the detection results according to a preset data format and store the encoded detection results in a shared memory.