Oil cylinder displacement real-time calculation method and system based on sonar

By combining sonar ranging and temperature sensors with Kalman filtering, the problem of decreased accuracy in cylinder displacement detection in hydraulic systems was solved, achieving highly stable and real-time cylinder displacement calculation.

CN120990960AActive Publication Date: 2025-11-21FANER INTELLIGENT TECH GRP CO LTD
View PDF 8 Cites 0 Cited by

Patent Information

Application Number
CN202511125676.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-08-12
Publication Date
2025-11-21
Estimated Expiration
2045-08-12

AI Technical Summary

Technical Problem

In existing hydraulic systems, cylinder displacement detection relies on mechanical sensors, which are susceptible to the effects of high-pressure oil environment and temperature changes, resulting in short lifespan and decreased accuracy.

Method used

A real-time displacement calculation method for hydraulic cylinders based on sonar is adopted. Through a sonar ranging mechanism and a central control module, combined with a temperature sensor and a Kalman filter algorithm, non-contact high-precision displacement measurement is achieved.

Benefits of technology

It improves the accuracy and data traceability of cylinder displacement calculation, adapts to complex working conditions, and ensures stability and real-time performance during long-term operation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120990960A_ABST
    Figure CN120990960A_ABST
Patent Text Reader

Abstract

The invention discloses an oil cylinder displacement real-time calculation method and system based on sonar, relates to the technical field of hydraulic equipment measurement and control, and is used for solving the problem that the displacement calculation precision of a long-stroke oil cylinder is reduced under complex working conditions. Before the oil cylinder is put into use, a piston rod (4) is driven to move point by point according to a constant step pitch, sonar pulses are emitted at each step pitch position, echo waveforms, timestamps and position indexes are recorded, meanwhile, the oil temperature is collected, the sound velocity is converted, and a binding data table is established. Then, multiple echo waveforms are analyzed, features are extracted, the amplitude change rate, the peak drift rate and the envelope distortion rate are calculated, fluctuation abnormal values are generated and sorted, and a trunk step position is selected to establish a comprehensive feature vector; the comprehensive feature vectors are matched in real time, displacement is calculated in combination with the real-time sound velocity, and displacement data are smoothly processed through Kalman filtering and a time window. In the maintenance stage, the piston rod (4) is pushed to the limit position, updated features are collected again, and synchronous correction of the feature chain is completed.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of hydraulic equipment measurement and control, and more particularly to an oil cylinder displacement real-time calculation method and system based on sonar. BACKGROUND

[0002] In a hydraulic system, the oil cylinder is a key execution component, and the accurate acquisition of the position of the piston rod (4) directly affects the stability and safety of the equipment operation control. Existing oil cylinder displacement detection relies on mechanical sensors, magnetostrictive sensors or potentiometers. Such sensors are easily affected by high-pressure oil environment, temperature changes, long-term wear and other factors, and have the problems of short service life and precision decline.

[0003] In view of the above problems, the present application provides a solution. SUMMARY

[0004] In order to overcome the above-mentioned defects of the prior art, the embodiments of the present application provide an oil cylinder displacement real-time calculation method and system based on sonar to solve the problems raised in the background art.

[0005] To achieve the above-mentioned purpose, the present application provides the following technical scheme: The oil cylinder displacement real-time calculation system based on sonar comprises a cylinder body (2), a piston rod (4), a sonar ranging mechanism (1) arranged at the tail end of the cylinder body (2), and a general control module (8) connected thereto. The sonar ranging mechanism (1) comprises a sonar sensor (1) arranged at the tail end of the cylinder body (2), an ultrasonic wave transmitting head (6) arranged at the front end of the sonar sensor (1), and an ultrasonic wave receiving head (7). The side wall of the cylinder body (2) is provided with a liquid inlet P1 and a liquid inlet P1P2, the liquid inlet P1 is used to realize the jacking of the jack, and the liquid inlet P1P2 is used to realize the recovery of the jack. The general control module (8) comprises an acquisition submodule, a sound speed conversion submodule, a zero reference reading submodule, a displacement calculation submodule, a filtering correction submodule and a data output submodule, and the submodules are signal connected to form a data processing closed loop. The acquisition submodule is used to receive the echo signal output by the sonar ranging mechanism (1) and extract the time difference, the sound speed conversion submodule is used to calculate the sound wave propagation speed according to the current oil temperature, the displacement calculation submodule is used to combine the time difference and the sound speed for difference operation and generate a displacement initial value, the filtering correction submodule is used to filter the displacement initial value, and the data output submodule is used to output the final displacement result to the upper computer or the actuator.

[0006] The oil cylinder displacement real-time calculation method based on sonar comprises the following steps: The piston rod (4) is driven to move point by point at a constant step, a sonar pulse is emitted at each step position, the echo waveform, timestamp and position index are recorded, the oil temperature at the corresponding step position is collected and the sound speed is converted, and a binding data table is established; The multiple echo waveforms at each step position are aligned and superimposed, the rising edge, peak value and envelope characteristics are extracted, the amplitude variation rate, peak value drift rate and envelope distortion rate are calculated, and the fluctuation abnormal value at each step position is generated, the step position with the largest fluctuation abnormal value is selected after sorting, and a comprehensive feature vector is established. The real-time echo waveform is recorded, the comprehensive feature vector is called to match, the time characteristic point is obtained, the displacement is calculated combined with the real-time sound speed, Kalman filtering and time window smoothing are performed, and the displacement sequence is processed and recorded. The piston rod (4) is pushed to the limit position to re-collect echo and temperature data, update sound speed and waveform characteristics, trigger feature chain synchronous correction, and select secondary feature positions to re-call and replace features according to confidence.

