Fault reporting device and method

By designing a fault reporting device in the LoRaWAN gateway and using detection circuits and fault processing circuits, remote fault information reporting when power supply is abnormal is realized, which solves the inconvenience of on-site maintenance and improves the efficiency and success rate of fault handling.

CN110418366BActive Publication Date: 2024-09-03EASYLINKIN TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN201910517336.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2019-06-14
Publication Date
2024-09-03
Estimated Expiration
2039-06-14

AI Technical Summary

Technical Problem

Existing LoRaWAN gateways require on-site maintenance when power supply is abnormal, causing inconvenience. It is difficult to achieve remote fault monitoring and processing with existing technology.

Method used

A fault reporting device is designed, which includes a detection circuit and a fault processing circuit. It uses voltage acquisition and comparator to detect the power supply status of the gateway, generates notifications and communicates with adjacent gateways or servers through LoRa, and reports abnormal power supply information to the server.

Benefits of technology

It enables remote reporting of fault information when the power supply of the LoRaWAN gateway is abnormal, avoiding the inconvenience of on-site maintenance and improving the efficiency and success rate of fault handling.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN110418366B
    Figure CN110418366B
Patent Text Reader

Abstract

The embodiment of the present invention provides a fault reporting device and method. The fault reporting device includes: a detection circuit and a fault processing circuit; the detection circuit is used to detect whether the power supply of the first gateway is abnormal, and when the abnormality is detected, sends a first notification to the fault processing circuit; the fault processing circuit is used to report a first data packet to a server after receiving the first notification from the detection circuit; the first data packet is a data packet carrying the power supply abnormality information of the first gateway; the first gateway communicates with the terminal based on the long-distance radio LoRa. The fault reporting device in the embodiment of the present invention can report the data packet carrying the power supply abnormality information to the server when the power supply abnormality occurs in the long-distance radio wide area network LoRaWAN gateway, so that the relevant maintenance personnel can remotely understand the fault condition of the gateway, thereby avoiding the inconvenience of having to arrive at the site for maintenance.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to a long range radio (LoRa) technology in the field of communications, and in particular to a fault reporting device and method. Background Art

[0002] In the related technologies, Long Range Radio Wide Area Network (LoRaWAN) is a set of communication protocols and system architecture designed based on the LoRa long-distance communication network, and is widely used in the Internet of Things.

[0003] When LoRaWAN is working normally, the LoRaWAN gateway (hereinafter referred to as the gateway) is controlled and managed by the LoRaWAN network server (hereinafter referred to as the server). However, when an abnormality occurs in the gateway, relevant maintenance personnel must arrive at the site to confirm the fault. Summary of the invention

[0004] In order to solve the existing technical problems, the embodiments of the present invention propose a fault reporting device and method, which can report a data packet carrying power supply abnormality information to a server when a power supply abnormality occurs in a LoRaWAN gateway, so that relevant maintenance personnel can remotely understand the fault condition of the gateway, thereby avoiding the inconvenience of having to arrive at the on-site maintenance.

[0005] The embodiment of the present invention provides a fault reporting device, comprising: a detection circuit and a fault processing circuit; wherein:

[0006] The detection circuit is used to detect whether the power supply of the first gateway is abnormal, and when an abnormality is detected, send a first notification to the fault processing circuit;

[0007] The fault handling circuit is used to report a first data packet to a server after receiving a first notification from the detection circuit; the first data packet is a data packet carrying power supply abnormality information of the first gateway; wherein the first gateway communicates with the terminal based on LoRa.

[0008] In the above solution, the fault processing circuit is used to:

[0009] After receiving the first notification from the detection circuit, the first data packet is sent to at least one second gateway adjacent to the first gateway, so as to report the first data packet to the server through the at least one second gateway; wherein the at least one second gateway communicates with the terminal based on LoRa.

[0010] In the above solution, the first gateway communicates with the second gateway via LoRa.

[0011] In the above scheme, the detection circuit includes a voltage acquisition circuit and a voltage comparator circuit; wherein:

[0012] The voltage acquisition circuit is used to detect the working voltage of the first gateway;

[0013] The voltage comparator circuit is used to send the first notification to the fault processing circuit when it is determined that the detected operating voltage is less than a preset voltage threshold.

[0014] In the above solution, the device further comprises an energy storage circuit, which is used for:

[0015] When the first gateway is powered abnormally, the stored energy is released to power the fault processing circuit.

[0016] In the above solution, the energy storage circuit is used for:

[0017] When the first gateway is powered normally, energy is stored by charging the capacitor using the electric energy provided to the first gateway.

[0018] In the above solution, the fault processing circuit includes a first controller and a fault reporting circuit; wherein,

[0019] The first controller is configured to generate a first control signal after receiving a first notification from the detection circuit;

[0020] The fault reporting circuit is used to respond to the first control signal and send the first data packet to the at least one adjacent second gateway, so as to report the first data packet to the server through the at least one adjacent second gateway.

[0021] In the above solution, the first controller is used to:

[0022] When the first notification is received, a second control signal is generated; the second control signal is used to instruct to shut down a first device of the first gateway whose power consumption is greater than a preset power consumption;

[0023] When it is determined that the first device is turned off, the first control signal is generated.

[0024] In the above solution, the detection circuit is used to detect whether the power supply of the first gateway is abnormal after sending the first data packet to the at least one adjacent second gateway, and send a second notification to the first controller when it is detected to be normal;

[0025] The first controller is further configured to generate a third control signal upon receiving the second notification after a preset time period; the third control signal is configured to instruct to turn on the first device.

