A power line detection circuit and control method

By using a microcontroller and a current-limiting resistor to divide the voltage and determine the wiring status through a mains power connection detection circuit, the problem of not being able to determine the power supply connection status is solved, thus improving electrical safety.

CN114336567BActive Publication Date: 2026-05-12XIAMEN CHIPSUN SCIENCE & TECHNOLOGY CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
XIAMEN CHIPSUN SCIENCE & TECHNOLOGY CO LTD
Filing Date
2021-12-22
Publication Date
2026-05-12

AI Technical Summary

Technical Problem

Existing technologies cannot effectively determine the power supply wiring, posing a safety hazard.

Method used

Design a mains power connection detection circuit that uses a microcontroller, a first current-limiting resistor, and a second current-limiting resistor to generate a zero-point signal through voltage division. The microcontroller determines the connection status and provides feedback on the connection status via an indicator light.

Benefits of technology

It enables simple and low-cost judgment of the wiring status of sockets and home appliances, thus improving electrical safety.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114336567B_ABST
    Figure CN114336567B_ABST
Patent Text Reader

Abstract

The application relates to the technical field of circuit detection, in particular to a commercial power wiring detection circuit and a control method, which comprises a power module connected with commercial power and a detection module connected between the input end and the output end of the power module; the power ground end of the power module is connected with the input zero line; the detection module comprises a single-chip microcomputer, a first current-limiting resistor and a second current-limiting resistor; the input IO port of the single-chip microcomputer is connected with the commercial power input end through the second current-limiting resistor while being connected with the ground through the first current-limiting resistor; and the output end of the single-chip microcomputer is connected on the output end of the power module. The commercial power wiring detection circuit provided by the application is connected on a socket or a household appliance, the first current-limiting resistor and the second current-limiting resistor are used for detecting whether the single-chip microcomputer has zero point signal input through voltage division, so that the wiring state of the socket or the household appliance can be judged, the circuit structure is simple, the cost is low, and the application can be widely applied to various electronic devices to improve power safety.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of circuit testing technology, and in particular to a mains power connection detection circuit and control method. Background Technology

[0002] With societal development and advancements in intelligent devices, smart electronic products are becoming increasingly common, leading to higher demands for electrical safety. Particularly in household electricity use, household appliances can accumulate static electricity on their casings over time due to poor insulation or humid environments, potentially causing electric shock. Therefore, checking the grounding of appliance input lines is crucial.

[0003] For example, the power adapter socket disclosed in patent number CN201120210306.1 on January 18, 2012 includes a housing, a power supply circuit installed inside the housing, and an input socket installed on the side panel of the housing. An external AC power supply is connected to the power supply circuit through the input socket. It also includes a relay and at least one output socket. The coil of the relay is connected to the output terminal of the power supply circuit. The neutral / live wire terminal of the input socket is connected to the neutral / live wire terminal of the output socket. The normally open contact of the relay is connected in series between the neutral or live wire terminals of the input socket and the output socket. The output socket is installed on the housing.

[0004] The aforementioned patent allows for the convenient direct connection of the power input terminal of a computer peripheral device to the computer power supply. However, there is currently no effective way to judge and provide feedback on the power connection status, which poses certain safety hazards. Summary of the Invention

[0005] To address the shortcomings of the prior art in that it cannot determine the power supply wiring, the present invention provides a mains power wiring detection circuit, including a power module connected to the mains power and a detection module connected between the input and output terminals of the power module; the power supply ground terminal of the power module is connected to the input neutral line.

[0006] The detection module includes a microcontroller, a first current-limiting resistor, and a second current-limiting resistor. The microcontroller's input I / O port is grounded through the first current-limiting resistor and also connected to the mains input terminal through the second current-limiting resistor. The microcontroller's output terminal is connected to the output terminal of the power module.

[0007] In one embodiment, the mains input terminal is also connected to the power module via a rectifier unit and a filter unit.

[0008] In one embodiment, the rectifier unit is a diode D1 and the filter unit is a capacitor EC1.

[0009] In one embodiment, the detection module further includes an indicator light LED1 and a resistor R5. One end of the indicator light LED1 is connected to the output I / O port of the microcontroller, and the other end is grounded through the resistor R5.

[0010] In one embodiment, a capacitor C1 is also connected between the ground terminal and the output terminal of the microcontroller.

[0011] In one embodiment, the resistance values ​​of both the first current-limiting resistor and the second current-limiting resistor are not less than 10 MΩ.

