Valuing method, device and equipment of air pressure sensor and storage medium
By dynamically adjusting the value frequency of the air pressure sensor, the problem of inaccurate value in the monitoring of air pressure change during the production process of airbag mattress is solved, and robustness and quality inspection efficiency are improved.
Patent Information
- Application Number
- CN202411921163.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-25
- Publication Date
- 2025-04-08
AI Technical Summary
In the prior art, the air pressure sensor value is inaccurate, resulting in the high misjudgment rate in real-time monitoring of air pressure changes in the airbag mattress during production.
By dynamically adjusting the value frequency according to the actual working voltage of the air pressure sensor, a more stable measurement voltage is collected, thereby improving the value accuracy of the air pressure sensor.
It improves the robustness of the value logic of the air pressure sensor, reduces the misjudgment rate of air leakage faults, effectively intercepts the air bag mattress for air leakage faults, and improves the efficiency of production line quality inspection.
Smart Images

Figure CN119779553A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of sensor technology, and in particular to a value acquisition method, device, equipment and storage medium of an air pressure sensor. Background Art
[0002] As people's demand for comfortable sleep increases, airbag mattresses, as a new type of sleeping equipment, are becoming more and more popular. However, due to the complex internal structure of airbag mattresses and the long-term use of airbag mattresses, which are easily affected by the external environment and human factors, various faults often occur, such as airbag leakage, abnormal inflation, and uneven pressure distribution. At present, the airtightness failure of airbag mattresses is analyzed by real-time reporting of the current air pressure values of each part to see if there is a fault in the airtightness of each part. Therefore, the accuracy and consistency of the air pressure sensor value are particularly important. Summary of the invention
[0003] The present invention provides a method, device, equipment and storage medium for obtaining a value of an air pressure sensor, so as to solve the problem of inaccurate value obtaining of the air pressure sensor in the prior art.
[0004] According to a first aspect of the present invention, a method for obtaining a value of an air pressure sensor is provided, comprising:
[0005] Obtain the actual working voltage and preset value frequency of the air pressure sensor;
[0006] Determine the actual value frequency according to the actual working voltage and the preset value frequency;
[0007] The measured voltage of the air pressure sensor is collected according to the actual value sampling frequency.
[0008] Optionally, determining the actual value frequency according to the actual working voltage and the preset value frequency includes:
[0009] Determine the voltage fluctuation frequency according to the actual working voltage;
[0010] The actual value frequency is determined according to the voltage fluctuation frequency and the preset value frequency; wherein the actual value frequency is greater than the voltage fluctuation frequency.
[0011] Optionally, determining the actual value frequency according to the voltage fluctuation frequency and the preset value frequency includes:
[0012] When the voltage fluctuation frequency is less than the preset value frequency, the actual value frequency is determined according to the preset value frequency;
[0013] When the voltage fluctuation frequency is greater than or equal to the preset value frequency, the actual value frequency is determined according to the voltage fluctuation frequency.
[0014] Optionally, after collecting the measured voltage of the air pressure sensor according to the actual value frequency, the following steps are further included:
[0015] Removing a measured voltage that does not meet a preset voltage range from each of the n measured voltages collected continuously;
[0016] A measured mean voltage is determined based on the remaining na measured voltages.
[0017] Optionally, removing a measured voltage that does not meet a preset voltage range from each of the n measured voltages collected continuously includes:
[0018] Sort each of the n consecutively collected measured voltages according to the voltage magnitude;
[0019] The lowest measured voltage of the first preset proportion A% and the highest measured voltage of the second preset proportion B% are removed from every n consecutively collected measured voltages; wherein a=A%*n+B%*n.
[0020] Optionally, determining a measured mean voltage according to the remaining na measured voltages includes:
[0021] Determine the average value of the remaining na measured voltages according to the remaining na measured voltages;
[0022] The measured mean voltage is determined from the mean value.
[0023] Optionally, after collecting the measured voltage of the air pressure sensor according to the actual value sampling frequency, the method further includes:
[0024] The air pressure detection value of the air pressure sensor is determined based on the measured voltage.
[0025] According to a second aspect of the present invention, a value obtaining device of an air pressure sensor is provided, which is used to execute a value obtaining method of an air pressure sensor. The value obtaining device of the air pressure sensor comprises:
[0026] A parameter acquisition module is used to obtain the actual working voltage and preset value frequency of the air pressure sensor;
[0027] A frequency determination module, used to determine an actual value frequency according to an actual operating voltage and a preset value frequency;
[0028] The air pressure acquisition module is used to collect the measured voltage of the air pressure sensor according to the actual value sampling frequency.
[0029] According to a third aspect of the present invention, there is provided a computer device, comprising a memory, a processor and a computer program stored in the memory and executable on the processor, wherein the method for obtaining a value of an air pressure sensor is implemented when the processor executes the program.
[0030] According to a fourth aspect of the present invention, there is provided a computer-readable storage medium having a computer program stored thereon, which implements a method for obtaining a value of an air pressure sensor when the program is executed by a processor.
[0031] The technical solution of the present invention dynamically adjusts the reading frequency of the pressure sensor according to the actual working voltage of the pressure sensor, and determines whether the airbag pressure is abnormal according to the value of the pressure sensor. This solves the problem of inaccurate pressure sensor values caused by the inconsistency of electronic components in the real-time monitoring of the pressure changes in the production process of the airbag mattress, improves the robustness of the pressure sensor value logic, reduces the misjudgment rate of air leakage faults, and enables the production end of the production line to effectively intercept airbag mattresses with air leakage faults, thereby improving the efficiency of production line quality inspection.
[0032] It should be understood that the contents described in this section are not intended to identify the key or important features of the embodiments of the present invention, nor are they intended to limit the scope of the present invention. Other features of the present invention will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS
[0033] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0034] Figure 1 is a flow chart of a first method for obtaining a value of an air pressure sensor according to an embodiment of the present invention;
[0035] Figure 2 It is a schematic diagram of the results of air pressure collection in the prior art;
[0036] Figure 3 is a schematic diagram of air pressure collection results provided by an embodiment of the present invention;
[0037] Figure 4 is a flow chart of a second method for obtaining a value of an air pressure sensor according to an embodiment of the present invention;
[0038] Figure 5 is a schematic diagram of a first voltage measurement collection result provided according to an embodiment of the present invention;
[0039] Figure 6 is a schematic diagram of a second voltage measurement collection result provided according to an embodiment of the present invention;
[0040] Figure 7 is a flow chart of a third method for obtaining a value of an air pressure sensor according to an embodiment of the present invention;
[0041] Figure 8 is a flow chart of a fourth method for obtaining a value of an air pressure sensor according to an embodiment of the present invention;
[0042] Fig. 9 is a flow chart of a fifth method for obtaining a value of an air pressure sensor according to an embodiment of the present invention;
[0043] Fig.10 is a flow chart of a sixth method for obtaining a value of an air pressure sensor according to an embodiment of the present invention;
[0044] Fig.11 is a flow chart of a seventh method for obtaining a value of an air pressure sensor according to an embodiment of the present invention;
[0045] Fig.12 is a connection diagram of a value obtaining device of an air pressure sensor provided according to an embodiment of the present invention;
[0046] Fig.13 The figure is a schematic diagram of the structure of an electronic device applied to a value obtaining method of an air pressure sensor according to an embodiment of the present invention. DETAILED DESCRIPTION
[0047] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.
[0048] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0049] Airbag mattresses in the prior art are often equipped with air pressure sensors to monitor in real time whether there are problems such as airbag leakage, abnormal inflation, and uneven pressure distribution. However, it was found in the actual test process that the air pressure sensor value is unstable due to the fluctuation of the actual working voltage of the air pressure sensor, which reduces the accuracy of the air pressure sensor in detecting air pressure and increases the misjudgment rate. Therefore, an embodiment of the present invention provides a method for obtaining the value of an air pressure sensor. Figure 1FIG. 1 is a flow chart of a method for obtaining a value of a first air pressure sensor according to an embodiment of the present invention. Figure 1 As shown, the value obtaining method includes:
[0050] S10, obtaining the actual working voltage and preset value frequency of the air pressure sensor.
[0051] The actual working voltage of the air pressure sensor may be the actual voltage that ensures the normal operation of the air pressure sensor. Ideally, the actual working voltage is a constant voltage value, but in actual operation, it often fluctuates due to test environment interference and other reasons. Therefore, obtaining the actual working voltage in real time can monitor the fluctuation of the working voltage.
[0052] The preset value-taking frequency may be the value-taking frequency of the air pressure sensor preset in the control unit.
[0053] It is understandable that when the actual working voltage fluctuates, the measuring voltage of the air pressure sensor will also fluctuate, which will cause the air pressure measured by the air pressure sensor to be inaccurate. The fluctuation can be determined by collecting the actual working voltage.
[0054] S11. Determine the actual value frequency according to the actual working voltage and the preset value frequency.
[0055] The actual sampling frequency is the frequency of obtaining the voltage measured by the pressure sensor. For example, the preset sampling frequency is The actual value frequency is 50Hz.
[0056] Among them, when the actual working voltage fluctuates, the accuracy of the measured voltage of the air pressure sensor will decrease if it continues to be collected at the preset sampling frequency. Therefore, at this time, the actual sampling frequency is determined according to the fluctuation of the actual working voltage and the preset sampling frequency, and the frequency of collecting the measured voltage of the air pressure sensor is increased, so that more voltage measurement data is obtained in the same time period, thereby improving the accuracy of airbag pressure abnormality detection.
[0057] S12. Collect the measured voltage of the air pressure sensor according to the actual value sampling frequency.
[0058] Among them, the control unit can collect the measurement voltage of the air pressure sensor according to the actual value sampling frequency, and then determine the air pressure value measured by the air pressure sensor.
[0059] Specifically, when the actual working voltage fluctuates, the measured voltage of the air pressure sensor will also fluctuate. The measured voltage adc of the air pressure sensor, the preset working voltage V0, the actual working voltage V1 and the control unit accuracy 2 x Satisfaction between Therefore, there is a positive correlation between the value of the air pressure sensor and the actual working voltage, and it will increase with the increase of the actual working voltage and decrease with the decrease of the actual working voltage.
[0060] Exemplarily, the air pressure detection process of the airbag in the mattress is as follows:
[0061] First, after the mattress comes off the production line, the finished product inspection instruction is sent through the mobile phone Bluetooth, so that the mattress can perform the corresponding automated inspection program to detect the current of each electronic component of the mattress, ensuring that the air pump, solenoid valve, air pressure sensor and other components in the mattress can be powered on and work normally, and data communication is normal. After the inspection is completed, the control unit controls the air pressure sensor to perform an air tightness test on the airbag. First, the air pump is controlled to inflate the airbag to 7.5kpa, and then the device communicates with the cloud through the wireless module, and the mattress device uploads the data of the built-in air pressure sensors corresponding to the shoulders, back, waist, buttocks, thighs, and calves to the cloud in real time. When the preset value frequency is used, the air pressure sensor data is sent to the cloud. When collecting, the specific air pressure data obtained is as follows Figure 2 shown. Figure 2 It is a schematic diagram of the results of air pressure collection in the prior art. Figure 2 The following table shows the air pressure and leakage ratio of the airbag corresponding to the waist. Figure 2 It can be seen from the figure that when the standard value of air leakage is 7kpa, the calculated air leakage ratio fluctuates greatly and has low accuracy. When the technical solution of the embodiment of the present invention is used to determine the actual value frequency according to the actual working voltage and the preset value frequency, the measured air pressure of the air pressure sensor is collected according to the actual value frequency of 50Hz, and the specific air pressure data obtained is as follows: Figure 3 shown. Figure 3 is a schematic diagram of a result of air pressure collection provided according to an embodiment of the present invention, Figure 3 The following table shows the air pressure and leakage ratio of the airbag corresponding to the waist. Figure 3 It can be seen that when the leakage standard value is 7kpa, the calculated leakage ratio is in a linear upward trend, which is consistent with the situation of natural leakage of the airbag. This further indicates that the accuracy of air pressure detection is improved, which facilitates accurate and timely analysis of airbag pressure failures in the mattress, thereby improving the reliability of the mattress and user experience.
[0062] The technical solution of the embodiment of the present invention dynamically adjusts the reading frequency of the pressure sensor according to the actual working voltage of the pressure sensor, and determines whether the airbag pressure is abnormal according to the value of the pressure sensor. This solves the problem of inaccurate pressure sensor values caused by the inconsistency of electronic components in the real-time monitoring of the pressure changes in the production process of the airbag mattress, improves the robustness of the pressure sensor value logic, reduces the misjudgment rate of air leakage faults, and enables the production end of the production line to effectively intercept airbag mattresses with air leakage faults, thereby improving the efficiency of production line quality inspection.
[0063] Based on the above embodiments, Figure 4 is a flow chart of a second method for obtaining a value of an air pressure sensor according to an embodiment of the present invention. Figure 4 As shown, the value obtaining method includes:
[0064] S20: Obtain the actual working voltage and preset value frequency of the air pressure sensor.
[0065] S21. Determine the voltage fluctuation frequency according to the actual working voltage.
[0066] The voltage fluctuation frequency may be the fluctuation frequency of the actual working voltage. The fluctuation period may be determined by determining the peak occurrence time of the actual working voltage, and the voltage fluctuation frequency may be determined according to the fluctuation period.
[0067] In some embodiments, the voltage fluctuation frequency can be determined by connecting the air pressure sensor with an oscilloscope to detect the waveform of the actual working voltage of the air pressure sensor.
[0068] S22, determining an actual value frequency according to the voltage fluctuation frequency and the preset value frequency, wherein the actual value frequency is greater than the voltage fluctuation frequency.
[0069] Among them, when the voltage fluctuation frequency is high, it means that the measured voltage fluctuation frequency of the pressure sensor is high. When the measured voltage collected at the preset value frequency is unstable, continuous collection of fluctuation peaks or valleys occurs, which will lead to inaccurate pressure detection. By determining the actual value frequency based on the voltage fluctuation frequency and the preset value frequency, since the actual value frequency is greater than the voltage fluctuation frequency, the pressure sensor takes more intensive values, thereby making the pressure determination more accurate.
[0070] S23. Collect the measured voltage of the air pressure sensor according to the actual value sampling frequency.
[0071] For example, Figure 5 is a schematic diagram of the first voltage measurement result provided according to an embodiment of the present invention. When collecting, the collection point is as follows Figure 5 As shown; Figure 6 : is a schematic diagram of the collection result of the second voltage measurement provided by an embodiment of the present invention. When the collection is performed at an actual value sampling frequency of 50 Hz, the collection points are as follows: Figure 6 shown.
[0072] The technical solution of the embodiment of the present invention determines the voltage fluctuation frequency according to the actual working voltage, determines the actual value frequency according to the voltage fluctuation frequency and the preset value frequency, dynamically adjusts the value frequency of the air pressure sensor, and determines whether the airbag pressure is abnormal according to the value of the air pressure sensor, thereby ensuring accurate and timely monitoring of the airbag pressure and improving the reliability of the mattress and user experience.
[0073] Based on the above embodiments, Figure 7FIG. 1 is a flow chart of a third method for obtaining a value of an air pressure sensor according to an embodiment of the present invention. Figure 7 As shown, the value obtaining method includes:
[0074] S30: Obtain the actual working voltage and preset value frequency of the air pressure sensor.
[0075] S31. Determine the voltage fluctuation frequency according to the actual working voltage.
[0076] S32. When the voltage fluctuation frequency is less than the preset value frequency, determine the actual value frequency according to the preset value frequency.
[0077] Among them, since the voltage fluctuation frequency is positively correlated with the measured voltage of the air pressure sensor, when the voltage fluctuation frequency is less than the preset value frequency, it means that the measured voltage fluctuation range of the air pressure sensor is small and relatively stable. Therefore, the preset value frequency can be directly determined as the actual value frequency to ensure the measurement accuracy of the air pressure sensor while improving the measurement efficiency of the air pressure sensor.
[0078] S33. When the voltage fluctuation frequency is greater than or equal to the preset value frequency, determine the actual value frequency according to the voltage fluctuation frequency.
[0079] Among them, when the voltage fluctuation frequency is greater than or equal to the preset value frequency, it means that the measured voltage fluctuation of the air pressure sensor is obvious. At this time, collecting the measured voltage according to the preset value frequency will cause the air pressure detection accuracy to decrease. Therefore, the actual value frequency is determined according to the voltage fluctuation frequency. For example, the voltage fluctuation frequency is 10Hz. In order to ensure multi-point value taking within one fluctuation cycle, the actual value taking frequency can be set to 50Hz, so that there are at least 5 value taking points within the voltage fluctuation cycle, which improves the accuracy of air pressure detection.
[0080] S34. Collect the measured voltage of the air pressure sensor according to the actual value sampling frequency.
[0081] For example, when the voltage fluctuation frequency Less than the preset frequency When , the actual value frequency is determined to be This can satisfy the multi-point value taking of the voltage fluctuation cycle; when the voltage fluctuation frequency 10Hz is greater than or equal to the preset value taking frequency In order to ensure the multi-point value taking of the voltage fluctuation period, the actual value taking frequency of 50Hz is selected which is greater than the voltage fluctuation frequency of 10Hz to achieve accurate air pressure detection.
[0082] The technical solution of the embodiment of the present invention ensures the accuracy of airbag pressure detection by determining the actual value frequency based on the comparison relationship between the voltage fluctuation frequency and the preset value frequency, while also improving the efficiency of air pressure detection, thereby enhancing the reliability of the mattress and user experience.
[0083] Based on the above embodiments, Figure 8 FIG. 4 is a flow chart of a fourth method for obtaining a value of an air pressure sensor according to an embodiment of the present invention. Figure 8 As shown, the value obtaining method includes:
[0084] S40: Obtain the actual working voltage and preset value frequency of the air pressure sensor.
[0085] S41. Determine an actual value-taking frequency according to an actual working voltage and a preset value-taking frequency.
[0086] S42. Collect the measured voltage of the air pressure sensor according to the actual value sampling frequency.
[0087] S43. Determine the air pressure detection value of the air pressure sensor according to the measured voltage.
[0088] Among them, the control unit can further determine the air pressure detection value according to the measured voltage of the air pressure sensor according to the corresponding relationship between voltage and air pressure, and then determine the air pressure change of the airbag according to the air pressure detection value, so as to subsequently calculate the leakage ratio.
[0089] For example, continue to refer to Figure 3 As shown, the air pressure detection value can be obtained according to the measured voltage of the air pressure sensor. Figure 3 The following table shows the air pressure and leakage ratio of the airbag corresponding to the waist. Figure 2 It can be seen that when the leakage standard value is 7kpa, the calculated leakage ratio is in a linear upward trend, which can be used to observe the airbag leakage situation.
[0090] The technical solution of the embodiment of the present invention ensures the normal operation of the airbag air pressure detection by determining the air pressure detection value of the air pressure sensor according to the measurement voltage of the air pressure sensor.
[0091] Based on the above embodiments, Fig. 9 is a flow chart of a fifth method for obtaining a value of an air pressure sensor according to an embodiment of the present invention. Fig. 9 As shown, the value obtaining method includes:
[0092] S50: Obtain the actual working voltage and preset value frequency of the air pressure sensor.
[0093] S51. Determine an actual value-taking frequency according to an actual working voltage and a preset value-taking frequency.
[0094] S52. Collect the measured voltage of the air pressure sensor according to the actual value sampling frequency.
[0095] S53: remove a measured voltage that does not meet a preset voltage range from each of the n measured voltages collected continuously.
[0096] Among them, since there is a positive correlation between the value of the air pressure sensor and the actual working voltage, it will increase with the increase of the actual working voltage and decrease with the decrease of the actual working voltage. Therefore, in order to ensure the stability and accuracy of the value of the air pressure sensor, after collecting the measured voltage of the air pressure sensor according to the actual value frequency, remove the a measured voltages that do not meet the preset voltage range in each consecutive collection of n measured voltages.
[0097] The preset voltage range may be a preset voltage within the ideal working voltage fluctuation range. Figure 6 and Fig. 9 As shown, the ideal working voltage is 3.3 V, and the preset voltage range can be 3.2-3.4 V. A measured voltage that does not meet the preset voltage range is removed from each of the n measured voltages collected continuously to ensure that the remaining measured voltages are within the preset voltage range, thereby improving the stability and accuracy of the measured voltage.
[0098] S54. Determine a measured mean voltage according to the remaining na measured voltages.
[0099] Among them, the measured voltage that meets the preset voltage range is averaged, so that a measured mean voltage is obtained for every na measured voltages, corresponding to the output air pressure detection value. Compared with the instantaneous value output when the timer reports, the measured mean voltage offsets the influence of voltage fluctuations, is more stable and accurate, and further improves the air pressure detection accuracy.
[0100] Exemplarily, it is set to collect 100 measurement voltages continuously, eliminate the measurement voltages that do not meet the preset voltage range of 3.2-3.4V, and determine the measurement mean voltage based on the remaining measurement voltages. Then, for every 100 measurement voltages collected, the corresponding air pressure detection value can be determined based on the measurement mean voltage, further improving the stability and accuracy of air pressure detection and reducing the misjudgment rate of air leakage faults.
[0101] Based on the above embodiments, Fig.10 is a flow chart of a sixth method for obtaining a value of an air pressure sensor according to an embodiment of the present invention. Fig.10 As shown, the value obtaining method includes:
[0102] S60: Obtain the actual working voltage and preset value frequency of the air pressure sensor.
[0103] S61. Determine an actual value-taking frequency according to an actual working voltage and a preset value-taking frequency.
[0104] S62. Collect the measured voltage of the air pressure sensor according to the actual value sampling frequency.
[0105] S63, sorting the n continuously collected measured voltages according to the voltage magnitudes.
[0106] Among them, due to the uncertainty of the actual working voltage fluctuation of the air pressure sensor, the number of measured voltages that meet the preset voltage range in every n measured voltages may not be consistent. In order to ensure the efficiency of air pressure detection, each continuously collected n measured voltages are sorted according to the voltage size so as to more efficiently eliminate data.
[0107] S64, remove the lowest measured voltage of the first preset proportion A% and the highest measured voltage of the second preset proportion B% from every n measured voltages collected continuously, where a=A%*n+B%*n.
[0108] Among them, the lowest measurement voltage of the first preset ratio A% may be the lowest measurement voltage that accounts for the first preset ratio A% among the n measurement voltages. For example, n=100, the first preset ratio is A%, then the lowest measurement voltage of the first preset ratio may be the lowest A measurement voltages among the 100 measurement voltages. The highest measurement voltage of the second preset ratio B% may be the highest measurement voltage that accounts for the second preset ratio B% among the n measurement voltages. For example, n=100, the second preset ratio is B%, then the highest measurement voltage of the second preset ratio may be the highest B measurement voltages among the 100 measurement voltages, then the number of measurement voltages that do not meet the preset voltage range a=A+B.
[0109] It is understandable that the first preset ratio and the second preset ratio can be determined according to a pre-experimental determination to be a suitable ratio that can satisfy the preset voltage range. After the first preset ratio and the second preset ratio are determined, the measured voltage after the first preset ratio and the second preset ratio are subtracted satisfies the preset voltage range by default, so as to improve the efficiency of air pressure detection.
[0110] S65. Determine a measured mean voltage according to the remaining na measured voltages.
[0111] The technical solution of the embodiment of the present invention is to obtain the first preset ratio and the second preset ratio in advance. After collecting n measurement voltages, the measurement voltage that meets the preset voltage range is obtained by removing the lowest measurement voltage of the first preset ratio and the highest measurement voltage of the second preset ratio in each consecutive collection of n measurement voltages. This method is applicable to the detection process of the air pressure sensor, which ensures accuracy while improving the efficiency of air pressure detection.
[0112] Based on the above embodiments, Fig.11 is a flow chart of a seventh method for obtaining a value of an air pressure sensor according to an embodiment of the present invention. Fig.11 As shown, the value obtaining method includes:
[0113] S70: Obtain the actual working voltage and preset value frequency of the air pressure sensor.
[0114] S71. Determine an actual value-taking frequency according to an actual working voltage and a preset value-taking frequency.
[0115] S72. Collect the measured voltage of the air pressure sensor according to the actual value sampling frequency.
[0116] S73, removing a measured voltage that does not meet a preset voltage range from each of the n measured voltages collected continuously.
[0117] S74. Determine an average value of the remaining na measured voltages according to the remaining na measured voltages.
[0118] S75. Determine a measured mean voltage according to the mean value.
[0119] The average of the remaining na measured voltages is calculated and output as the measured average voltage.
[0120] The technical solution of the embodiment of the present invention improves the robustness of the value-taking logic of the air pressure sensor and reduces the misjudgment rate of air leakage faults by determining the mean of the remaining na measured voltages based on the remaining na measured voltages that meet the preset voltage range, and determining the measured mean voltage based on the mean.
[0121] Based on the same inventive concept, Fig.12 is a connection diagram of a value acquisition device of an air pressure sensor provided according to an embodiment of the present invention, such as Fig.12 As shown, an embodiment of the present invention provides a value obtaining device of an air pressure sensor, which is used to execute a value obtaining method of an air pressure sensor. The value obtaining device of the air pressure sensor includes:
[0122] The parameter acquisition module 100 is used to obtain the actual working voltage and preset value frequency of the air pressure sensor.
[0123] The frequency determination module 200 is used to determine the actual value frequency according to the actual working voltage and the preset value frequency.
[0124] The air pressure acquisition module 300 is used to acquire the air pressure measured by the air pressure sensor according to the actual value sampling frequency.
[0125] Specifically, first, the actual working voltage and preset value frequency of the air pressure sensor are obtained through the parameter acquisition module 100. Then, the frequency determination module 200 is used to determine the actual value frequency according to the actual working voltage and the preset value frequency. Then, the air pressure acquisition module 300 is used to collect the measured air pressure of the air pressure sensor according to the actual value frequency, and the corresponding air pressure detection value is determined according to the measured air pressure.
[0126] The technical solution of the embodiment of the present invention determines whether the air bag air pressure is abnormal according to the parameter acquisition module, the frequency determination module and the air pressure acquisition module, thereby solving the problem of inaccurate pressure sensor values caused by the inconsistency of electronic components in the real-time monitoring of the air pressure changes in the air bag mattress during the production process, improving the robustness of the pressure sensor value logic, reducing the misjudgment rate of air leakage faults, so that the production end of the production line can effectively intercept air bag mattresses with air leakage faults, and improving the efficiency of production line quality inspection.
[0127] Based on the same inventive concept, an embodiment of the present invention further provides a computer device, Fig.13 FIG. 1 is a schematic diagram of the structure of an electronic device for a method for obtaining a value of an air pressure sensor according to an embodiment of the present invention. Fig.13 As shown, it includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, a method for obtaining a value of the air pressure sensor is implemented.
[0128] Among them, electronic devices are intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. Electronic devices can also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices (such as helmets, glasses, watches, etc.) and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present invention described and / or required herein.
[0129] like Fig.13 As shown, the electronic device 50 includes at least one processor 51, and a memory connected to the at least one processor 51 in communication, such as a read-only memory (ROM) 52, a random access memory (RAM) 53, etc., wherein the memory stores a computer program that can be executed by at least one processor, and the processor 51 can perform various appropriate actions and processes according to the computer program stored in the read-only memory (ROM) 52 or the computer program loaded from the storage unit 58 to the random access memory (RAM) 53. In the RAM 53, various programs and data required for the operation of the electronic device 50 can also be stored. The processor 51, the ROM 52, and the RAM 53 are connected to each other via a bus 54. An input / output (I / O) interface 55 is also connected to the bus 54.
[0130] A number of components in the electronic device 50 are connected to the I / O interface 55, including: an input unit 56, such as a keyboard, a mouse, etc.; an output unit 57, such as various types of displays, speakers, etc.; a storage unit 58, such as a disk, an optical disk, etc.; and a communication unit 59, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 59 allows the electronic device 50 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.
[0131] The processor 51 may be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the processor 51 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any appropriate processor, controller, microcontroller, etc. The processor 51 executes the various methods and processes described above, such as the value acquisition method applied to the air pressure sensor.
[0132] Based on the same inventive concept, an embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored, and when the program is executed by a processor, a method for obtaining a value of an air pressure sensor is implemented.
[0133] Of course, the computer-readable storage medium provided in the embodiment of the present invention, whose computer-executable instructions are not limited to the method operations described above, can also perform the related operations in the value obtaining method of the air pressure sensor provided in any embodiment of the present invention, and continue to refer to Fig.13 As shown, it is tangibly contained in a computer-readable storage medium, such as a storage unit 58. In some embodiments, part or all of the computer program can be loaded and / or installed on the electronic device 50 via the ROM 52 and / or the communication unit 59. When the computer program is loaded into the RAM 53 and executed by the processor 51, one or more steps of the value-taking method applied to the air pressure sensor described above can be executed. Alternatively, in other embodiments, the processor 51 can be configured to execute the value-taking method applied to the air pressure sensor in any other appropriate manner (for example, by means of firmware).
[0134] Various implementations of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various implementations can include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.
[0135] Computer programs for implementing the methods of the present invention may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, so that when the computer program is executed by the processor, the functions / operations specified in the flow chart and / or block diagram are implemented. The computer program may be executed entirely on the machine, partially on the machine, partially on the machine and partially on a remote machine as a stand-alone software package, or entirely on a remote machine or server.
[0136] In the context of an embodiment of the present invention, a computer-readable storage medium may be a tangible medium that may contain or store a computer program for use by or in conjunction with an instruction execution system, device, or equipment. A computer-readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or equipment, or any suitable combination of the foregoing. Alternatively, a computer-readable storage medium may be a machine-readable signal medium. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0137] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps described in the present invention can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solution of the present invention can be achieved, and this document does not limit this.
[0138] The above specific implementations do not constitute a limitation on the protection scope of the present invention. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions can be made according to design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.
Claims
1. A method for obtaining a value of an air pressure sensor, characterized in that: include: Obtain the actual working voltage and preset value frequency of the air pressure sensor; Determine the actual value frequency according to the actual working voltage and the preset value frequency; The measured voltage of the air pressure sensor is collected according to the actual value sampling frequency.
2. The method for obtaining a value according to claim 1, characterized in that: Determining the actual value frequency according to the actual working voltage and the preset value frequency includes: determining a voltage fluctuation frequency according to the actual operating voltage; An actual value frequency is determined according to the voltage fluctuation frequency and the preset value frequency; wherein the actual value frequency is greater than the voltage fluctuation frequency.
3. The method for obtaining a value according to claim 2, characterized in that: Determining an actual value frequency according to the voltage fluctuation frequency and the preset value frequency includes: When the voltage fluctuation frequency is less than the preset value frequency, determining the actual value frequency according to the preset value frequency; When the voltage fluctuation frequency is greater than or equal to the preset value frequency, the actual value frequency is determined according to the voltage fluctuation frequency.
4. The method for obtaining a value according to claim 1, characterized in that: After collecting the measured voltage of the air pressure sensor according to the actual value frequency, the method further includes: Removing a measured voltage that does not meet a preset voltage range from each of the n measured voltages collected continuously; A measured mean voltage is determined according to the remaining na measured voltages.
5. The method for obtaining a value according to claim 4, characterized in that: Removing a measured voltage that does not meet a preset voltage range from each of the n measured voltages collected continuously, comprising: Sorting each of the n continuously collected measured voltages according to the voltage magnitudes; The lowest measured voltage of the first preset proportion A% and the highest measured voltage of the second preset proportion B% are removed from every n consecutively collected measured voltages; wherein a=A%*n+B%*n.
6. The method for obtaining a value according to claim 4, characterized in that: Determining a measured mean voltage according to the remaining na measured voltages includes: Determine the average value of the remaining na measured voltages according to the remaining na measured voltages; A measured mean voltage is determined based on the mean value.
7. The method for obtaining a value according to claim 1, characterized in that: After collecting the measured voltage of the air pressure sensor according to the actual value frequency, the method further includes: An air pressure detection value of the air pressure sensor is determined according to the measured voltage.
8. A device for obtaining a value of an air pressure sensor, characterized in that: The method for obtaining a value of an air pressure sensor according to any one of claims 1 to 7 is used, wherein the air pressure sensor obtaining a value device comprises: A parameter acquisition module is used to obtain the actual working voltage and preset value frequency of the air pressure sensor; A frequency determination module, used to determine an actual value frequency according to the actual working voltage and the preset value frequency; The air pressure acquisition module is used to acquire the measured voltage of the air pressure sensor according to the actual value sampling frequency.
9. A computer device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the program, the value obtaining method as described in any one of claims 1-7 is implemented.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the value obtaining method as described in any one of claims 1 to 7 is implemented.