[0007] In a preferred embodiment, multiple sonar pulses are emitted to record echo waveforms, the rising edge, peak value and falling edge of the echo waveform are analyzed, stable time characteristic points are determined and written into a feature parameter table.

[0008] In a preferred embodiment, after the time characteristic point is determined, the multiple echo times are uniformly processed to generate an echo time judgment rule and save it, a sonar pulse is periodically emitted during the normal working stage, the echo waveform is recorded, the time characteristic point is matched and the difference is calculated to write into the displacement calculation sequence.

[0009] In a preferred embodiment, the piston rod (4) is pushed at a constant step to move step by step from the zero position, and the unique index value of each step position is obtained and recorded when it reaches a step position; a sonar pulse is emitted at the step position, the timestamp and echo signal are recorded and the whole waveform curve is continuously sampled and recorded, and then the oil temperature value is collected by the temperature sensor.

[0010] In a preferred embodiment, the piston rod (4) stroke is segmented to establish a one-to-one correspondence between the step position and the temperature sensor, and the piston rod (4) is pushed to record the step position index and write it into the position index record table. The oil temperature value is obtained by matching the temperature sensor and written into the position and temperature mapping table, the echo waveform is recorded by emitting a sonar pulse multiple times at each step position and written into the waveform record table. The rising edge, peak value, envelope and falling edge characteristics are extracted and written into the feature data record table, the waveform time sequence feature data set is constructed, and the waveform time sequence feature data at different oil temperature values are compared to calculate the fluctuation abnormal value.

[0011] In a preferred embodiment, the fluctuation abnormal values in the full stroke range are sorted, the step position with the largest fluctuation abnormal value is extracted, the main step position is confirmed, the amplitude feature, peak position feature and envelope shape feature of the main step position are written into the comprehensive feature vector record table, and the comprehensive feature vector is constructed; After real-time echo data collection, matching and correction operations are performed, and the waveform matching parameters of adjacent step positions are updated layer by layer to form a multi-level feature correction chain; The emitted sonar pulse calculates the displacement initial value and outputs the displacement sequence, the piston rod (4) is pushed to the designed limit position, the echo waveform and temperature value are re-collected, the feature record is updated, and the synchronization correction is performed.

[0012] In a preferred embodiment, the step position with the second highest abnormal value is written into the secondary feature correction section table, the amplitude standard deviation, the maximum drift of the peak position and the envelope curve shape change rate are calculated, and the sensitivity record is written; The feature confidence Pi is calculated and written into the feature confidence table and the secondary feature correction pool, the step position feature parameter set with the highest Pi value is obtained to replace the main step position, and matching and correction are performed.

[0013] In a preferred embodiment, the oil temperature value is collected, the sound velocity data is converted, the echo time difference and the sound velocity data are calculated to obtain the real-time displacement initial value, and the real-time displacement data is output. When the machine is stopped for maintenance, the piston rod (4) is pushed to the limit position to re-collect and update the calibration record table.

[0014] The technical effects and advantages of the oil cylinder displacement real-time calculation method and system based on sonar of the present application are as follows: The present application collects echoes, time and temperature sound velocity data point by point according to the step distance in the calibration stage, establishes a multi-dimensional binding of position, waveform and sound velocity, and completely avoids the defects of applying a single feature to the full stroke. Through multiple echo superposition and feature extraction, fluctuation abnormal values are calculated and the main position is selected to form a comprehensive feature vector, so that the matching process in the running stage is always based on real features. In the running stage, the comprehensive feature vector is called to match the real-time echo point by point, the displacement is calculated by combining the real-time temperature converted sound velocity, and then the Kalman filter and time window smoothing processing are performed to realize high stability and real-time of the data. In the maintenance stage, the features are re-collected and updated through the limit position, the synchronous correction of the feature chain is triggered, and the continuous and effective features in long-term operation are ensured. The method significantly improves the displacement calculation accuracy and data traceability of the long-stroke oil cylinder under complex working conditions. BRIEF DESCRIPTION OF DRAWINGS

[0015] Figure 1 The present application is an oil cylinder displacement real-time calculation method and system based on sonar.

[0016] Figure 2This is a timing diagram of the real-time calculation method and system for hydraulic cylinder displacement based on sonar of the present invention.

[0017] Figure 3 This is a schematic diagram of the sonar ranging mechanism (1) in the oil cylinder in this invention.

[0018] Figure 4 for Figure 3 The working principle and enlarged schematic diagram of the transmitting and receiving structure of the sonar sensor (1) are shown.

[0019] Label Explanation: Sonar sensor (1) Hydraulic cylinder body (3) Piston rod (4) Mounting hole (5) Ultrasonic transmitter (6) Ultrasonic receiver head (7) Liquid inlet P1 (P1) Liquid inlet P2 (P2) Jack extension direction (A) The jack is retracted in the direction of (B). Detailed Implementation

[0020] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention. Example

[0021] This invention discloses a real-time calculation method for hydraulic cylinder displacement based on sonar, such as... Figure 2 As shown, it includes: Drive the piston rod (4) to move point by point according to a constant step distance. At each step distance position, emit a sonar pulse, record the echo waveform, timestamp and position index, collect the corresponding oil temperature and convert the sound speed, and establish a binding data table. Multiple echo waveforms at each step position are aligned and superimposed to extract rising edge, peak value, and envelope features. The amplitude change rate, peak drift rate, and envelope distortion rate are calculated and fluctuation anomalies are generated. After sorting, the step position with the largest fluctuation anomaly is selected to establish a comprehensive feature vector. During operation, sonar pulses are emitted, real-time echo waveforms are recorded, and comprehensive feature vectors are called for matching to obtain time feature points. The displacement is calculated by combining the real-time sound velocity. At the same time, Kalman filtering and time window smoothing are performed to process and record the displacement sequence. The push rod (4) is advanced to the limit position to reacquire echo and temperature data, update the sound velocity and waveform characteristics, trigger the feature chain synchronous correction, screen the secondary feature positions, and re-call and replace the features according to the confidence.

