Device alarm method and device, electric appliance and alarm

By dynamically monitoring the environmental data of electrical equipment and identifying alarm status by combining time intervals and frequency of occurrence, the problem of false alarms caused by the vibration of electrical equipment near the threshold is solved, thus improving the accuracy and reliability of alarms.

CN119360572BActive Publication Date: 2026-01-23GREE ELECTRIC APPLIANCE INC OF ZHUHAI
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202411324140.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-09-23
Publication Date
2026-01-23
Estimated Expiration
2044-09-23

AI Technical Summary

Technical Problem

In the existing technology, the alarm devices of electrical equipment are prone to false alarms or frequent alarms due to vibration when environmental data is close to the threshold, and there is a lack of effective methods to identify the state to be alarmed.

Method used

By acquiring environmental data from electrical equipment, the data type is determined, and when abnormal data occurs, an alarm signal is generated by combining the time interval and number of occurrences of the previous N consecutive abnormal data to avoid immediate alarm; when normal data is restored, the number of occurrences is updated to the initial value to identify the alarm recovery status.

Benefits of technology

It improves the accuracy of device alarms, avoids false alarms or frequent alarms caused by environmental data fluctuating around the threshold, and enhances the ability to identify alarm states.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119360572B_ABST
    Figure CN119360572B_ABST
Patent Text Reader

Abstract

The application relates to an equipment alarm method and device, an electrical appliance and an alarm, and relates to the technical field of alarms. The method comprises the following steps: acquiring environment data of an electrical appliance collected at this time; determining the data type of the environment data, wherein the data type comprises abnormal data and normal data; in the case that the environment data is the abnormal data, generating an alarm signal to trigger an alarm according to the abnormal data, a first time interval between the abnormal data and the previous N times of continuously determined abnormal data, and a first occurrence number of the abnormal data. The method can avoid a jitter alarm caused by environment data near an alarm threshold.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of alarm technology, and in particular to a device alarm method and apparatus, electrical equipment and alarm. Background Technology

[0002] With the continuous development of electrical technology, electrical appliances have become an indispensable part of daily life. To ensure safe use, these appliances are usually equipped with alarm devices. For example, water heaters have built-in alarm devices that trigger alerts through temperature monitoring.

[0003] In existing technologies, alarm devices trigger an alarm when the collected environmental data exceeds a preset safety threshold. However, this method may lead to frequent false alarms or repeated alarms because the environmental data fluctuates around the threshold. Summary of the Invention

[0004] Therefore, it is necessary to provide a device alarm method and apparatus, electrical equipment and alarm to address the above-mentioned technical problems, which can prevent alarm fluctuations caused by environmental data approaching the alarm threshold.

[0005] In a first aspect, this application provides a device alarm method, the method comprising:

[0006] Acquire the environmental data of the electrical equipment collected in this session;

[0007] Determine the data type of the environmental data, which includes abnormal data and normal data;

[0008] If the environmental data is abnormal, an alarm signal is generated to trigger an alarm based on the first time interval between the abnormal data and the previous N consecutive abnormal data, and the first occurrence number of the abnormal data.

[0009] In one embodiment, the method further includes:

[0010] If the environmental data is normal data and the first occurrence count is greater than a preset first initial value, the first occurrence count is updated to the first initial value based on the second time interval between the normal data and the previous M consecutive normal data, and the second occurrence count of the normal data.

[0011] In one embodiment, generating an alarm signal to trigger an alarm based on the abnormal data and a first time interval between the abnormal data and the previous N consecutively determined abnormal data, and a first number of occurrences of the abnormal data, includes:

[0012] Determine whether the first time interval and the first number of occurrences meet the first preset condition. If they do, generate the alarm signal to trigger the alarm. If they do not meet the condition, acquire new environmental data and return to the step of determining the data type of the environmental data.

[0013] The first preset condition includes that the first time interval is less than or equal to a preset first time threshold, and the first occurrence number is greater than or equal to a preset first quantity threshold.

[0014] In one embodiment, the method further includes:

[0015] Entered a period of observation for repeating a grade;

[0016] Update the first occurrence count;

[0017] Determine the first time interval between the abnormal data and the previous N consecutive data points that were determined to be abnormal.

[0018] In one embodiment, updating the first occurrence count to the first initial value based on the normal data, the second time interval between the previous M consecutive data determined to be normal data, and the second occurrence count of the normal data includes:

[0019] Determine whether the second time interval and the second occurrence count meet the second preset condition. If they do, update the first occurrence count to the first initial value. If they do not meet the condition, acquire new environmental data and return to the step of determining the data type of the environmental data.

[0020] The second preset condition includes that the second time interval is less than or equal to a preset second time threshold, and the second occurrence number is greater than or equal to a preset second quantity threshold.

[0021] In one embodiment, the method further includes:

[0022] Enter alarm recovery mode;

[0023] Update the second occurrence count;

[0024] The second time interval between the normal data and the previous M consecutive data points determined as normal is determined.

[0025] In one embodiment, the method further includes:

[0026] The environmental data is stored in a preset cache area;

[0027] If the remaining cache space in the cache area is less than or equal to a preset storage threshold, a data storage request is sent.

[0028] If the number of failed transmissions corresponding to the data storage request exceeds a preset request threshold, at least a portion of the environmental data in the cache is stored in a preset memory area, and at least a portion of the environmental data in the cache is cleared.

[0029] In one embodiment, the method further includes:

[0030] The number of failed transmissions is updated to a preset second initial value, and the cache flag is updated to a preset first flag value;

[0031] If the number of failed transmissions is less than or equal to the request threshold and the data storage request is successfully sent, target environment data is sent according to the cache flag corresponding to the cache area; wherein, the target environment data includes at least a portion of the environment data in the cache area, or at least a portion of the environment data in the cache area and the memory area.

