Protection Circuit for Type-C Interface Chip and Method for Determining VBUS Current of Type-C Interface

Through the protection circuit of the Type-C interface chip, the combination of sense resistor and amplifier is used to accurately detect VBUS current, solving the problem of inaccurate VBUS current detection, and achieving high-precision current detection and low power consumption loss.

CN115168267BActive Publication Date: 2025-07-29ANALOGIX SEMICON (SUZHOU) INC +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210764514.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-06-30
Publication Date
2025-07-29
Estimated Expiration
2042-06-30

AI Technical Summary

Technical Problem

In the prior art, the VBUS current detection of the USB Type-C interface is not accurate enough, resulting in low current detection accuracy, and may not be able to detect currents above 5.5A normally. The series resistance will cause the VBUS voltage to drop, increasing power consumption loss.

Method used

The protection circuit using Type-C interface chip, including a sense resistor and an amplifier, accurately detects VBUS current through four switching branches and self-zero structures. The amplifier amplifies the voltage difference between the 10mΩ resistor by 20 times, providing a voltage signal that is easily detected.

Benefits of technology

Accurate detection of VBUS current is achieved, the voltage reduction is less than 0.1%, and the detection accuracy reaches 1.6%, reducing power consumption loss and simplifying the circuit structure.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115168267B_ABST
    Figure CN115168267B_ABST
Patent Text Reader

Abstract

The present invention discloses a protection circuit for a Type-C interface chip and a method for determining the VBUS current of a Type-C interface. The invention includes: a sense resistor, which is respectively connected to a protection sub-circuit inside the Type-C interface chip through a VBUS_P terminal and a VBUS_N terminal, the VBUS_P terminal and the VBUS_N terminal are respectively the two ends of a target VBUS pin, and the target VBUS pin is any one of the VBUS pins provided on the Type-C interface; a protection sub-circuit, which is arranged inside the Type-C interface chip, and the protection sub-circuit includes a first switch branch, a second switch branch, a third switch branch, a fourth switch branch and an amplifier. Through the present invention, the technical problem that the detection means for detecting the VBUS current on the USB Type-C interface in the related art is not accurate enough is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field, and specifically, to a protection circuit for a Type-C interface chip and a method for determining the VBUS current of a Type-C interface. Background Art

[0002] Due to the characteristics of supporting plugging in both directions, small size, supporting high power, high-speed data communication, and audio / video transmission, the USB Type-C interface has been more and more widely used in consumer electronic devices. At the same time, as the functions of various electronic devices become more and more complex, the power consumption has increased significantly. In order to meet the demand for high power consumption, the power consumption supported by the USB Type-C interface is also getting larger and larger. In the USB4.0 protocol, the VBUS supports a maximum voltage of 48V and a current of 5A, with a total maximum power consumption of 240W. Such a large voltage and current pose a great challenge to chip design. Once the voltage or current is too large, the chip is extremely easy to burn out, seriously affecting the use of the USB Type-C interface. Therefore, there is an urgent need for a circuit structure that can accurately detect the VBUS current and voltage.

[0003] In the related art, the detection of the USB Type-C interface current is relatively complex. It is necessary to first convert the current into a voltage and then detect the voltage to obtain the current magnitude. The traditional VBUS current detection structure is to connect a resistor in series on the VBUS. When the current flows through both sides of the resistor, a voltage difference is generated. By detecting the voltage across the resistor, the current passing through the VBUS is calculated. This detection method has two major drawbacks. The first is that the resistor connected in series on the VBUS will reduce the voltage of the VBUS. If connecting a resistor in series on the VBUS causes the VBUS voltage to drop by 0.5V and the current flowing through the resistor is 5A, then the power consumption on the resistor is 5A * 0.5V = 2.5W, resulting in power consumption loss. The second is the insufficient detection accuracy. If the maximum current supported on the Type-C cable is only 5.5A, and the VBUS current detection accuracy is low, it may not be able to normally detect currents above 5.5A, and at this time, the Type-C cable will be burned out.

[0004] Therefore, there is an urgent need for a circuit that can accurately detect the VBUS current without causing too much reduction in the VBUS voltage.

[0005] In view of the above problems existing in the related art, no effective solution has been proposed yet. Summary of the Invention