[0026] In the above solution, the fault reporting circuit includes a second controller and a radio frequency circuit; wherein,

[0027] The second controller is used to receive the first control signal by interruption and generate a fourth control signal;

[0028] The radio frequency circuit is used to send the first data packet to at least one adjacent second gateway in response to the fourth control signal.

[0029] In the above solution, the fault reporting circuit is used to:

[0030] The first control signal is received via a bus, and the first data packet is sent to at least one adjacent second gateway.

[0031] The embodiment of the present invention also provides a fault reporting method, comprising:

[0032] The detection circuit of the fault reporting device detects whether the power supply of the first gateway is abnormal, and when an abnormality is detected, sends a first notification to the fault processing circuit of the fault reporting device;

[0033] After receiving the first notification, the fault processing circuit reports a first data packet to the server; the first data packet is a data packet carrying power supply abnormality information of the first gateway; wherein the first gateway communicates with the terminal based on LoRa.

[0034] In the above solution, after receiving the first notification from the detection circuit, the fault processing circuit reports the first data packet to the server, including:

[0035] After receiving the first notification from the detection circuit, the fault processing circuit sends the first data packet to at least one second gateway adjacent to the first gateway, so as to report the first data packet to the server through the at least one second gateway; wherein the at least one second gateway communicates with the terminal based on LoRa.

[0036] In the above solution, the first gateway communicates with the second gateway via LoRa.

[0037] In the above solution, the detection circuit of the fault reporting device detects whether the power supply of the first gateway is abnormal, and when an abnormality is detected, sends a first notification to the fault processing circuit of the fault reporting device, including:

[0038] The voltage acquisition circuit of the detection circuit detects the working voltage of the first gateway;

[0039] When the voltage comparator circuit of the detection circuit determines that the detected operating voltage is less than a preset voltage threshold, the first notification is sent to the fault processing circuit.

[0040] In the above scheme, the method further comprises:

[0041] When the power supply of the first gateway is abnormal, the energy storage circuit of the fault reporting device releases the stored energy to supply power to the fault processing circuit.

[0042] In the above solution, after receiving the first notification from the detection circuit, the fault processing circuit sends the first data packet to at least one second gateway adjacent to the first gateway, so as to report the first data packet to the server through the at least one second gateway, including:

[0043] After receiving the first notification from the detection circuit, the first controller of the fault processing circuit generates a first control signal;

[0044] The fault reporting circuit of the fault processing circuit sends the first data packet to the at least one adjacent second gateway in response to the first control signal, so as to report the first data packet to the server through the at least one adjacent second gateway.

[0045] In the above solution, after receiving the first notification from the detection circuit, the first controller of the fault processing circuit generates a first control signal, including:

[0046] The first controller of the fault processing circuit generates a second control signal when receiving the first notification; the second control signal is used to instruct to shut down the first device of the first gateway whose power consumption is greater than the preset power consumption;

[0047] The first controller generates the first control signal when determining that the first device is turned off.

[0048] The embodiment of the present invention provides a fault reporting device and method. The fault reporting device includes: a detection circuit and a fault processing circuit; the detection circuit is used to detect whether the power supply of the first gateway is abnormal, and when the abnormality is detected, sends a first notification to the fault processing circuit; the fault processing circuit is used to report a first data packet to a server after receiving the first notification from the detection circuit; the first data packet is a data packet carrying the power supply abnormality information of the first gateway; the first gateway communicates with the terminal based on LoRa. The fault reporting device in the embodiment of the present invention can report the data packet carrying the power supply abnormality information to the server when the power supply abnormality occurs in the LoRaWAN gateway, so that the relevant maintenance personnel can remotely understand the fault condition of the gateway, thereby avoiding the inconvenience of having to arrive at the site for maintenance. BRIEF DESCRIPTION OF THE DRAWINGS

[0049] Figure 1 This is a schematic diagram of the network architecture of LoRaWAN in related technologies;

[0050] Figure 2 A schematic diagram of the structure of a fault reporting device according to an embodiment of the present invention;

[0051] Figure 3 A schematic diagram of an energy storage circuit of a fault reporting device according to an embodiment of the present invention;

[0052] Figure 4 A schematic diagram of a detection circuit of a fault reporting device according to an embodiment of the present invention;

[0053] Figure 5 Schematic diagram of a fault reporting circuit of a fault reporting device according to an embodiment of the present invention Figure 1 ;

[0054] Figure 6 Schematic diagram of a fault reporting circuit of a fault reporting device according to an embodiment of the present invention Figure 2 ;

[0055] Figure 7 A schematic diagram of a flow chart of a fault reporting method according to an embodiment of the present invention;

[0056] Figure 8 The figure is a schematic diagram of the network topology between the gateway and the server according to an embodiment of the present invention. DETAILED DESCRIPTION

[0057] To make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the specific technical solution of the invention will be further described in detail below in conjunction with the drawings in the embodiments of the present invention. The following embodiments are used to illustrate the present invention, but are not intended to limit the scope of the present invention.

[0058] The network architecture of LoRaWAN is as follows Figure 1 As shown, the terminal node is connected to the gateway via LoRa wireless communication; the gateway is connected to the server via an IP network (such as a mobile cellular network (third-generation mobile communication technology 3G or fourth-generation mobile communication technology 4G, etc.), wireless Internet access (WiFi), or Ethernet, etc.). Based on this network architecture, the gateway plays the role of connecting the server and the terminal node in LoraWan, that is: in the uplink direction, it demodulates the LoRa data packet sent by the terminal node, then encapsulates the demodulated data into IP network data and sends it to the server; in the downlink direction, it executes the downlink data sent by the server, then converts the downlink data into LoRa modulated data and sends it to the corresponding terminal node.