[0032] In one embodiment, sending the target environment data according to the cache flag bit corresponding to the cache area includes:

[0033] When the cache flag is the first flag value, send all environmental acquisition data of the memory area and the cache area, and update the cache flag to the second flag value;

[0034] When the cache flag is set to the second flag value, all environmental acquisition data in the cache area is sent.

[0035] Secondly, this application provides a device alarm apparatus, the apparatus comprising:

[0036] The acquisition module is used to acquire the environmental data of the electrical equipment collected in the current session;

[0037] A determination module is used to determine the data type of the environmental data, which includes abnormal data and normal data.

[0038] The generation module is configured to generate an alarm signal to trigger an alarm when the environmental data is the abnormal data, based on a first time interval between the abnormal data and the previous N consecutive abnormal data and a first occurrence number of the abnormal data.

[0039] Thirdly, this application provides an electrical device, the electrical device comprising:

[0040] Electrical appliance body;

[0041] An alarm, installed on the electrical appliance body, is used to acquire environmental data of the electrical appliance in a current determination, determine the data type of the environmental data, and, if the environmental data is abnormal data, generate an alarm signal to trigger an alarm based on a first time interval between the abnormal data and the previous N consecutive abnormal data determinations and a first occurrence number of the abnormal data; wherein, the data type includes abnormal data and normal data.

[0042] In one embodiment, the electrical device further includes a memory area, the alarm is connected to the host computer and the memory area respectively, the alarm includes a cache area, and the alarm is also used to store the environmental data acquired in the current time into the cache area, send a data storage request when the remaining cache space in the cache area is less than a preset storage threshold, and when the number of sending failures corresponding to the data storage request is greater than a preset request threshold, store at least a portion of the environmental data in the cache area into the memory area and clear at least a portion of the environmental data in the cache area.

[0043] Fourthly, this application provides an alarm device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps of the method described above.

[0044] Fifthly, this application provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the above-described method.

[0045] Sixthly, this application provides a computer program product, including a computer program that, when executed by a processor, implements the steps of the above-described method.

[0046] The aforementioned device alarm method, apparatus, electrical equipment, and alarm, by acquiring environmental data of the electrical equipment collected in the current session, determining the data type of the environmental data, and generating an alarm signal to trigger an alarm based on the first time interval between the abnormal data and the previous N consecutive abnormal data, and the first occurrence number of the abnormal data, when the environmental data is abnormal. This device alarm method achieves effective identification of the alarm-pending state of the electrical equipment through dynamic and progressive observation of environmental data. Specifically, when abnormal data is detected for the first time, the data type of subsequent environmental data is acquired and determined. In the process of triggering the alarm, not only the first occurrence number of abnormal data is considered, but also the time interval between each two adjacent abnormal data in multiple consecutive abnormal data. Compared with related technologies that immediately alarm when the alarm threshold is exceeded, the device alarm method provided in this application does not immediately alarm when the alarm threshold is exceeded. Instead, it identifies whether there is an alarm-pending situation from multiple dimensions such as the occurrence number and time interval, avoiding false alarms or frequent alarms caused by the fluctuation of environmental data near the alarm threshold, thus improving the accuracy of device alarms. Attached Figure Description

[0047] Figure 1 This is one of the flowcharts illustrating a device alarm method in one embodiment;

[0048] Figure 2 This is a second schematic flowchart of a device alarm method in one embodiment;

[0049] Figure 3 This is the third flowchart illustrating a device alarm method in one embodiment;

[0050] Figure 4 This is the fourth flowchart of a device alarm method in one embodiment;

[0051] Figure 5 This is the fifth flowchart illustrating a device alarm method in one embodiment;

[0052] Figure 6 This is a flowchart of a device alarm method in one embodiment, number six.

[0053] Figure 7 This is the seventh flowchart of a device alarm method in one embodiment;

[0054] Figure 8 This is the eighth flowchart of a device alarm method in one embodiment;

[0055] Figure 9 This is the ninth flowchart of a device alarm method in one embodiment;

[0056] Figure 10This is an application scenario diagram of the device alarm method in one embodiment;

[0057] Figure 11 This is a structural block diagram of the device alarm device in one embodiment;

[0058] Figure 12 This is a diagram of the internal structure of an alarm in one embodiment. Detailed Implementation

[0059] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0060] The device alarm method provided in this application can be applied to electrical equipment or to systems including terminals and / or servers. The electrical equipment can be devices with alarm requirements, such as water heaters, wall-hung boilers, and stoves. The terminal can be, but is not limited to, alarm devices, computers, and IoT devices. The server can be a standalone server or a server cluster consisting of multiple servers.

[0061] In one embodiment, such as Figure 1 As shown, a device alarm method is provided. This embodiment uses the method applied to an alarm device as an example for illustration. The method includes the following steps S102 to S106.

[0062] S102: Acquire the environmental data of the electrical equipment collected in this session.

[0063] Environmental data refers to the data collected for electrical equipment alarms. For example, if a water heater's alarm is a temperature alarm, the corresponding environmental data could include the water heater's temperature data; if a wall-hung boiler's alarm is a carbon monoxide (CO) leak alarm, the corresponding environmental data could include CO concentration data; and if a stove's alarm is a gas leak alarm, the corresponding environmental data could include gas concentration data. In application, environmental data can be set according to the alarm type of the electrical equipment; no specific limitations are imposed here.

[0064] In this application, environmental data from electrical appliances can be continuously collected. For example, environmental data from electrical appliances can be collected according to a preset cycle. The environmental data collected in a given cycle can be understood as the environmental data collected at that specific moment from the electrical appliance. For instance, if the environmental data includes temperature data, then the currently collected environmental data can be understood as the temperature data collected for the water heater at that particular moment.