[0022] As shown in Figure 3 and Figure 4 The present application discloses a kind of based on sonar's oil cylinder displacement real-time computing device, including: cylinder (2), piston rod (4) being installed in cylinder (2) inside, piston (3) being provided at the front end of piston rod (4), and sonar ranging mechanism (1) being provided at the tail end of cylinder (2); The sonar ranging mechanism (1) includes a mounting hole (5), a sonar sensor (1) disposed in the mounting hole (5), and an ultrasonic wave transmitter (6) and an ultrasonic wave receiver (7) provided at the front end of the sonar sensor (1). The side wall of the cylinder (2) is provided with a liquid inlet P1 and a liquid inlet P1P2, the liquid inlet P1 is used to inject hydraulic oil into the rear cavity of the piston (3) during the jacking process of the jack, and the liquid inlet P1P2 is used to inject hydraulic oil into the front cavity of the piston rod (4) during the recovery process of the jack, so as to drive the piston rod (4) to move axially and reciprocally along the cylinder (2). The front end of the piston (3) is provided with a target echo surface with good reflection characteristics, which forms a fixed ranging structure closed loop with the ultrasonic wave transmitter (6) and the ultrasonic wave receiver (7) in the sound wave propagation path.

[0023] The mechanical structure, in actual use, controls the liquid inlet P1 and the liquid inlet P1P2 through the hydraulic system to realize the reciprocating displacement of the piston rod (4) in the cylinder (2), in each control cycle, the sonar sensor (1) emits a sound wave signal and receives the echo signal reflected from the target surface of the piston (3), the ultrasonic wave transmitter (6) and the ultrasonic wave receiver (7) are respectively used to complete the transmitting and receiving actions. By calculating the time difference between the transmitting and receiving and combining the sound velocity value converted from the current oil temperature, the sound wave propagation distance can be obtained, and by comparing the difference with the initial reference position, the real-time displacement value of the piston rod (4) can be obtained.

[0024] Before the oil cylinder is put into use, the processing parameters of the sonar echo signal are first specially adjusted. Specifically, the control program issues a transmission instruction to the sonar probe, so that the sonar probe transmits sonar pulses multiple times in the calibration stage. After each pulse transmission, the returned echo signal is received through the signal acquisition interface, and the complete echo waveform is recorded in time sequence through the high sampling rate data acquisition card.

[0025] Among them, the echo waveform data is obtained from the actual echo return signal of the sonar probe, and all records are saved to the data buffer area to ensure that the data source is clear and traceable.

[0026] After the data acquisition is completed, the rising edge, peak value and falling edge of each echo are analyzed point by point by a waveform analysis algorithm. In the specific analysis process, all waveform characteristics are compared, and the stability of each characteristic point under multiple emission echoes is counted. The time characteristic point with the most stable waveform characteristics and the least noise influence under various working conditions is determined, and is written into the characteristic parameter table as the time determination point.

[0027] Further, after the time characteristic point is determined, the echo times of multiple records are unified based on the characteristic point, and the determination rule of the echo time is calculated through time sequence comparison. The rule takes the selected characteristic point as the only reference, and is saved as a callable characteristic parameter record through data writing operation.

[0028] After the oil cylinder enters the normal working stage, the sonar probe periodically emits sonar pulses according to the preset rhythm, and the timing circuit automatically generates a time stamp and writes it into the data sequence at each emission. After the echo signal returns, the real-time waveform is recorded through the same signal acquisition interface, and the established echo time determination rule is called to perform envelope extraction and characteristic point matching on the current echo, and the time characteristic point obtained by matching is subtracted from the emission time stamp, and the difference result is directly written into the displacement calculation sequence. The time record of each echo is based on the same determination reference, realizing high consistency and high precision of time record in actual running state.

[0029] It should be noted that in the continuous working process of the long-stroke oil cylinder, the surface of the piston rod (4) has slight differences at different positions due to machining tolerances and use wear, and the oil film thickness and surface roughness of the local area also have uneven distribution, resulting in changes in echo amplitude and waveform distortion when the sonar pulse propagates and reflects in different sections. In the existing scheme, the extraction of echo time uses a unified time determination point and a unified waveform threshold for the entire stroke. During calibration, only one set of feature determination rule is established at the initial position, and then this rule is directly applied in the entire stroke range. The differences in echo characteristics of different sections are ignored. When the piston rod (4) enters a section with significantly different waveform characteristics, the existing unified threshold and unified characteristic point cannot accurately identify the real echo in this section, and may extract a delayed peak value or misjudge a local echo, thereby continuously generating deviations in this section, resulting in jumps, lags or cumulative errors in the displacement calculation curve in part of the stroke range, and finally reducing the displacement calculation accuracy of the entire stroke. Therefore, in the calibration stage before the oil cylinder is put into use, the feature determination rule of a single section is no longer directly applied to the entire stroke in this embodiment, but the low-speed driving program is used to advance the piston rod (4) at a constant step distance, so that it moves step by step from the zero position. When it reaches a step position, the built-in displacement encoder is called to obtain and record the unique index value of the step position. Subsequently, the sonar probe is controlled to emit a sonar pulse at the step position, a timing circuit records a time stamp at the moment of emission, and a high sampling rate acquisition card receives the echo signal and continuously samples and records the entire waveform curve. Each set of echo data collected is directly derived from the actual echo return at the corresponding step position and corresponds one-to-one to the time stamp and position index.