[0059] When LoRaWAN is working normally, the gateway is controlled and managed by the server. When LoRaWAN is working abnormally, such as when the gateway power supply is abnormally interrupted, not only will the LoRaWan service be interrupted, but the server will also lose the ability to control and manage the gateway. In addition, the reason for the gateway disconnection and the current status are unclear, and generally relevant maintenance personnel are required to arrive at the site to confirm the fault.

[0060] Based on this, in each embodiment of the present invention, when a power supply anomaly occurs in the gateway, a data packet carrying the power supply anomaly information is reported to the server so that relevant maintenance personnel can remotely understand the fault condition of the gateway, thereby avoiding the inconvenience of having to arrive at the on-site maintenance.

[0061] Figure 2 The structure diagram of the fault reporting device according to the embodiment of the present invention is shown. The fault reporting device 20 according to the embodiment of the present invention comprises: a detection circuit 201 and a fault processing circuit 202; wherein,

[0062] The detection circuit 201 is used to detect whether the power supply of the first gateway is abnormal, and when an abnormality is detected, send a first notification to the fault processing circuit 202;

[0063] The fault handling circuit 202 is used to report a first data packet to the server after receiving the first notification from the detection circuit 201; the first data packet is a data packet carrying power supply abnormality information of the first gateway; wherein the first gateway communicates with the terminal based on LoRa.

[0064] Here, power supply anomalies include: power outage or input voltage fluctuation. Power outage means that the device cannot restore the power supply to normal state without external intervention; voltage fluctuation is a short-term condition caused by various transient mutations, and the device can restore the power supply to normal state by itself.

[0065] Here, the abnormal information may be a data bit in the first data packet, such as "1" indicates abnormality and "0" indicates normality.

[0066] When a power supply failure occurs in the first gateway, an energy storage circuit or a backup power supply is usually required to power the fault processing circuit 202 to ensure the normal operation of the fault processing circuit 202 .

[0067] Based on this, in one embodiment, the fault reporting device 20 further includes an energy storage circuit for:

[0068] When the first gateway is powered abnormally, the stored energy is released to power the fault processing circuit 202 .

[0069] Here, the energy storage circuit usually uses a large-capacity energy storage device, such as an electrolytic capacitor, a super capacitor or a battery to achieve energy storage, that is, when the power supply of the first gateway is normal, the power supply of the first gateway is used to charge the energy storage device to achieve energy storage; and when the power supply of the first gateway is abnormal, the energy storage device is discharged to power the fault processing circuit 202.

[0070] Based on this, in one embodiment, the energy storage circuit is used to:

[0071] When the first gateway is powered normally, energy is stored by charging the capacitor using the electric energy provided to the first gateway.

[0072] In practical applications, the number, capacitance or power value of the capacitors used in the energy storage circuit can be determined according to the overall power demand. Figure 3 As shown, the energy storage circuit can be composed of three electrolytic capacitors with a capacitance of 2200uF connected in parallel. The power supply circuit is a circuit for supplying power to the first gateway. When the power supply circuit is normal, the energy storage circuit is charged by the electrolytic capacitor. When the power supply circuit is abnormal, the energy storage circuit supplies power to the power supply circuit by discharging the electrolytic capacitor. Figure 3 A diode is also added, where the diode is connected in series with the three capacitors. The diode directs the discharge current of the electrolytic capacitor to the power supply circuit to isolate the influence of the discharge of the energy storage circuit on the detection circuit 201, so that the abnormal power supply state of the first gateway can be detected by the detection circuit 201 at the first time. Here, the capacitance and quantity of the capacitors in the energy storage circuit can be adjusted according to actual needs. In this embodiment, three electrolytic capacitors with a capacitance of 2200uF can ensure that the fault processing circuit 202 has an operation time of 150ms to send a data packet after receiving the first notification.

[0073] In actual application, the fault handling circuit 202 can report the first data packet carrying the power supply abnormality information of the first gateway to the server in the following manner: Considering that the gateway is connected to the server through an IP network (such as a mobile cellular network (third-generation mobile communication technology 3G or fourth-generation mobile communication technology 4G, etc.), wireless Internet access (WiFi), or Ethernet, etc.). When the gateway is abnormal due to power outage or voltage fluctuation, the fault handling circuit 202 can be directly transmitted back to the server through the upper network, that is, the IP network. Specifically, according to different IP networks, it can be divided into:

[0074] 1. Use Ethernet to transmit back:

[0075] When using the Transmission Control Protocol (TCP) for backhaul, the network delay for TCP to establish a connection is too large, usually reaching hundreds of milliseconds, and the energy storage circuit has high requirements for storing electricity; when using the User Datagram Protocol (UDP) for backhaul, the UDP method is only a best-effort network transmission method with a relatively low transmission success rate.

[0076] 2. Use mobile cellular network or wireless Internet access to transmit:

[0077] The general energy storage circuit can only provide a processing time of hundreds of milliseconds, while the mobile cellular network and wireless Internet access need at least seconds to send the data packet carrying power supply abnormality information to the server, and the power consumption is very large. In other words, the backhaul using the mobile cellular network or wireless Internet access requires a very high amount of energy storage in the energy storage circuit. At the same time, the wireless environment is complex and changeable, the probability of data packet loss is high, and the transmission success rate is relatively low.

