Anti-static interference valve circuit and valve circuit control method
By connecting the enable end of the valve control chip to the same power supply pin in the water meter valve control circuit, and using components such as unidirectional diodes and pull-up resistors, the signal instability caused by electrostatic interference is solved, and the circuit is improved The stability and anti-interference ability reduce power consumption.
Patent Information
- Application Number
- CN202411197864.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-29
- Publication Date
- 2024-12-13
AI Technical Summary
The water meter valve control circuit is susceptible to static interference, resulting in unstable signal, affecting the stability and increase power consumption of the driver chip.
A valve circuit with anti-static interference was designed. By connecting the enable end of the valve control chip and the power pin to the same power supply, and controlling the power supply on and off through the switch, the load of the main control chip and the valve control chip is reduced, and the load of the main control chip and valve control chip is increased. Circuit stability; use components such as unidirectional diodes and pull-up resistors to further resist static interference.
It effectively reduces the impact of electrostatic interference on the main control chip, improves the stability and anti-interference ability of the circuit, reduces power consumption, and prevents chip reset during electrostatic testing.
Smart Images

Figure CN119126622A_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present specification relate to the field of valve control technology, and more particularly to a valve circuit and a valve circuit control method for preventing electrostatic interference. Background Art
[0002] The valve control circuit of the water meter is an important part of the water meter system, which is responsible for controlling the on and off of the water flow. The valve control circuit mainly includes a control chip, a drive circuit and a valve. The control chip is used to receive signals from sensors or other input devices, and output corresponding control signals according to preset logical judgments. The drive circuit is used to convert the control signal output by the control chip into a current or voltage signal that can drive the valve to move. When the valve reaches the specified position during the movement, it will generate an in-place signal, which is used to enable the control chip to determine whether the valve is in place normally. However, the in-place signal is easily interfered during the transmission process, and the signal is unstable. When the drive circuit is interfered, it is also easy to interfere with the control chip, affecting the stability of the drive chip. Summary of the invention
[0003] The embodiments of the present specification provide a valve circuit and a valve circuit control method for preventing electrostatic interference, aiming to solve one or more of the above-mentioned problems and other potential problems.
[0004] In order to achieve the above objectives, the following technical solutions are provided: According to the first aspect of the present specification, there is provided an anti-static interference valve circuit, comprising a main control chip, a valve control chip and an actuator, wherein the input and output pins of the valve control chip are respectively connected to the main control chip and the actuator, and are used to control the forward or reverse rotation of the actuator based on the switch signal output by the main control chip, so that the valve is opened or closed; the in-position pin of the actuator is connected to the main control chip, and is used to feedback the open or closed state of the valve, and when the valve is in the open or closed position, the main control chip sends a stop signal to the valve control chip, and is characterized in that the enable end pin of the valve control chip and the power pin are connected to the same power supply, and the power supply is provided with a switch for controlling the on and off of the power supply, and the enable end of the main control chip is also connected to the power supply through the switch.
[0005] The anti-static interference valve circuit of the embodiment of the present specification connects the enable pin and the power pin of the valve control chip, and is connected to the same power supply as the enable pin of the main control chip. The on and off of the power supply is controlled by a switch so that no current passes through the chip when the main control chip and the valve control chip are not working, thereby reducing the load of the main control chip, reducing the circuit power consumption, and improving the stability of the entire circuit. The main control chip is not easily reset in the case of electrostatic test interference.
[0006] In some embodiments, a unidirectional diode is also included, the positive electrode of the unidirectional diode is connected to the main control chip, and the negative electrode of the unidirectional diode is connected to the in-place pin of the actuator; a first pull-up resistor is also provided between the in-place pin of the actuator and the main control chip.
[0007] In some embodiments, the switch includes a PMOS tube and a second pull-up resistor, the gate of the PMOS tube is connected to the enable pin of the valve control chip, the source of the PMOS tube is connected to the power supply, the drain of the PMOS tube is connected to the first pull-up resistor, and the second pull-up resistor is connected between the gate and source of the PMOS tube.
[0008] In some embodiments, the in-position pins of the actuator include an open in-position pin and a closed in-position pin, the first pull-up resistor provides a high level for the in-position pin, when the valve is in the open position, the open in-position pin becomes a low level, and when the valve is in the closed position, the closed in-position pin is grounded and becomes a low level; the port of the main control chip to which the in-position pin is connected is in input detection mode, and the level signal of the in-position pin is detected.
[0009] In some embodiments, a pull-down capacitor is provided between the in-place pin of the actuator and the main control chip.
[0010] In some embodiments, a parallel resistor for detecting valve voltage is connected between the ADC detection interface of the main control chip and the actuator.
[0011] In some embodiments, a judgment module is provided in the main control chip for judging whether the valve voltage is within a corresponding voltage range.
[0012] According to a second aspect of the present specification, a method for controlling a valve circuit for preventing electrostatic interference is provided. The method is implemented based on the above-mentioned valve circuit for preventing electrostatic interference, and the method includes: The main control chip obtains a valve switch instruction, and outputs a switch signal to the valve control chip based on the valve switch instruction; The valve control chip controls the switch to open after receiving the switch signal output by the main control chip, and controls the actuator to rotate forward or reverse based on the switch signal; The actuator controls the valve to open when it rotates forward, and controls the valve to close when it rotates reversely. When the valve is fully opened, the actuator feeds back a fully opened signal to the main control chip, and when the valve is fully closed, the actuator feeds back a fully closed signal to the main control chip. After receiving the fully opened signal or the fully closed signal, the main control chip outputs a stop signal to the valve control chip.
[0013] In some embodiments, the main control chip detects the valve voltage and determines whether the valve is in place based on the valve voltage. When the judgment result is inconsistent with the result indicated by the open position signal or the closed position signal, the main control chip controls the valve control chip to cut off power and issues a warning. BRIEF DESCRIPTION OF THE DRAWINGS
[0014] By reading the following detailed description with reference to the accompanying drawings, the above and other objects, features and advantages of the embodiments of the present specification will become readily understood. In the accompanying drawings, several embodiments of the present specification are shown by way of example and not limitation.
[0015] Figure 1 A circuit diagram of a valve circuit for preventing electrostatic interference according to an embodiment of the present specification is shown; Figure 2 A circuit diagram of a switch according to an embodiment of the present specification is shown; Figure 3 A flow chart of a valve circuit control method for preventing electrostatic interference according to an embodiment of the present specification is shown.
[0016] 1-main control chip, 2-valve control chip, 3-controller, 41-first pull-up resistor, 42-second pull-up resistor, 43-unidirectional diode, 5-switch.
[0017] In the various drawings, the same or corresponding reference numerals represent the same or corresponding parts. DETAILED DESCRIPTION
[0018] The preferred embodiments of the present specification will be described in more detail below with reference to the accompanying drawings. Although the preferred embodiments of the present specification are shown in the accompanying drawings, it should be understood that the present specification can be implemented in various forms and should not be limited by the embodiments set forth herein. On the contrary, these embodiments are provided to make the present specification more thorough and complete, and to fully convey the scope of the present specification to those skilled in the art.
[0019] The term "including" and its variations used in this document represent open inclusion, that is, "including but not limited to". Unless otherwise stated, the term "or" means "and / or". The term "based on" means "based at least in part on". The terms "an example embodiment" and "an embodiment" mean "at least one example embodiment". The term "another embodiment" means "at least one other embodiment". Terms such as "upper", "lower", "front", and "rear" indicating placement or positional relationships are based on the orientation or positional relationships shown in the drawings, and are only for the convenience of describing the principles of this specification, and do not indicate or imply that the referred elements must have a specific orientation, be constructed or operate in a specific orientation, and therefore should not be understood as limitations on this specification.
[0020] The following is a detailed description of an anti-static interference valve circuit according to an embodiment of the present specification in conjunction with the accompanying drawings. Figure 1 As shown, the circuit includes a main control chip 1, a valve control chip 2 and an actuator 3. The input and output pins of the valve control chip 2 are respectively connected to the main control chip 1 and the actuator 3, and are used to control the actuator 3 to rotate forward or reverse based on the switch signal output by the main control chip 1, so that the valve is opened or closed; the in-position pin of the actuator 3 is connected to the main control chip 1, and is used to feedback the open or closed state of the valve. When the valve is in the open or closed position, the main control chip 1 sends a stop signal to the valve control chip 2, and the enable end pin of the valve control chip 2 is connected to the same power supply as the power supply pin. The power supply is provided with a switch for controlling the on and off of the power supply, and the enable end of the main control chip 1 is also connected to the power supply through the switch 5.
[0021] Among them, the main control chip 1 is a single-chip microcomputer, the forward output pin OUTA of the main control chip 1 is connected to the forward input pin IA of the valve control chip 2, the reverse output pin OUTB of the main control chip 1 is connected to the reverse input pin IB of the valve control chip 2, the positive output pin DRV+ of the valve control chip 2 is connected to the forward pin of the actuator 3, and the negative output pin DRV- of the valve control chip 2 is connected to the reverse pin of the actuator 3. The levels of the positive output pin DRV+ and the forward output pin OUTA are consistent, and the levels of the negative output pin DRV- and the reverse output pin OUTB are consistent. When the valve needs to be closed in the forward direction, the forward output pin OUTA of the main control chip 1 outputs a high level, and the reverse output pin OUTB outputs a low level, thereby causing the positive output pin DRV+ to output a high level to the forward pin, and the negative output pin DRV- to output a low level to the reverse pin, and the actuator 3 controls the valve to rotate forward until the valve is fully closed and stops rotating forward. Similarly, when the valve needs to be reversed and opened, the forward output pin OUTA outputs a low level, and the reverse output pin OUTB outputs a high level, controlling the valve to reverse until the valve is fully opened and stops reversing. The main control chip 1 is connected to the in-position pin of the actuator 3, and the level signal of the in-position pin is used to determine whether the valve is fully opened or fully closed. The in-position pins include an open in-position pin and a closed in-position pin. Before the valve rotates, the main control chip 1 provides a pull-up high level for the in-position pins. When the valve is in the open position, the open in-position pin is grounded through the internal spring of the actuator 3, and the open in-position pin is pulled down to a low level. When the main control chip 1 detects that the open in-position pin is at a low level, it determines that the valve is in the open position. Similarly, when the valve is in the closed position, the closed in-position pin is grounded, and the closed in-position pin is pulled down to a low level, and the main control chip 1 determines that the valve is in the closed position. When the main control chip 1 detects that the valve is in the open position or the closed position, the forward output pin OUTA and the reverse output pin OUTB both output a low level, which can control the valve to stop.
[0022] The embodiment of this specification connects the enable pin nSLEEP of the valve control chip 2 and the power pin VCC, and is connected to the same power supply as the enable pin OUTEN of the main control chip 1. The on and off of the power supply is controlled by the switch 5, so that no current passes through the chip when the main control chip 1 and the valve control chip 2 are not working, thereby reducing the load of the main control chip 1, reducing the circuit power consumption, and improving the stability of the entire circuit. The main control chip 1 is not easily reset under the interference of electrostatic testing.
[0023] A unidirectional diode 43 is connected between the main control chip 1 and the in-place pin of the actuator 3. Specifically, the positive electrode of the unidirectional diode 43 is connected to the main control chip 1, and the negative electrode of the unidirectional diode 43 is connected to the in-place pin of the actuator 3. During the electrostatic test, the unidirectional diode 43 can shield the interference of the actuator 3 on the main control chip 1, and further prevent the main control chip 1 from resetting. Since the existing connection port between the main control chip 1 and the in-place pin needs to be set to input mode to detect the level of the in-place pin, the output capacity is poor, and it is impossible to effectively provide a pull-up high level for the in-place pin, and the ability to resist external interference is poor. Therefore, it is necessary to set a first pull-up resistor 41 between the in-place pin of the actuator 3 and the main control chip 1 to provide a stable pull-up high level signal, and cooperate with the unidirectional diode 43 to resist the electrostatic interference of the circuit. The additional pull-up high level signal is provided to further reduce the load of the main control chip 1 and increase the stability and anti-interference ability of the circuit. In addition, a pull-down capacitor is provided between the in-position pin of the actuator 3 and the main control chip 1 to further eliminate external interference and improve the quality and stability of the transmission signal.
[0024] Specifically, the pull-up resistor is also connected to the power supply through the switch 5 to ensure the working consistency of each part of the circuit and reduce power consumption. Figure 2 As shown, the switch 5 includes a PMOS tube and a second pull-up resistor 42, the gate of the PMOS tube is connected to the enable pin of the valve control chip 2, the source of the PMOS tube is connected to the power supply, the drain of the PMOS tube is connected to the first pull-up resistor 41, and the second pull-up resistor 42 is connected between the gate and the source of the PMOS tube. The second pull-up resistor 42 ensures that when the valve control chip 2 is not working, the gate of the PMOS is at a high level, and when the enable terminal of the valve control chip 2 outputs a low level, the gate of the PMOS tube becomes a low level, the PMOS is turned on, and the power supply starts to supply power.
[0025] In addition to judging whether the valve is fully opened or fully closed by the level signal of the in-position pin of the actuator 3, the main control chip 1 can also directly detect and judge the in-position state of the valve by the ADC detection method. A parallel resistor for detecting the valve voltage is connected between the ADC detection interface of the main control chip 1 and the actuator 3. When the valve is actuated, a current is generated, and the sampling voltage can be measured by the parallel resistor with a known resistance value and the current. Since the current when the valve is blocked and fully opened or fully closed is much larger than when it is rotating, the judgment circuit can be used to judge whether the sampling voltage reaches the threshold voltage to judge whether the valve is in position. The judgment circuit is a comparator or other forms of circuits.
[0026] The embodiment of this specification also discloses a valve circuit control method for preventing electrostatic interference. The method is implemented based on the above-mentioned valve circuit for preventing electrostatic interference. Figure 3 As shown, the method includes: S1, the main control chip 1 obtains a valve switch instruction, and outputs a switch signal to the valve control chip 2 based on the valve switch instruction; S3, the valve control chip 2 controls the switch 5 to open after receiving the switch signal output by the main control chip 1, and controls the actuator 3 to rotate forward or reverse based on the switch signal; S5, the actuator 3 controls the valve to open by forward rotation, and controls the valve to close by reverse rotation. When the valve is fully opened, the actuator 3 feeds back a fully opened signal to the main control chip 1, and when the valve is fully closed, the actuator 3 feeds back a fully closed signal to the main control chip 1; S7. After receiving the fully opened signal or the fully closed signal, the main control chip 1 outputs a stop signal to the valve control chip 2.
[0027] In step S5, when the main control chip 1 receives both the open position signal and the close position signal, it determines that the signal is abnormal, outputs a stop signal to the valve control chip 2, and issues a warning. In step S7, if the main control chip 1 does not receive the open position signal or the close position signal within a period of time after outputting the switch signal to the valve control chip 2, it also determines that the signal is abnormal, outputs a stop signal to the valve control chip 2, and issues a warning. This process can be implemented by hardware such as a timer. The timing starts when the switch signal is output, and the timing is reset when the open position signal or the close position signal is received. When the timing time exceeds the time threshold, the main control chip 1 determines that the signal is abnormal.
[0028] When the main control chip 1 determines the valve in-place status through the in-place pin and through the ADC detection method, the two judgment methods can verify each other. The main control chip 1 detects the valve voltage and determines whether the valve is in-place based on the valve voltage. When the judgment result is inconsistent with the result indicated by the open in-place signal or the closed in-place signal, the main control chip 1 controls the valve control chip 2 to cut off power and issue a warning.
[0029] Although several specific implementation details are included in the above discussion, these should not be interpreted as limiting the scope of this specification. Certain features described in the context of separate embodiments may also be implemented in a single implementation in combination. Conversely, various features described in the context of a single implementation may also be implemented in multiple implementations individually or in any suitable sub-combination.
[0030] Although the subject matter has been described in language specific to structural features and / or methodological logical actions, it should be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or actions described above. On the contrary, the specific features and actions described above are merely example forms of implementing the claims.
[0031] The embodiments of the present specification have been described above, and the above description is exemplary, not exhaustive, and is not limited to the disclosed embodiments. Many modifications and changes will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the described embodiments. The selection of terms used herein is intended to best explain the principles of the embodiments, practical applications, or technical improvements in the market, or to enable other persons of ordinary skill in the art to understand the embodiments disclosed herein.
Claims
1. An anti-static interference valve circuit, comprising a main control chip (1), a valve control chip (2) and an actuator (3), wherein the input and output pins of the valve control chip (2) are respectively connected to the main control chip (1) and the actuator (3), and are used to control the actuator (3) to rotate forward or reverse based on a switch signal output by the main control chip (1), so that the valve is opened or closed; the in-position pin of the actuator (3) is connected to the main control chip (1), and is used to feedback the open or closed position of the valve, and when the valve is in the open or closed position, the main control chip (1) sends a stop signal to the valve control chip (2). It is characterized in that The enable pin of the valve control chip (2) and the power pin are connected to the same power supply, and the power supply is provided with a switch (5) for controlling the on and off of the power supply. The enable terminal of the main control chip (1) is also connected to the power supply via the switch (5).
2. The circuit according to claim 1, It is characterized in that It also comprises a unidirectional diode (43), the positive electrode of the unidirectional diode (43) being connected to the main control chip (1), and the negative electrode of the unidirectional diode (43) being connected to the in-place pin of the actuator (3); and a first pull-up resistor (41) being provided between the in-place pin of the actuator (3) and the main control chip (1).
3. The circuit according to claim 1, It is characterized in that The switch (5) comprises a PMOS tube and a second pull-up resistor (42), the gate of the PMOS tube is connected to the enable pin of the valve control chip (2), the source of the PMOS tube is connected to the power supply, the drain of the PMOS tube is connected to the first pull-up resistor (41), and the second pull-up resistor (42) is connected between the gate and the source of the PMOS tube.
4. The circuit according to claim 2, It is characterized in that The in-position pins of the actuator (3) include an open in-position pin and a closed in-position pin. The first pull-up resistor (41) provides a high level for the in-position pins. When the valve is in the open position, the open in-position pin becomes a low level. When the valve is in the closed position, the closed in-position pin is grounded and becomes a low level. The port of the main control chip (1) to which the in-position pins are connected is in input detection mode, and the level signal of the in-position pins is detected.
5. The circuit according to claim 1, It is characterized in that A pull-down capacitor is provided between the in-position pin of the actuator (3) and the main control chip (1).
6. The circuit according to claim 4, It is characterized in that A parallel resistor for detecting valve voltage is connected between the ADC detection interface of the main control chip (1) and the actuator (3).
7. The circuit according to claim 6, It is characterized in that The main control chip (1) is provided with a judgment module for judging whether the valve voltage is within a corresponding voltage range.
8. A valve circuit control method for preventing electrostatic interference, the method being implemented based on the circuit of claim 6. It is characterized in that include: The main control chip (1) obtains a valve switch instruction, and outputs a switch signal to the valve control chip (2) based on the valve switch instruction; The valve control chip (2) controls the switch (5) to open after receiving the switch signal output by the main control chip (1), and controls the actuator (3) to rotate forward or reverse based on the switch signal; The actuator (3) controls the valve to open when it rotates forward, and controls the valve to close when it rotates reversely. When the valve is fully opened, the actuator (3) feeds back a fully opened signal to the main control chip (1), and when the valve is fully closed, the actuator (3) feeds back a fully closed signal to the main control chip (1); After receiving the fully opened signal or the fully closed signal, the main control chip (1) outputs a stop signal to the valve control chip (2).
9. The method according to claim 8, It is characterized in that The main control chip (1) detects the valve voltage and determines whether the valve is in place based on the valve voltage. When the determination result is inconsistent with the result indicated by the open position signal or the closed position signal, the main control chip (1) controls the valve control chip (2) to cut off power and issues a warning.