[0030] Further, in the embodiment of the present application, to achieve non-contact high-precision displacement measurement, the sonar probe structure is arranged at the center position of the bottom of the cylinder (2) and is coaxially arranged with the axis direction of the piston rod (4). This structure serves as the fixed starting point of the sonar pulse propagation path, ensuring that the echo signal always corresponds to the target area at the bottom of the piston rod (4) during propagation, effectively reducing the risk of echo distortion caused by sensor installation offset. This arrangement forms the basic reference path for the emission time point and the echo time difference in the present application, which is the starting point of the physical structure for subsequent propagation time difference calculation and displacement derivation.

[0031] Meanwhile, the oil temperature is collected by using the multi-point temperature sensor arranged in the oil cavity. Specifically, the temperature sensor is arranged at fixed points in the axial and radial directions of the cavity to form a temperature monitoring matrix covering the entire stroke range. Then, through a space matching algorithm, the current step position is matched with the monitoring matrix, and the temperature sensor closest to the step position is selected to obtain the real-time oil temperature value from the sensor.

[0032] The obtained oil temperature value data is converted into sound speed data at the current step position through a temperature-sound speed characteristic curve established and calibrated through physical experiments, and the sound speed data is bound with the index of the step position, ensuring that each step position has not only an independent spatial index and echo waveform but also sound speed data with a clear source and real-time correspondence with the oil state, which together constitute complete basic calibration data.

[0033] The temperature-sound speed characteristic curve is established by physical acoustics experimental data and obtained by collecting multiple sets of temperature and sound speed corresponding data in a special oil medium. The curve can be represented by a polynomial fitting relationship: C(T) = a0 + a1·T + a2·T² + a3·T³. Where C(T) represents the sound speed data, T represents the oil temperature value collected at the corresponding step position, and a0, a1, a2, and a3 are coefficients obtained through experimental calibration.

[0034] Further, the stroke of the piston rod (4) is segmented, so that each step position can find the closest temperature sensor arrangement point in space, and a one-to-one correspondence is established, so that each step position not only has an independent position index but also binds specific temperature sensor measurement point data.

[0035] Specifically, when the piston rod (4) is advanced to a certain step position with constant step, first, the built-in displacement encoder is called to read the step position and complete zero calibration, the obtained pulse count value is converted into a unique position index and a timestamp is attached to the position index record table, then, according to the spatial coordinates of the step position, the stored temperature sensor matrix is calculated and matched through the pre-configured spatial matching algorithm, which contains the coordinates and numbers of all temperature sensors arranged in the axial and radial directions of the oil cavity, then, the Euclidean distance between the current step position and each temperature sensor is calculated in turn and the temperature sensor number with the smallest Euclidean distance is selected, the real-time data output of the numbered temperature sensor is called through the temperature acquisition interface, the oil temperature value with timestamp is obtained, and the oil temperature value is bound with the step position index and written into the position and temperature mapping table, thereby forming a one-to-one correspondence in space.

[0036] Immediately after completing the mapping, the sonar probe is triggered to emit pulse signals at the step position multiple times, each emission is recorded by the timing circuit in real time, and after the echo returns, continuous full segment sampling is performed by the high sampling rate acquisition card, and the collected data is bound with the corresponding step position index and timestamp in chronological order and written into the waveform record table, ensuring that the waveform data source is clear and accurately corresponds to the spatial position.

[0037] Subsequently, all the waveform data recorded in the multiple emission processes at the same step position are called, aligned along the time axis, and after eliminating the slight deviation between samples by linear interpolation, point-to-point stacking is performed, wherein the amplitude value of each sample point is accumulated and averaged to generate a noise-reduced stacked waveform. The stacked waveform is sequentially called by a feature analysis algorithm, and the change point of the rising segment is determined by using the first derivative to identify the rising edge feature, and then the peak time position and peak amplitude are determined by using the second derivative and the sliding window to locate the maximum amplitude point. Subsequently, the Hilbert transform is called to extract the envelope curve and calculate the maximum value, width and morphology of the envelope, and other characteristic parameters; Then, the falling edge end point and amplitude change rate are extracted by the falling segment derivative change, and all the extracted feature parameters are written into the feature data record table of the step position in chronological order, forming a waveform timing feature data set composed of amplitude sequence, peak position sequence, envelope morphology parameters and edge change parameters.

[0038] After that, combined with the oil temperature value bound to the position, the waveform timing feature data under different oil temperature states are compared, the amplitude change rate, peak drift rate and envelope distortion rate are calculated to obtain each ratio feature, and then the normalized algorithm is used to output the fluctuation abnormal value of the step position and write it into the feature record table with the position index bound.

[0039] Specifically, the amplitude variation rate R1, the peak shift rate R2, and the envelope distortion rate R3 are calculated respectively. Through a normalization algorithm, each ratio feature is converted to the 0 to 1 interval, and then linearly combined, and the calculation formula is: fluctuation abnormal value = Q1·R1_norm + Q2·R2_norm + Q3·R3_norm; Wherein, R1_norm represents the normalized value of the amplitude variation rate, R2_norm represents the normalized value of the peak shift rate, R3_norm represents the normalized value of the envelope distortion rate, Q1 represents the weight of the normalized value of the amplitude variation rate, Q2 represents the weight of the normalized value of the peak shift rate, and Q3 represents the weight of the normalized value of the envelope distortion rate. Wherein, the amplitude variation rate is compared with the peak amplitude of the superimposed waveform and the reference amplitude at the step position, and the calculation formula is: amplitude variation rate R1 = (A_max - A_ref) / A_ref. Wherein, A_max represents the peak amplitude of the current superimposed waveform, and A_ref represents the reference peak amplitude recorded at the step position in the calibration stage.