[0078] It can be seen that the method of using the Internet to transmit data back to the server is time-consuming, difficult to load the energy storage circuit, and has a low probability of successful transmission.

[0079] However, in actual applications, some gateways are not even equipped with Ethernet uplink ports due to limited installation and construction conditions. These gateways are powered by a power supply system based on Ethernet (POE, Power Over Ethernet). If POE is used, when the POE power supply is abnormal, the network connection between the gateway and the server is also interrupted, and the data packet carrying the power supply abnormality information will not be sent. Therefore, these gateways cannot use the reporting method of directly transmitting back to the server through the uplink network.

[0080] On the other hand, in actual applications, in areas covered by the LoRaWan network, multiple gateways usually communicate with the same logical network server, that is, multiple gateways correspond to one logical network server; at the same time, there is overlap between the gateway coverage areas to ensure that the terminal node can be covered by at least two gateways at the same time. Because the gateway is usually set up on the top of a higher tower or building and uses a high-gain antenna, adjacent gateways can communicate directly in LoRa mode.

[0081] It can be seen from this that the fault handling circuit 202 can also upload the first data packet to the server through LoRa communication between adjacent gateways, that is, when a gateway abnormality occurs due to power outage or voltage fluctuation, the gateway quickly sends a power supply abnormality information data packet to the adjacent gateway in LoRa mode at the moment of power outage or power fluctuation, and forwards its power outage status information to the network server through the adjacent gateway.

[0082] Here, since the communication between adjacent gateways does not need to consider the delay of establishing a connection network, the distance between adjacent gateways is short (relative to the distance between the gateway and the server), and the power consumption of LoRa wireless communication is low. At the same time, the actual reporting process relies on the adjacent gateway with normal power supply to report to the server. Therefore, this method can alleviate the load of the energy storage circuit to a certain extent and improve the success rate of fault reporting.

[0083] Based on this, in one embodiment, the fault handling circuit 202 is used to send the first data packet to at least one second gateway adjacent to the first gateway after receiving the first notification from the detection circuit 201, so as to report the first data packet to the server through the at least one second gateway; wherein the first gateway and at least one second gateway both communicate with the terminal based on LoRa.

[0084] Here, the first gateway communicates with the second gateway via LoRa.

[0085] Here, the function of the detection circuit 201 is to determine whether the first gateway has a power supply anomaly, and to generate and issue a first notification when the first gateway has a power supply anomaly. In actual application, the first notification may be an electrical signal generated by a corresponding device when a power supply anomaly is detected, such as a low-level signal.

[0086] In actual application, the detection circuit 201 mainly determines whether the power supply of the first gateway is abnormal by detecting the working voltage of the first gateway in real time. After the detected working voltage drops to the preset voltage threshold, it is determined to be an abnormal state, and a low-level signal is immediately output. As long as the detected working voltage continues to be lower than the preset voltage threshold, the low-level signal is continuously output until the detected working voltage returns to the normal value range (the detected working voltage is higher than the preset threshold), and a high-level signal is output. Both the low-level signal and the high-level signal are sent to the fault processing circuit 202.

[0087] In practical applications, a voltage acquisition circuit may be used to detect the working voltage of the first gateway, and a voltage comparator circuit may be used to implement the above voltage comparison and generation of the first signal.

[0088] Based on this, in one embodiment, the detection circuit 201 includes a voltage acquisition circuit and a voltage comparator circuit; wherein:

[0089] The voltage acquisition circuit is used to detect the working voltage of the first gateway;

[0090] The voltage comparator circuit is used to send the first notification to the fault processing circuit 202 when it is determined that the detected operating voltage is less than a preset voltage threshold.

[0091] Here, the preset voltage threshold needs to consider the lowest voltage value at which the first gateway can work normally.

[0092] In actual application, the voltage acquisition circuit and the voltage comparator circuit can be implemented by using resistors, operational amplifiers, etc., or by using a chip that integrates voltage acquisition and voltage comparison. For example, a chip SGM706 (SGM706 is the chip model) that integrates the functions of voltage acquisition and voltage comparator is selected. Here, SGM706 is a chip that integrates reset, watchdog and voltage monitoring functions. In the embodiment of the present invention, only its voltage monitoring function is used. Figure 4 As shown in the figure, when the PFI input voltage is less than 1.25V (corresponding to the working voltage of the first gateway of 9.73V), the 5-pin PFO outputs a low level; when the PFI input voltage is greater than 1.3V (corresponding to the working voltage of the first gateway of 10.1V), the 5-pin PFO outputs a high level. 12V is the rated working voltage of the first gateway. Figure 4 The voltage divider circuit in can be calculated: when the working voltage of the first gateway is monitored to drop from 12V to less than 9.73V, the 5-pin PFO will output a low level, indicating that the power supply of the first gateway is abnormal; when the working voltage of the first gateway is monitored to return to above 10.1V, the 5-pin PFO will output a low level, indicating that the power supply of the first gateway is normal.

[0093] Here, 9.73V is the aforementioned preset voltage threshold, which is required to ensure the normal sending of the first notification and the minimum operating voltage range of the first gateway (e.g., the minimum operating voltage is 10.8V, and a decrease of less than 10% is allowed). In actual application, the preset voltage threshold can be adjusted according to the actual application situation, and the voltage threshold can be adjusted by changing the ratio of the resistor R1 to the resistor R2.

