Single-button switch control circuit with state memory function

By using a combination of magnetic holder and H-bridge circuit in the single-key switch control circuit, the problem of not being able to remember the state before power outage in the prior art is solved, and the function of memorizing and restoring the switch state after an external power supply is interrupted is realized. The circuit structure is simple and the cost is low.

CN119906404APending Publication Date: 2025-04-29TAIYUAN AERO INSTR
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411816456.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-11
Publication Date
2025-04-29

AI Technical Summary

Technical Problem

In the prior art, the single-key switch control circuit cannot effectively remember the pre-powered state after the external power supply is interrupted, and requires continuous power supply or memory recording information.

Method used

The state memory circuit including a magnetic holder and an H-bridge circuit is adopted, and the state characteristics of the magnetic holder are maintained after power-off, and combined with the positive and negative pole flip characteristics of the H-bridge circuit, the coil can still be kept in a normally closed or normally open state after power-off.

Benefits of technology

It realizes the switching state before power outage after the external power supply is interrupted, and continues to work according to the state before power outage after the power supply is restored. The circuit structure is simple and the cost is low.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119906404A_ABST
    Figure CN119906404A_ABST
Patent Text Reader

Abstract

The invention provides a single-key switch control circuit with a state memory function, and belongs to the technical field of electronics, the single-key switch control circuit specifically comprises a single-key switch circuit and a state memory circuit, the state memory circuit comprises a magnetic retainer and current turnover circuits connected to the two ends of a coil of the magnetic retainer, and the current turnover circuits are connected with the magnetic retainer. A contact switch of the magnetic retainer is connected to a voltage input end of the single-key switch circuit, the current overturning circuit is used for overturning current flowing through a coil of the magnetic retainer, so that the contact switch is closed or opened, and the state of the contact switch is kept through a permanent magnet of the magnetic retainer; the normally-closed or normally-open state can still be kept after the coil is powered off, and the state of the switch before power failure can be memorized after the voltage input end is interrupted. Through the processing scheme provided by the invention, the state memory function can be realized without maintaining power supply for the switch control circuit or recording information by the memory, the circuit structure is simple, and the cost is reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of electronic technology, and in particular to a single-key switch control circuit with a state memory function. Background Art

[0002] In the prior art, the MCU is often used to record the working status before power failure in a non-volatile memory. After power is restored, the MCU first reads the information recorded in the memory and then decides whether to start the product or keep it in standby mode. This technology requires the MCU to be equipped with an energy storage device to ensure that the MCU can continue to work and write data to the memory after the external power is interrupted. Moreover, after the external power is turned on, it is necessary to wait for the MCU to start and read the memory, which has a certain delay.

[0003] Alternatively, the state memory function of the bistable circuit built by the gate circuit can be used to realize the one-button power on / off function. The characteristic of this technology is that the bistable circuit needs to be in a working state all the time. If the external power supply is interrupted, the state memory function of the bistable circuit will fail.

[0004] Or use a dedicated one-button switch chip to achieve this function. This technology also requires the chip to be continuously powered to ensure that its memory is not lost. Summary of the invention

[0005] In view of this, an embodiment of the present application provides a single-key switch control circuit with a state memory function, which can realize the state memory function without maintaining power to the switch control circuit or requiring a memory to record information.

[0006] An embodiment of the present application provides a single-key switch control circuit with a state memory function, the circuit comprising a single-key switch circuit and a state memory circuit, the state memory circuit comprising a magnetic retainer and a current reversal circuit connected to both ends of a coil of the magnetic retainer, the contact switch of the magnetic retainer being connected to a voltage input end of the single-key switch circuit, the current reversal circuit being used to reverse the current flowing through the coil of the magnetic retainer, thereby closing or disconnecting the contact switch, and maintaining its state through the permanent magnet of the magnetic retainer, so that the coil can remain in a normally closed or normally open state after power is cut off, and when the voltage input end is interrupted, the state of the switch before power is cut off is memorized.