[0040] The peak shift rate is compared with the peak time position of the current superimposed waveform and the reference peak time position, and the calculation formula is: peak shift rate R2 = (T_peak - T_ref) / T_ref. Wherein, T_peak represents the peak time position of the current superimposed waveform, and T_ref represents the reference peak time position recorded at the step position in the calibration stage.

[0041] The envelope distortion rate is compared with the current waveform envelope width and the reference envelope width, and the calculation formula is: envelope distortion rate R3 = (W_env - W_ref) / W_ref. Wherein, W_env represents the width of the current waveform envelope, and W_ref represents the reference envelope width recorded at the step position in the calibration stage.

[0042] Further, after the fluctuation abnormal value of all step positions in the full stroke range is calculated, a sorting operation program is called to arrange the fluctuation abnormal value field in the feature record table in descending order, and according to the sorting result, the step position with the largest fluctuation abnormal value is extracted, and the index of the step position is taken as the unique identifier to confirm it as the main step position.

[0043] It should be noted that the position index is the unique identifier of each step position, which is directly derived from the pulse count value output by the built-in displacement encoder and recorded in the calibration stage, and is written into the index record table after zero point calibration, ensuring the uniqueness and traceability of the index.

[0044] The sound velocity data is obtained from the oil temperature value obtained by calling the temperature sensor matrix in the calibration stage, converted by the pre-established temperature-sound velocity characteristic curve, and bound to the position index, stored in the data table as a physical parameter for converting the echo time into spatial distance, to ensure the accuracy of the ranging result.

[0045] Then, the index of the main trunk step distance position is taken as the primary key, the amplitude feature, peak position feature and envelope shape feature of the position obtained by waveform analysis in the calibration stage are called from the feature data record table, and the sound velocity data bound to the position are jointly written into the comprehensive feature vector record table to form a comprehensive feature vector containing the unique position index for spatial positioning, the sound velocity data for time-distance conversion, and the key feature parameters for waveform matching.

[0046] And taking the comprehensive feature vector as the center, the real-time echo data is first called for matching and correction operation after collection, and the time feature points are corrected by point-by-point comparison of the real-time echo waveform and the amplitude, peak value and envelope parameters in the comprehensive feature vector according to the feature matching algorithm. After the correction is completed, according to the adjacency relationship of the position index, the step distance positions adjacent to the main trunk position are selected layer by layer in order, the local waveform features of the adjacent positions recorded in the calibration stage are called and fused with the main trunk comprehensive feature vector, the waveform matching parameters of the adjacent positions are updated after comparing the differences, and the updated waveform matching parameters are transmitted to the next layer of adjacent positions in turn, and the cycle is executed in this order, finally forming a multi-level feature correction chain with the main trunk step distance position as the core and extending outward.

[0047] When the main trunk comprehensive feature is extended outward, the sonar control instruction is called at the beginning of each sampling period to drive the sonar probe to emit a pulse at the current step distance position of the oil cylinder, the transmission timestamp is recorded by the timing circuit, and the echo is returned by the high sampling rate collection card after the signal interface to execute full segment sampling. The sampling data is written into the real-time waveform buffer with the timestamp and position index as the key.

[0048] Subsequently, the data retrieval logic is called to extract the waveform matching features updated by the wave propagation mechanism and the corresponding sound velocity data from the feature record table with the current position index as the primary key, the waveform matching calculation function is called to perform point-by-point comparison of the amplitude, peak position and envelope curve of the real-time echo data, the time difference calculation formula is called to calculate the propagation time according to the matched time feature points and the transmission timestamp, and the distance conversion is performed combined with the called sound velocity data to output the displacement initial value of the current sampling period and write it into the real-time displacement buffer.

[0049] Then, the Kalman filtering algorithm is used to perform state prediction and observation update on the real-time displacement sequence, load the state vector and covariance matrix of the previous period, calculate the difference between the predicted value and the initial value of the current displacement, weight and fuse according to the preset Kalman gain, output the filtered displacement estimation value, and write it into the filtering output table. Through the time window smoothing algorithm, the displacement estimation values of multiple repeated echoes in the same sampling period are retrieved, the mean and standard deviation in the window are calculated, and the outliers beyond the threshold range are removed by the elimination function. The output smoothed displacement data is written into the final displacement sequence.

[0050] To make the Kalman filtering operation more explicit, the core formula is supplemented as follows: In the state prediction stage, the state equation is established according to the motion law of the piston rod (4) in the hydraulic system: X_k-=F·X_{k-1}+B·U_{k-1}; Where X_k- represents the predicted state vector, F represents the state transition matrix, X_{k-1} represents the state vector of the previous sampling period, B represents the control matrix, and U_{k-1} represents the control quantity.

[0051] In the observation update stage, the predicted value is fused with the sonar ranging data in the current sampling period, and the update formula is: X_k=X_k-+K_k(Z_k−H·X_k-); Where X_k represents the updated state vector, K_k represents the Kalman gain, Z_k represents the observation value, and H represents the observation matrix.

[0052] Further, the specific threshold range is determined by the specific experimental conditions, and to make the time window smoothing algorithm more explicit, the processing logic is supplemented as follows: in the same sampling period, the sliding average is performed on the displacement estimation values of continuous multiple echoes, and the calculation formula is: S_win=(ΣX_i) / n; Where S_win represents the smoothed displacement value in the window, X_i represents the filtered displacement estimation value calculated by each echo in the window, and n represents the sampling number in the window.

[0053] S_win and the Kalman filtering output value are compared, and if there is an outlier measurement value deviating from the preset threshold, the final real-time displacement data is output after removing the outlier measurement value by the elimination function and written into the real-time displacement sequence table.