[0006] The main object of the present invention is to provide a protection circuit for a Type-C interface chip and a method for determining the VBUS current of a Type-C interface, so as to solve the technical problem that the detection means for detecting the VBUS current on the USB Type-C interface in the related art is not accurate enough, achieving the technical effect of being able to accurately detect the VBUS current without causing a significant reduction in the VBUS voltage.

[0007] To achieve the above object, according to one aspect of the present invention, there is provided a protection circuit for a Type-C interface chip. The circuit includes: a sense resistor, which is respectively connected to a protection sub-circuit inside the Type-C interface chip through a VBUS_P terminal and a VBUS_N terminal. The VBUS_P terminal and the VBUS_N terminal are respectively the two ends of a target VBUS pin, and the target VBUS pin is any one of the VBUS pins provided on the Type-C interface; a protection sub-circuit, which is provided inside the Type-C interface chip. The protection sub-circuit includes a first switch branch, a second switch branch, a third switch branch, a fourth switch branch, and an amplifier. The first end of the first switch branch is connected to the VBUS_P terminal, the second end is connected to the positive electrode of the amplifier, the first end of the second switch branch is connected to the VBUS_N terminal, the second end is connected to the negative electrode of the amplifier, the first end of the third switch branch is connected to the first end of the first switch branch, the second end is connected to the second end of the second switch branch, a third switch unit is connected to the third switch branch, the first end of the fourth switch branch is connected to the output terminal of the amplifier, and the second end is grounded.

[0008] Further, a first switch unit and a first resistor are connected to the first switch branch. The first end of the first switch unit is connected to the VBUS_P terminal, the second end of the first switch unit is connected to the first end of the first resistor, and the second end of the first resistor is connected to the positive electrode of the amplifier; a second switch unit and a second resistor are connected to the second switch branch. The first end of the second switch unit is connected to the VBUS_N terminal, the second end of the second switch unit is connected to the first end of the second resistor, and the second end of the second resistor is connected to the negative electrode of the amplifier.

[0009] Further, the amplifier includes an output terminal, a first input terminal, and a second input terminal. An output branch is connected to the output terminal. A fourth resistor is connected to the output branch. One end of the output branch is connected to the output terminal, and the other end is connected to the negative electrode of the amplifier. A reference voltage is connected to the first input terminal. The second input terminal is connected to a connection branch between a fourth switch unit of the fourth switch branch and a capacitor. One end of the fourth switch unit is connected to the output terminal, the other end is connected to the capacitor, and the other end of the capacitor is grounded.

[0010] Further, the protection sub-circuit further includes a third resistor branch, on which a third resistor is connected. One end of the third resistor branch is connected to the connection line between the first resistor and the positive electrode of the amplifier, and the other end of the third resistor is connected to the reference voltage.

[0011] To achieve the above object, according to one aspect of the present invention, there is provided a method for determining the VBUS current of a Type-C interface, which is applied to a protection circuit of a Type-C interface chip. The protection circuit of the Type-C interface chip includes an amplifier, a first switch branch, a second switch branch, a third switch branch, and a fourth switch branch. The method includes: controlling the first switch branch, the third switch branch, and the fourth switch branch to conduct, controlling the second switch branch to disconnect, and obtaining a first output voltage output from the output end of the amplifier; controlling the first switch branch and the second switch branch to conduct, controlling the third switch branch and the fourth switch branch to disconnect, and obtaining a second output voltage output from the output end of the amplifier; and determining the VBUS current based on the first output voltage and the second output voltage.

[0012] Further, the protection circuit of the Type-C interface chip further includes a sense resistor. Determining the VBUS current based on the first output voltage and the second output voltage includes: subtracting the first output voltage from the second output voltage to obtain a difference voltage; and dividing the difference voltage by the resistance value corresponding to the sense resistor to obtain the VBUS current.

[0013] To achieve the above object, according to one aspect of the present invention, there is provided a device for determining the VBUS current of a Type-C interface, which is applied to a protection circuit of a Type-C interface chip. The protection circuit of the Type-C interface chip includes an amplifier, a first switch branch, a second switch branch, a third switch branch, and a fourth switch branch. The device includes: a first acquisition unit, configured to control the first switch branch, the third switch branch, and the fourth switch branch to conduct, control the second switch branch to disconnect, and obtain a first output voltage output from the output end of the amplifier; a second acquisition unit, configured to control the first switch branch and the second switch branch to conduct, control the third switch branch and the fourth switch branch to disconnect, and obtain a second output voltage output from the output end of the amplifier; and a determination unit, configured to determine the VBUS current based on the first output voltage and the second output voltage.