[0094] It should be noted that: as mentioned above, the power supply anomaly of the first gateway includes power supply interruption or input voltage fluctuation. If it is voltage fluctuation (fluctuating voltage drops below 9.73V), causing PFO to output a low level), after a period of time (usually short), the working voltage of the first gateway can be restored to above 10.1V, and PFO will output a high level again. It can be understood that when there is no external force intervention, when PFO always outputs a low level, it indicates that the power supply of the first gateway is interrupted, and when PFO outputs a low level, it outputs a high level again in a short time, indicating that the voltage of the first gateway fluctuates.

[0095] In one embodiment, the fault processing circuit 202 includes a first controller and a fault reporting circuit; wherein,

[0096] The first controller is configured to generate a first control signal after receiving a first notification from the detection circuit;

[0097] The fault reporting circuit is used to respond to the first control signal and send the first data packet to the at least one adjacent second gateway, so as to report the first data packet to the server through the at least one adjacent second gateway.

[0098] Here, the first controller mainly completes the generation and processing of various control signals when the first gateway is powered abnormally. In actual application, the first controller can be a central processing unit (CPU) or a microcontroller unit (MCU). The first controller receives the first notification and enters an interrupt.

[0099] Due to the abnormal power supply of the first gateway, the energy storage circuit is started, but at this time, since the reserved power is limited, in order to extend the action time of the energy storage circuit and prevent some high-power consumption functional modules in the first gateway from directly causing the reserved power of the energy storage circuit to be exhausted, it is necessary to first turn off the high-power consumption functional modules in the first gateway, such as 4G module, WiFi module, GPS module, Ethernet module, Universal Serial Bus (USB) module and other functional modules, and adopt other methods to reduce power consumption (for example, for the main controller of the first gateway, turn off one of the processor cores, or reduce the frequency), and then perform the operation of sending the first data packet.

[0100] Based on this, in one embodiment, the first controller is used to:

[0101] When the first notification is received, a second control signal is generated; the second control signal is used to instruct to shut down a first device of the first gateway whose power consumption is greater than a preset power consumption;

[0102] When it is determined that the first device is turned off, the first control signal is generated.

[0103] Here, the preset power consumption can be adjusted according to actual conditions, such as 0.1w.

[0104] In actual application, the method of shutting down the functional module can usually be to shut down the power supply enable pin of the functional module, or to enable the reset function of the functional module.

[0105] The fault reporting circuit is mainly used to send the first data packet to at least one adjacent second gateway adjacent to the first gateway.

[0106] Here, adjacent can be understood as a gateway that has an overlapping geographical location and is adjacent to the first gateway network coverage in the same LoRaWAN.

[0107] In actual application, the fault reporting circuit can have two hardware topology solutions:

[0108] Solution 1: The fault reporting circuit includes a second controller and a radio frequency circuit; wherein,

[0109] The second controller is used to receive the first control signal by interruption and generate a fourth control signal;

[0110] The radio frequency circuit is used to send the first data packet to at least one adjacent second gateway in response to the fourth control signal.

[0111] In practical applications, such as Figure 5 As shown, the fault reporting circuit includes a radio frequency circuit (RF IC) and has its own MCU (equivalent to a second controller). At this time, the controller in the fault processing circuit 202 only needs to initiate an interrupt signal to the MCU in the fault reporting circuit. After receiving the interrupt, the MCU in the fault reporting circuit immediately controls the radio frequency circuit to send a data packet carrying power supply abnormality information.

[0112] Solution 2: The fault reporting circuit is used to: receive the first control signal through a bus, and send the first data packet to at least one adjacent second gateway.

[0113] In practical applications, such as Figure 6 As shown, the fault reporting circuit itself does not have an MCU, but only includes a radio frequency circuit (RF IC). At this time, the controller in the fault processing circuit 202 sends a first control signal to the radio frequency circuit via a bus (such as SPI). After receiving the first control signal, the radio frequency circuit in the fault reporting circuit immediately sends a data packet carrying power supply abnormality information.

[0114] In actual application, in order to improve the success rate of the server receiving data packets, when the energy stored in the energy storage circuit is sufficient, the RF circuit can repeatedly send data packets carrying power supply abnormality information, such as sending the first data packet twice in succession.

[0115] In practical applications, it is also necessary to distinguish whether the power supply anomaly is caused by power outage or voltage fluctuation, so as to provide more accurate fault information to relevant maintenance personnel.

[0116] In practical application, such as Figure 4 When the PFO of the detection circuit 201 outputs a low level, it outputs a high level again after a short period of time, indicating that the power supply of the first gateway has voltage fluctuations. Voltage fluctuations are generally related to the instability of the external power supply voltage. Such voltage fluctuations may cause the first gateway to restart or not restart. Specifically:

[0117] 1. If restarted, this fluctuation can be regarded as powering on again after power off, which does not contradict the logic that the first controller sends a power supply abnormality data packet after receiving the first notification, and the normal business of the gateway can also be restored automatically after power is restored.

[0118] 2. If there is no restart, this fluctuation only causes the first controller to process the received first notification, and does not cause the first controller to reset and restart. At this time, the first controller has been working normally. When it is detected that the working voltage of the first gateway has recovered to above the preset voltage threshold after a fluctuation, the PFO output will be set high again. However, at this time, the controller has instructed to shut down the high-power functional module of the first gateway, including the uplink network channel, and the power supply abnormality data packet has been sent to other adjacent gateways and transferred to the server, and it is impossible to withdraw it.

