Proximity switch distance measurement method and system based on combination of inductance and capacitance
By combining inductance and capacitive sensors, identifying the object material and dynamically adjusting the measurement weight, and adjusting the frequency according to environmental changes, the accuracy and stability of the traditional proximity switch distance measurement method is solved, and high-precision distance measurement in complex environments is achieved.
Patent Information
- Application Number
- CN202510582266.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-07
- Publication Date
- 2025-08-01
- Estimated Expiration
- 2045-05-07
AI Technical Summary
Traditional proximity switch distance measurement methods rely on a single inductor or capacitive sensor, resulting in low measurement accuracy and stability, especially in the case of environmental changes or the diversity of object materials, which is difficult to ensure consistency and reliability.
Combined with inductor and capacitive sensors, by detecting the reflection characteristics of electromagnetic signals and electric field signals, identifying object material information and dynamically adjusting the measurement weight value of the sensor, and adjusting the sensor frequency according to the ambient temperature and humidity to perform distance measurement.
Improves the accuracy and stability of distance measurement, and maintains consistency and reliability in complex application scenarios.
Smart Images

Figure CN120403414A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of distance measurement, and particularly to a proximity switch distance measurement method and system based on the combination of inductance and capacitance. Background Art
[0002] Proximity switch distance measurement methods are usually implemented based on inductive or capacitive sensors. Inductive proximity switches sense the approach of an object by generating an electromagnetic field and utilizing the conductivity of a metal object to affect the intensity of the electromagnetic field. When a metal object approaches, the electromagnetic field of the inductive sensor changes, causing a change in the output signal of the sensor, and thus determining the presence and distance of the object. Capacitive proximity switches detect the approach of an object by generating an electric field and relying on the influence of the object (especially non-metal objects) on the electric field. The working principle of a capacitive sensor is to calculate the distance between the object and the sensor by measuring the influence of the object on the electric field.
[0003] However, traditional proximity switch distance measurement methods often rely solely on a single inductive or capacitive sensor to measure the distance of a moving object, resulting in low measurement accuracy. In addition, under the influence of environmental changes or the diversity of object materials, the measurement accuracy and stability of traditional methods are low, making it difficult to ensure consistency and reliability in complex actual application scenarios. Summary of the Invention
[0004] The object of the present invention is to solve the above-mentioned problems and provide a proximity switch distance measurement method and system based on the combination of inductance and capacitance.
[0005] In the first aspect of the implementation of the present invention, a proximity switch distance measurement method based on the combination of inductance and capacitance is first proposed. The method includes:
[0006] The control modules of the inductive sensor and the capacitive sensor are activated to detect the surrounding electromagnetic signals and electric field signals in real time, send electromagnetic signals and electric field signals to the surrounding, and determine the material information of the moving object according to the reflected signals of the electromagnetic signals and electric field signals;
[0007] Based on the material information of the moving object, identify and adjust the corresponding measurement distance weight values of the inductive sensor and the capacitive sensor when measuring the distance of the current moving object;
[0008] Obtain the temperature and humidity of the environment where the current moving object is located, and adjust the frequencies of the inductive sensor and the capacitive sensor according to the temperature and humidity of the environment where the current moving object is located;
[0009] Complete the distance measurement according to the inductive sensor and the capacitive sensor after adjusting the frequencies and the corresponding measurement distance weight values of the inductive sensor and the capacitive sensor.
[0010] Optionally, the step of determining the material information of the moving object according to the reflection signals of the electromagnetic signal and the electric field signal is as follows:
[0011] Extract the reflection signal of the electromagnetic signal from the inductive sensor as the first signal, and extract the reflection signal of the electric field signal from the capacitive sensor as the second signal;
[0012] Preprocess the first signal and the second signal, calculate based on the preprocessed first signal and second signal, and obtain the time when the first signal and the second signal are emitted to and returned to the corresponding inductive sensor and capacitive sensor, denoted as the first delay time and the second delay time;
[0013] Calculate the amplitude integrals of the first signal and the second signal, and denote the integral results as the first signal intensity value and the second signal intensity value respectively;
[0014] Compare the first signal intensity value with the second signal intensity value, and compare the first delay time with the second delay time. If the first signal intensity value is greater than the second signal intensity value and the first delay time is less than the second delay time, the probability that the material information of the corresponding moving object is metal is relatively high;
[0015] If the first signal intensity value is less than the second signal intensity value and the first delay time is greater than the second delay time, the probability that the material information of the corresponding moving object is non-metal is relatively high;
[0016] If the first signal intensity value is equal to the second signal intensity value and the first delay time is equal to the second delay time, the probabilities that the material information of the corresponding moving object is non-metal and metal are equal.
[0017] Optionally, based on the material information of the moving object, the steps of identifying and adjusting the measurement distance weight values corresponding to the inductive sensor and the capacitive sensor when measuring the distance of the current moving object are as follows:
[0018] When the probabilities that the material information of the moving object is non-metal and metal are equal, record the measurement distance weight values corresponding to the inductive sensor and the capacitive sensor as 0.5;
[0019] When the probability that the material information of the moving object is metal is relatively high or the probability that the material information of the moving object is metal is relatively high, calculate the sum of the first signal intensity value and the second signal intensity value as the overall signal intensity value;
[0020] Divide the first signal intensity value and the second signal intensity value by the overall signal intensity value respectively to obtain the corresponding signal intensity weight values;
[0021] Calculate the sum of the first delay time and the second delay time as the overall delay time; divide the first delay time and the second delay time by the overall delay time respectively to obtain the corresponding delay time weight values;
[0022] Take the average value of the corresponding signal strength weight value and the corresponding delay time weight value as the measurement distance weight value corresponding to the inductive sensor and the capacitive sensor.
[0023] Optionally, the steps of obtaining the temperature and humidity of the environment where the current moving object is located and adjusting the frequencies of the inductive sensor and the capacitive sensor according to the temperature and humidity of the environment where the current moving object is located are as follows:
[0024] Take the time when the electromagnetic signal and the electric field signal are sent as the starting time, and record the time from the starting time to the current time as the time interval; obtain the temperature and humidity of the environment where the moving object is located within the time interval, and calculate the average temperature and the average humidity;
[0025] Compare the average temperature and the average humidity with the preset standard temperature and the preset standard humidity respectively. If the average temperature is greater than the preset standard temperature, reduce the frequencies of the inductive sensor and the capacitive sensor;
[0026] If the average humidity is greater than the preset standard humidity, reduce the frequencies of the inductive sensor and the capacitive sensor, and then reduce the frequency of the capacitive sensor.
[0027] Optionally, the steps of completing the distance measurement according to the inductive sensor and the capacitive sensor after adjusting the frequencies and the measurement distance weight values corresponding to the inductive sensor and the capacitive sensor are as follows:
[0028] The inductive sensor and the capacitive sensor after adjusting the frequencies send electromagnetic signals and electric field signals to the surroundings, and receive the reflected signals of the electromagnetic signals and the electric field signals;
[0029] Calculate the distance value corresponding to the inductive sensor, and the calculation formula is: In the formula, D1 is the distance value corresponding to the inductive sensor, c is the propagation speed of the electromagnetic wave, which is 3×10 8 , t1 is the round-trip time of the electromagnetic signal;
[0030] Calculate the distance value corresponding to the capacitive sensor, and the calculation formula is: In the formula, D2 is the distance value corresponding to the capacitive sensor, t2 is the round-trip time of the electric field signal, v is the propagation speed of the electric field signal, and the calculation formula is: In the formula, c is the propagation speed of the electromagnetic wave, ∈ r is the relative permittivity 1 of the medium;
[0031] Multiply the distance value corresponding to the inductive sensor by the corresponding distance weight value to obtain a first distance, multiply the distance value corresponding to the capacitive sensor by the corresponding distance weight value to obtain a second distance, add the first distance and the second distance, and divide the result of the addition by the sum of the measurement distance weight values corresponding to the inductive sensor and the capacitive sensor to obtain the final distance, completing the distance measurement.
[0032] In the second aspect of the implementation of the present invention, a proximity switch distance measurement system based on the combination of inductance and capacitance is proposed. The system includes:
[0033] The material information determination module includes:
[0034] A signal extraction module: Extract the reflected signal of the electromagnetic signal from the inductive sensor as the first signal, and extract the reflected signal of the electric field signal from the capacitive sensor as the second signal;
[0035] A marking module: Preprocess the first signal and the second signal, calculate based on the preprocessed first signal and second signal, and obtain the time when the first signal and the second signal are emitted and returned to the corresponding inductive sensor and capacitive sensor, denoted as the first delay time and the second delay time;
[0036] A signal intensity module: Calculate the amplitude integral of the first signal and the second signal, and denote the results of the integration as the first signal intensity value and the second signal intensity value respectively;
[0037] A first comparison module: Compare the first signal intensity value and the second signal intensity value, and compare the first delay time and the second delay time. If the first signal intensity value is greater than the second signal intensity value and the first delay time is less than the second delay time, the probability that the material information of the corresponding moving object is metal is relatively high;
[0038] A second comparison module: If the first signal intensity value is less than the second signal intensity value and the first delay time is greater than the second delay time, the probability that the material information of the corresponding moving object is non-metal is relatively high;
[0039] A third comparison module: If the first signal intensity value is equal to the second signal intensity value and the first delay time is equal to the second delay time, the probabilities that the material information of the corresponding moving object is non-metal and metal are equal.
[0040] Optionally, the distance weight module includes:
[0041] A first distance weight value: When the probabilities that the material information of the moving object is non-metal and metal are equal, record the measurement distance weight values corresponding to the inductive sensor and the capacitive sensor as 0.5 each;
[0042] Overall signal strength module: When the probability that the material information of the moving object is metal is relatively high or the probability that the material information of the moving object is metal is relatively high, calculate the sum of the first signal strength value and the second signal strength value as the overall signal strength value;
[0043] Signal strength weight module: Divide the first signal strength value and the second signal strength value by the overall signal strength value respectively to obtain the corresponding signal strength weight values;
[0044] Delay time weight module: Calculate the sum of the first delay time and the second delay time as the overall delay time; Divide the first delay time and the second delay time by the overall delay time respectively to obtain the corresponding delay time weight values;
[0045] Second distance weight module: Take the average value of the corresponding signal strength weight value and the corresponding delay time weight value as the measurement distance weight value corresponding to the inductive sensor and the capacitive sensor.
[0046] Optionally, the adjustment module includes:
[0047] Calculation of temperature and humidity module: Take the time when the electromagnetic signal and the electric field signal are sent as the starting time, and record the time from the starting time to the current time as the time interval; Obtain the temperature and humidity of the environment where the moving object is located within the time interval, and calculate the average temperature and the average humidity;
[0048] First adjustment module: Compare the average temperature and the average humidity with the preset standard temperature and the preset standard humidity respectively. If the average temperature is greater than the preset standard temperature, reduce the frequencies of the inductive sensor and the capacitive sensor;
[0049] Second adjustment module: If the average humidity is greater than the preset standard humidity, reduce the frequencies of the inductive sensor and the capacitive sensor, then reduce the frequency of the capacitive sensor.
[0050] Optionally, the distance measurement module includes:
[0051] Re-emission module: The inductive sensor and the capacitive sensor after adjusting the frequency send electromagnetic signals and electric field signals to the surroundings, and receive the reflected signals of the electromagnetic signals and the electric field signals;
[0052] First calculation module: Calculate the distance value corresponding to the inductive sensor, and the calculation formula is: In the formula, D1 is the distance value corresponding to the inductive sensor, c is the propagation speed of electromagnetic waves, which is 3×10 8 , t1 is the round-trip time of the electromagnetic signal;
[0053] The second calculation module calculates the distance value corresponding to the capacitive sensor, and the calculation formula is: In the formula, D2 is the distance value corresponding to the capacitance sensor, t2 is the round-trip time of the electric field signal, and v is the propagation speed of the electric field signal. The calculation formula is: In the formula, C is the propagation speed of the electromagnetic wave, ∈ r is the relative permittivity 1 of the medium;
[0054] The third calculation module: Multiply the distance value corresponding to the inductance sensor by the corresponding distance weight value to obtain the first distance, multiply the distance value corresponding to the capacitance sensor by the corresponding distance weight value to obtain the second distance, add the first distance and the second distance, and divide the added result by the sum of the measurement distance weight values corresponding to the inductance sensor and the capacitance sensor to obtain the final distance, thus completing the distance measurement.
[0055] Advantages of the present invention:
[0056] The present invention proposes a proximity switch distance measurement method and system based on the combination of inductance and capacitance. By sending electromagnetic signals and electric field signals to the surroundings and determining the material information of the moving object according to the reflected signals of the electromagnetic signals and electric field signals; based on the material information of the moving object, identifying and adjusting the measurement distance weight values corresponding to the inductance sensor and the capacitance sensor when measuring the distance of the current moving object; obtaining the temperature and humidity of the environment where the current moving object is located, and adjusting the frequencies of the inductance sensor and the capacitance sensor according to the temperature and humidity of the environment where the current moving object is located; completing the distance measurement according to the adjusted frequencies of the inductance sensor and the capacitance sensor and the measurement distance weight values corresponding to the inductance sensor and the capacitance sensor. In this way, by combining inductance and capacitance for distance measurement of the moving object, the measurement accuracy is relatively high; in addition, the frequencies of the inductance sensor and the capacitance sensor can be adjusted according to environmental changes or the diversity of object materials for distance measurement, so that the measurement accuracy and stability are relatively high, and consistency and reliability can be ensured in complex actual application scenarios. Description of the Drawings
[0057] The following further describes the present invention with reference to the drawings.
[0058] Figure 1 is a flowchart of a proximity switch distance measurement method based on the combination of inductance and capacitance;
[0059] Figure 2 is a framework diagram of a proximity switch distance measurement system based on the combination of inductance and capacitance. Detailed Embodiments
[0060] The following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts shall fall within the protection scope of the present invention.
[0061] The embodiment of the present invention provides a method for measuring the distance of a proximity switch based on the combination of an inductor and a capacitor. Refer to Figure 1 , Figure 1 which is a flowchart of the method for measuring the distance of a proximity switch based on the combination of an inductor and a capacitor provided by the embodiment of the present invention. The method includes the following steps:
[0062] The control modules of the inductor sensor and the capacitor sensor are started to detect the surrounding electromagnetic signals and electric field signals in real time, send electromagnetic signals and electric field signals to the surrounding, and determine the material information of the moving object according to the reflected signals of the electromagnetic signals and electric field signals;
[0063] Based on the material information of the moving object, identify and adjust the corresponding measurement distance weight values of the inductor sensor and the capacitor sensor when measuring the distance of the current moving object;
[0064] Obtain the temperature and humidity of the environment where the current moving object is located, and adjust the frequencies of the inductor sensor and the capacitor sensor according to the temperature and humidity of the environment where the current moving object is located;
[0065] Complete the distance measurement according to the adjusted frequencies of the inductor sensor and the capacitor sensor and the corresponding measurement distance weight values of the inductor sensor and the capacitor sensor.
[0066] Based on the method for measuring the distance of a proximity switch based on the combination of an inductor and a capacitor provided by the embodiment of the present invention, through the above method, by combining an inductor and a capacitor to measure the distance of a moving object, the measurement accuracy is relatively high; in addition, the frequencies of the inductor sensor and the capacitor sensor can be adjusted according to environmental changes or the diversity of object materials for distance measurement, so that the measurement accuracy and stability are relatively high, and consistency and reliability can be ensured in complex actual application scenarios.
[0067] In one embodiment, the control modules of the inductor sensor and the capacitor sensor are started to detect the surrounding electromagnetic signals and electric field signals in real time, send electromagnetic signals and electric field signals to the surrounding, and determine the material information of the moving object according to the reflected signals of the electromagnetic signals and electric field signals;
[0068] Among them, the step of determining the material information of the moving object according to the reflected signals of the electromagnetic signals and electric field signals is:
[0069] Extract the reflected signal of the electromagnetic signal from the inductive sensor as the first signal, and extract the reflected signal of the electric field signal from the capacitive sensor as the second signal;
[0070] Preprocess the first signal and the second signal, perform calculations based on the preprocessed first signal and second signal, and obtain the time for the first signal and the second signal to be transmitted and returned to the corresponding inductive sensor and capacitive sensor, denoted as the first delay time and the second delay time;
[0071] Calculate the amplitude integrals of the first signal and the second signal, and denote the results of the integrals as the first signal intensity value and the second signal intensity value respectively;
[0072] Compare the first signal intensity value with the second signal intensity value, and compare the first delay time with the second delay time. If the first signal intensity value is greater than the second signal intensity value and the first delay time is less than the second delay time, the probability that the material information of the corresponding moving object is metal is relatively high;
[0073] If the first signal intensity value is less than the second signal intensity value and the first delay time is greater than the second delay time, the probability that the material information of the corresponding moving object is non-metal is relatively high;
[0074] If the first signal intensity value is equal to the second signal intensity value and the first delay time is equal to the second delay time, the probabilities that the material information of the corresponding moving object is non-metal and metal are equal.
[0075] It should be noted that after the control modules of the inductive sensor and the capacitive sensor are started, they will detect the surrounding electromagnetic signals and electric field signals in real time and send signals to the surrounding. The inductive sensor senses the metal characteristics of an object through the reflection of the electromagnetic signal, while the capacitive sensor senses the non-metal characteristics of an object through the reflection of the electric field signal. By analyzing the reflection characteristics of the electromagnetic signal and the electric field signal, such as parameters like signal intensity and delay time, the material information of the moving object can be inferred. For example, for a metal object, the electromagnetic signal is usually reflected strongly and with a short delay, while the reflection of the electric field signal is relatively weak; for a non-metal object, the electric field signal is reflected strongly and the electromagnetic signal is reflected weakly. In this way, the system can accurately judge the material of the object, and then adjust the measurement parameters of the sensor to improve the measurement accuracy and stability. For example, when approaching a metal object, the system will preferentially enhance the measurement ability of the inductive sensor to ensure more accurate distance data in the case of a metal object.
[0076] It should be noted that by analyzing the reflection signals of inductive and capacitive sensors, objects of different materials can be effectively distinguished. For example, when the system detects an object, the reflection intensity of the electromagnetic signal is usually high and the return time is short, indicating that the object may be made of metal. For instance, when detecting a metal steel plate, the electromagnetic reflection signal received by the inductive sensor will show a strong reflection and the signal delay time is short because metal has a strong ability to reflect electromagnetic waves and the signal propagates rapidly. In contrast, when the system detects a plastic object, the reflection intensity of the electric field signal is often strong, while the reflection of the electromagnetic signal is weak and the signal delay time is long. This is because plastic has a weak reflection of electromagnetic waves, but has a more obvious impact on the electric field signal and the signal propagates slowly. In this way, the system can accurately judge the material of the object, and then adjust the measurement parameters of the sensor according to the material characteristics to improve the accuracy and stability of distance measurement. In a complex environment, this judgment can ensure that the sensor can work effectively on different objects and materials and avoid errors.
[0077] In one embodiment, based on the material information of the moving object, the steps of identifying and adjusting the measurement distance weight values corresponding to the inductive sensor and the capacitive sensor when measuring the distance of the current moving object are as follows:
[0078] When the probabilities of the material information of the moving object being non-metal and metal are equal, record the measurement distance weight values corresponding to the inductive sensor and the capacitive sensor as 0.5 each;
[0079] When the probability of the material information of the moving object being metal is relatively large or the probability of the material information of the moving object being metal is relatively large, calculate the sum of the first signal intensity value and the second signal intensity value as the overall signal intensity value;
[0080] Divide the first signal intensity value and the second signal intensity value by the overall signal intensity value respectively to obtain the corresponding signal intensity weight values;
[0081] Calculate the sum of the first delay time and the second delay time as the overall delay time; divide the first delay time and the second delay time by the overall delay time respectively to obtain the corresponding delay time weight values;
[0082] Take the average of the corresponding signal intensity weight values and the corresponding delay time weight values as the measurement distance weight values corresponding to the inductive sensor and the capacitive sensor.
[0083] It should be noted that in practical applications, based on the material information of the object, the measurement distance weight values of the inductive sensor and the capacitive sensor will be dynamically adjusted according to the different materials of the object. For example, when the system detects that the material information of the object is metal, the reflection of the electromagnetic signal will be stronger, the signal intensity will be larger, and the return time will be shorter. At this time, the weight value of the inductive sensor will be higher, indicating that the inductive sensor makes a greater contribution to the distance measurement, because the metal object is more sensitive to the electromagnetic signal. On the contrary, the weight value of the capacitive sensor will be lower, because its response to the change of the metal object is not as sensitive as that of the inductive sensor.
[0084] It should be noted that, for example, assume that the system detects a metal box, the signal intensity returned by the inductive sensor is 0.8, the signal intensity returned by the capacitive sensor is 0.2, the delay time of the inductive sensor is 0.05 seconds, and the delay time of the capacitive sensor is 0.15 seconds. In this case, the signal intensity of the inductive sensor dominates, and the weight value will be more biased towards the inductive sensor, while the influence of the capacitive sensor is relatively small. The calculation process may result in a weight value of 0.75 for the inductive sensor and a weight value of 0.25 for the capacitive sensor; for another example, assume that the detected object is a plastic object, and its signal intensity is relatively balanced, and the signal intensities of the inductive and capacitive sensors are not much different. The signal intensity of the inductive sensor is 0.5, the signal intensity of the capacitive sensor is 0.5, and the delay times are also nearly equal. At this time, due to the small differences in the reflected signal intensity and delay time between the two, the system sets the measurement distance weight values of the inductive sensor and the capacitive sensor to be equal, for example, 0.5 each, to ensure the balanced role of the two sensors in distance measurement.
[0085] In one implementation, this dynamic adjustment of the weight value enables the system to optimize the accuracy of distance measurement according to the material characteristics when processing objects of different materials, improving the measurement accuracy and stability.
[0086] In one embodiment, the steps of obtaining the ambient temperature and humidity of the current moving object and adjusting the frequencies of the inductive sensor and the capacitive sensor according to the ambient temperature and humidity of the current moving object are as follows:
[0087] Take the time when the electromagnetic signal and the electric field signal are sent as the starting time, and record the time from the starting time to the current time as the time interval; obtain the temperature and humidity of the environment where the moving object is located within the time interval, and calculate the average temperature and the average humidity;
[0088] Compare the average temperature and the average humidity with the preset standard temperature and the preset standard humidity respectively. If the average temperature is greater than the preset standard temperature, reduce the frequencies of the inductive sensor and the capacitive sensor;
[0089] If the average humidity is greater than the preset standard humidity, the frequencies of the inductive sensor and the capacitive sensor are reduced, and then the frequency of the capacitive sensor is reduced.
[0090] It should be noted that the period from the start time to the current time is called the time interval. During this time interval, the temperature and humidity of the surrounding environment are continuously monitored, and the data is collected and recorded. The data is read in real time through the built-in temperature and humidity sensors or other environmental monitoring devices. Calculate the average temperature and average humidity within this time interval. These two values reflect the temperature and humidity conditions of the current environment. For example, assume that within a 5-minute time interval, the temperatures are 22°C, 23°C, and 24°C respectively, and the humidities are 50%, 55%, and 53% respectively. Then the average temperature for this time period is (22 + 23 + 24) / 3 = 23°C, and the average humidity is (50 + 55 + 53) / 3 = 52.67%. Compare the calculated average temperature and average humidity with the preset standard temperature and standard humidity. The preset standard temperature and humidity are ideal values set according to normal working environmental conditions. For example, assume the preset standard temperature is 22°C and the standard humidity is 50%. By comparing the current average temperature and average humidity with these standard values, it is determined whether the current environment exceeds the ideal working range. If the average temperature is greater than the preset standard temperature (i.e., the environmental temperature is too high), it may cause an increase in the electromagnetic wave propagation speed, affecting the measurement accuracy of inductive sensors and capacitive sensors. Therefore, it is necessary to reduce the frequency to adapt to this change. Reducing the frequency can effectively reduce the errors that may be caused by the too-fast signal propagation speed in a high-temperature environment, ensuring that the signal can fully propagate on the surface of the target object, thereby improving the measurement accuracy. For example, assume the preset standard temperature is 22°C, and the current average temperature is 25°C (the temperature is on the high side). To compensate for this increase in temperature, the operating frequencies of the inductive sensor and the capacitive sensor will be reduced. The frequency may be reduced from the original 100 MHz to 90 MHz, which can make the signal propagation more stable and avoid signal distortion caused by the too-fast propagation speed at high temperatures. If the average humidity is greater than the preset standard humidity (i.e., the environmental humidity is too high), the high humidity may cause a change in the dielectric constant of the air, affecting the measurement characteristics of the capacitor. In an environment with a higher humidity, the response of the capacitive sensor may become more sensitive. Therefore, it is necessary to appropriately reduce the frequency of the capacitive sensor. By reducing the frequency, the signal deviation caused by the too-high humidity of the capacitive sensor can be reduced, thereby improving the measurement accuracy. Assume the preset standard humidity is 50%, and the current average humidity is 60% (the humidity is on the high side). To compensate for the increase in humidity, the frequency of the capacitive sensor can be reduced. The frequency may be reduced from 100 MHz to 95 MHz, which can ensure that the capacitive sensor can work more stably and avoid measurement errors caused by too-high humidity. Through the real-time collection and analysis of the temperature and humidity data, after obtaining the appropriate adjustment plan, the adjusted frequency setting will be immediately applied to the control modules of the inductive sensor and the capacitive sensor. At this time, the operating frequency of the sensor will be automatically adjusted according to the current temperature and humidity conditions to ensure the optimization of the measurement accuracy.The adjusted frequency will immediately affect the response characteristics of the sensor, thereby affecting the accuracy and stability of the measurement results. Assume that the preset standard temperature is 22°C and the standard humidity is 50%. In practical applications, assume that the temperature of the environment where the moving object is located is 25°C and the humidity is 60%. After analysis, the average temperature is calculated to be 25°C and the average humidity is 60%. Since the current temperature is higher than the standard temperature, the frequencies of the inductive sensor and the capacitive sensor will be reduced (for example, reduced to 90 MHz); at the same time, since the humidity is also higher than the standard humidity, the frequency of the capacitive sensor will be particularly reduced (for example, reduced to 95 MHz). In this way, the sensor can provide more accurate distance measurement results under the current environmental conditions.
[0091] It should be noted that when the temperature is lower than the preset standard temperature, the frequency of the inductive sensor remains unchanged because the influence of temperature change on the inductive sensor is small, and low temperature usually does not significantly change the operating characteristics of the inductive sensor. However, the frequency of the capacitive sensor needs to be reduced because in a low-temperature environment, the dielectric constant of air may increase, resulting in a slower propagation speed of the electric field signal. To adapt to this change and reduce measurement errors, the frequency of the capacitive sensor needs to be reduced. This adjustment can ensure that the capacitive sensor can still accurately respond to the change of the electric field under low-temperature conditions, thus maintaining the measurement accuracy.
[0092] It should be noted that when the temperature is lower than the preset standard temperature, the operating frequency of the inductive sensor usually does not need to be adjusted because in a low-temperature environment, the propagation speed of electromagnetic waves becomes slower, and the change in frequency has little impact on the measurement accuracy of the inductive sensor. Therefore, keep the frequency of the inductive sensor unchanged to ensure its stability and accuracy. When the humidity is higher than the preset standard humidity, the increase in humidity will cause a change in the dielectric constant in the air, thereby affecting the performance of the capacitive sensor. High humidity makes the number of water molecules in the air increase, which in turn changes the propagation characteristics of the electric field, making the response of the capacitive sensor more sensitive. To avoid the measurement error caused by too high humidity to the capacitive sensor, the frequency of the capacitive sensor is reduced to slow down its overly sensitive response, thereby improving the stability and accuracy of the measurement. Through this adjustment, the capacitive sensor can better adapt to the change of humidity.
[0093] In one implementation, through this series of steps, the operating frequency of the sensor can be intelligently adjusted to ensure high-precision measurement performance under different environmental conditions.
[0094] In one embodiment, the steps for completing distance measurement according to the measured distance weight values corresponding to the inductive sensor and the capacitive sensor and the inductive sensor and the capacitive sensor after adjusting the frequency are as follows:
[0095] After adjusting the frequency, the inductive sensor and the capacitive sensor send electromagnetic signals and electric field signals to the surroundings and receive the reflected signals of the electromagnetic signals and electric field signals;
[0096] Calculate the distance value corresponding to the inductive sensor. The calculation formula is: In the formula, D1 is the distance value corresponding to the inductive sensor, c is the propagation speed of electromagnetic waves (usually the speed of light 3×10 8 ), and t1 is the round-trip time of the electromagnetic signal;
[0097] It should be noted that dividing by 2 is because the signal propagation is not one-way but the round-trip time;
[0098] Calculate the distance value corresponding to the capacitive sensor. The calculation formula is: In the formula, D2 is the distance value corresponding to the capacitive sensor, t2 is the round-trip time of the electric field signal, and v is the propagation speed of the electric field signal. The calculation formula is: In the formula, c is the propagation speed of electromagnetic waves (usually the speed of light 3×10 8 ), ∈ r is the relative permittivity of the medium, indicating the influence degree of the medium on the electric field. For air, ∈ r is approximately 1;
[0099] Multiply the distance value corresponding to the inductive sensor by the corresponding distance weight value to obtain the first distance. Multiply the distance value corresponding to the capacitive sensor by the corresponding distance weight value to obtain the second distance. Add the first distance and the second distance, and divide the added result by the total sum of the measurement distance weight values corresponding to the inductive sensor and the capacitive sensor to obtain the final distance, thus completing the distance measurement.
[0100] It should be noted that the relative permittivity ∈ r of air is approximately 1. Since the electromagnetic wave propagation characteristics of air are similar to those of a vacuum, the propagation speed of the electric field signal in air is basically the same as the speed of light. Water: The relative permittivity of water also means that when performing capacitive measurement in a water environment, the signal propagation speed and the measurement accuracy of the sensor will be significantly affected. Glass: The relative permittivity ∈ r of glass is approximately 4 - 7, depending on the type of glass. The relative permittivity of glass is lower than that of air and water, but still higher than 1, which will cause the propagation speed of the electric field signal in glass to slow down, but faster than that in water. Plastic: The relative permittivity ∈ r of common plastics (such as polyethylene, polypropylene, etc.) is usually between 2 - 3. The relative permittivity of plastic is higher than that of air, but lower than that of water and glass. Therefore, the propagation speed of the electric field signal is moderate. Therefore, the relative permittivity ∈ rIt directly affects the response of the capacitive sensor in different environments. When measuring the distance, it is necessary to adjust the propagation speed according to the medium where it is located to ensure accurate calculation of the distance of the object.
[0101] It should be noted that in practical applications, combining the measurement results of the inductive sensor and the capacitive sensor to calculate the final distance is an important step. For example, assume that in a certain measurement scenario, the distance measured by the inductive sensor is 3 meters, and the distance measured by the capacitive sensor is 2.5 meters. On this basis, we can introduce their respective measurement weight values to optimize the distance calculation. For example, the weight of the inductive sensor is 0.6, and the weight of the capacitive sensor is 0.4, indicating that the inductive sensor is more reliable in this environment. According to this weight, we first multiply the distance of the inductive sensor (3 meters) by its weight (0.6) to get 1.8 meters; then multiply the distance of the capacitive sensor (2.5 meters) by its weight (0.4) to get 1 meter. Finally, add the two weighted results (1.8 meters + 1 meter = 2.8 meters) and divide by the sum of the two weights (0.6 + 0.4 = 1) to get the final distance of 2.8 meters. This method combines the measurement results and weights of the inductive and capacitive sensors, making the final distance measurement more accurate and reliable. Especially in complex measurement environments, it can fully consider the advantages and adaptability of different sensors, thus providing more accurate results.
[0102] Based on the same inventive concept, the embodiment of the present invention also provides a proximity switch distance measurement system based on the combination of inductance and capacitance. See Figure 2 , Figure 2 is a framework diagram of the proximity switch distance measurement system based on the combination of inductance and capacitance provided by the embodiment of the present invention. The system includes:
[0103] Material information determination module: The control modules of the inductive sensor and the capacitive sensor are started to detect the surrounding electromagnetic signals and electric field signals in real time, send electromagnetic signals and electric field signals to the surrounding, and determine the material information of the moving object according to the reflected signals of the electromagnetic signals and electric field signals;
[0104] Distance weight module: Based on the material information of the moving object, identify and adjust the corresponding measurement distance weight values of the inductive sensor and the capacitive sensor when measuring the distance of the current moving object;
[0105] Adjustment module: Obtain the temperature and humidity of the environment where the current moving object is located, and adjust the frequencies of the inductive sensor and the capacitive sensor according to the temperature and humidity of the environment where the current moving object is located;
[0106] Distance measurement module: Complete the distance measurement according to the inductive sensor and the capacitive sensor after adjusting the frequency and the corresponding measurement distance weight values of the inductive sensor and the capacitive sensor.
[0107] Based on the proximity switch distance measurement system combining inductance and capacitance provided by the embodiments of the present invention, through the above method, by combining inductance and capacitance to measure the distance of a moving object, the measurement accuracy is relatively high; in addition, the frequencies of the inductance sensor and the capacitance sensor can be adjusted according to environmental changes or the diversity of object materials for distance measurement, so that the measurement accuracy and stability are relatively high, and consistency and reliability can be ensured in complex actual application scenarios.
[0108] In one embodiment, the signal extraction module: extracts the reflected signal of the electromagnetic signal from the inductance sensor as the first signal, and extracts the reflected signal of the electric field signal from the capacitance sensor as the second signal;
[0109] The marking module: preprocesses the first signal and the second signal, calculates based on the preprocessed first signal and second signal, and obtains the time when the first signal and the second signal are emitted and returned to the corresponding inductance sensor and capacitance sensor, denoted as the first delay time and the second delay time;
[0110] The signal intensity module: calculates the amplitude integrals of the first signal and the second signal, and respectively denotes the integration results as the first signal intensity value and the second signal intensity value;
[0111] The first comparison module: compares the first signal intensity value and the second signal intensity value, and compares the first delay time and the second delay time. If the first signal intensity value is greater than the second signal intensity value and the first delay time is less than the second delay time, the probability that the material information of the corresponding moving object is metal is relatively high;
[0112] The second comparison module: If the first signal intensity value is less than the second signal intensity value and the first delay time is greater than the second delay time, the probability that the material information of the corresponding moving object is non-metal is relatively high;
[0113] The third comparison module: If the first signal intensity value is equal to the second signal intensity value and the first delay time is equal to the second delay time, the probabilities that the material information of the corresponding moving object is non-metal and metal are equal.
[0114] In one embodiment, the distance weight module includes:
[0115] The first distance weight value: When the probabilities that the material information of the moving object is non-metal and metal are equal, the measurement distance weight values corresponding to the inductance sensor and the capacitance sensor are both denoted as 0.5;
[0116] The overall signal intensity module: When the probability that the material information of the moving object is metal is relatively high or the probability that the material information of the moving object is metal is relatively high, calculates the sum of the first signal intensity value and the second signal intensity value as the overall signal intensity value;
[0117] Signal intensity weighting module: Divide the first signal intensity value and the second signal intensity value by the overall signal intensity value respectively to obtain the corresponding signal intensity weighting values;
[0118] Delay time weighting module: Calculate the sum of the first delay time and the second delay time as the overall delay time; Divide the first delay time and the second delay time by the overall delay time respectively to obtain the corresponding delay time weighting values;
[0119] Second distance weighting module: Take the average value of the corresponding signal intensity weighting value and the corresponding delay time weighting value as the measurement distance weighting value corresponding to the inductive sensor and the capacitive sensor.
[0120] In one embodiment, the adjustment module includes:
[0121] Temperature and humidity calculation module: Take the time when the electromagnetic signal and the electric field signal are sent as the starting time, and record the time from the starting time to the current time as the time interval; Obtain the temperature and humidity of the environment where the moving object is located within the time interval, and calculate the average temperature and the average humidity;
[0122] First adjustment module: Compare the average temperature and the average humidity with the preset standard temperature and the preset standard humidity respectively. If the average temperature is greater than the preset standard temperature, reduce the frequencies of the inductive sensor and the capacitive sensor;
[0123] Second adjustment module: If the average humidity is greater than the preset standard humidity, reduce the frequencies of the inductive sensor and the capacitive sensor, then reduce the frequency of the capacitive sensor.
[0124] In one embodiment, the distance measurement module includes:
[0125] Re - emission module: The inductive sensor and the capacitive sensor after frequency adjustment send electromagnetic signals and electric field signals to the surroundings, and receive the reflected signals of the electromagnetic signals and the electric field signals;
[0126] First calculation module: Calculate the distance value corresponding to the inductive sensor, and the calculation formula is: In the formula, D1 is the distance value corresponding to the inductive sensor, c is the propagation speed of the electromagnetic wave, which is 3×10 8 , t1 is the round - trip time of the electromagnetic signal;
[0127] The second calculation module calculates the distance value corresponding to the capacitive sensor, and the calculation formula is: In the formula, D2 is the distance value corresponding to the capacitive sensor, t2 is the round - trip time of the electric field signal, v is the propagation speed of the electric field signal, and the calculation formula is: In the formula, c is the propagation speed of the electromagnetic wave, ∈r is the relative permittivity 1 of the medium;
[0128] The third calculation module: Multiply the distance value corresponding to the inductive sensor by the corresponding distance weight value to obtain the first distance, multiply the distance value corresponding to the capacitive sensor by the corresponding distance weight value to obtain the second distance, add the first distance and the second distance, and divide the result of the addition by the total sum of the measurement distance weight values corresponding to the inductive sensor and the capacitive sensor to obtain the final distance, thus completing the distance measurement.
[0129] The above has described in detail an embodiment of the present invention, but the content is only a preferred embodiment of the present invention and cannot be considered as limiting the scope of implementation of the present invention. All equivalent changes and improvements made according to the scope of the application of the present invention shall still fall within the scope covered by the patent of the present invention.
Claims
1. A proximity switch distance measurement method based on the combination of inductance and capacitance, characterized in that Including the following steps: The control modules of the inductive sensor and the capacitive sensor are activated to detect the surrounding electromagnetic signals and electric field signals in real time, send electromagnetic signals and electric field signals to the surroundings, and determine the material information of the moving object based on the reflected signals of the electromagnetic signals and electric field signals; Based on the material information of the moving object, identify and adjust the corresponding measurement distance weight values of the inductive sensor and the capacitive sensor when measuring the distance of the current moving object; Obtain the temperature and humidity of the environment where the current moving object is located, and adjust the frequencies of the inductive sensor and the capacitive sensor according to the temperature and humidity of the environment where the current moving object is located; Complete the distance measurement according to the inductive sensor and the capacitive sensor after adjusting the frequencies and the corresponding measurement distance weight values of the inductive sensor and the capacitive sensor.
2. The proximity switch distance measurement method based on the combination of inductance and capacitance according to claim 1, characterized in that The step of determining the material information of the moving object based on the reflected signals of the electromagnetic signals and electric field signals is as follows: Extract the reflected signal of the electromagnetic signal from the inductive sensor as the first signal, and extract the reflected signal of the electric field signal from the capacitive sensor as the second signal; Preprocess the first signal and the second signal, calculate based on the preprocessed first signal and second signal, and obtain the time when the first signal and the second signal are transmitted to and returned to the corresponding inductive sensor and capacitive sensor, denoted as the first delay time and the second delay time; Calculate the amplitude integrals of the first signal and the second signal, and denote the results of the integrals as the first signal intensity value and the second signal intensity value respectively; Compare the first signal intensity value with the second signal intensity value, and compare the first delay time with the second delay time. If the first signal intensity value is greater than the second signal intensity value and the first delay time is less than the second delay time, the probability that the material information of the corresponding moving object is metal is relatively high; If the first signal intensity value is less than the second signal intensity value and the first delay time is greater than the second delay time, the probability that the material information of the corresponding moving object is non-metal is relatively high; If the first signal intensity value is equal to the second signal intensity value and the first delay time is equal to the second delay time, the probabilities that the material information of the corresponding moving object is non-metal and metal are equal.
3. The proximity switch distance measurement method based on the combination of inductance and capacitance according to claim 2, characterized in that, The steps of identifying and adjusting the corresponding measurement distance weight values of the inductive sensor and the capacitive sensor when measuring the distance of the current moving object based on the material information of the moving object are as follows: When the probabilities that the material information of the moving object is non-metal and metal are equal, record the corresponding measurement distance weight values of the inductive sensor and the capacitive sensor as 0.5; When the probability that the material information of the moving object is metal is relatively high or the probability that the material information of the moving object is metal is relatively high, calculate the sum of the first signal intensity value and the second signal intensity value as the overall signal intensity value; Divide the first signal intensity value and the second signal intensity value by the overall signal intensity value respectively to obtain the corresponding signal intensity weight values; Calculate the sum of the first delay time and the second delay time as the overall delay time; Divide the first delay time and the second delay time by the overall delay time respectively to obtain the corresponding delay time weight values; Take the mean value of the corresponding signal intensity weight value and the corresponding delay time weight value as the corresponding measurement distance weight values of the inductive sensor and the capacitive sensor.
4. The proximity switch distance measurement method based on the combination of inductance and capacitance according to claim 1, characterized in that, The steps of obtaining the temperature and humidity of the environment where the current moving object is located and adjusting the frequencies of the inductive sensor and the capacitive sensor according to the temperature and humidity of the environment where the current moving object is located are as follows: Take the time when the electromagnetic signal and the electric field signal are sent as the starting time, and record the time from the starting time to the current time as the time interval; obtain the temperature and humidity of the environment where the moving object is located within the time interval, and calculate the average temperature and the average humidity; Compare the average temperature and the average humidity with the preset standard temperature and the preset standard humidity respectively. If the average temperature is greater than the preset standard temperature, then reduce the frequencies of the inductive sensor and the capacitive sensor; If the average humidity is greater than the preset standard humidity, then reduce the frequencies of the inductive sensor and the capacitive sensor, and then reduce the frequency of the capacitive sensor.
5. The proximity switch distance measurement method based on the combination of inductance and capacitance according to claim 1, characterized in that The steps of completing distance measurement according to the inductive sensor and the capacitive sensor after adjusting the frequencies and the measurement distance weight values corresponding to the inductive sensor and the capacitive sensor are as follows: The inductive sensor and the capacitive sensor after adjusting the frequencies send electromagnetic signals and electric field signals to the surroundings, and receive the reflected signals of the electromagnetic signals and the electric field signals; Calculate the distance value corresponding to the inductive sensor, and the calculation formula is: In the formula, D1 is the distance value corresponding to the inductive sensor, c is the propagation speed of electromagnetic waves, which is 3×10 8 , and t1 is the round-trip time of the electromagnetic signal; Calculate the distance value corresponding to the capacitive sensor. The calculation formula is as follows: In the formula, D2 is the distance value corresponding to the capacitive sensor, t2 is the round-trip time of the electric field signal, and v is the propagation speed of the electric field signal. The calculation formula is as follows: In the formula, c is the propagation speed of electromagnetic waves, ∈ r is the relative permittivity 1 of the medium; Multiply the distance value corresponding to the inductive sensor by the corresponding distance weight value to obtain the first distance, multiply the distance value corresponding to the capacitive sensor by the corresponding distance weight value to obtain the second distance, add the first distance and the second distance, and divide the added result by the total sum of the measurement distance weight values corresponding to the inductive sensor and the capacitive sensor to obtain the final distance, and complete the distance measurement.
6. A proximity switch distance measurement system based on the combination of inductance and capacitance, characterized in that The system includes: Material information determination module: The control modules of the inductive sensor and the capacitive sensor are started, the electromagnetic signals and the electric field signals around are detected in real time, electromagnetic signals and electric field signals are sent to the surroundings, and the material information of the moving object is determined according to the reflected signals of the electromagnetic signals and the electric field signals; Distance weight module: Based on the material information of the moving object, identify and adjust the measurement distance weight values corresponding to the inductive sensor and the capacitive sensor when the current moving object performs distance measurement; Adjustment module: Obtain the temperature and humidity of the environment where the current moving object is located, and adjust the frequencies of the inductive sensor and the capacitive sensor according to the temperature and humidity of the environment where the current moving object is located; Distance measurement module: Complete distance measurement according to the inductive sensor and the capacitive sensor after adjusting the frequencies and the measurement distance weight values corresponding to the inductive sensor and the capacitive sensor.
7. The proximity switch distance measurement system based on the combination of inductance and capacitance according to claim 6, characterized in that, The material information determination module includes: Signal extraction module: Extract the reflected signal of the electromagnetic signal from the inductive sensor as the first signal, and extract the reflected signal of the electric field signal from the capacitive sensor as the second signal; Marking module: Preprocess the first signal and the second signal, calculate based on the preprocessed first signal and second signal, and obtain the time when the first signal and the second signal are emitted and returned to the corresponding inductive sensor and capacitive sensor, which is recorded as the first delay time and the second delay time; Signal intensity module: Calculate the amplitude integrals of the first signal and the second signal, and record the integral results as the first signal intensity value and the second signal intensity value respectively; The first comparison module: Compare the first signal strength value with the second signal strength value, and compare the first delay time with the second delay time. If the first signal strength value is greater than the second signal strength value and the first delay time is less than the second delay time, then the probability that the material information of the corresponding moving object is metal is relatively high; The second comparison module: If the first signal strength value is less than the second signal strength value and the first delay time is greater than the second delay time, then the probability that the material information of the corresponding moving object is non-metal is relatively high; The third comparison module: If the first signal strength value is equal to the second signal strength value and the first delay time is equal to the second delay time, then the probabilities that the material information of the corresponding moving object is non-metal and metal are equal.
8. The proximity switch distance measurement system based on the combination of inductance and capacitance according to claim 7, characterized in that The distance weight module includes: The first distance weight value: When the probabilities that the material information of the moving object is non-metal and metal are equal, the measurement distance weight values corresponding to the inductive sensor and the capacitive sensor are both recorded as 0.5; The overall signal strength module: When the probability that the material information of the moving object is metal is relatively high or the probability that the material information of the moving object is metal is relatively high, calculate the sum of the first signal strength value and the second signal strength value as the overall signal strength value; The signal strength weight module: Divide the first signal strength value and the second signal strength value by the overall signal strength value respectively to obtain the corresponding signal strength weight values; The delay time weight module: Calculate the sum of the first delay time and the second delay time as the overall delay time; Divide the first delay time and the second delay time by the overall delay time respectively to obtain the corresponding delay time weight values; The second distance weight module: Take the average value of the corresponding signal strength weight value and the corresponding delay time weight value as the measurement distance weight values corresponding to the inductive sensor and the capacitive sensor.
9. The proximity switch distance measurement system based on the combination of inductance and capacitance according to claim 6, characterized in that, The adjustment module includes: The temperature and humidity calculation module: Take the time when the electromagnetic signal and the electric field signal are sent as the starting time, and record the time from the starting time to the current time as the time interval; Obtain the temperature and humidity of the environment where the moving object is located within the time interval, and calculate the average temperature and the average humidity; The first adjustment module: Compare the average temperature and the average humidity with the preset standard temperature and the preset standard humidity respectively. If the average temperature is greater than the preset standard temperature, then reduce the frequencies of the inductive sensor and the capacitive sensor; The second adjustment module: If the average humidity is greater than the preset standard humidity, then reduce the frequencies of the inductive sensor and the capacitive sensor, and then reduce the frequency of the capacitive sensor.
10. The proximity switch distance measurement system based on the combination of inductance and capacitance according to claim 6, characterized in that, The distance measurement module includes: The retransmission module: The inductive sensor and the capacitive sensor after adjusting the frequency send electromagnetic signals and electric field signals to the surroundings, and receive the reflected signals of the electromagnetic signals and the electric field signals; First calculation module: Calculate the distance value corresponding to the inductive sensor. The calculation formula is: In the formula, D1 is the distance value corresponding to the inductive sensor, c is the propagation speed of electromagnetic waves, which is 3×10 8 , and t1 is the round-trip time of the electromagnetic signal; The second calculation module calculates the distance value corresponding to the capacitance sensor, and the calculation formula is: In the formula, D2 is the distance value corresponding to the capacitance sensor, t2 is the round-trip time of the electric field signal, and v is the propagation speed of the electric field signal. The calculation formula is: In the formula, c is the propagation speed of electromagnetic waves, and ∈ r is the relative permittivity 1 of the medium; The third calculation module: Multiply the distance value corresponding to the inductive sensor by the corresponding distance weight value to obtain the first distance, multiply the distance value corresponding to the capacitive sensor by the corresponding distance weight value to obtain the second distance, add the first distance and the second distance, and divide the added result by the total sum of the measurement distance weight values corresponding to the inductive sensor and the capacitive sensor to obtain the final distance, completing the distance measurement.
Citation Information
Patent Citations
Capacitive proximity switch sensor
CN113155012A
Electronic device pin length measuring device and method
CN116182690A
Actual measurement distance detector for proximity sensor
CN116242243A
Parameter testing method, device and equipment of distance measuring sensor and storage medium
CN116400359A
Long-distance inductor type approach switch
CN201113962Y