[0054] In the long-term operation, in order to prevent the feature drift caused by the surface wear of the piston rod (4) or the change of temperature distribution, the piston rod (4) is pushed to the design limit position through the hydraulic drive program, the pulse emission and echo collection are performed by using the sonar control instruction, the ranging result of the position is obtained by using the same waveform matching calculation function, the current ranging result is compared with the initial calibration record point by point through the data comparison function, if the deviation is detected, the mechanical adjustment program is called to adjust the installation angle of the sonar probe, then the temperature value of the limit position is obtained by re-calling the temperature acquisition interface, the new sound speed data is calculated through the temperature and sound speed characteristic curve function, the amplitude, peak position and envelope curve feature extraction are performed on the re-collected echo waveform by using the waveform analysis algorithm, the updated sound speed data and the new waveform features are bound and written into the feature record corresponding to the position index, the feature parameter of the adjacent position is synchronously corrected by triggering the feature outward expansion algorithm, and the updated feature parameter is written into the feature record table of all affected positions, so that the parameter chain of the main feature outward spread is synchronously corrected, and the overall refresh of the feature chain is completed.

[0055] Then, the sorting retrieval logic is called to scan in descending order in the fluctuation abnormal value sorting result, and the first k step distance positions whose abnormal value is the second highest and the feature matching residual value is still within the preset threshold range after calculation by the residual evaluation function are screened out, and the position indexes are written into the secondary feature correction section table.

[0056] Then, the data statistical function is used to retrieve the real-time echo data recorded in the latest operation cycle for each secondary feature correction section, the amplitude standard deviation of the section is calculated according to the sampling time axis, the peak value analysis function is called to calculate the maximum drift of the peak position, and the envelope analysis function is called to calculate the morphological change rate of the envelope curve. The three indicators are combined into a fluctuation sensitivity parameter group and written into the sensitivity record of the corresponding section.

[0057] Then, the feature confidence calculation function is used to calculate the feature confidence Pi of each section by comprehensively calculating each index according to the weight, and the Pi value is bound and written into the feature confidence table with the corresponding position index. All secondary feature correction sections are arranged in descending order according to the Pi value, and the output result is written into the secondary feature correction pool.

[0058] Among them, in order to make the calculation process of the feature confidence Pi more clear, the mathematical expression thereof is supplemented as follows: The feature confidence Pi is comprehensively calculated according to the weight of the amplitude standard deviation S_amp, the maximum drift D_peak of the peak position and the morphological change rate C_env in the fluctuation sensitivity parameter group, and the calculation formula is as follows: Pi=W1·f1(S_amp)+W2·f2(D_peak)+W3·f3(C_env); Wherein, W1 represents the weight of the amplitude standard deviation S_amp, W2 represents the weight of the maximum drift D_peak of the peak position, W3 represents the weight of the envelope curve shape change rate C_env, f1, f2, f3 are mapping functions after normalizing the original indicators; Meanwhile, in the running process, the feature outward wave link continuously calls the matching monitoring logic to detect the waveform matching state of the section where the backbone step position is located in real time. When detecting abnormal trends such as waveform matching failure, echo time continuous offset, or sound speed data inconsistent with real-time propagation characteristics, the secondary feature correction pool is used to retrieve the confidence ranking results, the step position index with the highest Pi value is selected, the feature retrieval function is called to obtain its feature parameter set, the feature matching parameters of the current backbone region are replaced, the matching and correction operations are re-executed, the updated feature parameters are written back to the backbone feature vector, and the feature outward wave link continues to drive the progressive expansion, realizing the immediate takeover and seamless switching of the backbone feature matching logic, and ensuring that the feature correction link has continuous verification and failure replacement capabilities.

[0059] Further, after obtaining the time data, a temperature data acquisition instruction is called, and a temperature sensor arranged near the inner wall of the oil cavity continuously outputs an oil temperature value. Each temperature value is written into a temperature cache table with a time stamp. Then, a temperature-sound speed conversion function is called, and the real-time temperature value is input into the sound speed characteristic curve established by physical acoustics experimental data and corrected by combining specific oil medium calibration data, to output the real-time sound speed data at the corresponding moment and write it into a sound speed record table. A displacement calculation function is called to multiply the current collected echo time difference with the sound speed data at this moment to obtain the instantaneous distance. A zero reference record table is called to read the zero reference distance stored at the calibration time, and a difference operation is performed to output the real-time displacement initial value of the current piston rod (4) and write it into a displacement cache table.

[0060] Wherein, the sound speed characteristic curve is obtained from physical acoustics experimental data and corrected by specific oil medium calibration data, ensuring that the source of sound speed calculation is clear and the data is reliable.

[0061] Further, Kalman filtering operation is used to perform state prediction and observation update on the real-time displacement initial value in the displacement cache table. The state prediction model loads the motion law established according to the piston rod (4) in the hydraulic system, and the observation update value calls the sonar ranging data in the current sampling period. The predicted value and the observed value are weighted and fused through Kalman gain, and the filtered displacement estimation value is output and written into a filtering output table, effectively eliminating short-term abnormalities caused by sonar multipath effect, mechanical vibration and hydraulic fluctuation.

[0062] The displacement estimation values of multiple repeated echoes in the same sampling period are processed by a time window smoothing algorithm, the mean value is compared with the predicted value output by the Kalman filter, the outlier measurement value deviating from the preset threshold is removed, and the final real-time displacement data is output and written into a real-time displacement sequence table.

[0063] During the long-term operation of the oil cylinder, when the maintenance window is triggered, the driving control instruction is called to push the piston rod (4) to the limit position of the mechanical design, the sonar control instruction is called to emit pulses, collect echoes and perform the same time difference and sound speed calculation as in the running stage, and the instantaneous distance of the limit position is obtained.