[0012] In one embodiment, the first current-limiting resistor includes at least one set of resistors, and the second current-limiting resistor includes at least one set of resistors.

[0013] In one embodiment, when the first current-limiting resistor has several groups of resistors, the sum of the resistance values ​​of the several groups of resistors is not less than 10MΩ; when the second current-limiting resistor has several groups of resistors, the sum of the resistance values ​​of the several groups of resistors is not less than 10MΩ.

[0014] In one embodiment, when there are several groups of resistors for the first current-limiting resistor and the second current-limiting resistor, the sum of the resistance values ​​of the first current-limiting resistor is equal to the sum of the resistance values ​​of the second current-limiting resistor.

[0015] The present invention also provides a control method for a mains power connection detection circuit, which uses the mains power connection detection circuit as described above, and includes the following steps:

[0016] During the process of connecting the device to the mains power, if the microcontroller detects a zero-point signal input, it will determine that the wiring is incorrect; if the microcontroller detects no zero-point signal input, it will determine that the wiring is normal. The wiring status will be displayed by an indicator light.

[0017] Based on the above, compared with the prior art, the mains wiring detection circuit provided by the present invention is connected to the socket or household appliance. It uses the voltage division of the first current limiting resistor and the second current limiting resistor to generate a zero-point signal. By detecting whether the microcontroller has a zero-point signal input, it can make a judgment on the wiring status of the socket or household appliance. Its circuit structure is simple and the cost is low. It can be widely used in various electronic devices to protect the circuit and improve electrical safety.

[0018] Other features and beneficial effects of the invention will be set forth in the following description, and will be apparent in part from the description, or may be learned by practicing the invention. The objects and other beneficial effects of the invention can be realized and obtained by means of the structures particularly pointed out in the description, claims and drawings. Attached Figure Description

[0019] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort. Unless otherwise specified, the positional relationships shown in the drawings in the following description are based on the direction in which the components are drawn in the figure.

[0020] Figure 1 A circuit diagram of the mains power connection detection circuit provided for this invention; Detailed Implementation

[0021] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. The technical features designed in the different embodiments of the present invention described below can be combined with each other as long as they do not conflict with each other. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without creative effort are within the scope of protection of the present invention.

[0022] In the description of this invention, it should be noted that all terms used in this invention (including technical and scientific terms) have the same meaning as commonly understood by one of ordinary skill in the art to which this invention pertains, and should not be construed as limiting the invention; it should be further understood that the terms used in this invention should be understood to have the same meaning as those in the context of this specification and in the relevant field, and should not be understood in an idealized or overly formal sense, except as expressly defined in this invention.

[0023] This invention provides a mains power connection detection circuit, including a power module connected to mains power and a detection module connected between the input and output terminals of the power module; the power ground terminal of the power module is connected to the input neutral line; the detection module includes a microcontroller, a first current-limiting resistor, and a second current-limiting resistor, the microcontroller's input I / O port is grounded through the first current-limiting resistor and also connected to the mains power input terminal through the second current-limiting resistor, and the microcontroller's output terminal is connected to the output terminal of the power module.

[0024] In specific implementation, such as Figure 1As shown, the circuit includes a power supply module and a detection module. The power supply module can be selected with an appropriate power rating based on the specific load of the actual product. It is also necessary to ensure that the power supply grounding terminal is connected to the input neutral wire to facilitate detection of the power supply grounding status. The detection module includes a microcontroller, a first current-limiting resistor, and a second current-limiting resistor. The microcontroller model can be a conventional model based on the actual circuit requirements, such as the BYD BF7612CM microcontroller. It should be noted that both the first and second current-limiting resistors include at least one set of resistors, for example, [example resistor]. Figure 1 As shown, the first current-limiting resistor includes resistors R3 and R4, and the second current-limiting resistor includes resistors R1 and R2. The specific number and value of the resistors can be set according to actual needs.

[0025] The working principle of the detection circuit provided by this invention is as follows: when the power supply is connected to the product, the microcontroller will determine the connection status of the power supply's live wire, neutral wire, and ground wire based on whether there is a zero-point signal input at the first and second current-limiting resistors. Specifically, this can be divided into the following three cases:

[0026] 1. When the live wire, neutral wire, and ground wire are connected normally, the voltage across the second current-limiting resistor is pulled down to zero by the ground wire. Since the microcontroller's input I / O port is set to high impedance input, there is no zero-point signal input, which can be judged as normal wiring.