[0119] In actual application, in order to filter the operation of repeatedly shutting down various functional modules caused by voltage fluctuations, and also avoid repeatedly sending power supply abnormality notification data packets, the controller only responds to one interrupt after receiving the first notification in an interrupt manner, and no longer responds to other interrupts within 30s (configurable time). At 30s, it is detected again whether the signal indicating that the power supply of the first gateway is normal is still received from the detection circuit 201. If it is received, it means that it is a voltage fluctuation and the fluctuation has ended. At this time, the controller needs to reopen various large power consumption functional modules of the first gateway that have been shut down, restore business, restore network data, and directly send a data packet carrying power supply recovery information to the server. The server judges it as a short-term work abnormality caused by a power supply fluctuation through a power supply abnormality data packet and a power supply recovery information data packet before and after 30s, and has learned that the first gateway has resumed normal operation. This mechanism can ensure that there is no false alarm of the power outage and business interruption of the gateway due to the power supply voltage fluctuation of the first gateway, thereby achieving the purpose of reducing the maintenance workload.

[0120] Based on this, in one embodiment, the detection circuit 201 is used to detect whether the power supply of the first gateway is abnormal after sending the first data packet to the at least one adjacent second gateway, and send a second notification to the first controller when it is detected to be normal;

[0121] The first controller is further configured to generate a third control signal upon receiving the second notification after a preset time period; the third control signal is configured to instruct to turn on the first device.

[0122] The preset duration here can be adjusted according to actual conditions, such as 30s.

[0123] In actual application, after receiving the power supply anomaly information data packet, at least one adjacent second gateway can encapsulate the data with TCP and then send it to the server. If the server receives at least two first gateway power supply anomaly information data packets within a preset time (e.g., 1s), it will directly filter one or several data packets following the first data packet, and interpret these filtered data packets as the same power supply anomaly of the first gateway. After a waiting time of at least a preset time (e.g., >30s), the server confirms whether it is a power outage or a power supply fluctuation based on the situation of the data packet received again (if the power supply related information of the first gateway is not received, it is confirmed to be a power outage; if the power supply anomaly recovery information sent by the first gateway is received, it is confirmed to be a power supply fluctuation). Finally, the confirmed status is sent to the network operation and maintenance server to complete the final information reporting.

[0124] The fault reporting device provided in the embodiment of the present invention includes: a detection circuit and a fault processing circuit; wherein the detection circuit is used to detect whether the power supply of the first gateway is abnormal, and when the abnormality is detected, send a first notification to the fault processing circuit; the fault processing circuit, the fault processing circuit, is specifically used to: after receiving the first notification of the detection circuit, send a first data packet to at least one second gateway adjacent to the first gateway, so as to report the first data packet to the server through the at least one second gateway; the first data packet is a data packet carrying the power supply abnormality information of the first gateway; wherein the first gateway and at least one second gateway both communicate with the terminal based on LoRa. The fault reporting device in the embodiment of the present invention can report the data packet carrying the power supply abnormality information to the server when the power supply abnormality occurs in the LoRaWAN gateway, so that the relevant maintenance personnel can remotely understand the fault condition of the gateway, thereby avoiding the inconvenience of having to arrive at the site for maintenance.

[0125] On the other hand, in an embodiment of the present invention, when a power supply abnormality occurs in the first gateway in LoRaWAN and the probability of failure in reporting directly to the server is very high, power supply fault information is forwarded to at least one adjacent second gateway, and the data packet carrying the power supply abnormality information is reported to the server through the second gateway. In this way, the fault information can be reported with the help of the second gateway to improve the success rate of the first gateway reporting to the server.

[0126] In addition, the fault reporting device provided in the embodiment of the present invention can enable relevant maintenance personnel to remotely understand the fault status of the gateway only by performing minor optimizations on the internal software and hardware of the first gateway. In this way, it can avoid the situation where relevant maintenance personnel climb a tower or a ladder to reach the first gateway set up at a high place on site, thereby eliminating the need to add additional detection equipment and management and maintenance costs, reducing manpower investment and safety risks.

[0127] Based on the above device, the embodiment of the present invention also provides a fault reporting method, such as Figure 7 As shown, the fault reporting method includes the following steps:

[0128] Step S701: The detection circuit of the fault reporting device detects whether the power supply of the first gateway is abnormal, and when an abnormality is detected, sends a first notification to the fault processing circuit of the fault reporting device;

[0129] Step S702: After receiving the first notification, the fault processing circuit reports a first data packet to the server; the first data packet is a data packet carrying power supply abnormality information of the first gateway; wherein the first gateway communicates with the terminal based on LoRa.

[0130] In one embodiment, after receiving the first notification from the detection circuit, the fault processing circuit reports a first data packet to the server, including:

[0131] After receiving the first notification from the detection circuit, the fault processing circuit sends the first data packet to at least one second gateway adjacent to the first gateway, so as to report the first data packet to the server through the at least one second gateway; wherein the at least one second gateway communicates with the terminal based on LoRa.

[0132] In one embodiment, the first gateway communicates with the second gateway via LoRa.

[0133] In one embodiment, the detection circuit of the fault reporting device detects whether the power supply of the first gateway is abnormal, and when an abnormality is detected, sends a first notification to the fault processing circuit of the fault reporting device, including:

[0134] The voltage acquisition circuit of the detection circuit detects the working voltage of the first gateway;

[0135] When the voltage comparator circuit of the detection circuit determines that the detected operating voltage is less than a preset voltage threshold, the first notification is sent to the fault processing circuit.

[0136] In one embodiment, the method further comprises:

[0137] When the power supply of the first gateway is abnormal, the energy storage circuit of the fault reporting device releases the stored energy to supply power to the fault processing circuit.