[0014] To achieve the above object, according to one aspect of the present invention, there is provided a protection system for a Type-C interface chip, which includes a protection circuit for a Type-C interface chip according to any one of claims 1 to 4, and a device for determining the VBUS current of a Type-C interface. The device for determining the VBUS current of a Type-C interface is configured to execute a method for determining the VBUS current of a Type-C interface.

[0015] To achieve the above object, according to another aspect of the present invention, there is provided a computer-readable storage medium. The computer-readable storage medium includes a stored program, wherein when the program runs, it controls the device where the computer-readable storage medium is located to execute a method for determining the VBUS current of a Type-C interface.

[0016] To achieve the above object, according to another aspect of the present invention, there is provided a processor. The processor is used to run a program, wherein when the program runs, it executes a method for determining the VBUS current of a Type-C interface.

[0017] According to the present invention, it includes: a sense resistor, which is respectively connected to the internal protection sub-circuit of the Type-C interface chip through the VBUS_P terminal and the VBUS_N terminal. The VBUS_P terminal and the VBUS_N terminal are respectively the two ends of the target VBUS pin, and the target VBUS pin is any one of the VBUS pins set on the Type-C interface; a protection sub-circuit, which is arranged inside the Type-C interface chip. The protection sub-circuit includes a first switch branch, a second switch branch, a third switch branch, a fourth switch branch and an amplifier. The first end of the first switch branch is connected to the VBUS_P terminal, the second end is connected to the positive pole of the amplifier, the first end of the second switch branch is connected to the VBUS_N terminal, the second end is connected to the negative pole of the amplifier, the first end of the third switch branch is connected to the first end of the first switch branch, the second end is connected to the second end of the second switch branch, a third switch unit is connected to the third switch branch, the first end of the fourth switch branch is connected to the output terminal of the amplifier, and the second end is grounded. This solves the technical problem that the detection means for detecting the VBUS current on the USB Type-C interface in the related art is not accurate enough, and achieves the technical effect of being able to accurately detect the VBUS current without causing a large reduction in the VBUS voltage. BRIEF DESCRIPTION OF THE DRAWINGS

[0018] The drawings constituting a part of the present invention are used to provide a further understanding of the present invention. The schematic embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation to the present invention. In the drawings:

[0019] Figure 1 is a schematic structural diagram of a protection circuit of a Type-C interface chip provided according to an embodiment of the present invention; and

[0020] Figure 2 is a flowchart of a method for determining the VBUS current of a Type-C interface provided according to an embodiment of the present invention;

[0021] Figure 3It is a schematic diagram of a device for determining the VBUS current of a Type-C interface according to an embodiment of the present invention.

[0022] It includes the following reference numerals:

[0023] Sense resistor, Rs; protection sub-circuit, 10; first switch unit, S1; second switch unit, S2; third switch unit, S3; fourth switch unit, S4; first resistor, R1; second resistor, R2; third resistor, R3; fourth resistor, R4; amplifier, AMP; reference voltage, Vref; capacitor, C1. Detailed implementation manners

[0024] It should be noted that, without conflict, the embodiments in the present invention and the features in the embodiments may be combined with each other. The present invention will be described in detail below with reference to the drawings and in conjunction with the embodiments.

[0025] In order to enable those skilled in the art to better understand the solution of the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.

[0026] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above drawings are used to distinguish similar objects, and do not have to be used to describe a specific order or sequence. It should be understood that such data can be interchanged under appropriate circumstances, so as to describe the embodiments of the present invention here. In addition, the terms "comprising" and "having" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product or device including a series of steps or units does not have to be limited to those steps or units clearly listed, but may include other steps or units not clearly listed or inherent to these processes, methods, products or devices.

[0027] According to an embodiment of the present invention, a protection circuit for a Type-C interface chip is provided.

[0028] Figure 1 It is a schematic structural diagram of a protection circuit for a Type-C interface chip according to an embodiment of the present invention. As Figure 1 shown, the circuit includes the following parts: sense resistor Rs, protection sub-circuit 10;

