Smooth ultrasonic curved surface scanning method based on PLC
Through the smooth ultrasonic curved surface scanning method based on PLC, the S-shaped speed planning and correction point calculation program are used to solve the problems of specific points and impact of moving mechanisms in ultrasonic curved surface scanning, and the reliability and imaging quality of the scanning process are achieved. Improvement.
Patent Information
- Application Number
- CN202411624337.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-14
- Publication Date
- 2025-02-18
AI Technical Summary
During the ultrasonic curved surface scanning process, the appearance of special points affects the scanning results, and the frequent start and stop of the movement mechanism leads to impact, affecting the imaging quality.
Using the PLC-based smooth ultrasonic surface scanning method, through the S-shaped speed planning and motion control function block, the echo amplitude is monitored in real time, the specific points are judged, and the correction point calculation program is called, and the control points are adjusted to achieve smooth motion.
It solves the problem that special points cannot be modified online and the frequent start and stop of the movement mechanism, realizes the correction and adjustment of the scanning process trajectory and the smoothness of the movement, and ensures the reliability and imaging quality of the scanning process.
Smart Images

Figure CN119470662A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of ultrasonic detection, and in particular to a smooth ultrasonic curved surface scanning method based on PLC. Background Art
[0002] Ultrasonic testing is a common non-destructive testing method used to scan workpieces. Currently, ultrasonic testing is mostly used for flat parts. However, curved workpieces have complex shapes and the normal direction changes with the curvature. It is difficult to ensure vertical incidence of ultrasonic waves during scanning. With the application of curved workpieces in the automotive, shipbuilding and aerospace fields, there are fewer non-destructive testing methods to choose from, which puts forward new requirements and challenges for ultrasonic testing methods.
[0003] Traditional ultrasonic curved surface scanning methods mostly use the CAD model of the curved workpiece to obtain control points. By adjusting the incident angle of these control points, ultrasonic waves are vertically injected into the curved workpiece, generating a motion path for inspection. However, in actual inspection, some curved workpieces are rough parts, and their CAD models are unavailable. Prior art, such as the invention patent application with publication number CN115469015A, discloses an ultrasonic inverse modeling method based on the principles of ultrasonic ranging and maximum ultrasonic amplitude. Path planning is performed based on the modeling results, and a novel ultrasonic C-scan imaging method is proposed. This method makes scanning results more intuitive and clear, solving the modeling and imaging issues of ultrasonic curved surface scanning.
[0004] In response to the above solution, the applicant of the present invention has found that the above technology has at least the following technical problems: 1. When scanning a curved workpiece, the appearance of singular points is inevitable, and the singular points directly affect the scanning results. However, in the existing technology, the singular points cannot be modified during the scanning process, and the validity of the echo amplitude of each control point cannot be guaranteed, nor can the reliability of the scanning process be guaranteed.
[0005] 2. When scanning curved workpieces, the distance between two adjacent control points may be less than the preset minimum distance threshold. At this time, the motion mechanism frequently starts and stops, which can easily cause sudden changes in acceleration, resulting in impact and affecting imaging quality. However, the existing technology has not proposed a solution to this problem, and the smoothness of the ultrasonic probe movement cannot be guaranteed, nor can the quality of subsequent imaging be guaranteed. Summary of the Invention
[0006] In view of the above-mentioned technical deficiencies, the purpose of the present invention is to provide a smooth ultrasonic curved surface scanning method based on PLC.
[0007] In order to solve the above technical problems, the present invention adopts the following technical solution: The present invention provides a smooth ultrasonic surface scanning method based on PLC, comprising the following steps: Step 1, obtaining control points: the ultrasonic probe selects control points on the curved workpiece.
[0008] Step 2. Select the echo amplitude limit frame: Take a standard test block with the same material as the curved workpiece, and while ensuring that the water-acoustic distance remains unchanged and the ultrasonic wave is injected vertically, intercept the echo waveform in the static state as standard comparison data, and record the surface wave amplitude and bottom wave amplitude. Set the surface wave monitoring frame, defect wave monitoring frame and bottom wave monitoring frame according to the surface wave amplitude and bottom wave amplitude.
[0009] Step 3: Point-to-point motion planning: Use S-shaped velocity to plan point-to-point motion. Use the motion control function block trigger method when planning point-to-point motion. During the scanning process, monitor the echo amplitude of each control point in real time to determine whether the echo amplitude is valid.
[0010] Step 4: Calculate the correction point: When the ultrasonic collector determines the singular point, call the correction point position calculation program and insert the calculated correction point into the control point file.
[0011] Step 5. Adjust the correction point: If the ultrasonic amplitude of the singular point still cannot meet the requirements after three consecutive corrections, correction should be made in the opposite direction of the correction direction, and compensation should be made during the first correction.
[0012] Preferably, the ultrasonic probe selects control points on the curved workpiece, and the specific analysis process is as follows: S11, the ultrasonic probe transmits ultrasonic waves to each point on the curved workpiece. When the ultrasonic waves reach each point on the curved workpiece and return to the ultrasonic probe from each point, the piezoelectric element inside the probe deforms and generates electric charges to generate electrical signals. The strength of the electrical signal reflects the magnitude of the echo amplitude. The stronger the electrical signal, the larger the echo amplitude.
[0013] S12. When the ultrasonic probe emits an ultrasonic wave, the PLC starts the timer from 0. When the ultrasonic echo returns to the ultrasonic probe, the generated electrical signal is sent to the PLC. The PLC stops the timer immediately upon receiving the electrical signal. The time displayed on the timer is the propagation time of the ultrasonic wave, and the one-way propagation time of the ultrasonic wave is calculated:
[0014]
[0015] Calculate the water sound distance based on the one-way travel time:
[0016] Water sound distance = W*one-way propagation time,
[0017] Where W represents the speed of ultrasonic waves in water, W = 1500 m / s;
[0018] S13. Compare the echo amplitudes of each point obtained, and compare the water-acoustic distance of each point with the preset water-acoustic distance. If the echo amplitude of the point is the largest and the water-acoustic distance is within the preset water-acoustic distance range, then the point is the control point, thereby obtaining the control points of the curved workpiece.
[0019] Preferably, the surface wave monitoring frame, the defect wave monitoring frame, and the bottom wave monitoring frame are set according to the surface wave amplitude and the bottom wave amplitude. The specific analysis process is as follows: take a standard test block made of the same material as the curved workpiece, and when the underwater acoustic distance remains unchanged and the ultrasonic wave is vertically incident on the curved workpiece, the ultrasonic collector intercepts the echo waveform in the static state as standard comparison data, and records the surface wave amplitude at this time as Asf and the bottom wave amplitude as Abt. The surface wave monitoring frame, the defect wave monitoring frame, and the bottom wave monitoring frame are set according to the surface wave amplitude and the bottom wave amplitude. The surface wave monitoring frame, the defect wave monitoring frame, and the bottom wave monitoring frame are referred to as echo amplitude effective frames:
[0020] Surface wave monitoring frame: setting range is 75%*Asf~125%*Asf;
[0021] Defect wave monitoring frame: setting range is 0~25%*Abt;
[0022] Bottom wave monitoring frame: The setting range is 75%*Abt~125%*Abt.
[0023] Preferably, the point-to-point movement using S-shaped speed planning is specifically analyzed as follows: the S-shaped speed planning includes an acceleration segment, a uniform acceleration segment, a deceleration segment, a uniform speed segment, an acceleration / deceleration segment, a uniform deceleration segment, and a deceleration / deceleration segment. The acceleration segment, the uniform acceleration segment, and the deceleration segment are called acceleration segments, and the acceleration / deceleration segment, the uniform deceleration segment, and the deceleration segment are called deceleration segments. When the PLC controls the ultrasonic probe to move from the first control point to the next control point, the PLC timer starts timing from 0 and monitors the time variable in real time: the ultrasonic probe first enters the acceleration segment. When the motion time variable is equal to the preset time variable threshold from the control point to the uniform acceleration segment, the ultrasonic probe enters the uniform acceleration segment. When the motion time variable is equal to the preset time variable threshold from the control point to the deceleration segment, the ultrasonic probe enters the deceleration segment; when the motion time variable is equal to the preset time variable threshold from the control point to the uniform speed segment, the ultrasonic probe enters the uniform speed segment; when the motion time variable is equal to the preset time variable threshold from the control point to the acceleration and deceleration segment, the ultrasonic probe enters the acceleration and deceleration segment; when the motion time variable is equal to the preset time variable threshold from the control point to the uniform deceleration segment, the ultrasonic probe enters the uniform deceleration segment; when the motion time variable is equal to the preset time variable threshold from the control point to the deceleration segment, the ultrasonic probe enters the deceleration segment.
[0024] Preferably, the motion control function block triggering method is used when planning the point-to-point movement. The specific analysis process is as follows: when the S-shaped speed is used to plan the movement of the ultrasonic probe from the first control point to the next control point, the PLC controls the movement of the ultrasonic probe by triggering the motion control function block until the scan is completed. The specific process is as follows: S21, when the ultrasonic probe starts to move from the first monitoring point, the PLC timer starts counting from 0, and monitors the time variable in the PLC in real time. When the time variable is 0, the PLC controls the ultrasonic probe to enter the acceleration section;
[0025] S22, when the time variable is equal to the preset time variable threshold for moving from the control point to the deceleration stage, the PLC controls the ultrasonic probe to enter the deceleration stage;
[0026] S23, when the time variable is greater than the preset time variable threshold from the control point to the deceleration stage, the PLC controls the ultrasonic probe to enter the next point-to-point motion plan;
[0027] S24. When the ultrasonic probe enters the deceleration motion stage between the last control point and the previous control point, the motion control function block is no longer triggered.
[0028] Preferably, the PLC controls the movement of the ultrasonic probe by triggering a motion control function block. The specific analysis process is as follows: S31, when the ultrasonic probe starts to move from the first control point, the PLC timer starts counting from 0 and monitors the time variable in the PLC in real time;
[0029] S32. Compare the time variable monitored in real time with the preset time variable threshold from the control point movement to the deceleration stage:
[0030]
[0031] Where T′ and T represent the time variable and the preset time variable threshold from the control point to the deceleration stage, respectively, and α represents the trigger condition value;
[0032] When the trigger condition value is 1, the PLC controls the movement of the ultrasonic probe. When the trigger condition value is 0, the motion control function block is not triggered.
[0033] Preferably, the specific analysis process for determining whether the echo amplitude is valid is as follows: when the ultrasonic probe scans the curved workpiece according to the acquired control points, the ultrasonic collector collects the surface wave amplitude and the bottom wave amplitude of each control point, and compares them with the set echo amplitude valid frame. The surface wave amplitude and the bottom wave amplitude are called echo amplitude:
[0034]
[0035] Where Asf i、Abt i They represent the surface wave amplitude and bottom wave amplitude of the ith control point, respectively. i represents the number of the control point, i=1,2,3,....,n, n represents the number of control points, and both i and n are positive integers. Trisur, Trifault, and Tribot represent the surface wave monitoring frame, the defect wave monitoring frame, and the bottom wave monitoring frame, respectively. An effective indicator representing the echo amplitude of the i-th control point;
[0036] When the effective index of the echo amplitude of the i-th control point When it is 1, it means that the echo amplitude of the ith control point is not within the set echo amplitude valid frame, and the control point is a special point. When the ith control point echo amplitude is a valid indicator When it is 1, it means that the echo amplitude of the i-th control point is within the set echo amplitude valid box.
[0037] Preferably, when the ultrasonic collector determines a singular point, the correction point position calculation program is called, and the specific analysis process is as follows: after the ultrasonic collector analyzes the singular point based on the surface wave amplitude and bottom wave amplitude of each control point of the curved workpiece collected, the incident angle of the ultrasonic wave at the singular point is collected as u1, and the three-dimensional coordinates of the singular point are collected as (x1, y1, z1), and the collected incident angle and three-dimensional coordinates are returned to the PLC. After receiving them, the PLC calls the correction point position calculation program, and the specific process is as follows: S41, the ultrasonic collector collects the three-dimensional coordinates of the previous control point and the three-dimensional coordinates of the next control point of the singular point, which are (x′, y′, z′) and (x″, y″, z″), respectively, and collects the three-dimensional coordinates of the incident point of the ultrasonic wave on the surface of the curved workpiece as (x, y, z);
[0038] S42. Keeping the incident point of the ultrasonic wave on the surface of the curved workpiece and the water acoustic distance unchanged, the ultrasonic probe is rotated θ degrees in the direction of movement of the ultrasonic probe with the incident point as the center and the water acoustic distance as the radius:
[0039]
[0040] Where d represents the water sound distance;
[0041] S43. Assume that the three-dimensional coordinates of the correction point are (x2, y2, z2), and the incident angle of the ultrasonic wave at the correction point is u2:
[0042]
[0043] The three-dimensional coordinates of the correction point are obtained as follows:
[0044]
[0045] S44. Insert the calculated correction points into the control point file.
[0046] Preferably, the calculated correction point is inserted into the control point file. The specific analysis process is as follows: the designer uses Python to write a script on the PLC side to automatically generate a control point file, and write the number and three-dimensional coordinates of each control point into the control point file. After the PLC calculates the position of the correction point, the script inserts the calculated three-dimensional coordinates of the correction point into the control point file between the three-dimensional coordinates of the singular point and the three-dimensional coordinates of the next control point of the singular point, and sets a number for the correction point.
[0047] Preferably, the correction is performed in the opposite direction of the correction direction, and compensation is required during the first correction. The specific analysis process is as follows: after the three-dimensional coordinates of the correction point are calculated and inserted into the control point file, when the ultrasonic probe moves to the correction point, the ultrasonic collector collects the echo amplitude of the correction point and compares it with the set echo amplitude valid frame. If the comparison result shows that the echo amplitude of the correction point is not in the set echo amplitude valid frame, the correction point position calculation program is continued to be called. If three correction points are inserted continuously and the echo amplitude of the third correction point does not meet the set echo amplitude limit frame, the correction point is added in the reverse direction and compensation is performed. The specific process is as follows: S51, the ultrasonic collector collects the three-dimensional coordinates of the previous control point and the next control point of the singular point, which are (x′, y′, z′) and (x″, y″, z″), respectively, and collects the three-dimensional coordinates of the incident point of the ultrasonic wave on the surface of the curved workpiece as (x, y, z), the incident angle of the ultrasonic wave at the singular point as u1, and the three-dimensional coordinates of the singular point as (x1, y1, z1);
[0048] S52. Keeping the incident point of the ultrasonic wave on the surface of the curved workpiece and the water acoustic distance unchanged, the ultrasonic probe is rotated 4θ degrees in the direction opposite to the direction of movement of the ultrasonic probe, with the incident point as the center and the water acoustic distance as the radius:
[0049]
[0050] Where d represents the water sound distance;
[0051] S53. Assume that the three-dimensional coordinates of the correction point are (x′′, y′′, z′′), and the incident angle of the ultrasonic wave at the correction point is u′′:
[0052]
[0053] The three-dimensional coordinates of the correction point are obtained as follows:
[0054]
[0055] S54. Insert the calculated correction points into the control point file.
[0056] The beneficial effects of the present invention are as follows: the present invention provides a smooth ultrasonic curved surface scanning method based on PLC, acquires each control point of the curved surface workpiece, and the ultrasonic probe scans the curved surface workpiece according to the acquired control points. During the scanning process, the S-shaped speed is used to plan the movement of the ultrasonic probe from the current control point to the next control point, and the motion control function block is called. At the same time, the frontal echo amplitude of each control point is collected to determine whether the control point is a singular point. If it is a singular point, the correction point calculation program is called, and the calculation result is inserted into the control point file, which solves the problem that the singular point cannot be modified online during the scanning process and the impact caused by the frequent start and stop of the motion mechanism during the curved surface scanning, realizes the correction and adjustment of the trajectory and the smoothness of the movement during the scanning process, and ensures the reliability of the scanning process and the quality of subsequent imaging. BRIEF DESCRIPTION OF THE DRAWINGS
[0057] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0058] Figure 1 The figure is a schematic flow chart of the steps for implementing the method of the present invention. DETAILED DESCRIPTION
[0059] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of the present invention.
[0060] See also Figure 1 As shown, the present invention provides a smooth ultrasonic curved surface scanning method based on PLC, comprising the following steps: Step 1, obtaining control points: the ultrasonic probe selects control points on the curved surface workpiece;
[0061] It should be noted that the control points are the key to defining the movement path of the ultrasonic probe on the curved workpiece, and the ultrasonic probe scans the curved workpiece based on the control points.
[0062] In a specific embodiment, the ultrasonic probe selects control points on a curved workpiece, and the specific analysis process is as follows: S11, ultrasonic waves are emitted vertically toward each point on the curved workpiece. When the ultrasonic waves reach each point on the curved workpiece and return to the ultrasonic probe from each point, the piezoelectric element inside the probe deforms and generates electric charge to generate an electric signal. The strength of the electric signal reflects the magnitude of the echo amplitude. The stronger the electric signal, the larger the echo amplitude.
[0063] S12. The ultrasonic probe transmits ultrasonic waves to each point on the curved workpiece. The PLC starts the timer from 0. When the ultrasonic echo returns to the ultrasonic probe, the generated electrical signal is sent to the PLC. The PLC stops the timer immediately upon receiving the electrical signal. The time displayed on the timer is the propagation time of the ultrasonic wave, and the one-way propagation time of the ultrasonic wave is calculated:
[0064]
[0065] Calculate the water sound distance based on the one-way travel time:
[0066] Water sound distance = W*one-way propagation time,
[0067] Where W represents the speed of ultrasonic waves in water, W = 1500 m / s;
[0068] S13. Compare the echo amplitudes of each point obtained, and compare the water-acoustic distance of each point with the preset water-acoustic distance. If the echo amplitude of the point is the largest and the water-acoustic distance is within the preset water-acoustic distance range threshold, then the point is the control point, thereby obtaining the control points of the curved workpiece.
[0069] It should be noted that the hydroacoustic distance refers to the distance between the ultrasonic probe and the curved workpiece.
[0070] Step 2: Select the echo amplitude limit frame: Take a standard test block made of the same material as the curved workpiece, and while ensuring that the water-acoustic distance remains unchanged and the ultrasonic wave is incident vertically, intercept the echo waveform in the static state as standard comparison data, and record the surface wave amplitude and bottom wave amplitude. Set the surface wave monitoring frame, defect wave monitoring frame, and bottom wave monitoring frame based on the surface wave amplitude and bottom wave amplitude;
[0071] It should be noted that the echo waveform diagram in a stationary state refers to the echo waveform diagram of the ultrasonic wave when the ultrasonic probe and the standard test block remain relatively stationary.
[0072] In a specific embodiment, the surface wave monitoring frame, the defect wave monitoring frame, and the bottom wave monitoring frame are set according to the surface wave amplitude and the bottom wave amplitude. The specific analysis process is as follows: a standard test block made of the same material as the curved workpiece is taken. When the underwater acoustic distance remains unchanged and the ultrasonic wave is vertically incident on the curved workpiece, the ultrasonic collector intercepts the echo waveform in the static state as standard comparison data, and records the surface wave amplitude at this time as Asf and the bottom wave amplitude as Abt. The surface wave monitoring frame, the defect wave monitoring frame, and the bottom wave monitoring frame are set according to the surface wave amplitude and the bottom wave amplitude. The surface wave monitoring frame, the defect wave monitoring frame, and the bottom wave monitoring frame are referred to as echo amplitude effective frames:
[0073] Surface wave monitoring frame: setting range is 75%*Asf~125%*Asf;
[0074] Defect wave monitoring frame: setting range is 0~25%*Abt;
[0075] Bottom wave monitoring frame: The setting range is 75%*Abt~125%*Abt.
[0076] It should be noted that the echo amplitude represents the intensity of the echo signal. This patent refers to the intensity of the echo signal collected by the ultrasonic collector when the ultrasonic probe receives the echo signal reflected from each control point of the curved workpiece.
[0077] Step 3: Point-to-point motion planning: Use S-shaped velocity to plan point-to-point motion. Use the motion control function block trigger method when planning point-to-point motion. During the scanning process, monitor the echo amplitude of each control point in real time to determine whether the echo amplitude is valid.
[0078] In a specific embodiment, the point-to-point motion using S-shaped speed planning is specifically analyzed as follows: the S-shaped speed planning includes an acceleration segment, a uniform acceleration segment, a deceleration segment, a uniform speed segment, an acceleration / deceleration segment, a uniform deceleration segment, and a deceleration / deceleration segment. The acceleration segment, the uniform acceleration segment, and the deceleration segment are called acceleration segments, and the acceleration / deceleration segment, the uniform deceleration segment, and the deceleration segment are called deceleration segments. When the PLC controls the ultrasonic probe to move from the first control point to the next control point, the PLC timer starts timing from 0 and monitors the time variable in real time: the ultrasonic probe first enters the acceleration segment, and when the motion time variable is equal to the preset time variable threshold from the control point to the uniform acceleration segment, the ultrasonic probe enters the acceleration segment. Enter the uniform acceleration section. When the motion time variable is equal to the preset time variable threshold from the control point to the deceleration section, the ultrasonic probe enters the deceleration section. When the motion time variable is equal to the preset time variable threshold from the control point to the uniform speed section, the ultrasonic probe enters the uniform speed section. When the motion time variable is equal to the preset time variable threshold from the control point to the acceleration and deceleration section, the ultrasonic probe enters the acceleration and deceleration section. When the motion time variable is equal to the preset time variable threshold from the control point to the uniform deceleration section, the ultrasonic probe enters the uniform deceleration section. When the motion time variable is equal to the preset time variable threshold from the control point to the deceleration section, the ultrasonic probe enters the deceleration section.
[0079] In another specific embodiment, the motion control function block triggering method is used when planning point-to-point motion. The specific analysis process is as follows: when the S-shaped speed is used to plan the motion of the ultrasonic probe from the first control point to the next control point, the PLC controls the motion of the ultrasonic probe by triggering the motion control function block until the scan is completed. The specific process is as follows: S21, when the ultrasonic probe starts to move from the first monitoring point, the PLC timer starts counting from 0 and monitors the time variable in the PLC in real time. When the time variable is 0, the PLC controls the ultrasonic probe to enter the acceleration section;
[0080] S22, when the time variable is equal to the preset time variable threshold for moving from the control point to the deceleration stage, the PLC controls the ultrasonic probe to enter the deceleration stage;
[0081] S23, when the time variable is greater than the preset time variable threshold from the control point to the deceleration stage, the PLC controls the ultrasonic probe to enter the next point-to-point motion plan;
[0082] S24. When the ultrasonic probe enters the deceleration motion stage between the last control point and the previous control point, the motion control function block is no longer triggered.
[0083] It should be noted that when the ultrasonic probe enters the deceleration motion stage between the last control point and the previous control point, the motion control function block is no longer triggered because the scanning of the curved workpiece is completed when it moves to the last control point.
[0084] In the above, the PLC controls the movement of the ultrasonic probe by triggering the motion control function block. The specific analysis process is as follows: S31, when the ultrasonic probe starts to move from the first control point, the PLC timer starts counting from 0 and monitors the time variable in the PLC in real time;
[0085] S32. Compare the time variable monitored in real time with the preset time variable threshold from the control point movement to the deceleration stage:
[0086]
[0087] Where T′ and T represent the time variable and the preset time variable threshold from the control point to the deceleration stage, respectively, and α represents the trigger condition value;
[0088] When the trigger condition value is 1, the PLC controls the movement of the ultrasonic probe. When the trigger condition value is 0, the motion control function block is not triggered.
[0089] In another specific embodiment, the specific analysis process for determining whether the echo amplitude is valid is as follows: when the ultrasonic wave scans the curved workpiece according to the acquired control points, the ultrasonic collector collects the surface wave amplitude and the bottom wave amplitude of each control point and compares them with the set echo amplitude valid frame. The surface wave amplitude and the bottom wave amplitude are called echo amplitude:
[0090]
[0091] Where Asf i 、Abt i They represent the surface wave amplitude and bottom wave amplitude of the ith control point, respectively. i represents the number of the control point, i=1,2,3,....,n, n represents the number of control points, n is a positive integer, Trisur, Trifault, and Tribot represent the surface wave monitoring frame, the defect wave monitoring frame, and the bottom wave monitoring frame, respectively. An effective indicator representing the echo amplitude of the i-th control point;
[0092] When the effective index of the echo amplitude of the i-th control point When it is 1, it means that the echo amplitude of the i-th control point is not within the set echo amplitude valid frame, and the control point is a special point. When the valid index of the echo amplitude of the i-th control point is When it is 1, it means that the echo amplitude of the i-th control point is within the set echo amplitude valid box.
[0093] Step 4: Calculate the correction point: When the ultrasonic collector determines the singular point, call the correction point position calculation program and insert the calculated correction point into the control point file;
[0094] It should be noted that the control point file includes surface parameters, three-dimensional coordinates of each control point and control strategy. The surface parameters are the mathematical model of the surface workpiece, and the control strategy is to use S-shaped velocity planning to control the movement of the ultrasonic probe between the control points.
[0095] In a specific embodiment, when the ultrasonic collector determines a singular point, the correction point position calculation program is called. The specific analysis process is as follows: after the ultrasonic collector analyzes the singular point based on the surface wave amplitude and bottom wave amplitude collected at each control point of the curved workpiece, the incident angle of the ultrasonic wave at the singular point is collected as u1, and the three-dimensional coordinates of the singular point are collected as (x1, y1, z1). The collected incident angle and three-dimensional coordinates are returned to the PLC. After receiving them, the PLC calls the correction point position calculation program. The specific process is as follows:
[0096] It should be noted that the incident angle refers to the angle between the propagation direction of the ultrasonic wave and the normal line when the ultrasonic wave is emitted to the curved workpiece at the control point.
[0097] S41, the ultrasonic collector collects the three-dimensional coordinates of the preceding control point and the following control point of the singular point, which are (x′, y′, z′) and (x″, y″, z″), respectively, and collects the three-dimensional coordinates of the incident point of the ultrasonic wave on the surface of the curved workpiece as (x, y, z);
[0098] S42. Keeping the incident point of the ultrasonic wave on the surface of the curved workpiece and the water acoustic distance unchanged, the ultrasonic probe is rotated θ degrees in the direction of movement of the ultrasonic probe with the incident point as the center and the water acoustic distance as the radius:
[0099]
[0100] Where d represents the water sound distance;
[0101] S43. Assume that the three-dimensional coordinates of the correction point are (x2, y2, z2), and the incident angle of the ultrasonic wave at the correction point is u2:
[0102]
[0103] The three-dimensional coordinates of the correction point are obtained as follows:
[0104]
[0105] S44. Insert the calculated correction points into the control point file.
[0106] In the above, the calculated correction point is inserted into the control point file. The specific analysis process is as follows: the designer uses Python to write a script on the PLC side to automatically generate a control point file, and write the number and three-dimensional coordinates of each control point into the control point file. After the PLC calculates the position of the correction point, the script inserts the calculated three-dimensional coordinates of the correction point into the control point file between the three-dimensional coordinates of the singular point and the three-dimensional coordinates of the next control point of the singular point, and sets a number for the correction point.
[0107] It should be noted that the control point file includes surface parameters, three-dimensional coordinates of each control point and control strategy. The surface parameters are the mathematical model of the surface workpiece, and the control strategy is to use S-shaped velocity planning to control the movement of the ultrasonic probe between the control points.
[0108] Step 5. Adjust the correction point: If the ultrasonic amplitude of the singular point still cannot meet the requirements after three consecutive corrections, then make corrections in the opposite direction of the correction direction, and make compensation during the first correction.
[0109] It should be noted that performing compensation during the first correction means that the ultrasonic probe is rotated by 4θ degrees during the first direction correction.
[0110] In a specific embodiment, the correction point is added in the opposite direction and compensation is performed. The specific analysis process is as follows: after the three-dimensional coordinates of the correction point are calculated and inserted into the control point file, when the ultrasonic probe moves to the correction point, the ultrasonic collector collects the echo amplitude of the correction point and compares it with the set echo amplitude valid frame. If the comparison result shows that the echo amplitude of the correction point is not in the set echo amplitude valid frame, the correction point position calculation program is continued to be called. If three correction points are inserted continuously and the echo amplitude of the third correction point does not meet the set echo amplitude limit frame, the correction point is added in the reverse direction and compensation is performed. The specific process is as follows: S51, the ultrasonic collector collects the three-dimensional coordinates of the previous control point and the next control point of the singular point, which are (x′, y′, z′) and (x″, y″, z″), respectively, and collects the three-dimensional coordinates of the incident point of the ultrasonic wave on the surface of the curved workpiece as (x, y, z), the incident angle of the ultrasonic wave at the singular point as u1, and the three-dimensional coordinates of the singular point as (x1, y1, z1);
[0111] S52. Keeping the incident point of the ultrasonic wave on the surface of the curved workpiece and the water acoustic distance unchanged, the ultrasonic probe is rotated 4θ degrees in the direction opposite to the direction of movement of the ultrasonic probe, with the incident point as the center and the water acoustic distance as the radius:
[0112]
[0113] Where d represents the water sound distance;
[0114] It should be noted that the ultrasonic probe needs to be rotated by 4θ degrees only when the correction point is inserted in the reverse direction for the first time. When the correction point is inserted in the reverse direction for the subsequent times, the ultrasonic probe needs to be rotated by θ degrees.
[0115] S53. Assume that the three-dimensional coordinates of the correction point are (x′′, y′′, z′′), and the incident angle of the ultrasonic wave at the correction point is u′′:
[0116]
[0117] The three-dimensional coordinates of the correction point are obtained as follows:
[0118]
[0119] S54. Insert the calculated correction points into the control point file.
[0120] In an embodiment of the present invention, an ultrasonic probe obtains each control point of a curved workpiece, and scans the curved workpiece according to the obtained control points. During the scanning process, an S-shaped speed is used to plan the movement of the ultrasonic probe from the current control point to the next control point, and a motion control function block is called. At the same time, the amplitude of the frontal echo of each control point is collected to determine whether the control point is a singular point. If it is a singular point, a correction point calculation program is called, and the calculation result is inserted into the control point file. This solves the problem that the singular point cannot be modified online during the scanning process and the problem that the motion mechanism frequently starts and stops during curved surface scanning and causes impact, realizes the correction and adjustment of the trajectory and the smoothness of the movement during the scanning process, and ensures the reliability of the scanning process and the quality of subsequent imaging.
[0121] The above content is merely an example and explanation of the concept of the present invention. Those skilled in the art may make various modifications or additions to the described specific embodiments or replace them in a similar manner. As long as they do not deviate from the concept of the invention or exceed the scope defined in this specification, they should all fall within the scope of protection of the present invention.
Claims
1. A smooth ultrasonic curved surface scanning method based on PLC, characterized in that: The steps include: Step 1: Obtain control points: The ultrasonic probe selects control points on the curved workpiece; Step 2, select the echo amplitude limit frame: take a standard test block with the same material as the curved workpiece, and under the condition that the water-acoustic distance is unchanged and the ultrasonic wave is vertically injected, intercept the echo waveform diagram in the static state as the standard comparison data, and record the surface wave amplitude and the bottom wave amplitude. According to the surface wave amplitude and the bottom wave amplitude, set the surface wave monitoring frame, the defect wave monitoring frame and the bottom wave monitoring frame; Step 3: Point-to-point motion planning: Use S-shaped speed to plan point-to-point motion. Use the motion control function block trigger method when planning point-to-point motion. During the scanning process, collect the echo amplitude of each control point in real time to determine whether the echo amplitude is valid. Step 4: Calculate the correction point: When the ultrasonic collector determines the singular point, call the correction point position calculation program and insert the calculated correction point into the control point file; Step 5: Adjust the correction point: If the ultrasonic amplitude of the singular point still cannot meet the requirements after three consecutive corrections, correction should be made in the opposite direction of the correction direction, and compensation should be made during the first correction.
2. A method for smooth ultrasonic curved surface scanning based on PLC according to claim 1, characterized in that: The ultrasonic probe selects control points for the curved workpiece, and the specific analysis process is as follows: S11. The ultrasonic probe transmits ultrasonic waves to each point on the curved workpiece. When the ultrasonic waves reach each point on the curved workpiece and return to the ultrasonic probe from each point, the piezoelectric element inside the probe is deformed and generates electric charges to generate electrical signals. The strength of the electrical signal reflects the magnitude of the echo amplitude. The stronger the electrical signal, the greater the echo amplitude. S12. When the ultrasonic probe emits ultrasonic waves, the PLC starts the timer from 0. When the ultrasonic echo returns to the ultrasonic probe, the generated electrical signal is sent to the PLC. The PLC stops the timer immediately upon receiving the electrical signal. The time displayed on the timer is the propagation time of the ultrasonic wave, and the one-way propagation time of the ultrasonic wave is calculated: Calculate the water sound distance based on the one-way propagation time: Water sound distance = W*one-way propagation time, Where W represents the speed of ultrasound propagation in water, W = 1500 m / s; S13. Compare the echo amplitudes of each point obtained, and compare the water-acoustic distance of each point with the preset water-acoustic distance. If the echo amplitude of the point is the largest and the water-acoustic distance is within the preset water-acoustic distance range, then the point is the control point, thereby obtaining the control points of the curved workpiece.
3. A method for smooth ultrasonic curved surface scanning based on PLC according to claim 1, characterized in that: The surface wave monitoring frame, the defect wave monitoring frame and the bottom wave monitoring frame are set according to the surface wave amplitude and the bottom wave amplitude. The specific analysis process is as follows: Take a standard test block with the same material as the curved workpiece. When the hydroacoustic distance remains unchanged and the ultrasonic wave is vertically projected into the curved workpiece, the ultrasonic collector intercepts the echo waveform in the static state as the standard comparison data, and records the surface wave amplitude at this time as Asf and the bottom wave amplitude as Abt. According to the surface wave amplitude and the bottom wave amplitude, the surface wave monitoring frame, the defect wave monitoring frame and the bottom wave monitoring frame are set. The surface wave monitoring frame, the defect wave monitoring frame and the bottom wave monitoring frame are called the echo amplitude effective frame: Surface wave monitoring frame: setting range is 75%*Asf~125%*Asf; Defect wave monitoring frame: setting range is 0~25%*Abt; Bottom wave monitoring frame: The setting range is 75%*Abt~125%*Abt.
4. The method for smooth ultrasonic curved surface scanning based on PLC according to claim 1, characterized in that: The point-to-point motion is planned using S-shaped speed. The specific analysis process is as follows: The S-shaped speed planning includes acceleration section, uniform acceleration section, deceleration section, uniform speed section, acceleration and deceleration section, uniform deceleration section and deceleration and deceleration section. The acceleration section, uniform acceleration section and deceleration section are called acceleration section, and the acceleration and deceleration section, uniform deceleration section and deceleration and deceleration section are called deceleration section. When the PLC controls the ultrasonic probe to move from the first control point to the next control point, the PLC timer starts counting from 0 and monitors the time variable in real time: The ultrasonic probe first enters the acceleration section. When the motion time variable is equal to the preset time variable threshold from the control point to the uniform acceleration section, the ultrasonic probe enters the uniform acceleration section. When the motion time variable is equal to the preset time variable threshold from the control point to the deceleration section, the ultrasonic probe enters the deceleration section. When the motion time variable is equal to the preset time variable threshold from the control point to the uniform speed section, the ultrasonic probe enters the uniform speed section. When the motion time variable is equal to the preset time variable threshold from the control point to the acceleration and deceleration section, the ultrasonic probe enters the acceleration and deceleration section. When the motion time variable is equal to the preset time variable threshold from the control point to the uniform deceleration section, the ultrasonic probe enters the uniform deceleration section. When the motion time variable is equal to the preset time variable threshold from the control point to the deceleration section, the ultrasonic probe enters the deceleration section.
5. The method for smooth ultrasonic curved surface scanning based on PLC according to claim 1, characterized in that: The motion control function block trigger method is used when planning point-to-point motion. The specific analysis process is as follows: When the S-shaped velocity is used to plan the movement of the ultrasonic probe from the first control point to the next control point, the PLC controls the movement of the ultrasonic probe by triggering the motion control function block until the scan is completed. The specific process is as follows: S21, when the ultrasonic probe starts to move from the first monitoring point, the PLC timer starts timing from 0, and monitors the time variable in the PLC in real time. When the time variable is 0, the PLC controls the ultrasonic probe to enter the acceleration stage; S22, when the time variable is equal to the preset time variable threshold from the control point to the deceleration section, the PLC controls the ultrasonic probe to enter the deceleration section; S23, when the time variable is greater than the preset time variable threshold from the control point to the deceleration stage, the PLC controls the ultrasonic probe to enter the next point-to-point motion planning; S24: When the ultrasonic probe enters the deceleration motion stage between the last control point and the previous control point, the motion control function block is no longer triggered.
6. A method for smooth ultrasonic curved surface scanning based on PLC according to claim 5, characterized in that: The PLC controls the movement of the ultrasonic probe by triggering the motion control function block. The specific analysis process is as follows: S31, when the ultrasonic probe starts to move from the first control point, the PLC timer starts timing from 0, and monitors the time variable in the PLC in real time; S32, comparing the time variable monitored in real time with the preset time variable threshold from the control point to the deceleration stage: Where T′ and T represent the time variable and the preset time variable threshold from the control point to the deceleration stage, respectively, and α represents the trigger condition value; When the trigger condition value is 1, the PLC controls the movement of the ultrasonic probe. When the trigger condition value is 0, the motion control function block is no longer triggered.
7. The method for smooth ultrasonic curved surface scanning based on PLC according to claim 1, characterized in that: The specific analysis process of judging whether the echo amplitude is valid is as follows: When the ultrasonic probe scans the curved workpiece according to the acquired control points, the ultrasonic collector collects the surface wave amplitude and bottom wave amplitude of each control point, and compares them with the set echo amplitude valid frame. The surface wave amplitude and bottom wave amplitude are called echo amplitude: Where Asf i , Abt i They represent the surface wave amplitude of the ith control point and the bottom wave amplitude of the ith control point respectively. i represents the number of the control point, i=1,2,3,....,n, n represents the number of control points, i and n are both positive integers. Trisur, Trifault and Tribot represent the surface wave monitoring frame, the defect wave monitoring frame and the bottom wave monitoring frame respectively. An effective indicator representing the echo amplitude of the ith control point; When the effective index of the echo amplitude of the i-th control point When it is 1, it means that the echo amplitude of the ith control point is not within the set echo amplitude valid frame, and the control point is a singular point. When it is 1, it means that the echo amplitude of the ith control point is within the set echo amplitude valid box.
8. The method for smooth ultrasonic curved surface scanning based on PLC according to claim 1, characterized in that: When the ultrasonic collector determines a singular point, the correction point position calculation program is called, and the specific analysis process is as follows: After the ultrasonic collector analyzes the singular point based on the surface wave amplitude and bottom wave amplitude of each control point of the curved workpiece, the incident angle of the ultrasonic wave at the singular point is collected as u1, and the three-dimensional coordinates of the singular point are collected as (x1, y1, z1). The collected incident angle and three-dimensional coordinates are returned to the PLC. After receiving them, the PLC calls the correction point position calculation program. The specific process is as follows: S41, the ultrasonic collector collects the three-dimensional coordinates of the previous control point and the next control point of the singular point, which are (x′, y′, z′) and (x″, y″, z″), respectively, and collects the three-dimensional coordinates of the incident point of the ultrasonic wave on the surface of the curved workpiece as (x, y, z); S42. Keep the incident point and water-acoustic distance of the ultrasonic wave on the surface of the curved workpiece unchanged, and rotate the ultrasonic probe by θ degrees in the direction of movement of the ultrasonic probe with the incident point as the center and the water-acoustic distance as the radius: Where d represents the water sound distance; S43. Assume that the three-dimensional coordinates of the correction point are (x2, y2, z2), and the incident angle of the ultrasonic wave at the correction point is u2: The three-dimensional coordinates of the correction point are obtained as follows: S44. Insert the calculated correction point into the control point file.
9. A PLC-based smooth ultrasonic curved surface scanning method according to claim 8, characterized in that: The calculated correction points are inserted into the control point file. The specific analysis process is as follows: Designers use Python to write scripts on the PLC side to automatically generate control point files and write the numbers and three-dimensional coordinates of each control point into the control point file. After the PLC calculates the position of the correction point, the script inserts the calculated three-dimensional coordinates of the correction point into the control point file between the three-dimensional coordinates of the singular point and the three-dimensional coordinates of the next control point of the singular point, and sets a number for the correction point.
10. The method for smooth ultrasonic curved surface scanning based on PLC according to claim 1, characterized in that: The correction is made in the opposite direction of the correction direction, and compensation is required during the first correction. The specific analysis process is as follows: After the three-dimensional coordinates of the correction point are calculated and inserted into the control point file, when the ultrasonic probe moves to the correction point, the ultrasonic collector collects the echo amplitude of the correction point and compares it with the set echo amplitude valid frame. If the comparison result shows that the echo amplitude of the correction point is not in the set echo amplitude valid frame, the correction point position calculation program is continued to be called. If three correction points are inserted continuously and the echo amplitude of the third correction point is not in the set echo amplitude limit frame, the correction point is added in the reverse direction and compensation is performed. The specific process is as follows: S51, the ultrasonic collector collects the three-dimensional coordinates of the previous control point and the next control point of the singular point, which are (x′, y′, z′) and (x″, y″, z″), respectively, collects the three-dimensional coordinates of the incident point of the ultrasonic wave on the surface of the curved workpiece as (x, y, z), collects the incident angle of the ultrasonic wave at the singular point as u1 and the three-dimensional coordinates of the singular point as (x1, y1, z1); S52. Keeping the incident point and water-acoustic distance of the ultrasonic wave on the surface of the curved workpiece unchanged, the ultrasonic probe is rotated 4θ degrees in the direction opposite to the movement direction of the ultrasonic probe, with the incident point as the center and the water-acoustic distance as the radius: Where d represents the water sound distance; S53, assuming that the three-dimensional coordinates of the correction point are (x″′, y″′, z″′), and the incident angle of the ultrasonic wave at the correction point is u″′: The three-dimensional coordinates of the correction point are obtained as follows: S54, inserting the calculated correction point into the control point file.
Citation Information
Patent Citations
Ultrasonic self-adaptive detection method for curved surface component
CN115469015A