[0138] In one embodiment, after receiving the first notification from the detection circuit, the fault processing circuit sends the first data packet to at least one second gateway adjacent to the first gateway, so as to report the first data packet to the server through the at least one second gateway, including:

[0139] After receiving the first notification from the detection circuit, the first controller of the fault processing circuit generates a first control signal;

[0140] The fault reporting circuit of the fault processing circuit sends the first data packet to the at least one adjacent second gateway in response to the first control signal, so as to report the first data packet to the server through the at least one adjacent second gateway.

[0141] In one embodiment, after receiving the first notification from the detection circuit, the first controller of the fault processing circuit generates a first control signal, including:

[0142] The first controller of the fault processing circuit generates a second control signal when receiving the first notification; the second control signal is used to instruct to shut down the first device of the first gateway whose power consumption is greater than the preset power consumption;

[0143] The first controller generates the first control signal when determining that the first device is turned off.

[0144] It should be noted that those skilled in the art can clearly understand that for the convenience and brevity of description, the specific steps of the method described above can refer to the corresponding process in the aforementioned charging device embodiment, and will not be repeated here.

[0145] The embodiment of the present invention provides a fault reporting method, comprising: a detection circuit of a fault reporting device detects whether the power supply of a first gateway is abnormal, and when an abnormality is detected, sends a first notification to a fault processing circuit of the fault reporting device; after receiving the first notification, the fault processing circuit reports a first data packet to a server; the first data packet is a data packet carrying power supply abnormality information of the first gateway; wherein the first gateway communicates with a terminal based on LoRa. The fault reporting method in the embodiment of the present invention can report a data packet carrying power supply abnormality information to a server when a power supply abnormality occurs in a LoRaWAN gateway, so that relevant maintenance personnel can remotely understand the fault condition of the gateway, thereby avoiding the inconvenience of having to arrive at the site for maintenance.

[0146] In an exemplary embodiment, the embodiment of the present invention further provides a storage medium, namely a computer storage medium, specifically a computer-readable storage medium, for example, a memory storing a computer program, and the computer program can be executed by a processor in a charging device to complete the steps of the aforementioned method. The computer-readable storage medium can be a ferroelectric random access memory (FRAM), a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), a flash memory, a magnetic surface memory, an optical disk, or a compact disc read-only memory (CD-ROM).

[0147] In order to better illustrate that the solution of the embodiment of the present invention can improve the success rate of fault reporting to a certain extent, a corresponding simulation verification experiment was carried out.

[0148] In LoRaWan, the gateway and server topology is shown in Figure 8. All gateways communicate with one server. Although the distance between gateways is far, usually 2-4km. However, each gateway is generally installed on the top floor of a building (where the top floor environment is relatively open and communication between gateways is not easily blocked), and the antenna gain and efficiency of each gateway are much greater than the terminal node, and the wireless environment is better. Therefore, the transmission distance for communication between gateways can be far, usually more than 5km, so gateway 2 (equivalent to the first gateway) can usually transmit information to at least two adjacent gateways, gateway 1 and gateway 3 (equivalent to the second gateway).

[0149] Set relevant parameters according to the actual distance between gateways, the time to reserve power after power failure, transmission status information, etc. For example, assuming that the gateway only supports 150ms of operation time after power failure, the parameters shown in Table 1 below can be used for simulation verification experiments.

[0150]

[0151]

[0152] Table 1

[0153] According to the set of parameters shown in Table 1, 9 bytes of valid data bits can include 6 bytes of media access control address (MAC), and the other 3 bytes can be defined as power supply abnormality information and power supply recovery information. Using the parameters in Table 1 and combining the modulation principle of LoRa, it can be concluded that the time for gateway 2 to successfully send a data packet to gateway 1 and gateway 3 is about 58ms, excluding the time for the first controller to control the shutdown of the high-power functional module of the first gateway and other operations (such as necessary command response) (a total of no more than 20ms), that is, two data packets can be stably sent 150ms after power failure.

[0154] The gateways communicate with each other using LoRa wireless communication. According to conservative estimates, the average packet loss rate of LoRa wireless communication is 10%. Two packets carrying power supply abnormality information are sent to Gateway 1 and Gateway 3 adjacent to Gateway 2. Then the probability that the server receives at least one packet (normally it can receive four packets, that is, two packets are sent to the server by each of the two gateways) is 1-10%. 4 = 99.99%, and the success rate of 99.99% is sufficient to meet the purpose of stably and reliably reporting status information. Therefore, the fault reporting device or method provided by this embodiment has high reliability and stability, and greatly improves the success rate of fault reporting.

[0155] It should be noted that: "first", "second", etc. are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence.

[0156] In addition, the technical solutions described in the embodiments of the present invention can be arbitrarily combined without conflict.

[0157] The above description is only a preferred embodiment of the present invention and is not intended to limit the protection scope of the present invention. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the present invention.

Claims