[0027] 2. When the live wire and neutral wire are connected correctly, but the ground wire is not connected, the voltage at the microcontroller input terminal is pulled high in the positive half-wave region of the current and pulled low in the negative half-wave region of the current. Therefore, the microcontroller input IO port will have a zero-point signal input, which can be judged as a wiring error.

[0028] 3. Reversing the live and neutral wires: When the microcontroller's ground terminal is connected to the live wire, two scenarios can be considered: If the ground wire is connected, there is no voltage difference across the second current-limiting resistor. In the positive half-wave region of the current, the current flows through the first current-limiting resistor, pulling the voltage at the microcontroller's input terminal high. In the negative half-wave region, the voltage at the microcontroller's input terminal is pulled low. Therefore, the microcontroller's input I / O port has a zero-point signal input, indicating a wiring error. If the ground wire is not connected, in the positive half-wave region of the current, the current flows through both the first and second current-limiting resistors, pulling the voltage at the microcontroller's input terminal high. In the negative half-wave region, the voltage at the microcontroller's input terminal is pulled low. Therefore, the microcontroller's input I / O port also has a zero-point signal input, indicating a wiring error.

[0029] In summary, a microcontroller can determine whether the wiring is correct by detecting whether there is a zero-point signal input. Among the wiring errors, there are no ground wire connected, the live wire and neutral wire are reversed, and there is neither a ground wire connected nor a live wire and neutral wire are reversed.

[0030] Preferably, since the certification standards for socket products require that the impedance of the live wire and neutral wire to ground be greater than 10MΩ, the resistance values ​​of both the first and second current-limiting resistors are not less than 10MΩ to ensure that the first and second current-limiting resistors can effectively limit current, prevent high voltage from damaging the microcontroller's I / O port, and ensure that the power withstand voltage of the resistors does not exceed the rated value. It should be noted that those skilled in the art can also select appropriate current-limiting resistor values ​​based on the actual product's impedance to ground requirements, and are not limited to 10MΩ.

[0031] Preferably, the first current-limiting resistor includes at least one set of resistors, and the second current-limiting resistor includes at least one set of resistors, but is not limited to using only one set of resistors. Similarly, in order to meet the certification standard that the impedance of the live wire and neutral wire to ground must be greater than 10MΩ, when the first current-limiting resistor has several sets of resistors, the sum of the resistance values ​​of the several sets of resistors shall not be less than 10MΩ; when the second current-limiting resistor has several sets of resistors, the sum of the resistance values ​​of the several sets of resistors shall not be less than 10MΩ.

[0032] Preferably, to ensure that the voltage division of the first current-limiting resistor and the second current-limiting resistor is consistent, when there are several groups of resistors for the first and second current-limiting resistors, the sum of the resistance values ​​of the first current-limiting resistors is equal to the sum of the resistance values ​​of the second current-limiting resistors. This setting can prevent inconsistent voltage division from causing the voltage to exceed the withstand voltage of the resistor, thereby causing resistor damage.

[0033] For example, the resistances R1 and R2 of the first current-limiting resistor and the resistances R3 and R4 of the second current-limiting resistor are all 7.5MΩ, satisfying that the sum of the resistance values ​​of the first current-limiting resistor is equal to the sum of the resistance values ​​of the second current-limiting resistor, and each is not less than 10MΩ.

[0034] Preferably, the mains input terminal is also connected to the power module through a rectifier unit and a filter unit. As a preferred embodiment, the rectifier unit is a diode D1 and the filter unit is a capacitor EC1.

[0035] In practice, the mains power input is converted into high-voltage DC through half-wave rectification and filtering by diode D1 and capacitor EC1, and then converted into low-voltage DC suitable for product use by the power module.

[0036] It should be noted that the specific components and connection methods of the rectifier unit and filter unit can be set according to the actual working requirements of the product, and all of them fall within the scope of existing technology that can be understood by those skilled in the art, and will not be elaborated here.

[0037] Preferably, the detection module further includes an indicator light LED1 and a resistor R5. One end of the indicator light LED1 is connected to the output I / O port of the microcontroller, and the other end is grounded through the resistor R5. When the microcontroller detects a zero-point signal input, it will control the indicator light LED1 to illuminate to provide feedback on the wiring status, thereby reminding the user of the wiring status of the equipment and helping the user to connect the wires correctly.

[0038] Preferably, a capacitor C1 is connected between the ground terminal and the output terminal of the microcontroller to serve as a filter. Of course, other filter circuits can also be used instead.