[0029] The sensing resistor Rs is connected to the internal protection sub-circuit 10 of the Type-C interface chip through the VBUS_P terminal and the VBUS_N terminal respectively. The VBUS_P terminal and the VBUS_N terminal are respectively the two ends of the target VBUS pin, and the target VBUS pin is any one of the VBUS pins set on the Type-C interface.

[0030] The protection sub-circuit 10 is arranged inside the Type-C interface chip. The protection sub-circuit 10 includes a first switch branch, a second switch branch, a third switch branch, a fourth switch branch and an amplifier AMP. The first end of the first switch branch is connected to the VBUS_P terminal, and the second end is connected to the positive pole of the amplifier AMP. The first end of the second switch branch is connected to the VBUS_N terminal, and the second end is connected to the negative pole of the amplifier AMP. The first end of the third switch branch is connected to the first end of the first switch branch, and the second end is connected to the second end of the second switch branch. A third switch unit S3 is connected to the third switch branch. The first end of the fourth switch branch is connected to the output terminal of the amplifier, and the second end is grounded.

[0031] Specifically, in the protection circuit of the Type-C interface chip provided in the present application, by connecting a precise resistor for sensing the VBUS current in series on the VBUS pin, a voltage difference is generated when the current flows through the circuit. Preferably, the resistance value of the sensing resistor Rs is 10 mΩ. Therefore, when the current flows through the 10 mΩ circuit, a voltage difference is generated. The maximum VBUS current is 5 A, so the voltage across the 10 mΩ precise resistor is 50 mV. Compared with the 48 V on the VBUS, the ratio is 50 mV / 48 V, which is equal to 0.1%. Thus, the reduction of the VBUS voltage caused by the 10 mΩ precise resistor is very small. At the same time, this voltage is very small and difficult to detect. It is necessary for the amplifier AMP in the protection sub-circuit 10 provided in the present application to amplify the voltage difference across the 10 mΩ resistor by 20 times to obtain an easily detectable voltage, and detect the VBUS current through the amplified voltage. The amplifier AMP in the protection sub-circuit 10 also includes a self-zeroing structure, which can eliminate the offset of the amplifier AMP itself, ensure the amplification factor, and thus complete the very precise detection of the VBUS current.

[0032] In the protection circuit of the Type-C interface chip provided in the present application, it can not only accurately detect the VBUS current, but also does not cause a large reduction in the VBUS voltage, and the circuit structure is simple. Compared with other types of offset cancellation structures, such as chopper offset cancellation, the layout area is reduced by more than 5 times.

[0033] In an alternative embodiment, a first switch unit S1 and a first resistor are connected to the first switch branch. The first end of the first switch unit S1 is connected to the VBUS_P terminal, the second end of the first switch unit S1 is connected to the first end of the first resistor, and the second end of the first resistor is connected to the positive electrode of the amplifier; a second switch unit S2 and a second resistor are connected to the second switch branch. The first end of the second switch unit S2 is connected to the VBUS_N terminal, the second end of the second switch unit S2 is connected to the first end of the second resistor, and the second end of the second resistor is connected to the negative electrode of the amplifier.

[0034] In an alternative embodiment, the protection sub-circuit 10 further includes a third resistor R3 branch. A third resistor R3 is connected to the third resistor R3 branch. One end of the third resistor R3 branch is connected to the connection line between the first resistor R1 and the positive electrode of the amplifier AMP, and the other end of the third resistor R3 is connected to the reference voltage.

[0035] In the above embodiment, the protection sub-circuit 10 includes four switch branches. Among them, switch units are correspondingly arranged on the four switch branches. The four switch units are switches controlled by the internal logic of the protection circuit of the Type-C interface chip. R1, R2, R3, and R4 are respectively arranged on the four switch branches and are all internal resistors. Among them, R1 = R2, R3 = R4, AMP is a high-gain amplifier AMP, the input end is connected to R1, R2, R3, and R4, and the output of the amplifier AMP is Vout. The right end of R3 is connected to the reference voltage Vref, Vs is the voltage on the capacitor C1, and the capacitor C1 stores the calibration error voltage generated in the calibration step.

[0036] According to an embodiment of the present invention, a method for determining the VBUS current of a Type-C interface is provided.

[0037] Figure 2 It is a flowchart of a method for determining the VBUS current of a Type-C interface provided according to an embodiment of the present invention. As Figure 2 shown, the above method is applied to a protection circuit of a Type-C interface chip. The protection circuit of the Type-C interface chip includes an amplifier AMP, a first switch branch, a second switch branch, a third switch branch, and a fourth switch branch. The method includes the following steps:

[0038] Step S201, control the first switch branch, the third switch branch, and the fourth switch branch to conduct, control the second switch branch to disconnect, and obtain a first output voltage output by the output end of the amplifier AMP;

[0039] Specifically, the first step of VBUS current detection is as follows: close S1, S3, and S4, and open S2. At this time, the voltages at both ends of the AMP input are equal, and the voltages are both the voltages corresponding to VBUS_P. At this time, the protection circuit of the entire Type-C interface chip works in the calibration stage, and the output voltage Vout is the first output voltage U Vout1 .

[0040] Step S202: Control the first switch branch and the second switch branch to conduct, control the third switch branch and the fourth switch branch to disconnect, and obtain the second output voltage output by the output end of the amplifier AMP; in this step, S1 and S2 are closed, and S3 and S4 are open. At this time, the voltages at both ends of the AMP input are the voltages on the VBUS_P terminal and the voltages on the VBUS_N terminal respectively. At this time, the protection circuit of the entire Type-C interface chip works in the amplification state, and the voltage at the output end of the AMP is the second output voltage.

[0041] Step S203: Determine the VBUS current based on the first output voltage and the second output voltage.

[0042] Specifically, the second output voltage U Vout2 =(R3 / R1)*(U VBUS_P -U VBUS_N ), where U VBUS_P is the voltage on the VBUS_P terminal, and U VBUS_N is the voltage on the VBUS_N terminal.

[0043] Among them, Vout is connected to the internal analog-to-digital converter, and the analog-to-digital converter detects the two Vout voltages through a certain sequential relationship.

[0044] In an optional embodiment, the protection circuit of the Type-C interface chip further includes a sense resistor Rs. Determining the VBUS current based on the first output voltage and the second output voltage includes: subtracting the first output voltage from the second output voltage to obtain a differential voltage; dividing the differential voltage by the resistance value corresponding to the sense resistor Rs to obtain the VBUS current. Further, subtracting the first output voltage from the second output voltage to obtain a voltage difference, and determining the VBUS current based on the voltage difference and the resistance value of the sense resistor Rs, where the VBUS current is the current on VBUS.

[0045] Therefore, the VBUS current is I Rs =(U Vout2 -U Vout1 ) / Rs.

[0046] Through the above method, the offset inside the AMP can be eliminated, and the current on the VBUS can be detected more accurately. According to the process characteristics of TSMC, Monte Carlo simulation shows that the input offset of the traditional AMP is about 20 mV of 3 sigma. Thus, when detecting a 5 A current, the error accuracy is 40%. At the same time, this method can, through internal logic, perform the steps of S101 - S102 many times within a very short time and take the average value, which can also increase the detection accuracy of the VBUS current. According to the test results of the protection circuit of the Type-C interface chip designed according to the present invention, when measuring a 5 A VBUS current, the accuracy can reach 1.6%, that is, 80 mA.

[0047] A method for determining the VBUS current of a Type-C interface provided by an embodiment of the present invention controls the first switch branch, the third switch branch, and the fourth switch branch to conduct, controls the second switch branch to disconnect, and obtains a first output voltage output from the output end of the amplifier AMP; controls the first switch branch and the second switch branch to conduct, controls the third switch branch and the fourth switch branch to disconnect, and obtains a second output voltage output from the output end of the amplifier AMP; and determines the VBUS current based on the first output voltage and the second output voltage, solving the technical problem in the related art that the detection means for detecting the VBUS current on the USB Type-C interface is not accurate enough, and achieving the technical effect of being able to accurately detect the VBUS current without causing a large reduction in the VBUS voltage.

[0048] It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although the logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in a different order than here.

[0049] An embodiment of the present invention also provides a device for determining the VBUS current of a Type-C interface. It should be noted that the Z device in the embodiment of the present invention can be used to execute the method for determining the VBUS current of a Type-C interface provided by the embodiment of the present invention. The following introduces a device for determining the VBUS current of a Type-C interface provided by an embodiment of the present invention.