1. A fault reporting device, It is characterized in that The fault reporting device is located inside the first gateway and includes: a detection circuit and a fault processing circuit; wherein, The detection circuit is used to detect whether the power supply of the first gateway is abnormal, and when an abnormality is detected, send a first notification to the fault processing circuit; Wherein, the detection circuit includes a voltage acquisition circuit and a voltage comparator circuit; The voltage acquisition circuit is used to detect the working voltage of the first gateway; The voltage comparator circuit is configured to send the first notification to the fault processing circuit when determining that the detected operating voltage is less than a preset first voltage threshold; the first voltage threshold is associated with a voltage at which the first notification is normally sent and a minimum operating voltage range of the first gateway; The fault processing circuit is configured to send a first data packet to at least one second gateway adjacent to the first gateway after receiving the first notification from the detection circuit, so as to report the first data packet to the server through the at least one second gateway; wherein the first data packet is a data packet carrying power supply abnormality information of the first gateway, the first gateway communicates with the terminal based on the long-distance radio LoRa, and the at least one second gateway communicates with the terminal based on LoRa; The detection circuit is further configured to detect the operating voltage of the first gateway after sending the first data packet to the at least one adjacent second gateway, and send a second notification to the fault processing circuit when detecting that the operating voltage is greater than a preset second voltage threshold; wherein the second voltage threshold is greater than the first voltage threshold, and the second notification indicates that the power supply of the first gateway is normal; The fault processing circuit is further configured to report a second data packet to the server upon receipt of the second notification after a preset period of time, wherein the second data packet is a data packet carrying power supply recovery information.

2. The device according to claim 1, It is characterized in that The first gateway communicates with the second gateway via LoRa.

3. The device according to claim 1, It is characterized in that The device also includes a tank circuit for: When the first gateway is powered abnormally, the stored energy is released to power the fault processing circuit.

4. The device according to claim 3, It is characterized in that The energy storage circuit is used for: When the first gateway is powered normally, energy is stored by charging the capacitor using the electric energy provided to the first gateway.

5. The device according to claim 1, It is characterized in that The fault processing circuit includes a first controller and a fault reporting circuit; wherein, The first controller is configured to generate a first control signal after receiving a first notification from the detection circuit; The fault reporting circuit is used to respond to the first control signal and send the first data packet to the at least one adjacent second gateway, so as to report the first data packet to the server through the at least one adjacent second gateway.

6. The device according to claim 5, It is characterized in that The first controller is used for: When the first notification is received, a second control signal is generated; the second control signal is used to instruct to shut down a first device of the first gateway whose power consumption is greater than a preset power consumption; When it is determined that the first device is turned off, the first control signal is generated.

7. The device according to claim 6, It is characterized in that The first controller is further configured to: After a preset time period, when the second notification is received, a third control signal is generated; the third control signal is used to instruct to turn on the first device.

8. The device according to claim 5, It is characterized in that The fault reporting circuit includes a second controller and a radio frequency circuit; wherein, The second controller is used to receive the first control signal by interruption and generate a fourth control signal; The radio frequency circuit is used to send the first data packet to at least one adjacent second gateway in response to the fourth control signal.

9. The device according to claim 5, It is characterized in that The fault reporting circuit is used for: The first control signal is received via a bus, and the first data packet is sent to at least one adjacent second gateway.

10. A fault reporting method, It is characterized in that The method comprises: The detection circuit of the fault reporting device detects whether the power supply of the first gateway is abnormal, and when an abnormality is detected, sends a first notification to the fault processing circuit of the fault reporting device; wherein the fault reporting device is located inside the first gateway; The detection circuit of the fault reporting device detects whether the power supply of the first gateway is abnormal, and when an abnormality is detected, sends a first notification to the fault processing circuit of the fault reporting device, including: The voltage acquisition circuit of the detection circuit detects the working voltage of the first gateway; When the voltage comparator circuit of the detection circuit determines that the detected operating voltage is less than a preset first voltage threshold, the first notification is sent to the fault processing circuit; the first voltage threshold is associated with the voltage at which the first notification is normally sent and the minimum operating voltage range of the first gateway; After receiving the first notification, the fault processing circuit sends a first data packet to at least one second gateway adjacent to the first gateway, so as to report the first data packet to the server through the at least one second gateway; wherein the first gateway communicates with the terminal based on LoRa, and the at least one second gateway communicates with the terminal based on LoRa; the first data packet is a data packet carrying power supply abnormality information of the first gateway; After sending the first data packet to the at least one adjacent second gateway, the detection circuit detects the working voltage of the first gateway, and when detecting that the working voltage is greater than a preset second voltage threshold, sends a second notification to the fault processing circuit; wherein the second voltage threshold is greater than the first voltage threshold, and the second notification indicates that the power supply of the first gateway is normal; The fault processing circuit receives the second notification after a preset period of time, and reports a second data packet to the server, wherein the second data packet is a data packet carrying power supply recovery information.

11. The method according to claim 10, It is characterized in that The first gateway communicates with the second gateway via LoRa.

12. The method according to claim 10, It is characterized in that The method further comprises: When the power supply of the first gateway is abnormal, the energy storage circuit of the fault reporting device releases the stored energy to supply power to the fault processing circuit.

13. The method according to claim 10, It is characterized in that After receiving the first notification from the detection circuit, the fault processing circuit sends a first data packet to at least one second gateway adjacent to the first gateway, so as to report the first data packet to the server through the at least one second gateway, including: After receiving the first notification from the detection circuit, the first controller of the fault processing circuit generates a first control signal; The fault reporting circuit of the fault processing circuit sends the first data packet to the at least one adjacent second gateway in response to the first control signal, so as to report the first data packet to the server through the at least one adjacent second gateway.

14. The method according to claim 13, It is characterized in that After receiving the first notification from the detection circuit, the first controller of the fault processing circuit generates a first control signal, including: The first controller of the fault processing circuit generates a second control signal when receiving the first notification; the second control signal is used to instruct to shut down the first device of the first gateway whose power consumption is greater than the preset power consumption; The first controller generates the first control signal when determining that the first device is turned off.