Reset control circuit and reset method
By using the low-level state detection and timing of the SDA pin in the I2C bus to generate a reset signal, the problem of reset pins increasing chip costs in the prior art is solved, and the system reset is simplified and power consumption is reduced.
Patent Information
- Application Number
- CN202310637818.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-05-31
- Publication Date
- 2024-12-03
AI Technical Summary
In the prior art, when realizing system reset, additional chips are needed to support reset pins, resulting in increased chip costs and it is difficult to effectively implement the power-up and down process of the system.
A reset control circuit is designed, using the serial data line SDA and serial clock line SCL of the I2C bus, and the low level state of the SDA pin is detected and timed through the controllable switch, reset detection circuit and resistor network. The level state lasts for a period of time, generating a reset signal to trigger the controller reset, avoiding the addition of additional pins and power-up again.
The system reset is realized without increasing chip cost, avoiding unnecessary power-up and down processes, simplifying reset operations, and reducing power consumption.
Smart Images

Figure CN119065477A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of reset circuits, and in particular to a reset control circuit and a reset method. Background Art
[0002] When the system needs to be reset, it is often necessary to power off the system and then power it on again. In actual situations, the process of powering on and off the system is often difficult to implement; For systems with a dedicated reset pin, the system can be reset simply by setting the pin to a valid level state. However, this requires leading the pin to the terminal device to facilitate the terminal device to operate it when a reset is required. This will increase the chip cost for chip systems with limited pins.
[0003] In summary, in the prior art, if the reset control is to be realized, the chip system of the system needs to be improved and additional chips need to be added. Summary of the invention
[0004] In view of the above problems, the present invention is proposed to provide a reset control circuit and a reset method that overcome the above problems or at least partially solve the above problems.
[0005] According to one aspect of the present invention, there is provided a reset control circuit, the control circuit comprising: a reset terminal, a reset controller, a serial data line SDA and a serial clock line SCL; The reset controller includes a controllable switch, a reset detection circuit, a fifth series resistor R5, a third resistor R3 and a fourth resistor R4; The movable end of the controllable switch is connected to the reset circuit, and the fixed end is connected to the power supply; The movable end contacts the fixed end, and the controllable switch is closed; One end of the fifth series resistor R5 is connected to the active end, and the other end is connected to the serial data line SDA; The reset detection circuit is connected to the serial data line SDA; One end of the third resistor R3 is connected to the serial data line SDA, and the other end is grounded; One end of the fourth resistor R4 is connected to the serial clock line SCL, and the other end is grounded.
[0006] Optionally, the reset terminal specifically includes: an NMOS tube, a sixth resistor R6 and a second resistor R2; The source of the NMOS tube is grounded, the drain is connected to the serial data line SDA, and the gate is connected to a reset control signal; One end of the sixth resistor R6 is connected to the serial data line SDA, and the other end is connected to the power supply system; One end of the second resistor R2 is connected to the power supply system, and the other end is connected to the serial clock line SCL.
[0007] Optionally, the resistance of the fifth series resistor R5 is 10k ohms.
[0008] Optionally, the reset detection circuit outputs a reset signal to the controller for resetting the controller.
[0009] The present invention also provides a reset method, which is applied to the reset control circuit described above, and the reset method comprises: Determine that the serial data line SDA pin is at a high level; Disconnect the controllable switch, and all timings are stopped and reset to zero; Determine that the serial data line SDA pin is at a low level; The reset detection circuit starts timing the low level state of the SDA pin of the serial data line to obtain the low level state time; Determining that the controllable switch is closed, and timing the closing time of the controllable switch; It is determined that the closing time of the controllable switch exceeds a closing time threshold t, and the controllable switch is opened.
[0010] Determine that the controllable switch is open, determine that the low level state time is equal to 3T / 4, and close the controllable switch, where T is the timing period; Determine that the low level state time is greater than 3T / 4, determine that the low level state time is greater than or equal to T, and generate a reset signal.
[0011] Optionally, the closing time threshold t is 30 ms.
[0012] Optionally, after generating the reset signal, the method further includes: triggering a controller reset.
[0013] Optionally, the timing period T is 2 seconds.
[0014] Optionally, the serial data line SDA pin is at a high level specifically when: the terminal is powered off or the serial data line SDA is disconnected from the terminal, the reset detection circuit will disconnect the controllable switch, and the timing will stop and be reset.
[0015] Optionally, after the closing time of the controllable switch exceeds the closing time threshold t, the method specifically includes: during the closing period of the controllable switch, a reset detection circuit performs real-time detection on the serial data line SDA pin, and disconnects the controllable switch after the closing time threshold t has passed.
[0016] The present invention provides a reset control circuit and a reset method, wherein the control circuit comprises: a reset terminal, a reset controller, a serial data line SDA and a serial clock line SCL; the reset controller comprises a controllable switch, a reset detection circuit, a fifth series resistor R5, a third resistor R3 and a fourth resistor R4; the active end of the controllable switch is connected to the reset circuit, and the fixed end is connected to the power supply; the active end contacts the fixed end, and the controllable switch is closed; one end of the fifth series resistor R5 is connected to the active end, and the other end is connected to the serial data line SDA; the reset detection circuit is connected to the serial data line SDA; one end of the third resistor R3 is connected to the serial data line SDA, and the other end is grounded; one end of the fourth resistor R4 is connected to the serial clock line SCL, and the other end is grounded. The direct reset detection circuit generates a reset controller signal to reset the controller.
[0017] The above description is only an overview of the technical solution of the present invention. In order to more clearly understand the technical means of the present invention, it can be implemented according to the contents of the specification. In order to make the above and other purposes, features and advantages of the present invention more obvious and easy to understand, the specific implementation methods of the present invention are listed below. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying creative work.
[0019] Figure 1 A reset control circuit diagram provided by an embodiment of the present invention; Figure 2 A flowchart of a reset method provided by an embodiment of the present invention. Implementation
[0020] The exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although the exemplary embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure 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 enable a more thorough understanding of the present disclosure and to fully convey the scope of the present disclosure to those skilled in the art.
[0021] The terms "comprises" and "having" and any variations thereof in the description embodiments, claims and drawings of the present invention are intended to cover non-exclusive inclusions, for example, including a series of steps or units.
[0022] The technical solution of the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments.
[0023] Reset control circuit such as Figure 1 As shown, a reset control circuit, the control circuit includes: a reset terminal, a reset controller, a serial data line SDA and a serial clock line SCL; The reset controller includes a controllable switch, a reset detection circuit, a fifth series resistor R5, a third resistor R3 and a fourth resistor R4; The movable end of the controllable switch is connected to the reset circuit, and the fixed end is connected to the power supply; The movable end contacts the fixed end, and the controllable switch is closed; One end of a fifth series resistor R5 is connected to the active end, and the other end is connected to the serial data line SDA; The reset detection circuit is connected to the serial data line SDA; One end of the third resistor R3 is connected to the serial data line SDA, and the other end is grounded; One end of the fourth resistor R4 is connected to the serial clock line SCL, and the other end is grounded.
[0024] The SDA pin is pulled up to VCC through a controllable switch in series with a 10k resistor. When the SDA reset signal needs to be detected, the controllable switch will be closed. After the detection is completed, the controllable switch will be disconnected. The reset detection circuit will detect the state of the SDA pin in real time and time the reset valid state (low level) of the SDA pin. Then, based on the detection result and the timing duration, it will be determined whether the controller needs to be reset. When the controller needs to be reset, the reset detection circuit outputs a reset signal to the controller to reset the controller.
[0025] The specific working principle and implementation steps are as follows: In the default state, the controllable switch on the SDA pin is in the disconnected state, and the reset detection circuit detects the state of the SDA pin in real time; In actual applications, the serial data line SDA is often pulled up to the VCC of the terminal device through the pull-up resistor provided by the terminal device. Therefore, in some special scenarios, such as when the terminal is powered off or SDA is disconnected from the terminal, the SDA pin will continue to be at a low level. In order to avoid the uninterrupted reset of the controller in these special cases, affecting the normal operation of the controller, a controllable switch and a 10k resistor are connected in series to the VCC end of the controller on the SDA pin: When the SDA pin is detected as a low level, the reset detection circuit closes the switch. When the switch is closed, if the SDA pin is still at a low level, it is considered that the SDA pin state at this time is generated by the reset control signal; when the switch is closed, if the SDA pin is still at a high level, it is considered that the SDA pin state at this time is not generated by the reset control signal.
[0026] Since the controller VCC is discharged through the pull-up circuit and the pull-down resistor during the closing of the controllable switch, the power consumption of the controller is increased. Therefore, in order to make a trade-off between power consumption and reset control detection, the controllable switch and detection logic are set as follows: When the reset detection circuit detects that the SDA pin is at a low level, the reset detection circuit starts timing; When the reset detection circuit detects that the SDA pin is at a high level, the controllable switch is disconnected and all timings are reset.
[0027] When the controllable switch is turned on, when the SDA pin low level state timing time is equal to 3T / 4, the reset detection circuit will close the controllable switch; T is 2s.
[0028] After the controllable switch is closed, the closing time of the controllable switch is counted. If it is closed and lasts for more than 30ms, the SDA pin is pulled up to the controller VCC through a 10K resistor. During the closing period of the controllable switch, the reset detection circuit detects the SDA pin in real time and disconnects the controllable switch after time t. If the SDA pin is at a high level within time t, it is considered that the terminal is powered off or SDA is disconnected from the terminal. The reset detection circuit will disconnect the controllable switch, the timing will stop and reset, otherwise the timing will continue.
[0029] If the SDA pin low level state timing is greater than or equal to time T, it is considered that a reset request signal is generated, triggering the controller to reset.
[0030] Beneficial effect: The present invention reuses the serial data line SDA pin of the I2C bus commonly present in common interconnected systems as a reset control pin. It only needs to continuously pull down the SDA pin to make it a low level for a period of time. After the reset detection circuit detects this phenomenon, it will generate a reset controller signal to reset the controller.
[0031] The controller can be reset without adding extra pins or powering on and off the controller.
[0032] The above specific implementation methods further illustrate the objectives, technical solutions and beneficial effects of the present invention in detail. It should be understood that the above are only specific implementation methods of the present invention and are not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.
Claims
1. A reset control circuit, It is characterized in that The control circuit comprises: a reset terminal, a reset controller, a serial data line SDA and a serial clock line SCL; The reset controller includes a controllable switch, a reset detection circuit, a fifth series resistor R5, a third resistor R3 and a fourth resistor R4; The movable end of the controllable switch is connected to the reset circuit, and the fixed end is connected to the power supply; The movable end contacts the fixed end, and the controllable switch is closed; One end of the fifth series resistor R5 is connected to the active end, and the other end is connected to the serial data line SDA; The reset detection circuit is connected to the serial data line SDA; One end of the third resistor R3 is connected to the serial data line SDA, and the other end is grounded; One end of the fourth resistor R4 is connected to the serial clock line SCL, and the other end is grounded.
2. A reset control circuit according to claim 1, It is characterized in that The reset terminal specifically includes: an NMOS tube, a sixth resistor R6 and a second resistor R2; The source of the NMOS tube is grounded, the drain is connected to the serial data line SDA, and the gate is connected to a reset control signal; One end of the sixth resistor R6 is connected to the serial data line SDA, and the other end is connected to the power supply system; One end of the second resistor R2 is connected to the power supply system, and the other end is connected to the serial clock line SCL.
3. A reset control circuit according to claim 1, It is characterized in that The resistance of the fifth series resistor R5 is 10k ohms.
4. A reset control circuit according to claim 1, It is characterized in that The reset detection circuit outputs a reset signal to the controller for resetting the controller.
5. A reset method, It is characterized in that Applied to a reset control circuit as described in claims 1-2 above, the reset method comprises: Determine that the serial data line SDA pin is at a high level; Disconnect the controllable switch, and all timings are stopped and reset to zero; Determine that the serial data line SDA pin is at a low level; The reset detection circuit starts timing the low level state of the SDA pin of the serial data line to obtain the low level state time; Determining that the controllable switch is closed, and timing the closing time of the controllable switch; It is determined that the closing time of the controllable switch exceeds a closing time threshold t, and the controllable switch is opened. Determine that the controllable switch is open, determine that the low level state time is equal to 3T / 4, and close the controllable switch, where T is the timing period; Determine that the low level state time is greater than 3T / 4, determine that the low level state time is greater than or equal to T, and generate a reset signal.
6. A resetting method according to claim 5, It is characterized in that The closing time threshold t is 30 ms.
7. A resetting method according to claim 5, It is characterized in that After generating the reset signal, the method further includes: triggering a controller reset.
8. A resetting method according to claim 5, It is characterized in that The timing period T is 2 seconds.
9. A resetting method according to claim 5, It is characterized in that The serial data line SDA pin is at a high level specifically when the terminal is powered off or the serial data line SDA is disconnected from the terminal, the reset detection circuit will disconnect the controllable switch, and the timing will stop and be reset.
10. A resetting method according to claim 5, It is characterized in that After the closing time of the controllable switch exceeds the closing time threshold t, the following steps are specifically performed: During the closing period of the controllable switch, the reset detection circuit performs real-time detection on the SDA pin of the serial data line, and opens the controllable switch after the closing time threshold t has passed.