[0065] S104: Determine the data type of the environmental data, which includes abnormal data and normal data.

[0066] For example, the alarm can determine the data type of environmental data based on environmental data and a preset alarm threshold. Specifically, if the environmental data exceeds the alarm threshold, the data type is determined to be abnormal; if the environmental data is less than or equal to the alarm threshold, the data type is determined to be normal. The alarm threshold is preset and can be set according to the actual application scenario; no further limitations are imposed here. For example, if the appliance is a water heater, the corresponding alarm threshold is a temperature threshold, which could be set to 90℃ or other temperature values. It should be noted that the above is merely an illustrative example and should not be construed as a specific limitation on the alarm threshold.

[0067] S106: When the environmental data is abnormal, an alarm signal is generated to trigger the alarm based on the first time interval between the abnormal data and the previous N consecutive abnormal data, and the first occurrence number of the abnormal data.

[0068] The "first N times" refers to the number of times the current identified abnormal data is used, where N is greater than or equal to 1. The "first time interval" can be understood as the time interval between any two adjacent abnormal data points. The "first occurrence count" refers to the number of times the current and the N+1 environmental data points collected in the previous N collections are consecutively identified as abnormal data. The "first occurrence count" is equal to N+1.

[0069] For example, taking a water heater as an electrical appliance, in an application, continuously collected environmental data is arranged in time as a temperature data sequence {A1, A2, A3, A4, A5, A6}. The currently collected temperature data is A6. If temperature data A1, A2, A3, and A4 are normal data, and the current temperature data A6 and the previously collected temperature data A5 are both abnormal data, then the first occurrence count is 2, N is 1, and the first time interval includes the first time interval T56 between temperature data A5 and temperature data A6. Based on this, an alarm signal can be generated to trigger an alarm according to the first occurrence count 2 and the first time interval T56.

[0070] The aforementioned device alarm method acquires environmental data of the electrical equipment collected in the current session, determines the data type, and generates an alarm signal to trigger an alarm based on the first time interval between the abnormal data and the previous N consecutive abnormal data, as well as the first occurrence count of the abnormal data, when the environmental data is abnormal. This device alarm method achieves effective identification of the alarm-pending state of the electrical equipment through dynamic and progressive observation of environmental data. Specifically, upon first detecting abnormal data, it continues to acquire and determine the data type of subsequent environmental data. Furthermore, during the alarm triggering process, it considers not only the first occurrence count of the abnormal data but also the time interval between each two adjacent abnormal data in multiple consecutive abnormal data. Compared to related technologies that immediately alarm when the alarm threshold is exceeded, the device alarm method provided in this application does not immediately alarm when the alarm threshold is exceeded. Instead, it identifies whether an alarm-pending situation exists from multiple dimensions, including the occurrence count and time interval, avoiding false alarms or frequent alarms caused by fluctuations in environmental data near the alarm threshold, thus improving the accuracy of device alarms.

[0071] In one embodiment, the device alarm method may further include step S108: when the environmental data is normal data and the first occurrence number is a preset first initial value, update the first occurrence number to the first initial value based on the normal data, the second time interval between the previous M consecutively determined normal data, and the second occurrence number of the normal data.

[0072] The first M occurrences are relative to the currently identified abnormal data, where M is greater than or equal to 1. The second time interval can be understood as the time interval between any two adjacent normal data points. The second occurrence count refers to the number of times that the current and the M+1 environmental data points collected in the previous M collections are consecutively identified as normal data. The first occurrence count is equal to M+1. The first initial value is preset and can be understood as the default value for the first occurrence count; for example, the first initial value can be 0.

[0073] For example, taking a water heater as an electrical appliance, in an application, environmental data is continuously collected and arranged by time into a temperature data sequence {A1, A2, A3, A4, A5, A6}. The initial value is 0, and the currently collected temperature data is A6. If temperature data A1, A2, and A3 are normal data, temperature data A4 is abnormal data, and the current temperature data A6 and the previously collected temperature data A5 are both normal data, then in the current case, the first occurrence count is 1 > 0, N = 0, the second occurrence count is 2, M = 1, and the second time interval includes the second time interval T56 between temperature data A5 and temperature data A6. Based on this, the first occurrence count can be updated to 0 according to the second occurrence count 2 and the second time interval T56.

[0074] The aforementioned device alarm method, when the environmental data is normal and the first occurrence count is greater than a preset first initial value, updates the first occurrence count to the first initial value based on the normal data, the second time interval between the previous M consecutive normal data occurrences, and the second occurrence count of the normal data. The first occurrence count being greater than the first initial value indicates that at least one abnormal data has been detected and the alarm triggering condition is not met. In this case, the currently collected environmental data is normal, indicating that the electrical equipment may have returned to normal operation, meaning the environmental data of the electrical equipment fluctuates around the alarm threshold. Therefore, this application, upon first detecting normal data, continues to acquire and determine the data type of subsequent environmental data, and combines the second occurrence count of normal data with the second time interval between each adjacent pair of normal data to identify whether the electrical equipment has returned to normal operation. Furthermore, if it is determined that the electrical equipment has returned to normal operation, the first occurrence count is updated to the first initial value to record the occurrence count of subsequent abnormal data. Based on this, the device alarm method provided in this application can also identify alarm recovery scenarios from multiple dimensions such as the second occurrence number and the second time interval of normal data, avoiding false alarms caused by environmental data accidentally exceeding the alarm threshold and then returning to normal data, thereby further improving the accuracy of device alarms.

[0075] In one embodiment, such as Figure 2 As shown, step S106, generating an alarm signal to trigger an alarm based on the abnormal data and the first time interval between the abnormal data and the previous N consecutive abnormal data, and the first occurrence number of the abnormal data, may include the following steps S202 to S206.

