Gas meter control methods, devices, equipment and media
By receiving connection and command signals from the gas alarm within a preset time period and combining this with level signal detection, the problem of monitoring the connection status of the gas meter and gas alarm is solved, achieving compatibility with older meters and improving system reliability.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- GOLDCARD HIGH TECH
- Filing Date
- 2024-12-31
- Publication Date
- 2026-06-30
AI Technical Summary
The existing two-wire connection method for gas meters and gas alarms cannot effectively monitor the connection status, making it impossible to determine the cause of connection failure. Furthermore, it is incompatible with older meters, increases hardware costs, or is incompatible with wireless modules.
By receiving connection and command signals from the gas alarm within a preset time period, and combining this with level signal detection, the connection status of the gas meter and gas alarm can be monitored, and signals of different frequencies can be received at different times to ensure compatibility with older meters.
It enables monitoring of the connection status of gas meters and gas alarms, reduces hardware costs, is compatible with older meters, and improves the reliability and safety of the system.
Smart Images

Figure CN122313643A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of instrument control, and in particular to a gas meter control method, device, equipment and medium. Background Technology
[0002] The gas meter alarm detects the concentration of gas in the environment. When the gas alarm detects that the concentration of gas in the environment exceeds the standard, it will sound an audible and visual alarm to remind people to take safety measures. The gas meter will automatically shut off the valve to prevent further leakage in the pipeline downstream of the valve.
[0003] Currently, gas meters and gas alarms are usually connected by two wires. When the gas alarm detects that the concentration of gas in the environment exceeds the standard, it will issue an alarm and output the alarm signal to the gas meter.
[0004] However, when connected via two wires, there is no signal output from the signal line when no alarm is triggered, and there is also no signal output when the gas meter and gas alarm are not connected. Therefore, it is impossible to monitor the connection status between the gas meter and gas alarm, and it is impossible to determine whether the lack of signal output is due to a disconnection between the gas meter and gas alarm or the gas alarm not triggering. Adding more signal lines could diversify the output signal and monitor the connection status between the gas meter and gas alarm, but this increases hardware costs and is incompatible with older meters using two-wire connections. Alternatively, wireless methods such as Bluetooth could be used to monitor the connection status, but Bluetooth connections are incompatible with older meters using two-wire connections that lack a Bluetooth module. Summary of the Invention
[0005] This application provides a gas meter control method, device, equipment, and medium, which realizes the monitoring of the connection status between the gas meter and the gas alarm, as well as the alarm detection of the gas alarm and compatibility with existing two-wire connection products.
[0006] In a first aspect, embodiments of this application provide a gas meter control method, applied to a gas meter, the method comprising:
[0007] Within a first preset time period, it is determined whether a connection signal or a command signal sent by the gas alarm is received, so as to detect the disconnection of the gas alarm. The connection signal and the command signal have different frequencies.
[0008] During the second preset time period, the gas alarm receives an electrical level signal and detects the signal to determine the detection result. The electrical level signal is determined by the gas alarm based on the detected gas concentration.
[0009] If the detection result is a first-level signal, the valve is closed and an alarm message is sent to the control system. The first-level signal is used to indicate that the gas concentration in the area where the gas alarm is located is abnormal.
[0010] In one possible implementation, the second preset time period includes multiple detection cycles, and the detection of the level signal and determination of the detection result includes:
[0011] According to the detection cycle, the received level signal in each detection cycle is detected to obtain the level information corresponding to each detection cycle;
[0012] The level information corresponding to each detection cycle is filtered, and the filtered level information is used as the detection result.
[0013] In one possible implementation, the above-mentioned determination of whether a connection signal or command signal sent by the gas alarm is received, in order to perform a disconnection detection on the gas alarm, includes:
[0014] If no connection signal is received from the gas alarm, determine whether a command signal has been received;
[0015] If so, the target information corresponding to the instruction signal is determined, and corresponding control is performed based on the target information;
[0016] If not, a first message is generated and sent to the control system. The first message is used to indicate that the gas alarm is disconnected from the gas meter.
[0017] In one possible implementation, determining the target information corresponding to the instruction signal includes:
[0018] If the command signal is the first command signal, then the target information is determined to be communication information;
[0019] If the command signal is the second command signal, then the target information is determined to be valve closing information, wherein different command signals correspond to different frequencies.
[0020] In one possible implementation, the above-mentioned control based on the target information includes:
[0021] If the target information is communication information, an interaction request is sent to the control system based on the communication information;
[0022] If the target information is valve closing information, the valve closing operation is performed based on the valve closing information.
[0023] Secondly, embodiments of this application provide a gas meter control method applied to a gas alarm, the method comprising:
[0024] Within a first preset time period, it is determined whether a second message sent by an external device is received, in order to determine whether to send a connection signal or a command signal to the gas meter, wherein the frequency of the connection signal and the command signal are different;
[0025] Continuously monitor the gas concentration in the area and determine whether the gas concentration is abnormal;
[0026] In the event of an abnormal gas concentration, an alarm is triggered, and a first level signal is sent to the gas meter within a second preset time period. The first level signal is used to indicate that the gas concentration in the area where the gas alarm is located is abnormal.
[0027] In one possible implementation, the above-mentioned determination of whether a second message from an external device has been received, and based on the second message, sending a connection signal or command signal to the gas meter within a first preset time period, includes:
[0028] Determine whether a second message sent by an external device has been received;
[0029] If so, then according to the second message, a command signal corresponding to the second message is sent to the gas meter within a first preset time period. Different second messages correspond to command signals of different frequencies. The command signal is used to instruct the gas meter to perform corresponding control.
[0030] If not, a connection signal is sent to the gas meter within the first preset time period. The connection signal is used to indicate that the gas alarm is connected to the gas meter.
[0031] Thirdly, embodiments of this application provide a gas meter control device, applied to a gas meter, comprising:
[0032] The determination module is used to determine whether a connection signal or a command signal sent by the gas alarm is received within a first preset time period, so as to detect the disconnection of the gas alarm, wherein the frequency of the connection signal and the command signal are different.
[0033] The processing module is used to receive the level signal sent by the gas alarm during a second preset time period, detect the level signal, and determine the detection result. The level signal is determined by the gas alarm based on the detected gas concentration.
[0034] The processing module is also used to perform a valve closing operation and send an alarm message to the control system when the detection result is a first level signal. The first level signal is used to indicate that the gas concentration in the area where the gas alarm is located is abnormal.
[0035] In one possible implementation, the second preset time period includes multiple detection cycles. The processing module is further configured to detect the received level signal in each detection cycle according to the detection cycle, obtain the level information corresponding to each detection cycle, filter the level information corresponding to each detection cycle, and use the filtered level information as the detection result.
[0036] In one possible implementation, the determining module is used to determine whether a command signal has been received if no connection signal is received from the gas alarm; if so, it determines the target information corresponding to the command signal and performs corresponding control based on the target information; if not, it generates a first message and sends the first message to the control system, the first message being used to indicate that the gas alarm is disconnected from the gas meter.
[0037] In one possible implementation, if the command signal is a first command signal, the determining module is used to determine that the target information is communication information; if the command signal is a second command signal, the determining module is used to determine that the target information is valve closing information, wherein different command signals correspond to different frequencies.
[0038] In one possible implementation, the determining module is configured to, if the target information is communication information, send an interaction request to the control system based on the communication information; and if the target information is valve closing information, perform a valve closing operation based on the valve closing information.
[0039] Fourthly, embodiments of this application provide a gas meter control device, applied to a gas alarm, comprising:
[0040] The sending module is used to determine whether a second message sent by an external device is received within a first preset time period, so as to determine whether to send a connection signal or a command signal to the gas meter, wherein the frequency of the connection signal and the command signal are different;
[0041] The detection module is used to continuously detect the gas concentration in the area and determine whether the gas concentration is abnormal.
[0042] The detection module is also used to issue an alarm when the gas concentration is abnormal, and to send a first level signal to the gas meter within a second preset time period. The first level signal is used to indicate that the gas concentration in the area where the gas alarm is located is abnormal.
[0043] In one possible implementation, the sending module is further configured to determine whether a second message sent by an external device is received; if so, then according to the second message, a command signal corresponding to the second message is sent to the gas meter within a first preset time period, wherein different second messages correspond to command signals of different frequencies, and the command signals are used to instruct the gas meter to perform corresponding control; if not, then a connection signal is sent to the gas meter within the first preset time period, and the connection signal is used to instruct the gas alarm to connect to the gas meter.
[0044] Fifthly, embodiments of this application provide an electronic device, including: a memory and a processor;
[0045] The memory stores computer-executed instructions;
[0046] The processor executes computer execution instructions stored in the memory, causing the processor to perform the first aspect and / or various possible implementations of the first aspect and the second aspect and / or various possible implementations of the second aspect.
[0047] In a sixth aspect, embodiments of this application provide a computer-readable storage medium storing computer-executable instructions, which, when executed by a processor, are used to implement the first aspect and / or various possible implementations of the first aspect and the second aspect and / or various possible implementations of the second aspect.
[0048] The gas meter control method, apparatus, equipment, and medium provided in this application monitor the connection status between the gas meter and the gas alarm by receiving a connection signal or command signal sent by the gas alarm during a first preset time period of the signal transmission cycle. This allows the control system to promptly ascertain the connection status between the gas alarm and the gas meter, providing a reference for staff to understand the installation rate of gas alarms. Receiving an electrical level signal sent by the gas alarm during a second preset time period of the signal transmission cycle enables alarm detection. By receiving connection signals or command signals and electrical level signals at different times of the signal transmission cycle, compatibility with older meters using two-wire connections is achieved. Attached Figure Description
[0049] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.
[0050] Figure 1 This is a schematic diagram of a gas exceedance alarm system.
[0051] Figure 2 A flowchart illustrating a gas meter control method provided in this application embodiment. Figure 1 ;
[0052] Figure 3 A flowchart illustrating a gas meter control method provided in this application embodiment. Figure 2 ;
[0053] Figure 4 A connection diagram of a gas alarm and a gas meter provided in an embodiment of this application;
[0054] Figure 5 A flowchart illustrating a gas meter control method provided in this application embodiment. Figure 3 ;
[0055] Figure 6 A schematic diagram comparing the output signal waveforms of a gas alarm and a conventional alarm provided in this application embodiment;
[0056] Figure 7 A schematic diagram of the structure of a gas meter control device provided in this application embodiment. Figure 1 ;
[0057] Figure 8 A schematic diagram of the structure of a gas meter control device provided in this application embodiment. Figure 2 ;
[0058] Figure 9 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application.
[0059] The accompanying drawings illustrate specific embodiments of this application, which will be described in more detail below. These drawings and descriptions are not intended to limit the scope of the concept in any way, but rather to illustrate the concept of this application to those skilled in the art through reference to particular embodiments. Detailed Implementation
[0060] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numbers in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this application. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this application as detailed in the appended claims.
[0061] The terms “first,” “second,” “third,” “fourth,” etc. (if present) in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a particular order or sequence. It should be understood that such data can be interchanged where appropriate so that embodiments of the invention described herein can be implemented, for example, in orders other than those illustrated or described herein. Furthermore, the terms “comprising” and “having,” and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, products, or apparatus.
[0062] It should be noted that, in the embodiments of this application, the terms "exemplary" or "for example" are used to indicate examples, illustrations, or descriptions. Any embodiment or design scheme described as "exemplary" or "for example" in this application should not be construed as being more preferred or advantageous than other embodiments or design schemes. Specifically, the use of terms such as "exemplary" or "for example" is intended to present the relevant concepts in a specific manner.
[0063] Gas meter alarms detect the concentration of gas in the environment. When the gas alarm detects that the concentration of gas in the environment exceeds the standard, it will sound an audible and visual alarm to remind people to take safety measures. The gas meter will automatically shut off the valve to protect the equipment, thereby preventing various accidents caused by gas leaks.
[0064] Figure 1 This is a schematic diagram of a gas over-limit alarm system, such as... Figure 1 As shown, the gas over-limit alarm system includes a gas meter 11, a gas alarm 12, and a control system 13. The gas meter 11 is connected to the gas alarm 12; the gas alarm 12 is communicatively connected to the control system 13; and the gas meter 11 is communicatively connected to the control system 13.
[0065] The gas alarm 12 continuously monitors the gas concentration in the area. When the ambient concentration exceeds the standard, the gas meter 11 receives an alarm signal from the gas alarm 12. The gas meter 11 interacts with the control system 13 at fixed time intervals.
[0066] Based on the above scenarios, it is clear that in existing technologies, gas meters and gas alarms are mostly connected by two wires. The control system cannot monitor the connection status between the gas meter and the gas alarm. When the gas alarm does not sound, the control system cannot determine whether the connection between the gas meter and the gas alarm is broken or whether the gas alarm itself is not sounding. Adding signal lines could diversify the output signal and monitor the connection status between the gas meter and the gas alarm, but this increases hardware costs and is incompatible with older two-wire connected meters. Alternatively, wireless methods such as Bluetooth could be used to monitor the connection status, but Bluetooth connections are incompatible with older two-wire connected meters that lack a Bluetooth module.
[0067] The gas meter control method provided in this application connects the gas meter and the gas alarm via two wires, solving the problem of increased hardware costs caused by the increased diversity of signal output due to multi-wire connections. By monitoring the connection status between the gas meter and the gas alarm through the signal received by the gas meter in a first preset time period, and receiving the level signal sent by the gas alarm based on the detected gas concentration in a second preset time period, this method solves the problem of not being able to determine whether the gas meter and gas alarm are not connected or whether the gas alarm is not sounding, which is caused by uncertainty about whether the gas meter and gas alarm are connected, as well as the problem of incompatibility with old meters with two-wire connections.
[0068] The technical solution of this application and how it solves the above-mentioned technical problems will be described in detail below with specific embodiments. These specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments. The embodiments of this application will be described below with reference to the accompanying drawings.
[0069] Figure 2 A flowchart illustrating a gas meter control method provided in this application embodiment. Figure 1 The execution entity in this embodiment may be, for example, such as... Figure 1 The gas meter shown is as follows: Figure 2 As shown, the method includes:
[0070] S201. Within the first preset time period, determine whether a connection signal or instruction signal sent by the gas alarm is received, so as to detect the disconnection of the gas alarm.
[0071] The first preset time period is used to indicate the first fixed time period in the signal transmission cycle; the command signal is used to indicate the corresponding signal sent by the gas alarm based on the command issued by the control system. The connection signal and the command signal have different frequencies. The interface for receiving signals of the gas meter preferably uses an interface with interrupt and pulse counting functions.
[0072] For example, the first preset time period is the first fixed time period t1 in the signal transmission cycle T; the command signal is a valve closing signal, a communication signal, a recharge signal, etc.; the frequency of the connection signal is, for example, 5Hz; the frequency of the command signal is, for example, 25Hz, 50Hz, etc.
[0073] During the first fixed period of each signal transmission cycle, if the gas meter receives a connection signal or command signal from the gas alarm, it indicates that the gas meter and the gas alarm are connected normally; if the gas meter does not receive a connection signal or command signal from the gas alarm, it indicates that the gas meter and the gas alarm are disconnected, thus realizing the detection of the gas alarm's disconnection.
[0074] S202. During the second preset time period, receive the level signal sent by the gas alarm, detect the level signal, and determine the detection result;
[0075] The second preset time period is used to indicate the second fixed time period in the signal transmission cycle; the level signal is determined by the gas alarm based on the detected gas concentration, and the detection result is used to indicate the level state of the level signal, including high level and low level.
[0076] For example, the second preset time period is the second fixed time period t2 in the signal transmission period T.
[0077] During the second fixed period of each signal transmission cycle, a level signal determined based on the detected gas concentration is received from the gas alarm.
[0078] Understandably, conventional alarms can also output alarm signals. The gas alarm provided in this application embodiment sends a command signal during a first preset time period and an alarm signal during a second preset time period in each signal transmission cycle. Therefore, the duration of the signal transmission cycle T needs to be greater than the duration of the first preset time period t1. In order to achieve compatibility between conventional alarms and the gas alarm provided in this application embodiment, the gas meter needs to detect the level signal of the conventional alarm within the duration of the second preset time period t2.
[0079] In one possible implementation, the specific process of detecting the level signal and determining the detection result is described in detail below:
[0080] The level signals are detected according to a preset duration; the detected n level signals are filtered, and the filtered level signals are used as the detection results.
[0081] The second preset time period includes n detection points.
[0082] By detecting the level signal according to a preset duration, the power consumption of the gas meter is reduced. Furthermore, multiple filtering confirmations improve the accuracy of the detection results.
[0083] Understandably, if the preset duration is t0 and the number of filtering iterations is n, the following relationship needs to be satisfied:
[0084] t2>n×t0
[0085] Where t2 is the second preset time period.
[0086] S203. If the detection result is a first-level signal, perform the valve closing operation and send an alarm message to the control system.
[0087] The first level signal is used to indicate that the gas concentration in the area where the gas alarm is located is abnormal, and the alarm information is used to instruct the gas meter to report the abnormal gas concentration in the area where the gas alarm is located to the control system.
[0088] If the level signal is the first level signal, it means that the gas alarm has detected an abnormal gas concentration. Therefore, the gas meter performs a valve closing operation and sends an alarm message to the control system to inform the control system that the gas concentration in the area where the gas alarm is located is abnormal.
[0089] If the gas alarm sounds, the gas meter should be used to promptly shut off the valve and notify the system so that staff can handle the situation in a timely manner.
[0090] The gas meter control method provided in this application monitors the connection status between the gas meter and the gas alarm by receiving a connection signal or command signal sent by the gas alarm during the first preset time period of the signal transmission cycle. This allows the control system to promptly ascertain the connection status between the gas alarm and the gas meter, providing a reference for staff to understand the installation rate of gas alarms. Receiving an electrical level signal sent by the gas alarm during the second preset time period of the signal transmission cycle enables alarm detection. By receiving connection signals or command signals and electrical level signals at different times of the signal transmission cycle, compatibility with older meters using two-wire connections is achieved.
[0091] Figure 3 A flowchart illustrating a gas meter control method provided in this application embodiment. Figure 2 In this embodiment Figure 2 Based on the embodiments, the specific process of determining whether a connection signal or command signal sent by the gas alarm is received to detect disconnection of the gas alarm is described in detail, such as... Figure 3 As shown, the method includes:
[0092] S301. If no connection signal is received from the gas alarm, determine whether a command signal has been received; if yes, proceed to step S302; if no, proceed to step S303.
[0093] The first message indicates that the gas alarm has disconnected from the gas meter, and the target information corresponds one-to-one with the command signal. For example, when the command signal is a recharge signal, the target information is the recharge information.
[0094] If a connection signal or command signal is received from the gas alarm within the first preset time period, it indicates that the gas alarm and the gas meter are connected.
[0095] If no connection signal is received from the gas alarm within the first preset time period, it cannot be determined whether the gas alarm and gas meter are connected, since the command signal is also sent from the gas alarm to the gas meter. Therefore, it is necessary to further determine whether the gas meter has received the command signal from the gas alarm.
[0096] If the gas meter receives a command signal from the gas alarm, it means that the gas meter and the gas alarm are connected; if the gas meter does not receive a command signal from the gas alarm, it means that the gas meter and the gas alarm are not connected.
[0097] If no connection signal is received from the gas alarm within the first preset time period, but a command signal is received from the gas alarm, the corresponding target information is determined according to the frequency of the command signal, and corresponding control is performed based on the target information, thereby improving the timeliness of command signal execution.
[0098] For example: the frequency of the recharge signal is 10Hz. When a 10Hz frequency instruction signal is received within the first preset time period, the target information corresponding to the 10Hz frequency instruction signal is determined to be recharge information, and the recharge operation is performed.
[0099] If no command signal is received from the gas alarm, a first message is generated and sent to the control system. The gas meter then sends a first message indicating a disconnection between the gas alarm and the gas meter to the control system. This improves the linkage between the gas meter, gas alarm, and control system, enabling monitoring of the connection status between the gas meter and gas alarm. The control system can promptly determine the connection status between the gas alarm and gas meter, providing a reference for staff to understand the installation rate of gas alarms.
[0100] S302. Determine the target information corresponding to the command signal, and perform corresponding control based on the target information;
[0101] S303. Generate the first message and send the first message to the control system.
[0102] In one possible implementation, the specific process of determining the target information corresponding to the above-mentioned instruction signal is described in detail: if the instruction signal is a first instruction signal, then the target information is determined to be communication information; if the instruction signal is a second instruction signal, then the target information is determined to be valve closing information.
[0103] The first command signal is used to indicate communication information; the second command signal is used to indicate valve closing information. Different command signals correspond to different frequencies.
[0104] The gas meter determines the target information corresponding to different command signals based on these different command signals.
[0105] For example: the first command signal is 25Hz and the second command signal is 50Hz. If the command signal is a 25Hz signal, the target information is determined to be communication information; if the command signal is a 50Hz signal, the target information is determined to be valve closing information.
[0106] In one possible implementation, the corresponding control is different depending on the target information. The corresponding control based on the target information includes: when the target information is communication information, sending an interaction request to the control system based on the communication information; when the target information is valve closing information, performing a valve closing operation based on the valve closing information.
[0107] Interaction requests are used to remotely interact with the control system.
[0108] When the target information is communication information, the gas meter sends an interaction request to the control system based on the communication information. After the interaction request is approved, the gas meter and the control system interact remotely. This enables the gas meter to receive system commands online, reducing the power consumption of the gas meter.
[0109] When the target information is valve closure information, the gas meter will perform a valve closure operation based on that information, thus improving the safety of gas usage.
[0110] In one possible implementation, depending on the application requirements, if the alarm needs to output more states, more signals of different frequencies can be defined to achieve different functions.
[0111] Figure 4 This is a connection diagram of a gas alarm and a gas meter provided in an embodiment of this application. The gas alarm continuously detects the gas concentration in the area, such as... Figure 4 As shown, if the gas alarm receives a second message from an external device, it sends a command signal corresponding to the second message to the gas meter within a first preset time period; if the gas alarm does not receive a second message from an external device, it sends a connection signal to the gas meter within the first preset time period, such as... Figure 4 As shown, different signals correspond to different frequencies. The gas meter determines whether the gas alarm is properly connected based on whether it receives an instruction signal or a connection signal within the first preset time period. If there is no proper connection, the gas alarm is notified to the control system that the gas meter is disconnected from the gas alarm.
[0112] Continue to refer to Figure 4 Under normal connection conditions between the gas meter and the gas alarm, during the second preset time period, when the gas alarm detects that the gas concentration exceeds the standard, it indicates an abnormal gas concentration, triggers an alarm, and closes switch S1. The gas meter, upon detecting the S1 closure, sends a first message to the control system, informing it that the gas concentration has exceeded the standard.
[0113] Continue to refer to Figure 4 When the gas meter and gas alarm are properly connected, if the gas concentration detected by the gas alarm is not excessive, it indicates that the gas concentration is normal. The gas alarm will not sound an alarm and will disconnect S1. The gas meter will detect the S1 disconnection information and determine that the gas concentration is normal based on this information.
[0114] The gas meter control method provided in this application realizes the monitoring of the connection status between the gas meter and the gas alarm by determining whether a command signal sent by the gas alarm is received within a first preset time period; when the gas meter is connected to the gas alarm but the gas alarm does not sound, it is determined that the gas alarm is not sounding at this time; the gas meter performs corresponding control according to the command signal, realizing the remote control of the gas meter.
[0115] Figure 5 A flowchart illustrating a gas meter control method provided in this application embodiment. Figure 3 The execution entity in this embodiment may be, for example, such as... Figure 1 The gas alarm shown is as follows: Figure 3 As shown, the method includes:
[0116] S501. Within the first preset time period, determine whether a second message sent by an external device is received, so as to determine whether to send a connection signal or a command signal to the gas meter.
[0117] The external devices include: control system and terminal devices; the second message is used to indicate command messages, such as valve closing commands, communication commands, etc.
[0118] Mains power supply lines typically have high voltage, and connecting or disconnecting mains power, or when appliances malfunction, can easily generate electrical sparks. Since gas meters are usually installed near gas pipelines, they are typically powered by batteries, which have a very low probability of generating sparks. Battery-powered gas meters usually actively send metering data to the control system according to preset rules, such as reporting to the control system at set times each day. To enable the control system to actively control the gas meter, keeping the battery-powered gas meter constantly online would result in high power consumption and rapid battery depletion. Gas alarms, on the other hand, are typically powered by mains power and maintain constant online functionality, capable of receiving commands from the system in real time. Therefore, the gas alarm acts as an intermediary, relaying secondary messages from the control system to the gas meter.
[0119] In one possible implementation, the specific process of determining whether a second message from an external device has been received, and sending a connection signal or command signal to the gas meter within a first preset time period based on the second message, is described in detail below:
[0120] Determine whether a second message from an external device has been received; if so, send a command signal corresponding to the second message to the gas meter within a first preset time period; if not, send a connection signal to the gas meter within the first preset time period.
[0121] Different second messages correspond to different command signals. The command signal is used to instruct the gas meter to perform the corresponding control; the connection signal is used to instruct the gas alarm to connect to the gas meter.
[0122] Determine whether a second message has been received from the control system or terminal device. If a second message has been received, then, within a first preset time period, send a command signal at a frequency corresponding to the second message to the gas meter; if no second message has been received from the control system or terminal device, then send a connection signal to the gas meter within the first preset time period. The connection signal could be, for example, 5Hz.
[0123] Understandably, during the first preset period of each signal transmission cycle, the gas alarm sends a command signal or connection signal to the gas meter, with different signals corresponding to different frequencies.
[0124] In one possible implementation, the second message includes a communication message and a valve-closing message. A detailed description is provided of sending a command signal corresponding to the second message to the gas meter within a first preset time period, based on the second message, including:
[0125] If the second message is a communication message, a first command signal is sent to the gas meter within a first preset time period based on the communication message;
[0126] The first command signal is used to instruct the gas meter to perform real-time remote interaction with the control system.
[0127] When the second message is a communication command, the gas alarm sends a first instruction signal at the frequency corresponding to the communication command to the gas meter within a first preset time period, based on the received communication command. For example, the frequency corresponding to the communication command can be 25Hz.
[0128] If the second message is a valve-closing message, a second command signal is sent to the gas meter within a first preset time period based on the valve-closing message.
[0129] The second command signal is used to instruct the gas meter to perform a valve-closing operation.
[0130] When the second message is a valve-closing command, the gas alarm sends a second instruction signal at the frequency corresponding to the valve-closing command to the gas meter within a first preset time period, based on the received valve-closing command. For example, the frequency corresponding to the valve-closing command can be 50Hz.
[0131] For example, when a user forgets to turn off the gas while out, they can remotely send a valve-closing command via a terminal device. The gas alarm will then send a second command signal of the corresponding frequency to the gas meter based on the received valve-closing command.
[0132] In one possible implementation, depending on the application requirements, if the alarm needs to output more states, more signals of different frequencies can be defined to achieve different functions.
[0133] S502. Continuously monitor the gas concentration in the area and determine whether the gas concentration is abnormal;
[0134] S503. In the event of abnormal gas concentration, an alarm is triggered, and a first-level signal is sent to the gas meter within a second preset time period.
[0135] The first level signal is used to indicate an abnormal gas concentration in the area where the gas alarm is located.
[0136] When the gas alarm detects that the concentration of gas in the environment reaches a preset alarm threshold, the gas alarm can emit a sharp and piercing alarm sound through a buzzer, or it can also emit an alarm by flashing an LED, and send a first level signal to the gas meter within a second preset time period. The first level signal can be, for example, a low level.
[0137] Understandably, when the gas concentration is normal, the gas alarm sends a second-level signal to the gas meter during a second preset time period. The second-level signal can be, for example, a high level.
[0138] Figure 6This diagram illustrates a comparison of the output signal waveforms of a gas alarm and a conventional alarm provided in this embodiment. Wherein, T is the signal transmission period; t1 is the first preset time period; t2 is the second preset time period; a high level indicates no alarm; a low level indicates an alarm. A represents the waveform of a conventional alarm when there is no alarm; B represents the waveform of a conventional alarm when there is an alarm; C represents the waveform of the gas alarm provided in this embodiment when there is no alarm, where the signal in time period t1 is a connection signal and the signal in time period t2 is a high-level signal; D represents the waveform of the gas alarm provided in this embodiment when there is an alarm, where the signal in time period t1 is a connection signal and the signal in time period t2 is a low-level signal; E represents the waveform of the gas alarm provided in this embodiment when there is no alarm but a command signal, where the signal in time period t1 of the 1st, 3rd, and 5th signal transmission periods T is a connection signal and the signal in time period t2 is a high-level signal.
[0139] like Figure 6 As shown, when the conventional alarm does not sound, it continuously outputs a high level, indicating that the gas meter and the gas alarm are not connected. At this time, it is impossible to determine whether the conventional alarm is not sounding because the gas alarm and the gas meter are not properly connected or because the gas concentration is normal. When the conventional alarm sounds, it indicates that the gas concentration is abnormal.
[0140] The gas alarm provided in this application, when there is no alarm, outputs a connection signal or command signal during time period t1, confirming that the reason the gas alarm is not alarming is because the gas concentration is normal, rather than because the gas alarm and gas meter are not properly connected. When there is an alarm, the gas alarm outputs a gas alarm signal during time period t2, indicating that the gas concentration is abnormal.
[0141] The gas meter control method provided in this application, upon receiving a second message from an external device, determines whether the second message has been received within a first preset time period. This determines whether to send a connection signal or a command signal to the gas meter, thus enabling monitoring of the connection status between the gas meter and the gas alarm. This allows the control system to promptly ascertain the connection status between the gas alarm and the gas meter, providing a reference for staff to understand the installation rate of gas alarms. Within a second preset time period, the gas alarm sends an electrical level signal based on the detected gas concentration for alarm detection. By receiving connection signals, command signals, or electrical level signals at different times during the signal transmission cycle, compatibility with older two-wire connected meters is achieved.
[0142] Figure 7 A schematic diagram of the structure of a gas meter control device provided in this application embodiment. Figure 1 ,like Figure 7 As shown, the gas meter control device 70 provided in this embodiment is applied to a gas meter and includes:
[0143] This application provides a gas meter control device, applied to a gas meter, including:
[0144] The determination module 701 is used to determine whether a connection signal or a command signal sent by the gas alarm is received within a first preset time period, so as to detect the disconnection of the gas alarm. The connection signal and the command signal have different frequencies.
[0145] The processing module 702 is used to receive the level signal sent by the gas alarm during the second preset time period, detect the level signal, and determine the detection result. The level signal is determined by the gas alarm based on the detected gas concentration.
[0146] The processing module 702 is also used to perform a valve closing operation when the detection result is a first level signal, and to send an alarm message to the control system. The first level signal is used to indicate that the gas concentration in the area where the gas alarm is located is abnormal.
[0147] In one possible implementation, the second preset time period includes multiple detection cycles. The processing module 702 is further configured to detect the received level signal in each detection cycle according to the detection cycle, obtain the level information corresponding to each detection cycle, filter the level information corresponding to each detection cycle, and use the filtered level information as the detection result.
[0148] In one possible implementation, the determining module 701 is used to determine whether a command signal has been received if no connection signal is received from the gas alarm; if so, it determines the target information corresponding to the command signal and performs corresponding control based on the target information; if not, it generates a first message and sends the first message to the control system, the first message being used to indicate that the gas alarm is disconnected from the gas meter.
[0149] In one possible implementation, if the command signal is a first command signal, the determining module 701 is used to determine that the target information is communication information; if the command signal is a second command signal, the determining module 701 is used to determine that the target information is valve closing information, wherein different command signals correspond to different frequencies.
[0150] In one possible implementation, the determining module 701 is used to send an interaction request to the control system based on the communication information when the target information is communication information; and to perform a valve closing operation based on the valve closing information when the target information is valve closing information.
[0151] The gas meter control device provided in this embodiment can execute the method provided in the above method embodiment. Its implementation principle and technical effect are similar, and will not be described in detail here.
[0152] Figure 8A schematic diagram of the structure of a gas meter control device provided in this application embodiment. Figure 2 ,like Figure 8 As shown, the gas meter control device 80 provided in this embodiment is applied to a gas alarm and includes:
[0153] The sending module 801 is used to determine whether a second message sent by an external device is received within a first preset time period, so as to determine whether to send a connection signal or a command signal to the gas meter, wherein the connection signal and the command signal have different frequencies;
[0154] The detection module 802 is used to continuously detect the gas concentration in the area and determine whether the gas concentration is abnormal.
[0155] The detection module 802 is also used to issue an alarm when the gas concentration is abnormal, and to send a first level signal to the gas meter within a second preset time period. The first level signal is used to indicate that the gas concentration in the area where the gas alarm is located is abnormal.
[0156] In one possible implementation, the sending module 801 is further configured to determine whether a second message sent by an external device has been received; if so, then according to the second message, a command signal corresponding to the second message is sent to the gas meter within a first preset time period, wherein different second messages correspond to command signals of different frequencies, and the command signals are used to instruct the gas meter to perform corresponding control; if not, then a connection signal is sent to the gas meter within the first preset time period, and the connection signal is used to instruct the gas alarm to connect to the gas meter.
[0157] The gas meter control device provided in this embodiment can execute the method provided in the above method embodiment. Its implementation principle and technical effect are similar, and will not be described in detail here.
[0158] Figure 9 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Figure 9 As shown, the electronic device 90 provided in this embodiment includes at least one processor 901 and a memory 902. Optionally, the device 90 further includes a communication component 903. The processor 901, memory 902, and communication component 903 are connected via a bus 904.
[0159] In a specific implementation, at least one processor 901 executes computer execution instructions stored in memory 902, causing at least one processor 901 to perform the above-described method.
[0160] The specific implementation process of processor 901 can be found in the above method embodiments, and its implementation principle and technical effect are similar. It will not be repeated here.
[0161] In the above embodiments, it should be understood that the processor can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), etc. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the method disclosed in this invention can be directly implemented by a hardware processor, or implemented by a combination of hardware and software modules within the processor.
[0162] The memory may include random access memory (RAM) and may also include non-volatile memory (NVM), such as at least one disk storage device.
[0163] The bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus, etc. Buses can be categorized as address buses, data buses, control buses, etc. For ease of illustration, the buses shown in the accompanying drawings are not limited to a single bus or a single type of bus.
[0164] This application also provides a computer program product, including a computer program that, when executed by a processor, implements the above-described method.
[0165] This application also provides a computer-readable storage medium storing computer-executable instructions, which, when executed by a processor, implement the above-described method.
[0166] The aforementioned readable storage medium can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk. The readable storage medium can be any available medium accessible to a general-purpose or special-purpose computer.
[0167] An exemplary readable storage medium is coupled to a processor, enabling the processor to read information from and write information to the readable storage medium. Of course, the readable storage medium can also be a component of the processor. The processor and the readable storage medium can reside in an Application Specific Integrated Circuit (ASIC). Alternatively, the processor and the readable storage medium can exist as discrete components in the device.
[0168] The division of units is merely a logical functional division; in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be indirect coupling or communication connection through some interfaces, devices, or units, and may be electrical, mechanical, or other forms.
[0169] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0170] In addition, the functional units in the various embodiments of the present invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.
[0171] If a function is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this invention, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of the various embodiments of this invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0172] Those skilled in the art will understand that all or part of the steps of the above-described method embodiments can be implemented by hardware related to program instructions. The aforementioned program can be stored in a computer-readable storage medium. When executed, the program performs the steps of the above-described method embodiments; and the aforementioned storage medium includes various media capable of storing program code, such as ROM, RAM, magnetic disks, or optical disks.
[0173] Finally, it should be noted that other embodiments of the invention will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This invention is intended to cover any variations, uses, or adaptations of the invention that follow the general principles of the invention and include common knowledge or customary techniques in the art not disclosed herein, and is not limited to the precise structures described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of the invention is limited only by the appended claims.
Claims
1. A gas meter control method, characterized by, Applied to a gas meter, the method includes: Within a first preset time period, it is determined whether a connection signal or a command signal sent by the gas alarm is received, so as to detect the disconnection of the gas alarm. The connection signal and the command signal have different frequencies. During the second preset time period, the gas alarm receives an electrical level signal and detects the signal to determine the detection result. The electrical level signal is determined by the gas alarm based on the detected gas concentration. If the detection result is a first-level signal, the valve is closed and an alarm message is sent to the control system. The first-level signal is used to indicate that the gas concentration in the area where the gas alarm is located is abnormal.
2. The method of claim 1, wherein, The step of detecting the level signal and determining the detection result includes: The level signal is detected according to a preset duration, and the second preset time period includes n detection points; The detected n level signals are filtered, and the filtered level signals are used as the detection results.
3. The method of claim 1, wherein, The step of determining whether a connection signal or command signal is received from the gas alarm to detect if the gas alarm is offline includes: If no connection signal is received from the gas alarm, determine whether a command signal has been received; If so, the target information corresponding to the instruction signal is determined, and corresponding control is performed based on the target information; If not, a first message is generated and sent to the control system. The first message is used to indicate that the gas alarm is disconnected from the gas meter.
4. The method of claim 3, wherein, Determining the target information corresponding to the instruction signal includes: If the command signal is the first command signal, then the target information is determined to be communication information; If the command signal is the second command signal, then the target information is determined to be valve closing information, wherein different command signals correspond to different frequencies.
5. The method of claim 4, wherein, The control based on the target information includes: If the target information is communication information, an interaction request is sent to the control system based on the communication information; If the target information is valve closing information, the valve closing operation is performed based on the valve closing information.
6. A gas meter control method characterized by, Applied to gas alarms, the method includes: Within a first preset time period, it is determined whether a second message sent by an external device is received, so as to determine whether to send a connection signal to the gas meter or forward an instruction signal corresponding to the second message, wherein the connection signal and the instruction signal have different frequencies; Continuously monitor the gas concentration in the area and determine whether the gas concentration is abnormal; In the event of an abnormal gas concentration, an alarm is triggered, and a first level signal is sent to the gas meter within a second preset time period. The first level signal is used to indicate that the gas concentration in the area where the gas alarm is located is abnormal.
7. The method of claim 6, wherein, The step of determining whether a second message has been received from an external device, and sending a connection signal or command signal to the gas meter within a first preset time period based on the second message, includes: Determine whether a second message sent by an external device has been received; If so, then according to the second message, a command signal corresponding to the second message is sent to the gas meter within a first preset time period. Different second messages correspond to command signals of different frequencies. The command signal is used to instruct the gas meter to perform corresponding control. If not, a connection signal is sent to the gas meter within the first preset time period. The connection signal is used to indicate that the gas alarm is connected to the gas meter.
8. A gas meter control apparatus, characterized by, Applied to gas meters, including: The determination module is used to determine whether a connection signal or a command signal sent by the gas alarm is received within a first preset time period, so as to detect the disconnection of the gas alarm, wherein the frequency of the connection signal and the command signal are different. The processing module is used to receive the level signal sent by the gas alarm during a second preset time period, detect the level signal, and determine the detection result. The level signal is determined by the gas alarm based on the detected gas concentration. The processing module is also used to perform a valve closing operation and send an alarm message to the control system when the detection result is a first level signal. The first level signal is used to indicate that the gas concentration in the area where the gas alarm is located is abnormal.
9. An electronic device, comprising: include: Memory, processor; The memory stores computer-executed instructions; The processor executes computer execution instructions stored in the memory, causing the processor to perform the method as described in any one of claims 1-7.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer-executable instructions, which, when executed by a processor, are used to implement the method as described in any one of claims 1-7.