[0064] As shown in Figure 3 The sonar ranging structure adopted by the present application comprises a cylinder body (2) 3, a piston rod (4) 4 and a sonar sensor (1) 1 arranged in the direction of the central axis of the bottom of the cylinder body (2). The sonar sensor (1) 1 is fixedly installed on the bottom of the cylinder body (2) 3 by fasteners, and emits sonar pulses towards the axial lower end of the piston rod (4) 4, and the echoes propagate along the liquid medium and are reflected back from the bottom of the piston rod (4).

[0065] As shown in Figure 4 The sonar sensor (1) 1 is internally integrated with multiple ultrasonic transmitters 6 and multiple ultrasonic receivers 7, wherein the transmitters 6 emit ultrasonic waves into the hydraulic cavity in a high-frequency periodic manner, and the receivers 7 receive echo signals in real time, and the sonar propagation distance is calculated by the time difference between transmission and reception and the sound speed in the liquid, and then the displacement amount of the piston rod (4) 4 relative to the bottom of the cylinder body (2) 3 is calculated.

[0066] The sonar sensor (1) 1 and the cylinder body (2) 3 are fixedly positioned by a mechanical mounting bracket, ensuring that the sonar transmission direction is aligned with the piston rod (4) axis, and the sensor probe avoids the intrusion of hydraulic oil into the signal interface area through a sealing structure, ensuring long-term stable operation of the system.

[0067] The distance is compared with the installation initial calibration record point by point by a comparison function, if the deviation is calculated, the mechanical adjustment instruction is called to readjust the installation angle of the sonar probe, then the temperature value is reacquired, the temperature-sound speed conversion function is called to update the sound speed data of the position, and the waveform analysis algorithm is called to reextract the waveform features, and the updated zero reference distance and feature data are written into the calibration record table, ensuring the accuracy of subsequent displacement calculation.

[0068] In each sampling cycle echo signal processing, call time window smoothing algorithm to perform sliding average on continuous multiple echo data, average multiple calculations of the same instantaneous displacement value, and then compare with Kalman filter output value, remove outliers, and write the updated smoothed displacement value to the final output table, so that the displacement sequence remains consistent and high confidence in the long term under high frequency reciprocating motion and complex environment.

[0069] The application also provides an oil cylinder displacement real-time calculation system based on sonar, as shown in the drawings, comprising: Figure 1 The signal output end of the sonar ranging mechanism (1) is connected with a general control module (8), the general control module (8) is used for receiving echo signals output by the sonar ranging mechanism (1), processing data and calculating real-time displacement, and specifically comprises: The acquisition submodule is used for acquiring echo waveforms output by the sonar sensor (1) and corresponding time stamps, and recording to a cache; The sound velocity conversion submodule is used for calling a preset temperature-sound velocity characteristic curve according to a real-time oil temperature, and calculating a current propagation sound velocity; The zero reference reading submodule is used for calling reference distance data established by the piston rod (4) at an initial position as a subsequent calculation reference; The displacement calculation submodule is used for calculating a current distance according to a current sound velocity and a time difference of echo propagation, and performing difference operation in combination with the zero reference to obtain a real-time displacement value; The filter correction submodule is used for denoising and dynamically adjusting the displacement initial value by using a Kalman filter algorithm and a sliding window smoothing mechanism, and outputting a high-confidence displacement estimation result; The data output submodule is used for writing the final real-time displacement to an output end cache for reading by an upper control system or a hydraulic execution unit.

[0070] The general control module (8) forms a high-coupling non-contact displacement ranging system with the sonar ranging mechanism (1) and the cylinder body (2) structure, and has the characteristics of high structural integration and strong adaptability to working conditions.

[0071] The above formulas are all dimensionless values, and the formulas are obtained by software simulation of a large amount of data to obtain a formula of the nearest real situation, and the preset parameters in the formula are set by a person skilled in the art according to the actual situation.

[0072] The above embodiments can be realized by software, hardware, firmware or any combination thereof, in whole or in part. When realized by software, the above embodiments can be realized in the form of a computer program product in whole or in part.

[0073] ​Those skilled in the art can understand that the modules and algorithm steps of each example described in combination with the embodiments disclosed herein can be realized by electronic hardware or a combination of computer software and electronic hardware. Whether the functions are realized in hardware or software manner depends on the specific application of the technical solution and the constraints of the invention. The skilled person can use different methods to realize the described functions for each specific application, but such implementation should not be considered beyond the scope of the present application.

[0074] In addition, each functional module in each embodiment of the present application can be integrated in one processing module, or each module can exist physically alone, or two or more modules can be integrated in one module.

[0075] The above is merely specific embodiments of the present application, but the protection scope of the present application is not limited thereto, any skilled person in the art can easily think of changes or replacements within the technical range disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.

[0076] Finally: the above is only the preferred embodiment of the present application, and is not used to limit the present application, any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included in the protection scope of the present application.

Claims

1. A real-time calculation system for hydraulic cylinder displacement based on sonar, characterized in that: It includes a cylinder (2), a piston rod (4), a sonar ranging mechanism (1) located at the tail end of the cylinder (2), and a main control module (8) connected thereto. The sonar ranging mechanism (1) includes a sonar sensor (1) located at the tail end of the cylinder (2), an ultrasonic transmitter (6) located at the front end of the sonar sensor (1), and an ultrasonic receiver (7). The cylinder body (2) has a liquid inlet P1 and a liquid inlet P1P2 on its side wall. The liquid inlet P1 is used to extend the jack, and the liquid inlet P1P2 is used to retract the jack. The main control module (8) includes: a data acquisition submodule, a sound velocity conversion submodule, a zero reference reading submodule, a displacement calculation submodule, a filtering correction submodule, and a data output submodule. The signals of each submodule are connected to form a data processing closed loop. The acquisition submodule is used to receive the echo signal output by the sonar ranging mechanism (1) and extract the time difference. The sound speed conversion submodule is used to calculate the sound wave propagation speed according to the current oil temperature. The displacement calculation submodule is used to perform difference calculation by combining the time difference and the sound speed and generate the initial displacement value. The filtering correction submodule performs filtering processing on the initial displacement value. The data output submodule outputs the final displacement result to the host computer or actuator.