[0076] Step S202: Determine whether the first time interval and the first occurrence number meet the first preset condition. If they meet, proceed to step S204; if they do not meet, proceed to step S206.

[0077] The first preset condition includes a first time interval less than or equal to a preset first time threshold, and a first number of occurrences greater than or equal to a preset first quantity threshold. The first time threshold is preset and can be set based on experiments, experience, or actual application scenarios, such as the type of electrical equipment or the data collection cycle of the environment; it is not limited here. The first quantity threshold is preset, and its size affects the sensitivity of the device alarm. Specifically, a smaller first quantity threshold indicates fewer consecutively identified abnormal data points, making the first preset condition relatively lenient; a larger first quantity threshold indicates more consecutively identified abnormal data points, making the first preset condition relatively stringent. In application, it can be set according to actual alarm requirements; it is not limited here.

[0078] S204: Generate an alarm signal to trigger an alarm.

[0079] S206: Acquire new environmental data and return to the step of determining the data type of the environmental data. That is, after acquiring new environmental data, return to the previous step S104.

[0080] The aforementioned device alarm method identifies the alarm scenario by comparing a first occurrence count with a first quantity threshold and a first time interval with a first time threshold. Specifically, if the first time interval is less than or equal to the first time threshold and the first occurrence count is greater than or equal to the preset first quantity threshold, it indicates that abnormal data has been detected multiple times consecutively. In this case, it can be determined that the electrical device is in a state awaiting alarm, and an alarm signal is generated to trigger the alarm. Otherwise, it can be determined that the electrical device has not yet entered the state awaiting alarm, or that the electrical device is in a state close to alarm. In this case, the status of the electrical device can continue to be collected and monitored. This avoids false alarms or frequent alarms caused by environmental data fluctuating around the alarm threshold, thus improving the accuracy of device alarms.

[0081] In one embodiment, such as Figure 3 As shown, before step S202, the device alarm method further includes the following steps S302 to S306.

[0082] S302: Entering observation mode. Observation mode is a pre-set operating state. Being in observation mode indicates that abnormal data has been detected, but an alarm will not be triggered immediately; instead, environmental data from the electrical equipment will continue to be collected and monitored.

[0083] S304: Update the first occurrence count. For example, increment the first occurrence count by one and record the incremented first occurrence count.

[0084] S306: The first time interval between identifying abnormal data and the previous N consecutive data identified as abnormal.

[0085] The above-mentioned device alarm method does not immediately alarm when the currently collected environmental data is determined to be abnormal. Instead, it enters a level-keeping observation state. By updating the first occurrence count and determining the first time interval between the abnormal data and the previous N consecutive abnormal data, the alarm can be triggered based on the first occurrence count of the abnormal data and the corresponding first time interval. This avoids false alarms or frequent alarms caused by the environmental data fluctuating near the alarm threshold, thus improving the accuracy of device alarms.

[0086] In one embodiment, such as Figure 4As shown, step S108, which updates the first occurrence count to the first initial value based on the normal data and the second time interval determined as normal data in the previous M consecutive data, and the second occurrence count of normal data, may include the following steps S402 to S406.

[0087] S402: Determine whether the second time interval and the second occurrence number meet the second preset conditions. If they do, proceed to step S404; if they do not, proceed to step S406.

[0088] The second preset condition includes a second time interval less than or equal to a preset second time threshold, and a second occurrence count greater than or equal to a preset second quantity threshold. The second time threshold is preset and can be set based on experiments, experience, or actual application scenarios, such as the type of electrical equipment or the data collection cycle of the environment; it is not limited here. The second quantity threshold is preset, and its size affects the accuracy of the device alarm. Specifically, a smaller second quantity threshold indicates fewer consecutive data points that need to be identified as normal, making the second preset condition relatively lenient; a larger second quantity threshold indicates more consecutive data points that need to be identified as normal, making the second preset condition relatively stringent. In application, it can be set according to actual alarm requirements; it is not limited here.

[0089] S404: Update the first occurrence count to the first initial value.

[0090] S406: Acquire new environmental data and return to the step of determining the data type of the environmental data. That is, after acquiring new environmental data, return to the previous step S104.

[0091] The aforementioned device alarm method identifies alarm recovery scenarios by comparing a second occurrence count with a second quantity threshold and a second time interval with a second time threshold. Specifically, if the second time interval is less than or equal to the second time threshold and the second occurrence count is greater than or equal to the preset second quantity threshold, it indicates that normal data has been detected multiple times consecutively. In this case, it can be determined that the electrical device is in an alarm recovery state, or that the electrical device has recovered from a pending alarm state to a normal working state. Therefore, the first occurrence count can be updated to a first initial value to record subsequent abnormal data. Otherwise, it can be determined that the electrical device has not yet recovered to a normal working state. In this case, the status of the electrical device can continue to be collected and monitored to trigger an alarm or restore the alarm. This avoids false alarms or frequent alarms caused by environmental data fluctuating around the alarm threshold, thus improving the accuracy of device alarms.

[0092] In one embodiment, such as Figure 5As shown, before step S402, the device alarm method further includes the following steps S502 to S506.

[0093] S502: Entering alarm recovery state. Alarm recovery state is a pre-set operating state. Being in alarm recovery state indicates that normal data was detected after abnormal data was detected. In this state, environmental data of the electrical equipment continues to be collected and monitored to determine whether the electrical equipment has returned to normal operating condition.

[0094] S504: Update the second occurrence count. For example, increment the second occurrence count by one and record the incremented second occurrence count.

[0095] S506: Determine the second time interval between the normal data and the previous M consecutive data determined to be normal.