[0007] According to a specific implementation of the embodiment of the present application, the current flipping circuit is configured as an H-bridge circuit.

[0008] According to a specific implementation of the embodiment of the present application, the H-bridge circuit includes a first switch tube, a second switch tube, a third switch tube and a fourth switch tube, the first switch tube and the second switch tube are set as N-MOS tubes, and the third switch tube and the fourth switch tube are set as P-MOS tubes; the drain of the first switch tube and the source of the third switch tube are respectively connected to the voltage input end, the source of the first switch tube is connected to the source of the fourth switch tube, the drain of the third switch tube is connected to the drain of the second switch tube, the drain of the fourth switch tube and the source of the second switch tube are respectively grounded, the base of the first switch tube and the base of the second switch tube are respectively connected to the voltage output end, and the base of the third switch tube and the base of the fourth switch tube are respectively connected to the single-key switch circuit; one end of the coil of the magnetic retainer is connected between the source of the first switch tube and the source of the fourth switch tube, and the other end of the coil of the magnetic retainer is connected between the drain of the second switch tube and the drain of the third switch tube.

[0009] According to a specific implementation of the embodiment of the present application, the single-key switch circuit includes a key switch, a fifth switch tube, a sixth switch tube, a seventh switch tube, a fifth resistor and a first capacitor, the fifth switch tube and the sixth switch tube are set as N-MOS tubes, the seventh switch tube is set as a P-MOS tube, one end of the key switch is connected to the voltage input end, the other end of the key switch is connected to the drain of the fifth switch tube, the base of the fifth switch tube, the base of the sixth switch tube and one end of the fifth resistor, the other end of the fifth resistor is connected to the source of the fifth switch tube and the source of the sixth switch tube and then grounded, the first capacitor is connected in parallel to both ends of the fifth resistor, the source of the seventh switch tube is connected to the voltage input end, the drain of the seventh switch tube is connected to the voltage output end, the base of the seventh switch tube is respectively connected to the drain of the sixth switch tube and the voltage input end, the source of the sixth switch tube is grounded, one end of the base of the sixth switch tube is connected to one end of the contact switch, and the other end of the base of the sixth switch tube is connected between the drain of the fifth switch tube and the other end of the key switch;

[0010] The base of the third switch tube and the base of the fourth switch tube are both connected to the drain of the fifth switch tube.

[0011] According to a specific implementation method of an embodiment of the present application, the single-key switch circuit also includes a first resistor, one end of the first resistor is connected to the voltage input end, and the other end of the first resistor is respectively connected to the base of the seventh switch tube and the drain of the sixth switch tube.

[0012] According to a specific implementation method of an embodiment of the present application, the single-key switch circuit also includes a second resistor, a third resistor and a fourth resistor, the fourth resistor is located between the base of the sixth switch tube and the contact switch, the second resistor is located between the other end of the key switch and the drain of the fifth switch tube, one end of the third resistor is respectively connected to the midpoint of the second resistor and the drain of the fifth switch tube and the midpoint of the fourth resistor and the base of the sixth switch tube, and the other end of the third resistor is grounded.

[0013] Beneficial effects:

[0014] The single-key switch control circuit with state memory function in the embodiment of the present application does not need to maintain power supply to the switch control circuit, nor does it need a memory to record information. Based on the single-key switch circuit, this technical solution uses the characteristic of the magnetic retainer to maintain the attracted state after power failure, and adds a state memory function before and after power failure on the basis of the original circuit function. When the external power supply is interrupted, the state of the switch before or after the power failure can be memorized. After the external power supply is restored, the original working state can be maintained according to the switch state before the power failure. The circuit structure is simple and the cost is low. BRIEF DESCRIPTION OF THE DRAWINGS

[0015] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0016] Figure 1 4 is a structural diagram of a single-key switch control circuit with a state memory function according to an embodiment of the present invention. DETAILED DESCRIPTION

[0017] The embodiments of the present application are described in detail below with reference to the accompanying drawings.

[0018] The following describes the implementation methods of the present application through specific examples, and those skilled in the art can easily understand other advantages and effects of the present application from the contents disclosed in this specification. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. The present application can also be implemented or applied through other different specific implementation methods, and the details in this specification can also be modified or changed in various ways based on different viewpoints and applications without departing from the spirit of the present application. It should be noted that, in the absence of conflict, the following embodiments and the features in the embodiments can be combined with each other. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in the field without making creative work belong to the scope of protection of the present application.

[0019] It should be noted that various aspects of the embodiments within the scope of the appended claims are described below. It should be apparent that the aspects described herein can be embodied in a wide variety of forms, and any specific structure and / or function described herein is merely illustrative. Based on the present application, it should be understood by those skilled in the art that an aspect described herein can be implemented independently of any other aspect, and two or more of these aspects can be combined in various ways. For example, any number of aspects described herein can be used to implement the device and / or practice the method. In addition, other structures and / or functionalities other than one or more of the aspects described herein can be used to implement this device and / or practice this method.

[0020] It should also be noted that the illustrations provided in the following embodiments are only schematic illustrations of the basic concept of the present application. The illustrations only show the components related to the present application rather than being drawn according to the number, shape and size of the components in actual implementation. In actual implementation, the type, quantity and proportion of each component may be changed arbitrarily, and the component layout may also be more complicated.

[0021] Additionally, in the following description, specific details are provided to facilitate a thorough understanding of the examples. However, it will be understood by those skilled in the art that the aspects described may be practiced without these specific details.

[0022] The present application embodiment provides a single-key switch control circuit with a state memory function. Figure 1 The circuit includes a single-key switch circuit and a state memory circuit, wherein the state memory circuit includes a magnetic retainer KN and a current reversal circuit connected to both ends of the coil of the magnetic retainer KN, wherein the contact switch S_KN of the magnetic retainer KN is connected to the voltage input terminal V_I N of the single-key switch circuit, and the current reversal circuit is used to reverse the current flowing through the coil of the magnetic retainer KN, thereby closing or disconnecting the contact switch S_KN, and maintaining its state through the permanent magnet of the magnetic retainer KN, so that the coil can still maintain a normally closed or normally open state after power is cut off, and when the voltage input terminal V_I N is interrupted, the state of the switch before power is cut off is memorized.

[0023] Furthermore, the current flipping circuit is configured as an H-bridge circuit.

[0024] Specifically, the H-bridge circuit includes a first switch tube Q1, a second switch tube Q2, a third switch tube Q3 and a fourth switch tube Q4, the first switch tube Q1 and the second switch tube Q2 are configured as N-MOS tubes, the third switch tube Q3 and the fourth switch tube Q4 are configured as P-MOS tubes; the drain of the first switch tube Q1 and the source of the third switch tube Q3 are respectively connected to the voltage input terminal V_I N is connected, the source of the first switch tube Q1 is connected to the source of the fourth switch tube Q4, the drain of the third switch tube Q3 is connected to the drain of the second switch tube Q2, the drain of the fourth switch tube Q4 and the source of the second switch tube Q2 are grounded respectively, the base of the first switch tube Q1 and the base of the second switch tube Q2 are connected to the voltage output terminal V_OUT respectively, the base of the third switch tube Q3 and the base of the fourth switch tube Q4 are connected to the single-key switch circuit respectively; one end of the coil of the magnetic retainer KN is connected between the source of the first switch tube Q1 and the source of the fourth switch tube Q4, and the other end of the coil of the magnetic retainer KN is connected between the drain of the second switch tube Q2 and the drain of the third switch tube Q3.

[0025] Further, the single-key switch circuit includes a key switch AN, a fifth switch tube Q5, a sixth switch tube Q6, a seventh switch tube Q7, a fifth resistor R5 and a first capacitor C1, the fifth switch tube Q5 and the sixth switch tube Q6 are set as N-MOS tubes, the seventh switch tube Q7 is set as a P-MOS tube, one end of the key switch AN is connected to the voltage input terminal V_IN, the other end of the key switch AN is connected to the drain of the fifth switch tube Q5, the base of the fifth switch tube Q5, the base of the sixth switch tube Q6 and one end of the fifth resistor R5, the other end of the fifth resistor R5 is connected to the source of the fifth switch tube Q5 and the source of the sixth switch tube Q6 and then grounded, the first capacitor C1 is connected in parallel to both ends of the fifth resistor R5, the source of the seventh switch tube Q7 is connected to the voltage input terminal V_IN, the drain of the seventh switch tube Q7 is connected to the voltage output terminal V_OUT, and the base of the seventh switch tube Q7 is respectively connected to the drain of the sixth switch tube Q6 and the voltage input terminal V_IN. N is connected, the source of the sixth switch tube Q6 is grounded, one end of the base of the sixth switch tube Q6 is connected to one end of the contact switch S_KN, and the other end of the base of the sixth switch tube Q6 is connected between the drain of the fifth switch tube Q5 and the other end of the key switch AN;

[0026] The base of the third switch tube Q3 and the base of the fourth switch tube Q4 are both connected to the drain of the fifth switch tube Q5 .

[0027] Furthermore, the single-key switch circuit also includes a first resistor R1, one end of the first resistor R1 is connected to the voltage input terminal V_IN, and the other end of the first resistor R1 is respectively connected to the base of the seventh switch tube Q7 and the drain of the sixth switch tube Q6.

[0028] Furthermore, the single-key switch circuit also includes a second resistor R2, a third resistor R3 and a fourth resistor R4, the fourth resistor R4 is located between the base of the sixth switch tube Q6 and the contact switch S_KN, the second resistor R2 is located between the other end of the key switch AN and the drain of the fifth switch tube Q5, one end of the third resistor R3 is respectively connected to the midpoint of the second resistor R2 and the drain of the fifth switch tube Q5 and the midpoint of the fourth resistor R4 and the base of the sixth switch tube Q6, and the other end of the third resistor R3 is grounded.

[0029] This application utilizes the characteristics of the magnetic retainer KN that it can maintain the switch state after power failure and the characteristics of the H-bridge circuit that it can flip the positive and negative poles, combined with the existing single-key switch control circuit to achieve the expected function. The control principle is as follows:

[0030] 1. The first switch tube Q1, the second switch tube Q2, the third switch tube Q3, the fourth switch tube Q4, and KN constitute a state memory circuit. KN is a magnetic retainer, which is a relay. By changing the direction of the electromagnetic coil current, the relay contacts are closed / opened, and its state is maintained by a permanent magnet, so that the coil can still remain in a normally closed or normally open state after power is cut off; the first switch tube Q1, the second switch tube Q2, the third switch tube Q3, and the fourth switch tube Q4 form an H-bridge circuit, which can realize the current reversal flowing through the KN coil. This circuit is a prior art. The working principle of the state memory circuit is:

[0031] 1.1. The first switch tube Q1 and the second switch tube Q2 are N-MOS tubes. When the VGS voltage is greater than the threshold, the D and S poles of the MOS tubes are turned on; when the VGS voltage is less than the threshold, the D and S poles of the MOS tubes are turned off;

[0032] 1.2. The third switch tube Q3 and the fourth switch tube Q4 are P-MOS tubes. When the VGS voltage is less than the threshold, the D pole and the S pole of the MOS tube are turned on; when the VGS voltage is greater than the threshold, the D pole and the S pole of the MOS tube are turned off;

[0033] 1.3. KN is a magnetic retainer, and the contact switch S_KN is its corresponding electric shock switch. When the current flows from T1 to T2, the contact switch S_KN is closed; when the current flows from T2 to T1, the contact switch S_KN is opened;

[0034] 1.4. When the first switch tube Q1 and the second switch tube Q2 are turned on and the third switch tube Q3 and the fourth switch tube Q4 are turned off, the corresponding contact switch S_KN is closed, indicating that V_OUT has output and the device is in operation;

[0035] 1.5. When the first switch tube Q1 and the second switch tube Q2 are turned off and the third switch tube Q3 and the fourth switch tube Q4 are turned on, the corresponding contact switch S_KN is disconnected, indicating that V_OUT has no output at this time and the device is in a shutdown state.

[0036] 2. The first resistor R1 to the fifth resistor R5, the first capacitor C1, the key switch AN, the fifth switch tube Q5 to the seventh switch tube Q7 constitute a single-key switch circuit, and the functions of each component are as follows:

[0037] 2.1. The seventh switch tube Q7 is a P-MOS tube. When the VGS voltage is less than the threshold, the D and S poles of the MOS tube are turned on; when the VGS voltage is greater than the threshold, the D and S poles of the MOS tube are turned off;

[0038] 2.2. The seventh switch tube Q7 is used to control the on-off of V_IN to V_OUT. When the seventh switch tube Q7 is turned on, V_OUT has output and the device starts to work. When the seventh switch tube Q7 is turned off, V_OUT has no output and the device stops working.

[0039] 2.3. The fifth switch tube Q5 and the sixth switch tube Q6 are N-MOS tubes. When the VGS voltage is greater than the threshold, the D pole and the S pole of the MOS tube are turned on; when the VGS voltage is less than the threshold, the D pole and the S pole of the MOS tube are turned off;

[0040] 2.4. The sixth switch tube Q6 controls the on / off of the seventh switch tube Q7. When the sixth switch tube Q6 is on, the G pole voltage of the seventh switch tube Q7 is lower than the threshold, and the seventh switch tube Q7 is on; when the sixth switch tube Q6 is off, the G pole voltage of the seventh switch tube Q7 is higher than the threshold, and the seventh switch tube Q7 is off;

[0041] 2.5. The fifth switch tube Q5 controls the on / off of the sixth switch tube Q6; when the fifth switch tube Q5 is on, the G pole voltage of the sixth switch tube Q6 is lower than the threshold, and the sixth switch tube Q6 is turned off; when the fifth switch tube Q5 is off, the G pole voltage of the sixth switch tube Q6 is higher than the threshold, and the sixth switch tube Q6 is turned on;

[0042] 2.6. The fifth switch tube Q5 simultaneously controls the on / off of the third switch tube Q3 and the fourth switch tube Q4; when the fifth switch tube Q5 is on, the G-pole voltage of the third switch tube Q3 and the fourth switch tube Q4 is lower than the threshold, and the third switch tube Q3 and the fourth switch tube Q4 are on; when the fifth switch tube Q5 is off, the G-pole voltage of the third switch tube Q3 and the fourth switch tube Q4 is higher than the threshold, and the third switch tube Q3 and the fourth switch tube Q4 are off;

[0043] 2.7. The first capacitor C1 is a capacitor used to control the time it takes for the VGS voltage of the fifth switch tube Q5 to rise to a threshold;

[0044] 2.8. The key switch AN is a key switch. When pressed, the external power supply V_I N will enter the single-key switch circuit;

[0045] 2.9. The first resistor R1 is a resistor used to limit the current flowing through the sixth switch tube Q6 to avoid excessive current;

[0046] 2.10. The second resistor R2, the third resistor R3 and the fourth resistor R4 are resistors used to control the G pole voltage of the sixth switch tube Q6 and limit the current of the circuit to avoid being too large;

[0047] 2.11. The fifth resistor R5 is a resistor used to consume the electric energy stored in the first capacitor C1 after the power supply at both ends of the first capacitor C1 disappears, so that the first capacitor C1 can be charged again when the key switch AN is pressed again.

[0048] 3. The working principle of the entire circuit is:

[0049] 3.1. In the initial state, the first switch tube Q1 to the seventh switch tube Q7 are all in the off state, and V_IN and V_OUT are not conducting;

[0050] 3.2. Press the key switch AN, and the current flows from V_I N through the key switch AN, through the second resistor R2, the third resistor R3 to GND, and through the fifth resistor R5 to GND; because the first capacitor C1 needs to be charged, the voltage increase speed of the G pole of the fifth switch tube Q5 lags behind that of the sixth switch tube Q6, so the sixth switch tube Q6 is turned on before the fifth switch tube Q5; after the sixth switch tube Q6 is turned on, the voltage of the G pole of the seventh switch tube Q7 decreases, the seventh switch tube Q7 is turned on, V_I N and V_OUT are connected, and the device is powered on and starts working;

[0051] 3.3 After the device is powered on, the voltage of the G pole of the first switch tube Q1 and the second switch tube Q2 in the H-bridge circuit increases, the first switch tube Q1 and the second switch tube Q2 are turned on, the magnetic retainer KN coil has a current from T1 to T2, the contact switch S_KN is attracted, and the G pole of G6 can be kept at a high voltage. The sixth switch tube Q6 remains in the turned-on state, so the device can continue to work after the key switch AN is lifted;

[0052] 3.4. After the equipment is powered on, if the external power supply V_I N is interrupted, since KN has the characteristic of maintaining the state before power failure after power failure, the contact switch S_KN is energized and remains in the energized state. When the external power supply V_I N is restored, V_I N can directly flow to GND through the contact switch S_KN, the fourth resistor R4, and the third resistor R3, so that the G pole voltage of G6 increases. The sixth switch tube Q6 is turned on, and then the seventh switch tube Q7 is turned on, V_OUT has output, and the equipment returns to the working state before power failure;

[0053] 3.4. After the device is powered on, when the key switch AN is pressed again and remains pressed, when the pressing duration exceeds the charging time of the first capacitor C1, the G-pole voltage of the fifth switch tube Q5 rises to the threshold voltage, the fifth switch tube Q5 is turned on, the G-pole voltage of the sixth switch tube Q6 decreases, and the sixth switch tube Q6 is turned off; because the sixth switch tube Q6 is turned off, the G-pole voltage of the seventh switch tube Q7 increases, the seventh switch tube Q7 is turned off, V_I N and V_OUT are disconnected, and the device is powered off and stops working;

[0054] 3.5. When the push-button switch AN is long pressed and the fifth switch tube Q5 is turned on, the G-pole voltage of the third switch tube Q3 and the fourth switch tube Q4 in the H-bridge circuit decreases, the third switch tube Q3 and the fourth switch tube Q4 are turned on, the coil of the magnetic retainer KN has a current from T2 to T1, and the contact switch S_KN is disconnected; at this time, if the external power supply V_I N interrupts the power supply and then resumes, since KN has the characteristic of maintaining the state before power failure after power failure, the contact switch S_KN is energized and remains disconnected, the single-button switch circuit is disconnected at various locations, and the equipment remains in a stopped state.

[0055] In specific implementation, the components in the circuit are the minimum configuration. In actual application, resistors, capacitors, diodes, transistors and other devices with functions such as filtering, delay, anti-reverse, and accelerating the opening / closing of MOS tubes can be added as needed. The H bridge can be replaced by a chip with the same function to replace the column device; the MOS tube can be replaced by a transistor with a switch function.

[0056] The embodiment provided by the present invention does not need to maintain power supply to the switch control circuit, nor does it need a memory to record information. Based on the disclosed single-key switch circuit, this technical solution uses the characteristic of the magnetic retainer to maintain the attracted state after power failure, and adds a working state memory function before power failure on the basis of the original circuit function. When the external power supply is interrupted, the state of the switch before the power failure can be memorized, and after the external power supply is restored, the original working state can be maintained according to the switch state before the power failure.

[0057] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any changes or substitutions that can be easily thought of by a person skilled in the art within the technical scope disclosed in the present application should be included in the protection scope of the present application. Therefore, the protection scope of the present application shall be based on the protection scope of the claims.

Claims

1. A single-key switch control circuit with a state memory function, characterized in that: The circuit includes a single-key switch circuit and a state memory circuit. The state memory circuit includes a magnetic retainer and a current reversal circuit connected to both ends of the coil of the magnetic retainer. The contact switch of the magnetic retainer is connected to the voltage input end of the single-key switch circuit. The current reversal circuit is used to reverse the current flowing through the coil of the magnetic retainer, thereby closing or disconnecting the contact switch, and maintaining its state through the permanent magnet of the magnetic retainer, so that the coil can still maintain a normally closed or normally open state after power is cut off, and when the voltage input end is interrupted, the state of the switch before power is cut off is memorized.

2. The single-key switch control circuit with state memory function according to claim 1, characterized in that: The current flipping circuit is configured as an H-bridge circuit.

3. The single-key switch control circuit with state memory function according to claim 2, characterized in that: The H-bridge circuit includes a first switch tube, a second switch tube, a third switch tube and a fourth switch tube, wherein the first switch tube and the second switch tube are configured as N-MOS tubes, and the third switch tube and the fourth switch tube are configured as P-MOS tubes; the drain of the first switch tube and the source of the third switch tube are respectively connected to the voltage input end, the source of the first switch tube is connected to the source of the fourth switch tube, the drain of the third switch tube is connected to the drain of the second switch tube, the drain of the fourth switch tube and the source of the second switch tube are respectively grounded, the base of the first switch tube and the base of the second switch tube are respectively connected to the voltage output end, and the base of the third switch tube and the base of the fourth switch tube are respectively connected to the single-key switch circuit; one end of the coil of the magnetic retainer is connected between the source of the first switch tube and the source of the fourth switch tube, and the other end of the coil of the magnetic retainer is connected between the drain of the second switch tube and the drain of the third switch tube.

4. The single-key switch control circuit with state memory function according to claim 3, characterized in that: The single-key switch circuit includes a key switch, a fifth switch tube, a sixth switch tube, a seventh switch tube, a fifth resistor and a first capacitor. The fifth switch tube and the sixth switch tube are set as N-MOS tubes, and the seventh switch tube is set as a P-MOS tube. One end of the key switch is connected to the voltage input end, and the other end of the key switch is connected to the drain of the fifth switch tube, the base of the fifth switch tube, the base of the sixth switch tube and one end of the fifth resistor. The other end of the fifth resistor is connected to the source of the fifth switch tube and the source of the sixth switch tube and then grounded. The first capacitor is connected in parallel to both ends of the fifth resistor. The source of the seventh switch tube is connected to the voltage input end, the drain of the seventh switch tube is connected to the voltage output end, the base of the seventh switch tube is connected to the drain of the sixth switch tube and the voltage input end respectively, the source of the sixth switch tube is grounded, one end of the base of the sixth switch tube is connected to one end of the contact switch, and the other end of the base of the sixth switch tube is connected between the drain of the fifth switch tube and the other end of the key switch; The base of the third switch tube and the base of the fourth switch tube are both connected to the drain of the fifth switch tube.

5. The single-key switch control circuit with state memory function according to claim 4, characterized in that: The single-key switch circuit also includes a first resistor, one end of which is connected to the voltage input end, and the other end of which is respectively connected to the base of the seventh switch tube and the drain of the sixth switch tube.

6. The single-key switch control circuit with state memory function according to claim 4, characterized in that: The single-key switch circuit also includes a second resistor, a third resistor and a fourth resistor. The fourth resistor is located between the base of the sixth switch tube and the contact switch, the second resistor is located between the other end of the key switch and the drain of the fifth switch tube, one end of the third resistor is respectively connected to the midpoint of the second resistor and the drain of the fifth switch tube and the midpoint of the fourth resistor and the base of the sixth switch tube, and the other end of the third resistor is grounded.