[0050] An embodiment of the present invention also provides a protection system for a Type-C interface chip, including a protection circuit for a Type-C interface chip and a device for determining the VBUS current of a Type-C interface, and the device for determining the VBUS current of a Type-C interface is used to execute a method for determining the VBUS current of a Type-C interface.

[0051] Figure 3It is a schematic diagram of a device for determining the VBUS current of a Type-C interface according to an embodiment of the present invention. As Figure 3 shown, the device includes: a first acquisition unit 301, configured to control the first switch branch, the third switch branch, and the fourth switch branch to conduct, control the second switch branch to disconnect, and acquire a first output voltage output by the output end of the amplifier; a second acquisition unit 302, configured to control the first switch branch and the second switch branch to conduct, control the third switch branch and the fourth switch branch to disconnect, and acquire a second output voltage output by the output end of the amplifier; a determination unit 303, configured to determine the VBUS current based on the first output voltage and the second output voltage.

[0052] In an optional embodiment, the protection circuit of the Type-C interface chip further includes a sense resistor, and the determination unit includes: a third acquisition unit, configured to subtract the first output voltage from the second output voltage to obtain a difference voltage; a fourth acquisition unit, configured to divide the difference voltage by the resistance value corresponding to the sense resistor to obtain the VBUS current.

[0053] A device for determining the VBUS current of a Type-C interface provided by an embodiment of the present invention, through a first acquisition unit, configured to control the first switch branch, the third switch branch, and the fourth switch branch to conduct, control the second switch branch to disconnect, and acquire a first output voltage output by the output end of the amplifier; a second acquisition unit, configured to control the first switch branch and the second switch branch to conduct, control the third switch branch and the fourth switch branch to disconnect, and acquire a second output voltage output by the output end of the amplifier; a determination unit, configured to determine the VBUS current based on the first output voltage and the second output voltage, solves the technical problem that the detection means for detecting the VBUS current on the USB Type-C interface in the related art is not accurate enough, and achieves the technical effect of being able to accurately detect the VBUS current without causing a large reduction in the VBUS voltage.

[0054] A device for determining the VBUS current of a Type-C interface includes a processor and a memory. The above-mentioned first acquisition unit 301, etc. are all stored in the memory as program units, and the processor executes the above-mentioned program units stored in the memory to implement corresponding functions.

[0055] The processor includes a kernel, and the kernel retrieves the corresponding program units from the memory. One or more kernels can be set, and by adjusting the kernel parameters, the technical problem that the detection means for detecting the VBUS current on the USB Type-C interface in the related art is not accurate enough is solved.

[0056] The memory may include non-permanent memory in the form of computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM, and the memory includes at least one memory chip.

[0057] An embodiment of the present invention provides a storage medium, on which a program is stored, and a method for determining the VBUS current of a Type-C interface is implemented when the program is executed by a processor.

[0058] An embodiment of the present invention provides a processor for running a program, wherein a method for determining the VBUS current of a Type-C interface is executed when the program runs.

[0059] An embodiment of the present invention provides a device, which includes a processor, a memory, and a program stored on the memory and executable on the processor. When the processor executes the program, the following steps are implemented: controlling the first switch branch, the third switch branch, and the fourth switch branch to conduct, controlling the second switch branch to disconnect, and obtaining a first output voltage output from the output end of the amplifier; controlling the first switch branch and the second switch branch to conduct, controlling the third switch branch and the fourth switch branch to disconnect, and obtaining a second output voltage output from the output end of the amplifier; determining the VBUS current based on the first output voltage and the second output voltage.

[0060] Optionally, the protection circuit of the Type-C interface chip further includes a sense resistor. Determining the VBUS current based on the first output voltage and the second output voltage includes: subtracting the first output voltage from the second output voltage to obtain a difference voltage; dividing the difference voltage by the resistance value corresponding to the sense resistor to obtain the VBUS current.

[0061] The device herein may be a server, a PC, a PAD, a mobile phone, etc.

[0062] The present invention also provides a computer program product, which is suitable for executing a program initialized with the following method steps when executed on a data processing device: controlling the first switch branch, the third switch branch, and the fourth switch branch to conduct, controlling the second switch branch to disconnect, and obtaining a first output voltage output from the output end of the amplifier; controlling the first switch branch and the second switch branch to conduct, controlling the third switch branch and the fourth switch branch to disconnect, and obtaining a second output voltage output from the output end of the amplifier; determining the VBUS current based on the first output voltage and the second output voltage.