[0096] The aforementioned device alarm method, when the currently collected environmental data is determined to be normal and at least one abnormal data has been detected, enters an alarm recovery state. By updating the second occurrence count and the second time interval between the determination of normal data and the previous M consecutive normal data, the first occurrence count is updated to the first initial value based on the second occurrence count of normal data and the corresponding second time interval. This means that the electrical equipment is determined to have returned to normal working state, and subsequent environmental data is monitored again. This avoids false alarms caused by environmental data accidentally exceeding the alarm threshold and then returning to normal, thus improving the accuracy of device alarms.

[0097] In one embodiment, such as Figure 6 As shown, the device alarm method also includes the following steps S602 to S606.

[0098] S602: Store environment data in a preset cache.

[0099] A buffer is a pre-installed cache area on a device, used to cache environmental data. In applications, alarms can store the acquired environmental data separately in the buffer.

[0100] S604: Send a data storage request if the remaining cache space in the cache area is less than or equal to a preset storage threshold.

[0101] The storage threshold is preset and can be set based on the storage space size of the buffer, the size of the storage area occupied by environmental data, and other factors. For example, the storage threshold is zero. If the remaining buffer space is less than or equal to the storage threshold, it indicates that the remaining buffer space cannot meet the subsequent environmental data storage requirements. The data storage request is used to request the storage of environmental data within the buffer. In the application, the alarm can connect to a host computer via a network. When connected to the network, the data storage request can be sent to the host computer. The network can include wireless networks (WiFi), Ethernet, or other types of networks, and is not limited here.

[0102] S606: If the number of failed transmissions corresponding to a data storage request exceeds a preset request threshold, at least a portion of the environment data in the cache is stored in a preset memory area, and at least a portion of the environment data in the cache is cleared.

[0103] The number of failed transmissions refers to the number of times the alarm failed to successfully send a data storage request to the host computer. The request threshold is preset and can be set based on experience or actual application needs; it is not specified here. For example, the request threshold is zero. If the number of failed transmissions for a data storage request exceeds the preset request threshold, it indicates that the alarm and the host computer are disconnected from the network, and the alarm cannot send environmental data to the host computer for storage. The memory area is preset and can be used to store environmental data. For example, the alarm is equipped with a memory module, and the memory type is flash memory (FLASH). The environmental data stored in the preset memory area can be part of the environmental data in the buffer area, or it can be all the environmental data in the buffer area; the specific setting can be determined according to actual conditions and is not limited here. After clearing at least part of the environmental data in the buffer area, the remaining storage space of the buffer area is expanded to store subsequently collected environmental data.

[0104] The aforementioned device alarm method stores environmental data in a preset cache. When the remaining cache space in the cache is less than or equal to a preset storage threshold, a data storage request is sent. Furthermore, if the number of failed transmissions corresponding to the data storage request exceeds a preset request threshold, at least a portion of the environmental data in the cache is stored in a preset memory area, and at least a portion of the environmental data in the cache is cleared. Thus, when the remaining storage space in the cache cannot meet the storage needs of subsequent environmental data, by comparing the number of failed transmissions with the preset request threshold, a network outage is identified with the host computer. In this case, the system uses a preset memory area, copies at least a portion of the environmental data in the cache to the memory area for storage, and clears the environmental data in the cache. This ensures that subsequently collected environmental data is stored in the cache, preventing data loss due to ineffective data caching during network outages.

[0105] In one embodiment, please continue reading Figure 6 The device alarm method also includes the following steps S608 and S610.

[0106] S608: Update the number of failed transmissions to a preset second initial value, and update the buffer flag to a preset first flag value.

[0107] The second initial value is preset and can be understood as the initial value of the number of failed transmissions corresponding to the data storage request. For example, the second initial value is zero. The first flag value is preset and is used to indicate that the memory area stores environmental data. The first flag value can be any suitable value, without further limitations. For example, the first flag value is 1.

[0108] In the application, the alarm stores at least a portion of the environmental data in the buffer into a preset memory area. After clearing at least a portion of the environmental data in the buffer, it can update the number of failed transmissions to 0 and update the buffer flag to 1.

[0109] S610: If the number of failed transmissions is less than or equal to the request threshold and the data storage request is successfully sent, send the target environment data according to the cache flag bit corresponding to the cache area.

[0110] In cases where the number of failed transmissions is less than or equal to the request threshold and the data storage request is successfully sent, it indicates that the alarm and the host computer are connected. In this situation, target environment data can be sent based on the cache flag corresponding to the cache area. The target environment data includes at least a portion of the environment data in the cache area, or at least a portion of the environment data in both the cache area and memory area. Different values ​​of the cache flag correspond to different target environment data. See the related descriptions below for details.

[0111] The aforementioned device alarm method updates the number of failed transmissions to a preset second initial value and updates the cache flag to a preset first flag value. This allows the updated number of failed transmissions to identify the network status between the alarm and the host computer even when the remaining storage space in the cache is less than or equal to a preset storage threshold. This avoids data loss due to insufficient cache and network disconnection, improving the reliability of the device alarm method. Furthermore, by updating the cache flag to the first flag value, it indicates that environmental data is stored in the memory area. This allows the environmental data in the memory area to be sent to the host computer based on the first flag value when the device is connected to the network. In addition, when the number of failed transmissions is less than or equal to the request threshold and the data storage request is successfully sent, the device alarm method also sends the target environmental data based on the cache flag corresponding to the cache area. That is, when connected to the network, the environmental data stored in the cache and / or memory area can be sent to the host computer for storage via the network, achieving effective storage of environmental data and further improving the reliability of the device alarm method.

[0112] In one embodiment, such as Figure 7 As shown, step S610 above, which sends target environment data according to the cache flag bit corresponding to the cache area, may include the following steps S702 and S704.

[0113] S702: When the cache flag is set to the first flag value, send all environmental acquisition data from the memory area and the cache area, and update the cache flag to the second flag value.

[0114] S704: When the buffer flag is set to the second flag value, send all environmental acquisition data in the buffer.

