CN113298974A - Dust sensor output correction method, device, equipment and storage medium - Google Patents

Dust sensor output correction method, device, equipment and storage medium Download PDF

Info

Publication number
CN113298974A
CN113298974A CN202110525207.0A CN202110525207A CN113298974A CN 113298974 A CN113298974 A CN 113298974A CN 202110525207 A CN202110525207 A CN 202110525207A CN 113298974 A CN113298974 A CN 113298974A
Authority
CN
China
Prior art keywords
dust
value
compensation
accumulated
sensor
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202110525207.0A
Other languages
Chinese (zh)
Other versions
CN113298974B (en
Inventor
李春旭
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangdong Shangyan Electronic Technology Co ltd
Original Assignee
Guangdong Shangyan Electronic Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangdong Shangyan Electronic Technology Co ltd filed Critical Guangdong Shangyan Electronic Technology Co ltd
Priority to CN202110525207.0A priority Critical patent/CN113298974B/en
Publication of CN113298974A publication Critical patent/CN113298974A/en
Application granted granted Critical
Publication of CN113298974B publication Critical patent/CN113298974B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G07CHECKING-DEVICES
    • G07CTIME OR ATTENDANCE REGISTERS; REGISTERING OR INDICATING THE WORKING OF MACHINES; GENERATING RANDOM NUMBERS; VOTING OR LOTTERY APPARATUS; ARRANGEMENTS, SYSTEMS OR APPARATUS FOR CHECKING NOT PROVIDED FOR ELSEWHERE
    • G07C3/00Registering or indicating the condition or the working of machines or other apparatus, other than vehicles
    • G07C3/08Registering or indicating the production of the machine either with or without registering working or idle time
    • G07C3/10Registering or indicating the production of the machine either with or without registering working or idle time using counting means
    • FMECHANICAL ENGINEERING; LIGHTING; HEATING; WEAPONS; BLASTING
    • F24HEATING; RANGES; VENTILATING
    • F24FAIR-CONDITIONING; AIR-HUMIDIFICATION; VENTILATION; USE OF AIR CURRENTS FOR SCREENING
    • F24F11/00Control or safety arrangements
    • F24F11/89Arrangement or mounting of control or safety devices
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01NINVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES
    • G01N15/00Investigating characteristics of particles; Investigating permeability, pore-volume or surface-area of porous materials
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06MCOUNTING MECHANISMS; COUNTING OF OBJECTS NOT OTHERWISE PROVIDED FOR
    • G06M1/00Design features of general application
    • G06M1/08Design features of general application for actuating the drive
    • G06M1/10Design features of general application for actuating the drive by electric or magnetic means

Landscapes

  • Chemical & Material Sciences (AREA)
  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Analytical Chemistry (AREA)
  • Biochemistry (AREA)
  • General Health & Medical Sciences (AREA)
  • Health & Medical Sciences (AREA)
  • Immunology (AREA)
  • Pathology (AREA)
  • Dispersion Chemistry (AREA)
  • Combustion & Propulsion (AREA)
  • Mechanical Engineering (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Sampling And Sample Adjustment (AREA)

Abstract

The invention belongs to the technical field of air purification, and discloses a dust sensor output correction method, a device, equipment and a storage medium. The method comprises the steps of obtaining the operation duration, the accumulated dust value, the dust compensation value and the updated count value of the dust sensor; if the operation time length meets the preset compensation condition, acquiring an effective dust value of the dust sensor; when the effective dust value is larger than or equal to the dust compensation value, clearing the accumulated dust value and the updated count value; and when the accumulated dust value and the updated count value are cleared, determining the real dust output value of the dust sensor according to the effective dust value and the dust compensation value so as to realize the output correction of the dust sensor. The dust compensation value can be obtained by continuously correcting the dust sensor in the operation process, and the dust compensation value is adopted to correct the effective dust value when the output value of the dust sensor is determined, so that the influence caused by dust deposition can be avoided as much as possible, and the output of the dust sensor is more accurate.

Description

Dust sensor output correction method, device, equipment and storage medium
Technical Field
The invention relates to the technical field of air purification, in particular to a dust sensor output correction method, a dust sensor output correction device, dust sensor output correction equipment and a storage medium.
Background
Nowadays, air pollution is serious, the air purification field is also developed very rapidly, various air purification devices (such as air purifier) have appeared, and air purification devices generally rely on dust sensors to detect dust pollutants in the air, and at present, the general work flow of air purification devices on the market is as follows: the method comprises the steps of obtaining original dust data output by a dust sensor, carrying out smooth filtering and mutation tracking processing on the original dust data, and directly carrying out numerical value display through display equipment. However, in the actual use process, the dust sensor becomes longer along with the use time, the phenomenon of dust deposition and the like occurs, the output value of the dust sensor is larger, and accordingly, the detected dust pollutant data is inaccurate.
The above is only for the purpose of assisting understanding of the technical aspects of the present invention, and does not represent an admission that the above is prior art.
Disclosure of Invention
The invention mainly aims to provide a method, a device, equipment and a storage medium for correcting the output of a dust sensor, and aims to solve the technical problem of inaccurate output of the dust sensor caused by dust deposition.
To achieve the above object, the present invention provides a dust sensor output correction method, including the steps of:
acquiring the operation time length, the accumulated dust value, the dust compensation value and the updated count value of the dust sensor;
if the operation time length meets a preset compensation condition, acquiring an effective dust value of the dust sensor;
when the effective dust value is larger than or equal to the dust compensation value, clearing the accumulated dust value and the updated count value;
and when the accumulated dust value and the updated count value are cleared, determining a real dust output value of the dust sensor according to the effective dust value and the dust compensation value so as to realize output correction of the dust sensor.
Optionally, after the step of obtaining the effective dust value of the dust sensor if the operating time meets the preset compensation condition, the method further includes:
when the effective dust value is smaller than the dust compensation value, updating the accumulated dust value according to the effective dust value to obtain a current accumulated dust value, and adding one to the updated count value to obtain a current updated count value;
and if the current updating count value is less than or equal to a preset updating threshold value, returning to the step of acquiring the effective dust value of the dust sensor.
Optionally, after the step of updating the accumulated dust value according to the effective dust value to obtain the current accumulated dust value and adding one to the updated count value to obtain the current updated count value when the effective dust value is smaller than the dust compensation value, the method further includes:
if the current updating count value is larger than a preset updating threshold value, updating the dust compensation value according to the current updating count value and the current accumulated dust value;
and when the updating of the dust compensation value is finished, clearing the current updating count value and the current accumulated dust value, and returning to the step of acquiring the effective dust value of the dust sensor.
Optionally, after the step of determining the real dust output value of the dust sensor according to the effective dust value and the dust compensation value, the method further includes:
when the dust sensor meets a preset initialization condition, comparing the dust compensation value with a preset dust compensation threshold value;
when the dust compensation value is smaller than a preset dust compensation threshold value, acquiring a dust accumulated value of the dust sensor;
and if the real dust output value is greater than a preset cleaning standard value and the dust accumulated value is greater than a preset accumulated threshold value, initializing parameters and returning to the step of acquiring the effective dust value of the dust sensor.
Optionally, before the step of comparing the dust compensation value with a preset dust compensation threshold when the dust sensor meets a preset initialization condition, the method further includes:
acquiring a dust accumulated value, a clean air accumulated amount and a clean air count value of the dust sensor;
updating the accumulated clean air amount according to the real dust output amount, and adding one to the count value of the clean air to obtain the current count value of the clean air;
when the current clean air count value meets a preset accumulated updating condition, updating the dust accumulated value according to the clean air accumulated amount and the current clean air count value;
and when the updating of the dust accumulated value is finished, clearing the clean air accumulated amount and the current clean air count value, and executing the step of comparing the dust compensation value with a preset dust compensation threshold value when the dust sensor meets a preset initialization condition.
Optionally, before the step of comparing the dust compensation value with a preset dust compensation threshold when the dust sensor meets a preset initialization condition, the method further includes:
acquiring the current operation time length of the dust sensor, and determining whether the dust sensor meets a parameter adjustment condition according to the current operation time length;
when the dust sensor meets the parameter adjusting condition, judging that the dust sensor meets a preset initialization condition; or the like, or, alternatively,
and when the dust sensor does not meet the parameter adjustment condition and detects that the cleaning completion mark exists, judging that the dust sensor meets the preset initialization condition.
Optionally, after the step of comparing the dust compensation value with a preset dust compensation threshold when the dust sensor meets a preset initialization condition, the method further includes:
when the dust compensation value is larger than or equal to a preset dust compensation threshold value, judging that the dust sensor fails, and generating a sensor failure report according to the dust compensation value;
and saving and displaying the sensor failure report.
In addition, in order to achieve the above object, the present invention further provides a dust sensor output correction device, including the following modules:
the information acquisition module is used for acquiring the operation time length, the accumulated dust value, the dust compensation value and the updated count value of the dust sensor;
the data acquisition module is used for acquiring an effective dust value of the dust sensor if the operation time meets a preset compensation condition;
the data processing module is used for clearing the accumulated dust value and the updated count value when the effective dust value is larger than or equal to the dust compensation value;
and the output correction module is used for determining a real dust output value of the dust sensor according to the effective dust value and the dust compensation value when the accumulated dust value and the updated count value are cleared, so as to realize the output correction of the dust sensor.
Further, to achieve the above object, the present invention also proposes a dust sensor output correction apparatus comprising: a processor, a memory, and a dust sensor output correction program stored on and executable on the memory, the dust sensor output correction program when executed by the processor implementing the steps of the dust sensor output correction method as described above.
Further, in order to achieve the above object, the present invention also proposes a computer-readable storage medium having stored thereon a dust sensor output correction program which, when executed, realizes the steps of the dust sensor output correction method as described above.
The method comprises the steps of obtaining the operation duration, the accumulated dust value, the dust compensation value and the updated count value of the dust sensor; if the operation time length meets the preset compensation condition, acquiring an effective dust value of the dust sensor; when the effective dust value is larger than or equal to the dust compensation value, clearing the accumulated dust value and the updated count value; and when the accumulated dust value and the updated count value are cleared, determining the real dust output value of the dust sensor according to the effective dust value and the dust compensation value so as to realize the output correction of the dust sensor. The dust compensation value can be obtained by continuously correcting the dust sensor in the operation process, and the dust compensation value is adopted to correct the effective dust value when the output value of the dust sensor is determined, so that the influence caused by dust deposition can be avoided as much as possible, and the output of the dust sensor is more accurate.
Drawings
Fig. 1 is a schematic structural diagram of an electronic device in a hardware operating environment according to an embodiment of the present invention;
FIG. 2 is a schematic flow chart illustrating a first embodiment of a dust sensor output calibration method according to the present invention;
FIG. 3 is a schematic flow chart illustrating a second embodiment of a dust sensor output calibration method according to the present invention;
fig. 4 is a block diagram showing the structure of a first embodiment of the dust sensor output correction apparatus according to the present invention.
The implementation, functional features and advantages of the objects of the present invention will be further explained with reference to the accompanying drawings.
Detailed Description
It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
Referring to fig. 1, fig. 1 is a schematic structural diagram of a dust sensor output correction device in a hardware operating environment according to an embodiment of the present invention.
As shown in fig. 1, the electronic device may include: a processor 1001, such as a Central Processing Unit (CPU), a communication bus 1002, a user interface 1003, a network interface 1004, and a memory 1005. Wherein a communication bus 1002 is used to enable connective communication between these components. The user interface 1003 may include a Display screen (Display), an input unit such as a Keyboard (Keyboard), and the optional user interface 1003 may also include a standard wired interface, a wireless interface. The network interface 1004 may optionally include a standard wired interface, a WIreless interface (e.g., a WIreless-FIdelity (WI-FI) interface). The Memory 1005 may be a Random Access Memory (RAM) Memory, or may be a Non-Volatile Memory (NVM), such as a disk Memory. The memory 1005 may alternatively be a storage device separate from the processor 1001.
Those skilled in the art will appreciate that the configuration shown in fig. 1 does not constitute a limitation of the electronic device and may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components.
As shown in fig. 1, a memory 1005, which is a storage medium, may include therein an operating system, a network communication module, a user interface module, and a dust sensor output correction program.
In the electronic apparatus shown in fig. 1, the network interface 1004 is mainly used for data communication with a network server; the user interface 1003 is mainly used for data interaction with a user; the processor 1001 and the memory 1005 in the electronic apparatus of the present invention may be provided in the dust sensor output correction apparatus, which calls the dust sensor output correction program stored in the memory 1005 through the processor 1001 and executes the dust sensor output correction method provided by the embodiment of the present invention.
An embodiment of the present invention provides a method for correcting output of a dust sensor, and referring to fig. 2, fig. 2 is a schematic flow chart of a first embodiment of the method for correcting output of a dust sensor according to the present invention.
In this embodiment, the dust sensor output correction method includes the following steps:
step S10: and acquiring the operation time length, the accumulated dust value, the dust compensation value and the updated count value of the dust sensor.
It should be noted that, the execution main body of this embodiment may be the dust sensor output correction device, and the dust sensor output correction device may be a device such as a single chip microcomputer or a microcomputer, or may be another device that can achieve the same or similar functions.
It should be noted that the dust sensor may be installed in the air purification apparatus, the air purification apparatus may further be provided with a data storage and a counter, the data storage may be an Electrically Erasable Programmable Read Only Memory (EEPROM), the operation time, the accumulated dust value, the dust compensation value, and the update count value of the dust sensor may be obtained by reading the start time, the accumulated dust value, and the dust compensation value of the dust sensor recorded in the data storage, reading the update count value in the counter, and then calculating the operation time of the dust sensor according to the start time and the current time of the dust sensor.
In practical use, in order to reasonably utilize the usable times of each storage block in the data memory and prolong the service life of the data memory, a cyclic reading method can be adopted for reading data from the data memory, and a cyclic writing method can be adopted for writing data into the data memory.
The cyclic reading method comprises the steps of continuously detecting whether a reading task exists or not, when the reading task exists, determining a page address and a data address corresponding to data to be read according to the reading task, determining a current storage area according to the page address and the data address, trying to read the data in the current storage area, checking whether the read data are normal or not after reading, if the read data are not normal, trying to read again, and if the data cannot be normally read after multiple attempts, giving up reading the data in the current storage area, and restoring the page address and the data address to a state before reading; if the data is normal, the data in the backup storage area corresponding to the current storage area is tried to be read again, whether the data is normal or not can be verified after reading, if the data is normal, the currently read data is directly returned, if the data is not normal, re-reading is tried, if the data cannot be normally read after multiple attempts, the data reading is abandoned, and the page address and the data address are restored to the state before reading. The specific number of attempts of the multiple attempts may be set according to actual needs, for example: the setup was aborted after 5 repeat attempts.
The circular writing method can be that whether a writing task exists is continuously detected, when the writing task exists is detected, data to be written, a page address and a data address are determined according to the writing task, a current storage area is determined according to the page address and the data address, the data to be written are tried to be written in the current storage area, whether the writing is normal or not is verified after the writing, if the writing is not normal, the data is tried to be read again, if the data cannot be read normally after multiple times of trying, the writing of the data to be written in the current storage area is abandoned, and the page address and the data address are restored to a state before the writing; if the data is normal, trying to write data into the backup storage area corresponding to the current storage area, and checking whether the data writing is normal after the data writing, if the data writing is normal, ending the flow, if the data writing is not normal, trying to rewrite the data, if the data cannot be normally written after multiple attempts, giving up writing the data to be written, and restoring the page address and the data address to the state before writing. The data to be written, the page address and the data address are determined according to the writing task, so that the historical page address used when the data are written last time is searched for and is increased by one to obtain the page address, and the data address required by data storage is determined according to the data to be written and the data writing starting sequence number. The specific number of attempts of the multiple attempts may be set according to actual needs, for example: the setup was aborted after 5 repeat attempts.
It can be understood that, because the writing adopts a circular writing method, the writing is not performed on a certain storage block in the data memory, but the storage blocks in the data memory are circularly utilized, the maximum read-write times of the storage blocks in the data memory can be ensured to be utilized to the maximum extent, and the service life of the data memory is prolonged.
Step S20: and if the operation time length meets the preset compensation condition, acquiring the effective dust value of the dust sensor.
It should be noted that the measured value of the dust sensor is generally stable after the dust sensor is turned on for a certain time, and therefore, after the operation duration reaches the preset stable duration, it is determined that the operation duration meets the preset compensation condition, where the preset stable duration may be set by a developer according to different values of the dust sensor, for example: for the dust sensor of model a, it is determined according to an experiment that the measured value is stable after generally operating for 20 seconds, and then the preset stable time duration can be set to be 20 seconds. The obtaining of the effective dust value of the dust sensor may be obtaining a measurement value of the current dust sensor, and taking the obtained measurement value as the effective dust value.
In practical use, the step of obtaining the effective dust value of the dust sensor may be to obtain the effective dust value of the dust sensor every preset time period, and perform the following steps, for example: and after the operation time length meets the preset condition, taking 1 second as preset, taking 1 second as a preset time period, acquiring the effective dust value of the dust sensor once every 1 second, and executing the subsequent steps.
Step S30: and when the effective dust value is larger than or equal to the dust compensation value, clearing the accumulated dust value and the updated count value.
It can be understood that, if the effective dust value is greater than or equal to the dust compensation value, it can be said that there are many environmental dust pollutants and dust compensation is already needed, and therefore, the accumulated dust value and the updated count value for calculating the updated dust compensation can be cleared. The clearing of the accumulated dust value and the update count value may be setting the accumulated dust value recorded in the data memory to 0 and setting the update count value recorded in the counter to 0.
Step S40: and when the accumulated dust value and the updated count value are cleared, determining a real dust output value of the dust sensor according to the effective dust value and the dust compensation value so as to realize output correction of the dust sensor.
It can be understood that after the zero clearing is completed, the effective dust value may be corrected by using the dust compensation value to obtain a real dust output value, so as to correct the output value of the dust sensor, where determining the real dust output value of the dust sensor according to the effective dust value and the dust compensation value may be to subtract the dust compensation value from the effective dust value, and use the subtracted result as the real dust output value.
Further, in order to facilitate reasonable adjustment of the dust compensation value, after step S20, the method may further include:
when the effective dust value is smaller than the dust compensation value, updating the accumulated dust value according to the effective dust value to obtain a current accumulated dust value, and adding one to the updated count value to obtain a current updated count value; and if the current updating count value is less than or equal to a preset updating threshold value, returning to the step of acquiring the effective dust value of the dust sensor.
It should be noted that, if the effective dust value is smaller than the dust compensation value, it may be indicated that the content of dust pollutants in the environment may be low, the dust compensation value may be set to be high, and the dust compensation value may need to be adjusted. The preset update threshold may be set according to actual needs, for example: the preset update threshold is set to 30.
In practical use, the accumulated dust value is updated according to the effective dust value to obtain a current accumulated dust value, the updated count value is increased by one, the updated count value can be obtained by adding the accumulated dust value and the effective dust value, the sum obtained by adding is taken as the current accumulated dust value, the original accumulated dust value in the data memory is updated to the current accumulated dust value, the updated count value is increased by one to obtain the current updated count value, and the updated count value in the counter is updated to the current updated count value.
It can be understood that, if the current update count value is less than or equal to the preset update threshold value, it indicates that the duration of the effective dust value being less than the dust compensation value is still short, and it is not possible to determine whether the dust compensation value needs to be adjusted.
Further, in order to reasonably adjust the dust compensation value, in this example, after the step of updating the accumulated dust value according to the effective dust value when the effective dust value is smaller than the dust compensation value to obtain the current accumulated dust value, and adding one to the updated count value to obtain the current updated count value, the method may further include:
if the current updating count value is larger than a preset updating threshold value, updating the dust compensation value according to the current updating count value and the current accumulated dust value; and when the updating of the dust compensation value is finished, clearing the current updating count value and the current accumulated dust value, and returning to the step of acquiring the effective dust value of the dust sensor.
It can be understood that, if the current update count value is greater than the preset update threshold value, it may be determined that the effective dust value is continuously smaller than the dust compensation value within a period of time, and it may be determined that the dust compensation value is set to be possibly higher, and at this time, the dust compensation value may be updated according to the current accumulated dust value and the current update count value.
It can be understood that after the dust compensation value is updated according to the current accumulated dust value and the current updated count value, the current accumulated dust value and the current updated count value may be cleared, and the step of obtaining the effective dust value of the dust sensor is returned to continuously monitor whether the dust compensation value needs to be adjusted.
In practical use, the updating of the dust compensation value according to the current update count value and the current accumulated dust value may be to calculate a target dust compensation value through a preset compensation update formula, and then update the dust compensation value in the data storage to the target dust compensation value.
The preset compensation update formula may be:
TOFFSET=DUSTALL/Ta
wherein, TOFFSETIs a target dust compensation value; DUSTALLThe current accumulated dust value is obtained; t isaUpdating the count value for the current time; λ is a preset compensation coefficient, and is a positive integer, and can be set according to actual conditions, for example: λ ═ 5.
In the embodiment, the operation time length, the accumulated dust value, the dust compensation value and the updated count value of the dust sensor are obtained; if the operation time length meets the preset compensation condition, acquiring an effective dust value of the dust sensor; when the effective dust value is larger than or equal to the dust compensation value, clearing the accumulated dust value and the updated count value; and when the accumulated dust value and the updated count value are cleared, determining the real dust output value of the dust sensor according to the effective dust value and the dust compensation value so as to realize the output correction of the dust sensor. The dust compensation value can be obtained by continuously correcting the dust sensor in the operation process, and the dust compensation value is adopted to correct the effective dust value when the output value of the dust sensor is determined, so that the influence caused by dust deposition can be avoided as much as possible, and the output of the dust sensor is more accurate.
Referring to fig. 3, fig. 3 is a schematic flow chart of a dust sensor output calibration method according to a second embodiment of the present invention.
Based on the first embodiment described above, the dust sensor output correction method of the present embodiment further includes, after the step S40:
step S50: and when the dust sensor meets a preset initialization condition, comparing the dust compensation value with a preset dust compensation threshold value.
It should be noted that the preset initialization condition may be a preset condition for determining whether parameter initialization adjustment is required, the preset dust compensation threshold may be a maximum value of a preset dust compensation value, and if the dust compensation value exceeds the preset compensation threshold, it may be determined that the dust sensor has accumulated too much dust and cannot be used continuously.
Further, in order to reasonably determine whether parameter initialization needs to be performed on the dust sensor, before step S50 in this embodiment, the method may further include:
acquiring the current operation time length of the dust sensor, and determining whether the dust sensor meets a parameter adjustment condition according to the current operation time length; when the dust sensor meets the parameter adjusting condition, judging that the dust sensor meets a preset initialization condition; or when the dust sensor does not meet the parameter adjustment condition and detects that the cleaning completion mark exists, judging that the dust sensor meets the preset initialization condition.
It should be noted that the current operation duration may be the sum of the historical operation duration of the dust sensor and the operation duration of the current start, that is, the total usage duration of the dust sensor. In actual use, all starting moments and all closing moments of the dust sensor can be recorded, historical operating duration is obtained according to all the starting moments and the closing moments, and then the historical operating duration is added with the operating duration after the starting, so that the current operating duration is obtained. Determining whether the dust sensor meets the parameter adjustment condition according to the current operation time length may be that the dust sensor is judged to meet the parameter adjustment condition every time the current operation time length reaches a certain time length, such as: taking 30 minutes as an example, when the current operation time reaches 30 minutes, it is determined that the dust sensor meets the parameter adjustment condition, that is, when the current operation time reaches 30 × n (n is a positive integer) minutes, it is determined that the dust sensor meets the parameter adjustment condition.
It can be understood that if the dust sensor meets the parameter adjustment condition, it indicates that parameter initialization is required, and therefore, when the dust sensor meets the parameter adjustment condition, it can be determined that the dust sensor meets the preset initialization condition.
It should be noted that the cleaning completion flag may be a flag generated when the user cleans or replaces the dust sensor, and if the user cleans or replaces the dust sensor, parameter initialization is also required, so that when the dust sensor does not satisfy the parameter adjustment condition and detects that the cleaning completion flag exists, it may be determined that the dust sensor satisfies the preset initialization condition.
Further, in order to reasonably update the dust accumulated value and facilitate the parameter initialization of the dust sensor, before step S50, the method may further include:
acquiring a dust accumulated value, a clean air accumulated amount and a clean air count value of the dust sensor; updating the accumulated clean air amount according to the real dust output amount, and adding one to the count value of the clean air to obtain the current count value of the clean air; when the current clean air count value meets a preset accumulated updating condition, updating the dust accumulated value according to the clean air accumulated amount and the current clean air count value; and when the updating of the dust accumulated value is finished, clearing the clean air accumulated amount and the current clean air count value, and executing the step of comparing the dust compensation value with a preset dust compensation threshold value when the dust sensor meets a preset initialization condition.
The dust integrated value, the clean air integrated amount, and the clean air count value of the dust sensor may be obtained by reading the dust integrated value and the clean air integrated amount of the dust sensor in the data storage, and reading the clean air count value in the counter. The updating of the accumulated amount of clean air according to the actual dust output amount may be comparing the actual dust output amount with a preset clean standard value, subtracting the preset clean standard value from the actual dust output amount to obtain an output amount difference value when the actual dust output amount is greater than the preset clean standard value, adding the accumulated amount of clean air to the output amount difference value, taking the sum as the current accumulated amount of clean air, and updating the accumulated amount of clean air in the data storage to the current accumulated amount of clean air. The incrementing of the clean air count value to obtain the current clean air count value may be incrementing the clean air count value to obtain the current clean air count value, and updating the clean air count value in the counter to the current clean air count value. The preset cleaning standard value may be a constant preset by a developer, for example: the preset clean label value is set to 10.
It should be noted that, when the current clean air count value is greater than or equal to the preset cumulative update threshold, it may be determined that the current clean air count value satisfies the preset cumulative update condition, where the preset cumulative update threshold may be set according to actual needs, for example: the preset cumulative update threshold is set to 60. When the current clean air count value meets the preset cumulative update condition, updating the dust cumulative value according to the clean air cumulative amount and the current clean air count value may be to obtain an average clean air output amount by dividing the clean air cumulative amount by the current clean air count value, and when the average clean air output amount is greater than 0, adding the average clean air output amount and the dust cumulative value to obtain a current dust cumulative value, and updating the dust cumulative value in the data storage to the current dust cumulative value.
It is understood that, when the update of the dust accumulation value is completed, the accumulated clean air amount and the current clean air count value recorded in the data storage may be cleared, so that the accumulation may be continued subsequently, and the subsequent steps may be performed.
Further, in order to timely detect and prompt the user to replace the dust sensor when the dust sensor fails, after step S50, the method may further include:
when the dust compensation value is larger than or equal to a preset dust compensation threshold value, judging that the dust sensor fails, and generating a sensor failure report according to the dust compensation value; and saving and displaying the sensor failure report.
It can be understood that if the dust compensation value is greater than or equal to the preset dust compensation threshold value, it is described that the dust compensation amount of the dust sensor has reached the preset dust compensation amount maximum value, and therefore, it can be determined that the dust sensor has failed, a sensor failure report can be generated according to the dust compensation value, the sensor failure report is stored for tracing the reason, and the sensor failure report is displayed to prompt a user that the dust sensor has failed at present and needs to be cleaned or replaced.
Step S60: and when the dust compensation value is smaller than a preset dust compensation threshold value, acquiring a dust accumulated value of the dust sensor.
It can be understood that if the dust compensation value is smaller than the preset dust compensation threshold value, it indicates that the dust sensor does not fail, and therefore, the dust accumulated value of the dust sensor can be obtained.
In practical use, the acquiring of the dust accumulated value of the dust sensor may be reading the dust accumulated value of the dust sensor in a data storage.
Step S70: and if the real dust output value is greater than a preset cleaning standard value and the dust accumulated value is greater than a preset accumulated threshold value, initializing parameters and returning to the step of acquiring the effective dust value of the dust sensor.
It should be noted that the preset accumulation threshold may also be set in advance by a developer, and if the dust accumulation value is greater than the preset accumulation threshold, it indicates that the dust sensor has been operated for a long time in an environment with a high dust pollutant content, and parameter adjustment is required.
It can be understood that if the real dust output value is greater than the preset clean standard value, it indicates that the dust pollutant content in the current environment is higher, and the dust accumulated value is greater than the preset accumulated threshold value, it indicates that the dust sensor has been operated for a long time in an environment with a higher dust pollutant content, and therefore, the parameter initialization needs to be performed on the parameter to conform to the current environment.
In practical use, the parameter initialization may be performed by adding the dust compensation value recorded in the data storage to a preset clean standard value to obtain a target dust compensation value, updating the dust compensation value recorded in the data storage to the target dust compensation value, clearing the dust accumulation value and the clean air accumulation amount recorded in the data storage when the updating is completed, and clearing the clean air count value recorded in the counter.
In the embodiment, when the dust sensor meets a preset initialization condition, the dust compensation value is compared with a preset dust compensation threshold value; when the dust compensation value is smaller than a preset dust compensation threshold value, acquiring a dust accumulated value of the dust sensor; and if the real dust output value is greater than a preset cleaning standard value and the dust accumulated value is greater than a preset accumulated threshold value, performing parameter initialization on the dust sensor, and returning to the step of acquiring the effective dust value of the dust sensor. The parameters of the dust sensor are continuously analyzed in the operation process of the dust sensor, the parameters of the dust sensor are initialized according to the analysis result, and the corresponding dust compensation value is adjusted, so that the corrected output value of the dust sensor is more accurate.
Furthermore, an embodiment of the present invention also provides a storage medium having a dust sensor output correction program stored thereon, where the dust sensor output correction program is executed by a processor to implement the steps of the dust sensor output correction method as described above.
Referring to fig. 4, fig. 4 is a block diagram of a first embodiment of the dust sensor output correction apparatus according to the present invention.
As shown in fig. 4, the dust sensor output correction device according to the embodiment of the present invention includes:
the information acquisition module 401 is configured to acquire an operation duration, an accumulated dust value, a dust compensation value, and an updated count value of the dust sensor;
a data obtaining module 402, configured to obtain an effective dust value of the dust sensor if the operation duration meets a preset compensation condition;
a data processing module 403, configured to clear the accumulated dust value and the updated count value when the effective dust value is greater than or equal to the dust compensation value;
and an output correction module 404, configured to determine a real dust output value of the dust sensor according to the effective dust value and the dust compensation value when the accumulated dust value and the updated count value are cleared, so as to implement output correction on the dust sensor.
In the embodiment, the operation time length, the accumulated dust value, the dust compensation value and the updated count value of the dust sensor are obtained; if the operation time length meets the preset compensation condition, acquiring an effective dust value of the dust sensor; when the effective dust value is larger than or equal to the dust compensation value, clearing the accumulated dust value and the updated count value; and when the accumulated dust value and the updated count value are cleared, determining the real dust output value of the dust sensor according to the effective dust value and the dust compensation value so as to realize the output correction of the dust sensor. The dust compensation value can be obtained by continuously correcting the dust sensor in the operation process, and the dust compensation value is adopted to correct the effective dust value when the output value of the dust sensor is determined, so that the influence caused by dust deposition can be avoided as much as possible, and the output of the dust sensor is more accurate.
Further, the data processing module 403 is further configured to, when the effective dust value is smaller than the dust compensation value, update the accumulated dust value according to the effective dust value to obtain a current accumulated dust value, and add one to the update count value to obtain a current update count value; and if the current updating count value is less than or equal to a preset updating threshold value, returning to the step of acquiring the effective dust value of the dust sensor.
Further, the data processing module 403 is further configured to update the dust compensation value according to the current update count value and the current accumulated dust value if the current update count value is greater than a preset update threshold value; and when the updating of the dust compensation value is finished, clearing the current updating count value and the current accumulated dust value, and returning to the step of acquiring the effective dust value of the dust sensor.
Further, the output correction module 404 is further configured to compare the dust compensation value with a preset dust compensation threshold when the dust sensor meets a preset initialization condition; when the dust compensation value is smaller than a preset dust compensation threshold value, acquiring a dust accumulated value of the dust sensor; and if the real dust output value is greater than a preset cleaning standard value and the dust accumulated value is greater than a preset accumulated threshold value, initializing parameters and returning to the step of acquiring the effective dust value of the dust sensor.
Further, the output calibration module 404 is further configured to obtain a dust accumulated value, a clean air accumulated amount, and a clean air count value of the dust sensor; updating the accumulated clean air amount according to the real dust output amount, and adding one to the count value of the clean air to obtain the current count value of the clean air; when the current clean air count value meets a preset accumulated updating condition, updating the dust accumulated value according to the clean air accumulated amount and the current clean air count value; and when the updating of the dust accumulated value is finished, clearing the clean air accumulated amount and the current clean air count value, and executing the step of comparing the dust compensation value with a preset dust compensation threshold value when the dust sensor meets a preset initialization condition.
Further, the output correction module 404 is further configured to obtain a current operation duration of the dust sensor, and determine whether the dust sensor meets a parameter adjustment condition according to the current operation duration; when the dust sensor meets the parameter adjusting condition, judging that the dust sensor meets a preset initialization condition; or when the dust sensor does not meet the parameter adjustment condition and detects that the cleaning completion mark exists, judging that the dust sensor meets the preset initialization condition.
Further, the output correction module 404 is further configured to determine that the dust sensor has failed when the dust compensation value is greater than or equal to a preset dust compensation threshold value, and generate a sensor failure report according to the dust compensation value; and saving and displaying the sensor failure report.
It should be understood that the above is only an example, and the technical solution of the present invention is not limited in any way, and in a specific application, a person skilled in the art may set the technical solution as needed, and the present invention is not limited thereto.
It should be noted that the above-described work flows are only exemplary, and do not limit the scope of the present invention, and in practical applications, a person skilled in the art may select some or all of them to achieve the purpose of the solution of the embodiment according to actual needs, and the present invention is not limited herein.
In addition, the technical details that are not described in detail in this embodiment can be referred to the method for correcting the output of the dust sensor provided in any embodiment of the present invention, and are not described herein again.
Further, it is to be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or system that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or system. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or system that comprises the element.
The above-mentioned serial numbers of the embodiments of the present invention are merely for description and do not represent the merits of the embodiments.
Through the above description of the embodiments, those skilled in the art will clearly understand that the method of the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but in many cases, the former is a better implementation manner. Based on such understanding, the technical solution of the present invention or portions thereof that contribute to the prior art may be embodied in the form of a software product, where the computer software product is stored in a storage medium (e.g. Read Only Memory (ROM)/RAM, magnetic disk, optical disk), and includes several instructions for enabling a terminal device (e.g. a mobile phone, a computer, a server, or a network device) to execute the method according to the embodiments of the present invention.
The above description is only a preferred embodiment of the present invention, and not intended to limit the scope of the present invention, and all modifications of equivalent structures and equivalent processes, which are made by using the contents of the present specification and the accompanying drawings, or directly or indirectly applied to other related technical fields, are included in the scope of the present invention.

Claims (10)

1. A dust sensor output correction method is characterized by comprising the following steps:
acquiring the operation time length, the accumulated dust value, the dust compensation value and the updated count value of the dust sensor;
if the operation time length meets a preset compensation condition, acquiring an effective dust value of the dust sensor;
when the effective dust value is larger than or equal to the dust compensation value, clearing the accumulated dust value and the updated count value;
and when the accumulated dust value and the updated count value are cleared, determining a real dust output value of the dust sensor according to the effective dust value and the dust compensation value so as to realize output correction of the dust sensor.
2. The method of claim 1, wherein the step of obtaining the effective dust value of the dust sensor after the step of obtaining the effective dust value of the dust sensor if the operating time period satisfies a predetermined compensation condition further comprises:
when the effective dust value is smaller than the dust compensation value, updating the accumulated dust value according to the effective dust value to obtain a current accumulated dust value, and adding one to the updated count value to obtain a current updated count value;
and if the current updating count value is less than or equal to a preset updating threshold value, returning to the step of acquiring the effective dust value of the dust sensor.
3. The method of claim 2, wherein after the steps of updating the accumulated dust value according to the effective dust value to obtain a current accumulated dust value and incrementing the updated count value to obtain a current updated count value when the effective dust value is less than the dust compensation value, further comprising:
if the current updating count value is larger than a preset updating threshold value, updating the dust compensation value according to the current updating count value and the current accumulated dust value;
and when the updating of the dust compensation value is finished, clearing the current updating count value and the current accumulated dust value, and returning to the step of acquiring the effective dust value of the dust sensor.
4. The dust sensor output correction method of claim 1, wherein the step of determining the true dust output value of the dust sensor from the effective dust value and the dust compensation value is followed by further comprising:
when the dust sensor meets a preset initialization condition, comparing the dust compensation value with a preset dust compensation threshold value;
when the dust compensation value is smaller than a preset dust compensation threshold value, acquiring a dust accumulated value of the dust sensor;
and if the real dust output value is greater than a preset cleaning standard value and the dust accumulated value is greater than a preset accumulated threshold value, initializing parameters and returning to the step of acquiring the effective dust value of the dust sensor.
5. The dust sensor output correction method of claim 4, wherein the step of comparing the dust compensation value with a preset dust compensation threshold when the dust sensor satisfies a preset initialization condition further comprises:
acquiring a dust accumulated value, a clean air accumulated amount and a clean air count value of the dust sensor;
updating the accumulated clean air amount according to the real dust output amount, and adding one to the count value of the clean air to obtain the current count value of the clean air;
when the current clean air count value meets a preset accumulated updating condition, updating the dust accumulated value according to the clean air accumulated amount and the current clean air count value;
and when the updating of the dust accumulated value is finished, clearing the clean air accumulated amount and the current clean air count value, and executing the step of comparing the dust compensation value with a preset dust compensation threshold value when the dust sensor meets a preset initialization condition.
6. The dust sensor output correction method of claim 4, wherein the step of comparing the dust compensation value with a preset dust compensation threshold when the dust sensor satisfies a preset initialization condition further comprises:
acquiring the current operation time length of the dust sensor, and determining whether the dust sensor meets a parameter adjustment condition according to the current operation time length;
when the dust sensor meets the parameter adjusting condition, judging that the dust sensor meets a preset initialization condition; or the like, or, alternatively,
and when the dust sensor does not meet the parameter adjustment condition and detects that the cleaning completion mark exists, judging that the dust sensor meets the preset initialization condition.
7. The dust sensor output correction method of claim 4, wherein the step of comparing the dust compensation value with a preset dust compensation threshold when the dust sensor satisfies a preset initialization condition further comprises:
when the dust compensation value is larger than or equal to a preset dust compensation threshold value, judging that the dust sensor fails, and generating a sensor failure report according to the dust compensation value;
and saving and displaying the sensor failure report.
8. A dust sensor output correction device, characterized in that, the dust sensor output correction device includes the following modules:
the information acquisition module is used for acquiring the operation time length, the accumulated dust value, the dust compensation value and the updated count value of the dust sensor;
the data acquisition module is used for acquiring an effective dust value of the dust sensor if the operation time meets a preset compensation condition;
the data processing module is used for clearing the accumulated dust value and the updated count value when the effective dust value is larger than or equal to the dust compensation value;
and the output correction module is used for determining a real dust output value of the dust sensor according to the effective dust value and the dust compensation value when the accumulated dust value and the updated count value are cleared, so as to realize the output correction of the dust sensor.
9. A dust sensor output correction apparatus characterized by comprising: a processor, a memory, and a dust sensor output correction program stored on the memory and executable on the processor, the dust sensor output correction program when executed by the processor implementing the steps of the dust sensor output correction method of any of claims 1-7.
10. A computer-readable storage medium, having stored thereon a dust sensor output correction program that, when executed, performs the steps of the dust sensor output correction method of any one of claims 1-7.
CN202110525207.0A 2021-05-13 2021-05-13 Dust sensor output correction method, device, equipment and storage medium Active CN113298974B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110525207.0A CN113298974B (en) 2021-05-13 2021-05-13 Dust sensor output correction method, device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110525207.0A CN113298974B (en) 2021-05-13 2021-05-13 Dust sensor output correction method, device, equipment and storage medium

Publications (2)

Publication Number Publication Date
CN113298974A true CN113298974A (en) 2021-08-24
CN113298974B CN113298974B (en) 2023-05-16

Family

ID=77322077

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110525207.0A Active CN113298974B (en) 2021-05-13 2021-05-13 Dust sensor output correction method, device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN113298974B (en)

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH05309222A (en) * 1992-05-11 1993-11-22 Matsushita Seiko Co Ltd Air cleaner
JPH10170435A (en) * 1996-12-05 1998-06-26 Daikin Ind Ltd Method and device for dust detection
JP2000126531A (en) * 1998-10-23 2000-05-09 Matsushita Electric Ind Co Ltd Air cleaner
US20140015680A1 (en) * 2012-07-13 2014-01-16 Walter Kidde Portable Equipment, Inc. Photoelectric smoke detector with drift compensation
US20160042638A1 (en) * 2014-08-05 2016-02-11 Google Inc. Systems and methods for compensating for sensor drift in a hazard detection system
CN106765989A (en) * 2017-01-16 2017-05-31 广东美的制冷设备有限公司 The replacing control method of air purifier and its airstrainer
JP2019158162A (en) * 2018-03-07 2019-09-19 シャープ株式会社 Information processing device, air conditioner, information processing method and program
CN110400125A (en) * 2019-07-26 2019-11-01 珠海格力电器股份有限公司 Clarifier filter screen based reminding method, computer installation and computer readable storage medium
CN212236524U (en) * 2020-01-16 2020-12-29 刘珂杉 Dust treatment device for air purification

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH05309222A (en) * 1992-05-11 1993-11-22 Matsushita Seiko Co Ltd Air cleaner
JPH10170435A (en) * 1996-12-05 1998-06-26 Daikin Ind Ltd Method and device for dust detection
JP2000126531A (en) * 1998-10-23 2000-05-09 Matsushita Electric Ind Co Ltd Air cleaner
US20140015680A1 (en) * 2012-07-13 2014-01-16 Walter Kidde Portable Equipment, Inc. Photoelectric smoke detector with drift compensation
US20160042638A1 (en) * 2014-08-05 2016-02-11 Google Inc. Systems and methods for compensating for sensor drift in a hazard detection system
CN106765989A (en) * 2017-01-16 2017-05-31 广东美的制冷设备有限公司 The replacing control method of air purifier and its airstrainer
JP2019158162A (en) * 2018-03-07 2019-09-19 シャープ株式会社 Information processing device, air conditioner, information processing method and program
CN110400125A (en) * 2019-07-26 2019-11-01 珠海格力电器股份有限公司 Clarifier filter screen based reminding method, computer installation and computer readable storage medium
CN212236524U (en) * 2020-01-16 2020-12-29 刘珂杉 Dust treatment device for air purification

Also Published As

Publication number Publication date
CN113298974B (en) 2023-05-16

Similar Documents

Publication Publication Date Title
US8380946B2 (en) System, method, and computer program product for estimating when a reliable life of a memory device having finite endurance and/or retention, or portion thereof, will be expended
CN101529526B (en) Method for estimating and reporting the life expectancy of flash-disk memory
CN109556646B (en) Gas sensor calibration method and device, storage medium and terminal
CN107316156B (en) Data processing method, device, server and storage medium
US8214693B2 (en) Damaged software system detection
CN113833547A (en) Engine oil liquid level determination method and device
CN109669796B (en) Disk fault prediction method and device
CN111752481A (en) Memory monitoring and service life prediction method and system based on SPD
CN110568346A (en) Aging test method and system for smart card
CN113298974A (en) Dust sensor output correction method, device, equipment and storage medium
CN108196975B (en) Data verification method and device based on multiple checksums and storage medium
JP5504604B2 (en) RAM diagnostic device
CN111025223B (en) Clock correction method, device, equipment and storage medium of electric energy meter
CN106980402B (en) Method and device for judging reset calibration and terminal
CN111259338B (en) Component failure rate correction method and device, computer equipment and storage medium
CN114185882A (en) Bad data correction method and device, storage medium and electronic equipment
CN112946562B (en) Power failure protection method and device for double-core intelligent electric meter and double-core intelligent electric meter
WO2022183976A1 (en) Coulombmeter-based method and system for measuring remaining electric quantity of battery
CN109059989B (en) Method, system and equipment for evaluating remaining life of instrument
CN101341469A (en) Method for recognizing a power outage in a data memory and recovering the data memory
CN114356218A (en) Data error correction method, device and medium for Flash memory
CN113343479A (en) Method and device for calculating service life of equipment
CN111737034A (en) Method, device and equipment for calculating data retention time
JP2021135513A (en) Information processor, information processing method, and program
CN115932711B (en) Data processing method, device and medium for metering reliability of electric energy meter

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant