OTP (One Time Programmable) error write-in prevention circuit and chip

By designing an anti-error write circuit in OTP memory, and using the combination of switch tubes, capacitors and resistors to control the voltage, the error writing problem of OTP memory in ESD situation is solved, ensuring the safety of data and equipment.

CN118918934APending Publication Date: 2024-11-08禹创半导体(深圳)有限公司
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411091633.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-09
Publication Date
2024-11-08

AI Technical Summary

Technical Problem

When facing electrostatic discharge (ESD) shock, OTP memory is prone to voltage abnormalities, resulting in miswrites, threatening data integrity and device security.

Method used

A circuit that prevents OTP error writing is designed. Through the OTP module, power supply terminal, read and write module and anti-write module, the voltage of the OTP module is controlled by combining switch tubes, capacitors and resistors to avoid errors caused by fluctuations in external power supply. Write.

Benefits of technology

It effectively suppresses the voltage increase of the OTP module in the ESD situation, keeps the voltage at the preset value, prevents miswrites, and ensures data security and equipment stability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118918934A_ABST
    Figure CN118918934A_ABST
Patent Text Reader

Abstract

The invention provides an OTP miswrite prevention circuit and a chip, the OTP miswrite prevention circuit comprises an OTP module, a first power supply end, a second power supply end, an OTP read-write module, a first miswrite prevention module and a second miswrite prevention module, the first miswrite prevention module comprises a first switch tube, a first capacitor, a second capacitor and a first resistor, and the second anti-miswriting module comprises a second switch tube, a third switch tube, a fourth switch tube, a fifth switch tube, a sixth switch tube and a seventh switch tube. Wherein in the non-working mode, when abnormal voltage rise occurs at the first power supply end, the first switch tube is conducted, so that the OTP module is kept at a first preset voltage; and in a reading mode, when abnormal voltage rise occurs at the first power supply end, the third switch tube, the fourth switch tube, the fifth switch tube and the sixth switch tube are conducted, and the controlled end voltage of the sixth switch tube rises, so that the second switch tube is conducted, and the first end of the OTP read-write module is kept at a second preset voltage.
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 circuit and a chip for preventing OTP from being mistakenly written. Background Art

[0002] One-Time Programmable (OTP) memory plays a vital role in modern electronic system design. It is used to store key configuration information, security keys or user settings to ensure the personalization and security of the device. The read and write operations of OTP memory require precise power management to maintain data integrity and reliability. Usually, the OTP circuit is powered by the system main power supply VCC, which is responsible for providing a stable operating voltage for the read and write process. However, electrostatic discharge (ESD) is a long-standing challenge faced by the electronics industry, especially during production, transportation and daily operation. ESD events can invade the system through various channels, including direct contact with the VCC line. When the VCC line is hit by ESD, the instantaneous voltage spike may far exceed the normal operating voltage range, causing the VCC voltage to increase abnormally. This phenomenon not only threatens the safety of other sensitive components in the circuit, but is also catastrophic for OTP memory. The risk of miswriting increases sharply, which means that valuable configuration information may be modified incorrectly, or even cause device function failure or security mechanism to be destroyed. Summary of the invention

[0003] The present application provides an OTP miswriting prevention circuit and chip, which are used to clamp the voltage of the read and write ends of the OTP module to avoid miswriting of the OTP module when the external power supply fluctuates.

[0004] In a first aspect, an embodiment of the present application provides an OTP miswrite prevention circuit, the OTP miswrite prevention circuit comprising: an OTP module, a first power supply end, a second power supply end, an OTP read-write module, a first miswrite prevention module and a second miswrite prevention module, the first miswrite prevention module comprising: a first switch tube, a first capacitor, a second capacitor and a first resistor, the second miswrite prevention module comprising: a second switch tube, a third switch tube, a fourth switch tube, a fifth switch tube, a sixth switch tube and a seventh switch tube; The first power supply end is connected to the first end of the first capacitor, the second end of the first capacitor is respectively connected to the first end of the second capacitor, the first end of the first resistor, and the controlled end of the first switch tube, the second end of the second capacitor is grounded, the second end of the first resistor is grounded, the first end of the first switch tube is connected to the first end of the OTP module, the second end of the first switch tube is grounded, and the second end of the OTP module is grounded, the first power supply end is also respectively connected to the first end of the second switch tube and the first end of the third switch tube, the second end of the second switch tube is grounded, and the controlled end of the third switch tube is respectively connected to the second end of the third switch tube and the first end of the fourth switch tube. The controlled end of the fourth switch tube is respectively connected to the second end of the fourth switch tube and the first end of the fifth switch tube, the controlled end of the fifth switch tube is respectively connected to the second end of the fifth switch tube and the first end of the sixth switch tube, the controlled end of the sixth switch tube is respectively connected to the second end of the sixth switch tube, the first end of the seventh switch tube, and the controlled end of the second switch tube, the controlled end of the seventh switch tube is respectively connected to the second end of the seventh switch tube, and the second end of the seventh switch tube is grounded; the second power supply end is connected to the first end of the OTP read-write module, the second end of the OTP read-write module is connected to the OTP module, and the third end of the OTP read-write module is grounded; Among them, in the non-working mode, the voltage at the first end of the OTP module is a first preset voltage. When the voltage at the first power supply end rises abnormally, the first power supply end charges the first capacitor and the second capacitor, so that the voltage at the controlled end of the first switch tube rises, thereby turning on the first switch tube, and then keeping the first end of the OTP module at the first preset voltage; when the OTP read-write module is in the reading mode, the voltage at the first end of the OTP module is a second preset voltage, and the second preset voltage is the voltage of the second power supply end. When the voltage at the first power supply end rises abnormally, the third switch tube, the fourth switch tube, the fifth switch tube, the sixth switch tube and the seventh switch tube are turned on, and the voltage at the controlled end of the sixth switch tube rises from the third preset voltage to the fourth preset voltage, so that the second switch tube is turned on, so that the voltage at the first end of the OTP module is maintained at the second preset voltage.

[0005] In some embodiments, the OTP anti-miswrite circuit also includes: a third anti-miswrite module, the third anti-miswrite module includes: a first enable end and an eighth switch tube, the first enable end is connected to the control end of the eighth switch tube, the first end of the eighth switch tube is connected to the first end of the OTP module, and the second end of the eighth switch tube is grounded.

[0006] In some embodiments, the OTP read-write module includes: a second enable terminal, a third enable terminal, a fourth enable terminal, a second resistor, a third resistor, a ninth switch tube, a NAND gate, a NOT gate logic element, an AND gate logic element, a fourth resistor, a fifth resistor, a tenth switch tube, an eleventh switch tube, a twelfth switch tube, a thirteenth switch tube, a fourteenth switch tube, a sixth resistor, and a fifteenth switch tube; The second enable terminal is respectively connected to the first terminal of the second resistor and the first input terminal of the NAND gate component, the second terminal of the second resistor is grounded, the second power supply terminal is respectively connected to the first terminal of the third resistor, the first terminal of the fourth resistor, and the second terminal of the fourteenth switch tube, the second terminal of the third resistor is respectively connected to the second terminal of the ninth switch tube and the second input terminal of the NAND gate component, the first terminal of the ninth switch tube is grounded, the output terminal of the NAND gate component is respectively connected to the input terminal of the NOT gate logic component and the first input terminal of the AND gate logic component, the output terminal of the NOT gate logic component is connected to the controlled terminal of the tenth switch tube, the second input terminal of the AND gate logic component is connected to the third enable terminal, the first power supply terminal is connected to the first terminal of the eleventh switch tube, and the controlled terminals of the eleventh switch tube are respectively connected to the first terminal of the eleventh switch tube. The AND gate logic element is connected to the controlled end of the twelfth switch tube, the controlled end of the thirteenth switch tube is connected to the fourth enable end, the first end of the thirteenth switch tube is connected to the controlled end of the second switch tube, the second end of the thirteenth switch tube is grounded, the first end of the twelfth switch tube is respectively connected to the controlled end of the fourteenth switch tube, the first end of the sixth resistor, and the controlled end of the fifteenth switch tube, the second end of the sixth resistor is respectively connected to the first end of the fourteenth switch tube and the first end of the fifteenth switch tube, and the second end of the fifteenth switch tube is connected to the first end of the OTP module.

[0007] In a second aspect, an embodiment of the present application provides a chip, and the electronic device includes an anti-OTP miswriting circuit as described in any one of the embodiments of the present application.

[0008] The embodiment of the present application provides an OTP mis-write prevention circuit, which includes: an OTP module, a first power supply end, a second power supply end, an OTP read-write module, a first mis-write prevention module and a second mis-write prevention module, the first mis-write prevention module includes: a first switch tube, a first capacitor, a second capacitor and a first resistor, the second mis-write prevention module includes: a second switch tube, a third switch tube, a fourth switch tube, a fifth switch tube, a sixth switch tube and a seventh switch tube; the first power supply end is connected to the first end of the first capacitor, the second end of the first capacitor is respectively connected to the first end of the second capacitor, the first end of the first resistor and the controlled end of the first switch tube, the second end of the second capacitor is grounded, the second end of the first resistor is grounded, the first end of the first switch tube is connected to the first end of the OTP module, the second end of the first switch tube is grounded, the second end of the OTP module is grounded, and the A power supply end is also connected to the first end of the second switch tube and the first end of the third switch tube respectively, the second end of the second switch tube is grounded, the controlled end of the third switch tube is connected to the second end of the third switch tube and the first end of the fourth switch tube respectively, the controlled end of the fourth switch tube is connected to the second end of the fourth switch tube and the first end of the fifth switch tube respectively, the controlled end of the fifth switch tube is connected to the second end of the fifth switch tube and the first end of the sixth switch tube respectively, the controlled end of the sixth switch tube is connected to the second end of the sixth switch tube, the first end of the seventh switch tube, and the controlled end of the second switch tube respectively, the controlled end of the seventh switch tube is connected to the second end of the seventh switch tube respectively, and the second end of the seventh switch tube is grounded; the second power supply end is connected to the first end of the OTP read-write module, the second end of the OTP read-write module is connected to the OTP module, and the third end of the OTP read-write module is grounded. Among them, in the non-working mode, the voltage at the first end of the OTP module is a first preset voltage. When the voltage at the first power supply end rises abnormally, the first power supply end charges the first capacitor and the second capacitor, so that the voltage at the controlled end of the first switch tube rises, thereby turning on the first switch tube, and then maintaining the first end of the OTP module at the first preset voltage; when the OTP read-write module is in the reading mode, the voltage at the first end of the OTP module is a second preset voltage, and the second preset voltage is the voltage of the second power supply end. When the voltage at the first power supply end rises abnormally, the third switch tube, the fourth switch tube, the fifth switch tube, the sixth switch tube and the seventh switch tube are turned on, and the voltage at the controlled end of the sixth switch tube rises from the third preset voltage to the fourth preset voltage, so that the second switch tube is turned on, so that the voltage at the first end of the OTP module is maintained at the second preset voltage.Through the above circuit, in the non-working mode, the first end of the OTP module needs to be maintained at the first preset voltage, and when an abnormal voltage appears at the first power supply end, it will inevitably cause the voltage at the first end of the OTP module to increase, resulting in the capacitor voltage of the first capacitor and the second capacitor in the first miswrite module to increase, so that the first switch tube is turned on, thereby maintaining the voltage of the first power supply end at the first preset voltage; in the reading mode, through the third switch tube, the fourth switch tube, the fifth switch tube, the sixth switch tube and the seventh switch tube, the third preset voltage of the controlled end of the sixth switch tube cannot turn on the second switch tube, and the first end of the OTP module needs to be maintained at the second preset voltage, and when an abnormal voltage appears at the first power supply end, it will inevitably cause the second preset voltage of the first end of the OTP module to increase, thereby causing the third preset voltage of the controlled end of the sixth switch tube to increase to the fourth preset voltage, and then the second switch tube is turned on, thereby suppressing the voltage rise of the first end of the OTP module, maintaining the voltage of the first end of the OTP module at the second preset voltage, and avoiding miswriting of the OTP module. BRIEF DESCRIPTION OF THE DRAWINGS

[0009] 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 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 any creative work.

[0010] Figure 1 A schematic diagram of a first circuit for preventing OTP miswriting provided in an embodiment of the present application; Figure 2 A schematic diagram of a change in the first electrical signal provided in an embodiment of the present application; Figure 3 A schematic diagram of a change in a second electrical signal provided in an embodiment of the present application; Figure 4 A schematic diagram of a second circuit for preventing OTP miswriting provided in an embodiment of the present application; Figure 5 A schematic diagram of a third OTP miswriting prevention circuit provided in an embodiment of the present application.

[0011] Reference numerals: 100, OTP error-writing prevention circuit; 11, OTP module; VCC, first power supply terminal; 5VREG, second power supply terminal; 12, OTP read-write module; 13, first error-writing prevention module; Q1, first switch tube; C1, first capacitor; C2, second capacitor; R1, first resistor; 14, second error-writing prevention module; Q2, second switch tube; Q3, third switch tube; Q4, fourth switch tube; Q5, fifth switch tube; Q6, sixth switch tube; Q7, seventh switch tube; 15, third error-writing prevention module; VPP_DCHG_EN, first enable terminal; Q8, the eighth switch tube; OTP_PWR_EN, the second enable terminal; VPP_EN, the third enable terminal; OTPWR_EN, the fourth enable terminal; R2, the second resistor; R3, the third resistor; Q9, the ninth switch tube; A1, the NAND gate; A2, the NOT gate logic element; A3, the AND gate logic element; R4, the fourth resistor; R5, the fifth resistor; Q10, the tenth switch tube; Q11, the eleventh switch tube; Q12, the twelfth switch tube; Q13, the thirteenth switch tube; Q14, the fourteenth switch tube; R6, the sixth resistor; Q15, the fifteenth switch tube. DETAILED DESCRIPTION

[0012] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0013] The flowcharts shown in the accompanying drawings are only examples and do not necessarily include all the contents and operations / steps, nor must they be executed in the order described. For example, some operations / steps may also be decomposed, combined or partially merged, so the actual execution order may change according to actual conditions.

[0014] It should also be understood that the terms used in this application specification are only for the purpose of describing specific embodiments and are not intended to limit the application. As used in this application specification and the appended claims, unless the context clearly indicates otherwise, the singular forms "a", "an" and "the" are intended to include plural forms.

[0015] It should be further understood that the term “and / or” used in the specification and appended claims refers to any combination and all possible combinations of one or more of the associated listed items, and includes these combinations.

[0016] See also Figure 1 , Figure 1The embodiment of the present application also provides a schematic diagram of a first circuit for preventing OTP from being written incorrectly. Figure 1 As shown, the OTP miswrite prevention circuit 100 includes: an OTP module 11, a first power supply terminal VCC, a second power supply terminal 5VREG, an OTP read-write module 12, a first miswrite prevention module 13 and a second miswrite prevention module 14. The first miswrite prevention module 13 includes: a first switch tube Q1, a first capacitor C1, a second capacitor C2 and a first resistor R1. The second miswrite prevention module 14 includes: a second switch tube Q2, a third switch tube Q3, a fourth switch tube Q4, a fifth switch tube Q5, a sixth switch tube Q6 and a seventh switch tube Q7. Among them, the second power supply terminal 5VREG is connected to an external five-volt voltage regulator, and the input voltage of the second power supply terminal 5VREG is 5V.

[0017] like Figure 1 As shown, the first power supply terminal VCC is connected to the first end of the first capacitor C1, and the second end of the first capacitor C1 is respectively connected to the first end of the second capacitor C2, the first end of the first resistor R1, and the controlled end of the first switch tube Q1. The second end of the second capacitor C2 is grounded, and the second end of the first resistor R1 is grounded. The first end of the first switch tube Q1 is connected to the first end of the OTP module 11, the second end of the first switch tube Q1 is grounded, and the second end of the OTP module 11 is grounded. The first power supply terminal VCC is also connected to the first end of the second switch tube Q2 and the first end of the third switch tube Q3, and the second end of the second switch tube Q2 is grounded. The controlled end of the third switch tube Q3 is respectively connected to the second end of the third switch tube Q3 and the first end of the fourth switch tube Q4. The controlled end of the fourth switch tube Q4 is respectively connected to the second end of the fourth switch tube Q4 and the first end of the fifth switch tube Q5. The controlled end of the fifth switch tube Q5 is respectively connected to the second end of the fifth switch tube Q5 and the first end of the sixth switch tube Q6. The controlled end of the sixth switch tube Q6 is respectively connected to the second end of the sixth switch tube Q6, the first end of the seventh switch tube Q7, and the controlled end of the second switch tube Q2. The controlled end of the seventh switch tube Q7 is respectively connected to the second end of the seventh switch tube Q7, and the second end of the seventh switch tube Q7 is grounded. The second power supply end 5VREG is connected to the first end of the OTP read-write module 12, the second end of the OTP read-write module 12 is connected to the OTP module 11, and the third end of the OTP read-write module 12 is grounded.

[0018] It should be noted that in the embodiment of the present application, the first power supply terminal VCC[1] will generate abnormal voltage during ESD discharge, which may cause the OTP module 11 to be written incorrectly.

[0019] The OTP mis-writing prevention circuit 100 includes a non-operating mode, a reading mode and a writing mode.

[0020] Among them, in the non-working mode, the voltage (EXVPP) of the first end of the OTP module 11 is the first preset voltage. When the voltage of the first power supply end VCC rises abnormally, the first power supply end VCC charges the first capacitor C1 and the second capacitor C2, so that the voltage of the controlled end of the first switch tube Q1 rises, thereby turning on the first switch tube Q1, and then keeping the first end of the OTP module 11 at the first preset voltage. When the OTP read-write module 12 is in the reading mode, the voltage (EXVPP) of the first end of the OTP module 11 is the second preset voltage, and the second preset voltage is the voltage of the second power supply end 5VREG. When the voltage of the first power supply end VCC rises abnormally, the third switch tube Q3, the fourth switch tube Q4, the fifth switch tube Q5, the sixth switch tube Q6 and the seventh switch tube Q7 are turned on, and the voltage of the controlled end of the sixth switch tube Q6 rises from the third preset voltage to the fourth preset voltage, so that the second switch tube Q2 is turned on, so that the voltage of the first end of the OTP module 11 is kept at the second preset voltage.

[0021] It should be noted that in the embodiment of the present application, the first end of the NMOS type switch tube is the drain, the first end of the PMOS type switch tube is the source, and the controlled ends of the switch tubes are both gates.

[0022] In some embodiments, see Figure 2 , Figure 2 The first schematic diagram of the change of the electrical signal provided in the embodiment of the present application is shown. Figure 2 As shown, in the non-operating mode, the voltage (EXVPP) of the first end of the OTP module 11 is a first preset voltage, and the first preset voltage is 0V. When the voltage of the first power supply terminal VCC rises abnormally, for example, the current of the motor coil flows backward, the voltage of the controlled end of the first switch tube Q1 also rises accordingly. This is because the first power supply terminal VCC increases the charging amount of the first capacitor C1 and the second capacitor C2, increases the capacitor voltage of the first capacitor C1 and the second capacitor C2, and increases the voltage of the controlled end of the first switch tube Q1, thereby turning on the first switch tube Q1, and further maintaining the voltage (EXVPP) of the first end of the OTP module 11 at the first preset voltage.

[0023] In the embodiment of the present application, when the first power supply terminal VCC supplies power to the anti-OTP miswriting circuit 100, it may also supply power to electronic devices such as motors at the same time, and these electronic devices may cause voltage noise to be generated at the first power supply terminal VCC. In some cases, the induced current generated by the coil of the motor will flow back to the first power supply terminal VCC, causing the first power supply terminal VCC to increase abnormally and generate transient high voltage, which may cause the anti-OTP module 11 to be miswritten.

[0024] In some embodiments, see Figure 3 , Figure 3The second electrical signal variation diagram provided in the embodiment of the present application is shown. Figure 3 As shown, when the OTP read-write module 12 is in the read mode, the voltage (EXVPP) at the first end of the OTP module 11 is the second preset voltage. Under normal circumstances, the second preset voltage is approximately equal to the voltage of the second power supply terminal 5VREG, and the second preset voltage is 5V. The voltage at the controlled end of the second switch tube Q2 is the third preset voltage, and the third preset voltage is 0.75V. When the voltage of the first power supply terminal VCC rises abnormally, for example, a higher transient voltage appears at the first power supply terminal VCC, the body diodes of the third switch tube Q3, the fourth switch tube Q4, the fifth switch tube Q5, the sixth switch tube Q6 and the seventh switch tube Q7 are turned on to form a low-resistance channel, and the voltage of the controlled end of the sixth switch tube Q6 rises from the third preset voltage to the fourth preset voltage, the fourth preset voltage is 1.15V, and when the voltage (EXVPP) of the first end of the OTP module 11 rises to 6.5V at most, which is lower than the write voltage (7.1V), the second switch tube Q2 is turned on, so that the voltage (EXVPP) of the first end of the OTP module 11 drops and is maintained at the second preset voltage (5.6V).

[0025] The embodiment of the present application provides an OTP mis-write prevention circuit, which includes: an OTP module, a first power supply end, a second power supply end, an OTP read-write module, a first mis-write prevention module and a second mis-write prevention module, the first mis-write prevention module includes: a first switch tube, a first capacitor, a second capacitor and a first resistor, the second mis-write prevention module includes: a second switch tube, a third switch tube, a fourth switch tube, a fifth switch tube, a sixth switch tube and a seventh switch tube; the first power supply end is connected to the first end of the first capacitor, the second end of the first capacitor is respectively connected to the first end of the second capacitor, the first end of the first resistor and the controlled end of the first switch tube, the second end of the second capacitor is grounded, the second end of the first resistor is grounded, the first end of the first switch tube is connected to the first end of the OTP module, the second end of the first switch tube is grounded, the second end of the OTP module is grounded, and the A power supply end is also connected to the first end of the second switch tube and the first end of the third switch tube respectively, the second end of the second switch tube is grounded, the controlled end of the third switch tube is connected to the second end of the third switch tube and the first end of the fourth switch tube respectively, the controlled end of the fourth switch tube is connected to the second end of the fourth switch tube and the first end of the fifth switch tube respectively, the controlled end of the fifth switch tube is connected to the second end of the fifth switch tube and the first end of the sixth switch tube respectively, the controlled end of the sixth switch tube is connected to the second end of the sixth switch tube, the first end of the seventh switch tube, and the controlled end of the second switch tube respectively, the controlled end of the seventh switch tube is connected to the second end of the seventh switch tube respectively, and the second end of the seventh switch tube is grounded; the second power supply end is connected to the first end of the OTP read-write module, the second end of the OTP read-write module is connected to the OTP module, and the third end of the OTP read-write module is grounded. Among them, in the non-working mode, the voltage at the first end of the OTP module is a first preset voltage. When the voltage at the first power supply end rises abnormally, the first power supply end charges the first capacitor and the second capacitor, so that the voltage at the controlled end of the first switch tube rises, thereby turning on the first switch tube, and then maintaining the first end of the OTP module at the first preset voltage; when the OTP read-write module is in the reading mode, the voltage at the first end of the OTP module is a second preset voltage, and the second preset voltage is the voltage of the second power supply end. When the voltage at the first power supply end rises abnormally, the third switch tube, the fourth switch tube, the fifth switch tube, the sixth switch tube and the seventh switch tube are turned on, and the voltage at the controlled end of the sixth switch tube rises from the third preset voltage to the fourth preset voltage, so that the second switch tube is turned on, so that the voltage at the first end of the OTP module is maintained at the second preset voltage.Through the above circuit, in the non-working mode, the first end of the OTP module needs to be maintained at the first preset voltage, and when an abnormal voltage appears at the first power supply end, it will inevitably cause the voltage at the first end of the OTP module to increase, resulting in the capacitor voltage of the first capacitor and the second capacitor in the first miswrite module to increase, so that the first switch tube is turned on, thereby maintaining the voltage of the first power supply end at the first preset voltage; in the reading mode, through the third switch tube, the fourth switch tube, the fifth switch tube, the sixth switch tube and the seventh switch tube, the third preset voltage of the controlled end of the sixth switch tube cannot turn on the second switch tube, and the first end of the OTP module needs to be maintained at the second preset voltage, and when an abnormal voltage appears at the first power supply end, it will inevitably cause the second preset voltage of the first end of the OTP module to increase, thereby causing the third preset voltage of the controlled end of the sixth switch tube to increase to the fourth preset voltage, and then the second switch tube is turned on, thereby suppressing the voltage rise of the first end of the OTP module, maintaining the voltage of the first end of the OTP module at the second preset voltage, and avoiding miswriting of the OTP module.

[0026] In order to more clearly introduce the technical solution of the present application, the technical solution of the present application will be introduced through specific embodiments below. It should be noted that the specific embodiments are used to expand the technical solution of the present application, but are not intended to limit the present application.

[0027] In some embodiments, see Figure 4 , Figure 4 The embodiment of the present application also provides a schematic diagram of a second circuit for preventing OTP from being written incorrectly. Figure 4 As shown, the OTP miswrite prevention circuit 100 further includes: a third miswrite prevention module 15, and the third miswrite prevention module 15 includes: a first enable terminal VPP_DCHG_EN and an eighth switch tube Q8. The first enable terminal VPP_DCHG_EN is connected to the control terminal of the eighth switch tube Q8, the first terminal of the eighth switch tube Q8 is connected to the first terminal of the OTP module 11, and the second terminal of the eighth switch tube Q8 is grounded.

[0028] Through the third anti-miswrite module 15, when the OTP module 11 ends the read mode or the write mode, the voltage (EXVPP) of the first end of the OTP module 11 is guided to GND, so that the voltage of the first end of the OTP module 11 is maintained at the first preset voltage. The eighth switch tube Q8 is controlled by the signal of the first enable terminal VPP_DCHG_EN.

[0029] In some embodiments, see Figure 5 , Figure 5 The schematic diagram of the third circuit for preventing OTP miswriting provided by the embodiment of the present application is shown. Figure 5As shown, the OTP read-write module also includes: a second enable terminal, a third enable terminal, a fourth enable terminal, a second resistor, a third resistor, a ninth switch tube, a NAND gate component, a NOT gate logic component, an AND gate logic component, a fourth resistor, a fifth resistor, a tenth switch tube, an eleventh switch tube, a twelfth switch tube, a thirteenth switch tube, a fourteenth switch tube, a sixth resistor, and a fifteenth switch tube.

[0030] like Figure 5 As shown, the second enable terminal OTP_PWR_EN is respectively connected to the first end of the second resistor R2 and the first input end of the NAND gate element A1, and the second end of the second resistor R2 is grounded. The second power supply terminal 5VREG is respectively connected to the first end of the third resistor R3, the first end of the fourth resistor R4, and the second end of the fourteenth switch tube Q14. The second end of the third resistor R3 is respectively connected to the second end of the ninth switch tube Q9 and the second input end of the NAND gate element A1. The first end of the ninth switch tube Q9 is grounded. The output end of the NAND gate element A1 is respectively connected to the input end of the NOT gate logic element A2 and the first input end of the AND gate logic element A3. The output end of the NOT gate logic element A2 is connected to the controlled end of the tenth switch tube Q10, and the second input end of the AND gate logic element A3 is connected to the third enable terminal VPP_EN. The first power supply terminal VCC is connected to the first end of the eleventh switch tube Q11, the controlled end of the eleventh switch tube Q11 is respectively connected to the second end of the fourth resistor R4 and the first end of the fifth resistor R5, the second end of the fifth resistor R5 is connected to the first end of the tenth switch tube Q10, the second end of the tenth switch tube Q10 is grounded, the output end of the AND gate logic element A3 is connected to the controlled end of the twelfth switch tube Q12, the controlled end of the thirteenth switch tube Q13 is connected to the fourth enable terminal OTPWR_EN, the first end of the thirteenth switch tube Q13 is connected to the controlled end of the second switch tube Q2, the second end of the thirteenth switch tube Q13 is grounded, the first end of the twelfth switch tube Q12 is respectively connected to the controlled end of the fourteenth switch tube Q14, the first end of the sixth resistor R6, and the controlled end of the fifteenth switch tube Q15, the second end of the sixth resistor R6 is respectively connected to the first end of the fourteenth switch tube Q14 and the first end of the fifteenth switch tube Q15, and the second end of the fifteenth switch tube Q15 is connected to the first end of the OTP module 11.

[0031] The second resistor R2, the third resistor R3, the fourth resistor R4 and the fifth resistor R5 are used for current limiting. The eleventh switch tube Q11 enters the conduction mode by the voltage provided by the second power supply terminal 5VREG to conduct the voltage of the first power supply terminal VCC.

[0032] It should be noted that when the OTP miswrite prevention circuit 100 enters the read mode, the second power supply terminal is 5V, the first enable terminal VPP_DCHGG_EN is at a low level, the second enable terminal OTP_PWR_EN is at a high level, the third enable terminal VPP_EN is at a low level [3], and the fourth enable terminal OTPWR_EN is at a low level.

[0033] An embodiment of the present application provides a chip, and an electronic device includes an anti-OTP miswriting circuit as in any one of the embodiments of the present application.