[0115] The first and second flag values ​​differ. When the cache flag is at the first value, it indicates that the memory area stores environmental data. In this case, all environmental data collected in the memory area and the cache area can be integrated and sent to the host computer, and all environmental data in the cache area can be cleared to store subsequently collected environmental data. When the cache flag is at the second value, it indicates that the memory area does not store environmental data. In this case, all environmental data in the memory area can be sent to the host computer, and all environmental data in the cache area can be cleared to store subsequently collected environmental data. In applications where the remaining storage space in the memory area is zero, and all environmental data in the memory area has been sent to the host computer, all environmental data in the memory area can be cleared; or, after sending the environmental data in the memory area to the host computer, the corresponding environmental data in the memory area can be cleared to provide more storage space for new environmental data.

[0116] The above-mentioned device alarm method, when the cache flag is at the first flag value, sends all environmental data collected in the memory area and the cache area, and updates the cache flag to the second flag value. When the cache flag is at the second flag value, it sends all environmental data collected in the cache area. This method identifies whether the memory area stores environmental data through the cache flag. In this way, when connected to the network, it can send all environmental data in the cache area to the host computer, or send all environmental data in the cache area and the memory area to the host computer. The host computer can effectively store the environmental data to provide sufficient storage space for subsequent environmental data collection.

[0117] In one embodiment, such as Figures 8 to 10 As shown, a device alarm method is provided, with the application of this device alarm method to an alarm device as an example for illustration. Exemplarily, the alarm device includes a data acquisition module, a data processing module, an alarm response module, and a data reporting module. Exemplarily, the data acquisition module may include a sensor; the data processing module may include a processor; and the alarm response module may include at least one of a buzzer and an indicator light.

[0118] The data acquisition module primarily collects environmental data, which is then sent to the data processing module for processing. The data processing module includes a data buffer, external flash memory, and a data comparison unit. After receiving environmental data from the data acquisition module, the data processing module stores it in the data buffer. The data comparison unit compares the data in the buffer with a preset alarm threshold. If the environmental data does not exceed the preset alarm threshold, it remains buffered. Otherwise, the data comparison unit sends the abnormal data to the alarm response module.

[0119] At this point, the alarm response module enters a monitoring state, timing the time of the acquired abnormal data and accumulating the first occurrence count of the abnormal data, i.e., the number of times the threshold is exceeded. If, after several rounds of data collection, the number of times the threshold is exceeded is not zero and the first time interval between any two adjacent abnormal data points acquired by the alarm response module is less than a preset first duration threshold, an alarm state is determined, and an alarm response is initiated immediately. The alarm response module also sends the alarm information to the data reporting module for alarm data reporting. During the alarm recovery phase, when the environmental data does not exceed the threshold and the first occurrence count is not zero, the alarm response module enters an alarm recovery state, timing the time of the acquired normal data and accumulating the second occurrence count of the normal data, i.e., the number of times the normal value is reached. If, after several rounds of data collection, the second occurrence count is not zero and the second time interval between the normal data points acquired by the alarm response module is less than a preset second duration threshold, alarm recovery is determined, and the previous first occurrence count is reset to zero.

[0120] In addition, the data processing module includes a data cache and an external flash memory. When the device loses network access, the internal cache reaches its limit and actively requests data transmission, recording the number of failed requests. If multiple transmissions fail consecutively, the device is determined to be in a network-disconnected state. It then copies the environmental data from its internal cache to the external flash memory for storage, sets the cache flag to 1, and clears the environmental data and the number of failed requests from the cache to prepare for the next data transmission. When the next request is successfully transmitted, it first checks if the cache flag is 0. If the cache flag is not 0, it integrates the data in the external flash memory with the environmental data in the current cache and sends it for reporting; otherwise, it directly reports the environmental data from the cache. Finally, the data reporting module reports the environmental data to the host computer.

[0121] The aforementioned device alarm method does not immediately trigger an alarm when environmental data exceeds the alarm threshold; instead, it enters a monitoring state. Furthermore, an alarm is only considered triggered after multiple alarms occur within a certain time interval, avoiding false alarms caused by fluctuations in the detected value near the threshold. Additionally, when the internal cache reaches its critical point, it actively requests data transmission. If multiple transmissions fail, it is determined to be in a network outage state. In this case, the data in the internal cache is copied to the device's external flash memory for storage, while the cached data is cleared to prepare for the next data transmission. Upon successful transmission of the next request, the data in the external flash memory and the current cached data are integrated and sent for reporting. This method solves the problem of data loss caused by the device's internal cache reaching its critical point during network outages.

[0122] It should be understood that although the steps in the flowcharts of the embodiments described above are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the embodiments described above may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages of other steps.

[0123] Based on the same inventive concept, this application also provides a device alarm apparatus for implementing the device alarm method described above. The solution provided by this apparatus is similar to the implementation described in the above method; therefore, the specific limitations in one or more device alarm apparatus embodiments provided below can be found in the limitations of the device alarm method described above, and will not be repeated here.

[0124] In one embodiment, such as Figure 11 As shown, a device alarm device 1100 is provided, including: an acquisition module 1101, a determination module 1102, and a generation module 1103. The acquisition module 1101 is used to acquire environmental data of the electrical device currently collected. The determination module 1102 is used to determine the data type of the environmental data, which includes abnormal data and normal data. The generation module 1103 is used to generate an alarm signal to trigger an alarm when the environmental data is abnormal, based on a first time interval between the abnormal data and the previous N consecutively determined abnormal data, and a first occurrence number of the abnormal data.

[0125] In one embodiment, the device alarm device 1100 further includes an update module, which is used to update the first occurrence count to the first initial value based on the normal data, the second time interval between the previous M consecutively determined normal data, and the second occurrence count of the normal data when the environmental data is normal data and the first occurrence count is greater than the preset first initial value.