[0039] The present invention also provides a control method for a mains power connection detection circuit, which uses the mains power connection detection circuit as described above, and includes the following steps:

[0040] During the process of connecting the device to the mains power, if the microcontroller detects a zero-point signal input, it will determine that the wiring is incorrect; if the microcontroller detects no zero-point signal input, it will determine that the wiring is normal. The wiring status will be displayed by an indicator light.

[0041] In summary, compared with existing technologies, the mains power connection detection circuit provided by this invention is connected to a socket, household appliance, or other electronic product. It utilizes a voltage divider between a first and second current-limiting resistor to generate a zero-point signal. By detecting whether a microcontroller receives a zero-point signal, it determines the connection status of the socket, appliance, or other electronic product and converts the result into an indicator light display to inform the user of the device's connection status. Its circuit structure is simple, its cost is low, and it can be widely applied in various electronic devices to improve electrical safety, demonstrating promising application prospects.

[0042] Furthermore, those skilled in the art should understand that although many problems exist in the prior art, each embodiment or technical solution of the present invention can be improved in only one or a few aspects, without necessarily solving all the technical problems listed in the prior art or the background art simultaneously. Those skilled in the art should understand that any content not mentioned in a claim should not be construed as a limitation on that claim.

[0043] Although this document frequently uses terms such as power module, detection module, rectifier unit, and filter unit, the possibility of using other terms is not excluded. These terms are used merely for the convenience of describing and explaining the essence of the invention; interpreting them as any additional limitation would contradict the spirit of the invention. The terms "first," "second," etc. (if present) in the specification, claims, and accompanying drawings of the embodiments of the invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence.

[0044] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present invention.

Claims

1. A mains power connection detection circuit, characterized in that: It includes a power module that is connected to the mains power supply and a detection module connected between the input and output terminals of the power module; The power supply ground terminal of the power module is connected to the input neutral line; The detection module includes a microcontroller, a first current-limiting resistor, and a second current-limiting resistor. The microcontroller's input I / O port is grounded through the first current-limiting resistor and also connected to the mains input terminal through the second current-limiting resistor. The microcontroller's output terminal is connected to the output terminal of the power module. The microcontroller determines whether the wiring of the power module's live wire, neutral wire, and ground wire is correct based on whether there is a zero-point signal input through the first and second current-limiting resistors.

2. The mains power connection detection circuit according to claim 1, characterized in that: The mains input terminal is also connected to the power module through a rectifier unit and a filter unit.

3. The mains power connection detection circuit according to claim 2, characterized in that: The rectifier unit is a diode D1, and the filter unit is a capacitor EC1.

4. The mains power connection detection circuit according to claim 1, characterized in that: The detection module also includes an indicator light LED1 and a resistor R5. One end of the indicator light LED1 is connected to the output I / O port of the microcontroller, and the other end is grounded through the resistor R5.

5. The mains power connection detection circuit according to claim 1, characterized in that: A capacitor C1 is also connected between the ground terminal and the output terminal of the microcontroller.

6. The mains power connection detection circuit according to claim 1, characterized in that: The resistance values ​​of both the first current-limiting resistor and the second current-limiting resistor are not less than 10MΩ.

7. The mains power connection detection circuit according to claim 1, characterized in that: The first current-limiting resistor includes at least one set of resistors, and the second current-limiting resistor includes at least one set of resistors.

8. The mains power connection detection circuit according to claim 7, characterized in that: When the first current-limiting resistor has several groups of resistors, the sum of the resistance values ​​of the several groups of resistors shall not be less than 10MΩ; when the second current-limiting resistor has several groups of resistors, the sum of the resistance values ​​of the several groups of resistors shall not be less than 10MΩ.

9. The mains power connection detection circuit according to claim 7 or 8, characterized in that: When there are several sets of resistors for the first current-limiting resistor and the second current-limiting resistor, the sum of the resistance values ​​of the first current-limiting resistor is equal to the sum of the resistance values ​​of the second current-limiting resistor.

10. A control method for a mains power connection detection circuit, characterized in that: The mains power connection detection circuit as described in any one of claims 1-9 includes the following steps: During the process of connecting the device to the mains power, if the microcontroller detects a zero-point signal input, it will determine that the wiring is incorrect; if the microcontroller detects no zero-point signal input, it will determine that the wiring is normal. The wiring status will be displayed by an indicator light.