2. A method for real-time calculation of hydraulic cylinder displacement based on sonar, based on the real-time calculation system for hydraulic cylinder displacement based on sonar as described in claim 1, characterized in that; Includes the following steps: Drive the piston rod (4) to move point by point according to a constant step distance. At each step distance position, emit a sonar pulse, record the echo waveform, timestamp and position index, and at the same time collect the oil temperature at the corresponding step distance position and convert the sound speed to establish a binding data table. The echo waveforms at each step position are aligned and superimposed, and the rising edge, peak value, and envelope features are extracted. The amplitude change rate, peak drift rate, and envelope distortion rate are calculated, and the fluctuation anomaly value at each step position is generated. After sorting, the step position with the largest fluctuation anomaly value is selected, and a comprehensive feature vector is established. Record the real-time echo waveform, call the comprehensive feature vector for matching, obtain the time feature points and calculate the displacement by combining the real-time sound velocity, and at the same time perform Kalman filtering and time window smoothing to process and record the displacement sequence; Push the piston rod (4) to the limit position to reacquire echo and temperature data, update sound velocity and waveform features, trigger synchronous correction of feature chain, and filter secondary feature positions, and retrieve and replace features according to confidence level.

3. The real-time calculation method for hydraulic cylinder displacement based on sonar according to claim 2, characterized in that: Multiple sonar pulses are transmitted to record the echo waveforms. The rising edge, peak value, and falling edge of the echo waveforms are analyzed to determine stable time feature points, which are then written into the feature parameter table.

4. The sonar-based real-time calculation method for hydraulic cylinder displacement according to claim 3, characterized in that: After determining the time feature points, the echo times of multiple echoes are standardized to generate echo time determination rules and are saved. During normal operation, sonar pulses are periodically emitted, echo waveforms are recorded, time feature points are matched, and the difference is calculated and written into the displacement calculation sequence.

5. The sonar-based real-time cylinder displacement calculation method according to claim 1, characterized in that; The piston rod (4) is moved gradually from the zero position with a constant step distance. At each step distance position, the unique index value of the step distance position is obtained and recorded. At the step distance position, a sonar pulse is emitted, the timestamp and echo signal are recorded, and the entire waveform curve is continuously sampled and recorded. Then, the oil temperature value is collected by the temperature sensor.

6. The real-time calculation method for hydraulic cylinder displacement based on sonar according to claim 5, characterized in that: The piston rod (4) stroke is segmented to establish a one-to-one correspondence between the step position and the temperature sensor. The piston rod (4) is pushed forward to record the step position index and write it into the position index record table. The temperature sensor is matched to obtain the oil temperature value and write it into the position and temperature mapping table. Sonar pulses are emitted multiple times at each step position to record the echo waveform and write it into the waveform recording table. The rising edge, peak value, envelope, and falling edge features are extracted and written into the feature data record table to construct a waveform time series feature dataset. The waveform time series feature data under different oil temperature values ​​are compared and calculated to obtain the fluctuation anomaly value.

7. The sonar-based real-time calculation method for hydraulic cylinder displacement according to claim 6, characterized in that: The fluctuation anomalies within the entire stroke range are sorted, and the step position with the largest fluctuation anomaly value is extracted to be identified as the main step position. The amplitude characteristics, peak position characteristics, and envelope shape characteristics of the main step position, along with the sound velocity data, are written into the comprehensive feature vector record table to construct the comprehensive feature vector. After real-time echo data acquisition, matching and correction operations are performed, and waveform matching parameters at adjacent step positions are updated layer by layer to form a multi-level feature correction chain; The sonar pulse is emitted to calculate the initial displacement value and output the displacement sequence. The piston rod (4) is pushed to the design limit position to reacquire the echo waveform and temperature value, update the feature record and correct it synchronously.

8. The real-time calculation method for hydraulic cylinder displacement based on sonar according to claim 7, characterized in that: The step position with the second highest outlier is selected and written into the secondary feature correction segment table. The amplitude standard deviation, the maximum drift of the peak position, and the rate of change of the envelope curve shape are calculated and written into the sensitivity record. Calculate the feature confidence Pi and write it into the feature confidence table and secondary feature correction pool. Obtain the step position feature parameter set with the highest Pi value to replace the main step position and perform matching and correction.

9. The sonar-based real-time calculation method for hydraulic cylinder displacement according to claim 1, characterized in that; Collect oil temperature value, convert sound velocity data, calculate echo time difference and sound velocity data to obtain real-time initial displacement value, and output real-time displacement data. When the machine is stopped for maintenance, push the piston rod (4) to the limit position to re-collect and update the calibration record table.

Citation Information

Patent Citations

  • Intelligent hydraulic cylinder built in ultrasonic sensor

    CN109236798A

  • Method and apparatus for determining category of object using ultrasound sensor

    CN116106876A

  • Hydraulic oil cylinder displacement detection system and hydraulic oil cylinder displacement detection method

    CN119042193A

  • Ultrasonic high-precision bone ranging method, system and probe for noninvasive registration

    CN119454097A

  • Water level measuring method and system based on ultrasonic waves

    CN120293265A