[0126] In one embodiment, the generation module 1103 is further configured to determine whether the first time interval and the first occurrence number meet the first preset conditions. If they meet, an alarm signal is generated to trigger an alarm; if they do not meet, the acquisition module 1101 is triggered to reacquire new environmental data. The first preset conditions include that the first time interval is less than or equal to a preset first time threshold and the first occurrence number is greater than or equal to a preset first quantity threshold.

[0127] In one embodiment, the generation module 1103 includes an observation unit, a first update unit, and a first determination unit, wherein the observation unit is used to enter a retention observation state. The first update unit is used to update the first occurrence count. The first determination unit is also used to determine a first time interval between the abnormal data and the previously determined abnormal data.

[0128] In one embodiment, the first update module is further configured to determine whether the second time interval and the second occurrence number meet the second preset conditions. If they meet the conditions, the first occurrence number is updated to the first initial value. If they do not meet the conditions, the acquisition module 1101 is re-triggered to acquire new environmental data. The second preset conditions include that the second time interval is less than or equal to a preset second time threshold and the second occurrence number is greater than or equal to a preset second quantity threshold.

[0129] In one embodiment, the first update module includes a recovery unit, a second update unit, and a second determination unit, wherein the recovery unit is used to enter an alarm recovery state; the second update unit is used to update the second occurrence count; and the second determination unit is used to determine a second time interval between the normal data and the previously determined normal data.

[0130] In one embodiment, the device alarm device 1100 further includes a storage module, a sending module, and a clearing module. The storage module stores environmental data in a preset cache area; the sending module sends a data storage request when the remaining cache space in the cache area is less than or equal to a preset storage threshold; the sending module also stores at least a portion of the environmental data in the cache area in a preset memory area when the number of failed transmissions corresponding to the data storage request exceeds a preset request threshold; and the clearing module clears at least a portion of the environmental data in the cache area after it has been stored in the preset memory area.

[0131] In one embodiment, the device alarm device 1100 further includes a second update module, which is used to update the number of failed transmissions to a preset second initial value and update the cache flag to a preset first flag value; the transmission module is also used to send target environment data according to the cache flag corresponding to the cache area when the number of failed transmissions is less than or equal to the request threshold and the data storage request is successfully sent; wherein, the target environment data includes at least a portion of the environment data in the cache area, or at least a portion of the environment data in the cache area and the memory area.

[0132] In one embodiment, the sending module is further configured to send all environmental acquisition data of the memory area and the cache area when the cache flag is a first flag value, and update the cache flag to a second flag value; and send all environmental acquisition data of the cache area when the cache flag is a second flag value.

[0133] Each module in the aforementioned alarm device 1100 can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in the processor of a computer device in hardware form or independent of it, or stored in the memory of a computer device in software form, so that the processor can call and execute the corresponding operations of each module.

[0134] Based on the same inventive concept, this application also provides an electrical device, which includes: an electrical body; an alarm, disposed on the electrical body, for acquiring environmental data of the electrical device currently determined, determining the data type of the environmental data, and generating an alarm signal to trigger an alarm in the case that the environmental data is abnormal data, based on a first time interval between the abnormal data and the previous N consecutively determined abnormal data and a first occurrence number of the abnormal data; wherein, the data type includes abnormal data and normal data.

[0135] In one embodiment, the electrical device further includes a memory area, and the alarm is connected to the host computer and the memory area respectively. The alarm includes a buffer area, and the alarm is also used to store the environmental data acquired in the current time into the buffer area, send a data storage request when the remaining cache space in the buffer area is less than a preset storage threshold, and when the number of failed sending corresponding to the data storage request is greater than a preset request threshold, store at least a portion of the environmental data in the buffer area into the memory area and clear at least a portion of the environmental data in the buffer area.

[0136] In one embodiment, an alarm device is provided, which may be a server, and its internal structure diagram may be as follows. Figure 12 As shown, the alarm includes a processor, memory, and network interface connected via a system bus. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system, computer programs, and a database. The internal memory provides the environment for the operation of the operating system and computer programs in the non-volatile storage media. The database stores environmental data. The network interface communicates with external alarms via a network connection. When the computer program is executed by the processor, it implements a device alarm method.

[0137] Those skilled in the art will understand that Figure 12 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the alarm on which the present application is applied. A specific alarm may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.

[0138] In one embodiment, an alarm is provided, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps of the aforementioned method.

[0139] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon, which, when executed by a processor, implements the steps of the aforementioned method.

[0140] In one embodiment, a computer program product is provided, including a computer program that, when executed by a processor, implements the steps of the aforementioned method.

[0141] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties.

[0142] Those skilled in the art will understand that all or part of the processes in the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium. When executed, the computer program can include the processes of the embodiments described above. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, etc., and are not limited to these.

[0143] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0144] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.

Claims

1. A device alarm method, characterized in that, The method includes: Acquire the environmental data of the electrical equipment collected in this session; Determine the data type of the environmental data, which includes abnormal data and normal data; When the environmental data is the abnormal data, an alarm signal is generated to trigger an alarm based on the first time interval between the abnormal data and the previous N consecutive abnormal data, and the first occurrence number of the abnormal data; the first time interval is the time interval between any two adjacent abnormal data; the first occurrence number is N+1. If the environmental data is normal data and the first occurrence count is greater than a preset first initial value, the first occurrence count is updated to the first initial value based on the second time interval between the normal data and the previous M consecutive normal data, and the second occurrence count of the normal data; the second time interval is the time interval between any two adjacent normal data; the second occurrence count is M+1. The step of updating the first occurrence count to the first initial value based on the normal data, the second time interval determined as normal data in the previous M consecutive occurrences, and the second occurrence count of the normal data includes: Determine whether the second time interval and the second occurrence count meet the second preset condition. If they do, update the first occurrence count to the first initial value. If they do not meet the condition, acquire new environmental data and return to the step of determining the data type of the environmental data. The second preset condition includes that the second time interval is less than or equal to a preset second time threshold, and the second occurrence number is greater than or equal to a preset second quantity threshold.