[0063] Optionally, the protection circuit of the Type-C interface chip further includes a sense resistor. Determining the VBUS current based on the first output voltage and the second output voltage includes: subtracting the first output voltage from the second output voltage to obtain a differential voltage; dividing the differential voltage by the resistance value corresponding to the sense resistor to obtain the VBUS current.

[0064] Those skilled in the art will understand that the embodiments of the present invention can be provided as a method, a system, or a computer program product. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Moreover, the present invention can take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0065] The present invention is described with reference to the flowcharts and / or block diagrams of methods, apparatuses (systems), and computer program products according to embodiments of the present invention. It should be understood that each flow and / or block in the flowchart and / or block diagram, and the combination of flows and / or blocks in the flowchart and / or block diagram, can be realized by computer program instructions. These computer program instructions can be provided to the processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing devices to generate a machine, such that the instructions executed by the processor of the computer or other programmable data processing devices generate means for realizing the functions specified in Figure 1 one or more of the processes or multiple processes and / or blocks Figure 1 one or more of the blocks or multiple blocks.

[0066] These computer program instructions can also be stored in a computer-readable memory capable of guiding the computer or other programmable data processing devices to work in a specific manner, such that the instructions stored in the computer-readable memory generate a manufactured article including instruction means, and the instruction means realizes the functions specified in Figure 1 one or more of the processes or multiple processes and / or blocks Figure 1 one or more of the blocks or multiple blocks.

[0067] These computer program instructions can also be loaded onto the computer or other programmable data processing devices, such that a series of operation steps are executed on the computer or other programmable devices to generate a computer-implemented process, and thus the instructions executed on the computer or other programmable devices provide steps for realizing the functions specified in Figure 1 one or more of the processes or multiple processes and / or blocks Figure 1 one or more of the blocks or multiple blocks.

[0068] In a typical configuration, a computing device includes one or more processors (CPUs), an input / output interface, a network interface, and a memory.

[0069] The memory may include non-permanent memory in a computer-readable medium, random access memory (RAM) and / or non-volatile memory in the form of read-only memory (ROM) or flash RAM. The memory is an example of a computer-readable medium.

[0070] Computer readable media include permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. Information can be computer readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer readable media does not include temporary computer readable media (transitory media), such as modulated data signals and carrier waves.

[0071] It should also be noted that the terms "comprises," "includes," or any other variations thereof are intended to encompass non-exclusive inclusion, such that a process, method, commodity, or apparatus that includes a series of elements includes not only those elements but also other elements not explicitly listed, or includes elements inherent to such process, method, commodity, or apparatus. In the absence of further limitations, an element defined by the phrase "comprises a ..." does not exclude the presence of other identical elements in the process, method, commodity, or apparatus that includes the element.

[0072] Those skilled in the art will appreciate that embodiments of the present invention may be provided as methods, systems, or computer program products. Thus, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0073] The above are only embodiments of the present invention and are not intended to limit the present invention. For those skilled in the art, various modifications and variations can be made to the present invention. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included within the scope of the claims of the present invention.

Claims

1. A protection circuit for a Type-C interface chip, characterized in that, Comprising: A sense resistor (Rs) is respectively connected to a protection sub-circuit (10) inside the Type-C interface chip through a VBUS_P terminal and a VBUS_N terminal. The VBUS_P terminal and the VBUS_N terminal are respectively two ends of a target VBUS pin, and the target VBUS pin is any one of the VBUS pins provided on the Type-C interface; A protection sub-circuit (10) is provided inside the Type-C interface chip. The protection sub-circuit (10) includes a first switch branch, a second switch branch, a third switch branch, a fourth switch branch, and an amplifier (AMP). A first end of the first switch branch is connected to the VBUS_P terminal, and a second end is connected to the positive electrode of the amplifier (AMP). A first end of the second switch branch is connected to the VBUS_N terminal, and a second end is connected to the negative electrode of the amplifier (AMP). A first end of the third switch branch is connected to the first end of the first switch branch, and a second end is connected to the second end of the second switch branch. A third switch unit (S3) is connected to the third switch branch. A first end of the fourth switch branch is connected to the output end of the amplifier (AMP), and a second end is grounded; Wherein, a first switch unit (S1) and a first resistor (R1) are connected to the first switch branch. A first end of the first switch unit (S1) is connected to the VBUS_P terminal, a second end of the first switch unit (S1) is connected to a first end of the first resistor (R1), and a second end of the first resistor (R1) is connected to the positive electrode of the amplifier (AMP); A second switch unit (S2) and a second resistor (R2) are connected to the second switch branch. A first end of the second switch unit (S2) is connected to the VBUS_N terminal, a second end of the second switch unit (S2) is connected to a first end of the second resistor (R2), and a second end of the second resistor (R2) is connected to the negative electrode of the amplifier (AMP).