[0034] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of various equivalent modifications or replacements within the technical scope disclosed in the present application, and these modifications or replacements 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 circuit for preventing OTP from being written in error, characterized in that: The OTP miswrite prevention circuit comprises: an OTP module, a first power supply end, a second power supply end, an OTP read-write module, a first miswrite prevention module and a second miswrite prevention module, wherein the first miswrite prevention module comprises: a first switch tube, a first capacitor, a second capacitor and a first resistor, and the second miswrite prevention module comprises: a second switch tube, a third switch tube, a fourth switch tube, a fifth switch tube, a sixth switch tube and a seventh switch tube; The first power supply end is connected to the first end of the first capacitor, the second end of the first capacitor is respectively connected to the first end of the second capacitor, the first end of the first resistor, and the controlled end of the first switch tube, the second end of the second capacitor is grounded, the second end of the first resistor is grounded, the first end of the first switch tube is connected to the first end of the OTP module, the second end of the first switch tube is grounded, and the second end of the OTP module is grounded, the first power supply end is also respectively connected to the first end of the second switch tube and the first end of the third switch tube, the second end of the second switch tube is grounded, and the controlled end of the third switch tube is respectively connected to the second end of the third switch tube and the first end of the fourth switch tube. The controlled end of the fourth switch tube is respectively connected to the second end of the fourth switch tube and the first end of the fifth switch tube, the controlled end of the fifth switch tube is respectively connected to the second end of the fifth switch tube and the first end of the sixth switch tube, the controlled end of the sixth switch tube is respectively connected to the second end of the sixth switch tube, the first end of the seventh switch tube, and the controlled end of the second switch tube, the controlled end of the seventh switch tube is respectively connected to the second end of the seventh switch tube, and the second end of the seventh switch tube is grounded; the second power supply end is connected to the first end of the OTP read-write module, the second end of the OTP read-write module is connected to the OTP module, and the third end of the OTP read-write module is grounded; Among them, in the non-working mode, the voltage at the first end of the OTP module is a first preset voltage. When the voltage at the first power supply end rises abnormally, the first power supply end charges the first capacitor and the second capacitor, so that the voltage at the controlled end of the first switch tube rises, thereby turning on the first switch tube, and then keeping the first end of the OTP module at the first preset voltage; when the OTP read-write module is in the reading mode, the voltage at the first end of the OTP module is a second preset voltage, and the second preset voltage is the voltage of the second power supply end. When the voltage at the first power supply end rises abnormally, the third switch tube, the fourth switch tube, the fifth switch tube, the sixth switch tube and the seventh switch tube are turned on, and the voltage at the controlled end of the sixth switch tube rises from the third preset voltage to the fourth preset voltage, so that the second switch tube is turned on, so that the voltage at the first end of the OTP module is maintained at the second preset voltage.

2. The OTP miswriting prevention circuit as claimed in claim 1, characterized in that: The OTP mis-write prevention circuit also includes: a third mis-write prevention module, and the third mis-write prevention module includes: a first enable end and an eighth switch tube, the first enable end is connected to the control end of the eighth switch tube, the first end of the eighth switch tube is connected to the first end of the OTP module, and the second end of the eighth switch tube is grounded.

3. The OTP miswriting prevention circuit as claimed in claim 1, characterized in that: The OTP read-write module includes: a second enable terminal, a third enable terminal, a fourth enable terminal, a second resistor, a third resistor, a ninth switch tube, a NAND gate, a NOT gate logic element, an AND gate logic element, a fourth resistor, a fifth resistor, a tenth switch tube, an eleventh switch tube, a twelfth switch tube, a thirteenth switch tube, a fourteenth switch tube, a sixth resistor, and a fifteenth switch tube; The second enable terminal is respectively connected to the first terminal of the second resistor and the first input terminal of the NAND gate component, the second terminal of the second resistor is grounded, the second power supply terminal is respectively connected to the first terminal of the third resistor, the first terminal of the fourth resistor, and the second terminal of the fourteenth switch tube, the second terminal of the third resistor is respectively connected to the second terminal of the ninth switch tube and the second input terminal of the NAND gate component, the first terminal of the ninth switch tube is grounded, the output terminal of the NAND gate component is respectively connected to the input terminal of the NOT gate logic component and the first input terminal of the AND gate logic component, the output terminal of the NOT gate logic component is connected to the controlled terminal of the tenth switch tube, the second input terminal of the AND gate logic component is connected to the third enable terminal, the first power supply terminal is connected to the first terminal of the eleventh switch tube, and the controlled terminals of the eleventh switch tube are respectively connected to the first terminal of the eleventh switch tube. The AND gate logic element is connected to the controlled end of the twelfth switch tube, the controlled end of the thirteenth switch tube is connected to the fourth enable end, the first end of the thirteenth switch tube is connected to the controlled end of the second switch tube, the second end of the thirteenth switch tube is grounded, the first end of the twelfth switch tube is respectively connected to the controlled end of the fourteenth switch tube, the first end of the sixth resistor, and the controlled end of the fifteenth switch tube, the second end of the sixth resistor is respectively connected to the first end of the fourteenth switch tube and the first end of the fifteenth switch tube, and the second end of the fifteenth switch tube is connected to the first end of the OTP module.

4. A chip, characterized in that: The electronic device comprises the OTP miswriting prevention circuit as claimed in any one of claims 1 to 3.