2. The device alarm method according to claim 1, characterized in that, The step of generating an alarm signal to trigger an alarm based on the abnormal data and a first time interval between the abnormal data and the previous N consecutively identified abnormal data, and a first occurrence number of the abnormal data, includes: Determine whether the first time interval and the first number of occurrences meet the first preset condition. If they do, generate the alarm signal to trigger the alarm. If they do not meet the condition, acquire new environmental data and return to the step of determining the data type of the environmental data. The first preset condition includes that the first time interval is less than or equal to a preset first time threshold, and the first occurrence number is greater than or equal to a preset first quantity threshold.

3. The device alarm method according to claim 2, characterized in that, The method further includes: Entered a period of observation for repeating a grade; Update the first occurrence count; Determine the first time interval between the abnormal data and the previous N consecutive data points that were determined to be abnormal.

4. The device alarm method according to claim 1, characterized in that, The method further includes: Enter alarm recovery mode; Update the second occurrence count; Determine the second time interval between the normal data and the previous M consecutive data points that were determined to be normal.

5. The method according to claim 1, characterized in that, The method further includes: The environmental data is stored in a preset cache area; If the remaining cache space in the cache area is less than or equal to a preset storage threshold, a data storage request is sent. If the number of failed transmissions corresponding to the data storage request exceeds a preset request threshold, at least a portion of the environmental data in the cache is stored in a preset memory area, and at least a portion of the environmental data in the cache is cleared.

6. The method according to claim 5, characterized in that, The method further includes: The number of failed transmissions is updated to a preset second initial value, and the cache flag is updated to a preset first flag value; If the number of failed transmissions is less than or equal to the request threshold and the data storage request is successfully sent, target environment data is sent according to the cache flag corresponding to the cache area; wherein, the target environment data includes at least a portion of the environment data in the cache area, or at least a portion of the environment data in the cache area and the memory area.

7. The method according to claim 6, characterized in that, Sending target environment data according to the cache flag bit corresponding to the cache area includes: When the cache flag is the first flag value, send all environmental acquisition data of the memory area and the cache area, and update the cache flag to the second flag value; When the cache flag is set to the second flag value, all environmental acquisition data in the cache area is sent.

8. An equipment alarm device, characterized in that, The device includes: The acquisition module is used to acquire the environmental data of the electrical equipment collected in the current session; The determination module is used to determine the data type of the environmental data, which includes abnormal data and normal data; the first time interval is the time interval between any two adjacent abnormal data. The generation module is configured to, when the environmental data is the abnormal data, generate an alarm signal to trigger an alarm based on a first time interval between the abnormal data and the previous N consecutively determined abnormal data, and a first occurrence number of the abnormal data; the first occurrence number is N+1. The first update module is configured to, when the environmental data is normal data and the first occurrence count is greater than a preset first initial value, update the first occurrence count to the first initial value based on the second time interval between the normal data and the previous M consecutive normal data, and the second occurrence count of the normal data; determine whether the second time interval and the second occurrence count satisfy a second preset condition; if they satisfy, update the first occurrence count to the first initial value; if they do not satisfy, re-acquire new environmental data and re-trigger the acquisition module to acquire new environmental data; wherein, the second time interval is the time interval between any two adjacent normal data; the second preset condition includes the second time interval being less than or equal to a preset second time threshold, and the second occurrence count being greater than or equal to a preset second quantity threshold; the second occurrence count is M+1.

9. An electrical appliance, characterized in that, The electrical equipment includes: Electrical appliance body; An alarm, installed on the electrical appliance body, is used to acquire environmental data of the electrical appliance in a current determination, determine the data type of the environmental data, and, if the environmental data is abnormal, generate an alarm signal to trigger an alarm based on a first time interval between the abnormal data and the previous N consecutive abnormal data determinations, and a first occurrence count of the abnormal data; wherein, the data type includes abnormal data and normal data; the first time interval is the time interval between any two adjacent abnormal data; if the environmental data is normal data and the first occurrence count is greater than a preset first initial value, update the first occurrence count to the first initial value based on a second time interval between the normal data and the previous M consecutive normal data determinations, and a second occurrence count of the normal data; determine whether the second time interval and the second occurrence count meet a second preset condition; if they do, update the first occurrence count to the first initial value; if not, acquire new environmental data again and return to the step of determining the data type of the environmental data; wherein, the second time interval is the time interval between any two adjacent normal data; the second preset condition includes the second time interval being less than or equal to a preset second time threshold, and the second occurrence count being greater than or equal to a preset second quantity threshold; the first occurrence count is N+1; the second occurrence count is M+1.

10. The electrical equipment according to claim 9, characterized in that, The electrical device also includes a memory area. The alarm is connected to the host computer and the memory area. The alarm includes a buffer area. The alarm is also used to store the environmental data acquired in the current time into the buffer area. If the remaining buffer space in the buffer area is less than a preset storage threshold, a data storage request is sent. If the number of failed transmissions corresponding to the data storage request is greater than a preset request threshold, at least a portion of the environmental data in the buffer area is stored into the memory area, and at least a portion of the environmental data in the buffer area is cleared.

11. An alarm device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 7.

12. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 7.

13. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 7.

Citation Information

Patent Citations

  • Abnormal data processing method

    CN104090951A

  • Tunnel cable grounding current safety alarm expert analysis method

    CN106645870A

  • Heat pump unit control method and device and heat pump unit

    CN115638560A