2. The protection circuit according to claim 1, characterized in that, The amplifier (AMP) includes the output end, a first input end, and a second input end. The output end is connected to an output branch. A fourth resistor (R4) is connected to the output branch. One end of the output branch is connected to the output end, and the other end is connected to the negative electrode of the amplifier (AMP). The first input end is connected to a reference voltage (Vref). The second input end is connected to a connection branch between a fourth switch unit (S4) and a capacitor (C1) of the fourth switch branch. One end of the fourth switch unit (S4) is connected to the output end, and the other end is connected to the capacitor (C1). The other end of the capacitor (C1) is grounded.

3. The protection circuit according to claim 1, characterized in that The protection sub-circuit (10) further includes a third resistor (R3) branch, on which a third resistor (R3) is connected. One end of the third resistor (R3) branch is connected to the connection line between the first resistor (R1) and the positive electrode of the amplifier (AMP), and the other end of the third resistor (R3) is connected to the reference voltage (Vref).

4. A method for determining the VBUS current of a Type-C interface, characterized in that, Applied to the protection circuit of a Type-C interface chip according to any one of claims 1 to 3, the protection circuit of the Type-C interface chip includes an amplifier, a first switch branch, a second switch branch, a third switch branch, and a fourth switch branch. The method includes: Controlling the first switch branch, the third switch branch, and the fourth switch branch to conduct, controlling the second switch branch to disconnect, and obtaining a first output voltage output by the output end of the amplifier; Controlling the first switch branch and the second switch branch to conduct, controlling the third switch branch and the fourth switch branch to disconnect, and obtaining a second output voltage output by the output end of the amplifier; Determining the VBUS current according to the first output voltage and the second output voltage.

5. The method according to claim 4, characterized in that The protection circuit of the Type-C interface chip further includes a sense resistor. Determining the VBUS current according to the first output voltage and the second output voltage includes: Subtracting the first output voltage from the second output voltage to obtain a differential voltage; Dividing the differential voltage by the resistance value corresponding to the sense resistor to obtain the VBUS current.

6. A device for determining the VBUS current of a Type-C interface, characterized in that, Applied to the protection circuit of a Type-C interface chip according to any one of claims 1 to 3, the protection circuit of the Type-C interface chip includes an amplifier (AMP), a first switch branch, a second switch branch, a third switch branch, and a fourth switch branch. The device includes: A first acquisition unit, configured to control the first switch branch, the third switch branch, and the fourth switch branch to conduct, control the second switch branch to disconnect, and obtain a first output voltage output by the output end of the amplifier (AMP); A second acquisition unit, configured to control the first switch branch and the second switch branch to conduct, control the third switch branch and the fourth switch branch to disconnect, and obtain a second output voltage output by the output end of the amplifier (AMP); A determination unit, configured to determine the VBUS current according to the first output voltage and the second output voltage.

7. A protection system for a Type-C interface chip, characterized in that, Including the protection circuit of a Type-C interface chip according to any one of claims 1 to 3, and including the device for determining the VBUS current of a Type-C interface according to claim 6.

8. A computer-readable storage medium, characterized in that, The computer-readable storage medium includes a stored program, wherein when the program runs, it controls the device where the computer-readable storage medium is located to execute the method for determining the VBUS current of a Type-C interface according to any one of claims 4 to 5.

9. A processor, characterized in that, The processor is used to run a program, wherein, when the program runs, it executes a method for determining the VBUS current of a Type-C interface according to any one of claims 4 to 5.

Citation Information

Patent Citations

  • Battery protection circuit capable of sampling current accurately

    CN104821555A

  • Circuit supporting OTG function, terminal and control method of circuit

    CN107480086A