Power supply device and method for detecting same

By outputting a preset current between the interfaces of the power supply device and calculating the cable resistance, the problem of users being unable to identify the quality of cables is solved, and cable impedance detection and power supply device efficiency are improved.

CN123136183APending Publication Date: 2026-11-20ANKER INNOVATIONS TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510654609.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-05-20
Publication Date
2026-11-20

Smart Images

  • Figure CN123136183A_ABST
    Figure CN123136183A_ABST
Patent Text Reader

Abstract

The application discloses a power supply device and a detection method thereof. The power supply device comprises a first interface and a second interface. The detection method comprises the following steps: when the first interface is electrically connected with the second interface through a cable, controlling the power supply device to output a preset current between the first interface and the second interface through the cable; acquiring a first voltage of the first interface and a second voltage of the second interface; and obtaining the resistance value of the cable based on the first voltage, the second voltage and the preset current. The resistance value of the cable is obtained based on the first voltage, the second voltage and the preset current, so that the user can know the impedance of the cable, the quality of the cable can be determined through the impedance of the cable, the influence of the impedance of the cable on the power supply device is reduced, and the efficiency of the power supply device is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of power supply technology, and in particular to a power supply device and its testing method. Background Technology

[0002] With the rapid development of electronic devices such as smartphones and tablets, power supply devices adapted to these devices, such as chargers, are needed to charge mobile phones via cables.

[0003] Current cables include electronic marker chips (E-markers), which power supply devices use to identify the current corresponding to the cable, such as whether the cable current is 3A or 5A. When multiple cables all have a current of 3A, because the cross-sectional diameter and / or length of the cables are different, users cannot distinguish the quality of the cables. Summary of the Invention

[0004] This application mainly provides a power supply device and its testing method to solve the problem that users cannot identify the quality of cables.

[0005] This application provides a method for detecting a power supply device, the power supply device including a first interface and a second interface, the detection method comprising:

[0006] When the first interface is electrically connected to the second interface via a cable, the power supply device is controlled to output a preset current between the first interface and the second interface via the cable;

[0007] Obtain the first voltage of the first interface and the second voltage of the second interface;

[0008] The resistance value of the cable is obtained based on the first voltage, the second voltage, and the preset current.

[0009] The power supply device includes a constant current circuit, and controlling the power supply device to output a preset current between the first interface and the second interface via the cable includes:

[0010] The constant current circuit is electrically connected to the first interface and the second interface respectively, and the constant current circuit outputs the preset current between the first interface and the second interface through the cable;

[0011] At preset time intervals, acquire the first voltage of the first interface and the second voltage of the second interface.

[0012] The step of obtaining the resistance value of the cable based on the first voltage, the second voltage, and the preset current includes:

[0013] Obtain the absolute value of the difference between the first voltage and the second voltage, and divide the absolute value by the preset current to obtain the resistance value.

[0014] The power supply device further includes a trigger, a first switching circuit, a second switching circuit, a third switching circuit, a fourth switching circuit, a power supply circuit, and a protocol chip. The constant current circuit is electrically connected to the first interface through the first switching circuit, the constant current circuit is electrically connected to the second interface through the second switching circuit, the power supply circuit is electrically connected to the first interface through the third switching circuit, the power supply circuit is electrically connected to the second interface through the fourth switching circuit, and the protocol chip is electrically connected to the third switching circuit and the fourth switching circuit, respectively.

[0015] The constant current circuit that controls the electrical connection to the first interface and the second interface respectively includes:

[0016] In response to receiving a first trigger signal from the trigger element, the system enters detection mode;

[0017] The first and second switching circuits are turned on based on the first trigger signal, and the third and fourth switching circuits are turned off based on the protocol chip.

[0018] The detection method further includes:

[0019] After obtaining the resistance value, the first and second switching circuits are disconnected, and the third and fourth switching circuits are turned on by the protocol chip, so that the power supply circuit supplies power to the first and second interfaces.

[0020] Upon receiving a second trigger signal from the trigger element, the detection mode is exited.

[0021] The detection method further includes:

[0022] When the first interface or the second interface is electrically connected to the receiving device via the cable, the power supply device is controlled to output the preset current to the first interface or the second interface.

[0023] Obtain the first voltage of the first interface or the second voltage of the second interface, and obtain the resistance value of the cable based on the first voltage or the second voltage and the preset current.

[0024] The step of controlling the power supply device to output the preset current to the first interface or the second interface includes:

[0025] Receive request information from the receiving device through the first interface or the second interface, and obtain the preset current and preset voltage from the request information;

[0026] Control the power supply device to output the preset current and the preset voltage to the first interface or the second interface;

[0027] The step of obtaining the first voltage of the first interface or the second voltage of the second interface includes:

[0028] A status data packet is obtained from the receiving device through the first interface or the second interface, the status data packet including the input voltage of the receiving device;

[0029] Obtain the input voltage of the receiving device.

[0030] The step of obtaining the resistance value of the cable based on the first voltage or the second voltage and the preset current includes:

[0031] Obtain the difference between the first voltage and the input voltage, or the difference between the second voltage and the input voltage, and divide the difference by the preset current to obtain the resistance value.

[0032] The step of obtaining the resistance value of the cable based on the first voltage or the second voltage and the preset current includes:

[0033] When the cable includes an electronic marker chip, the difference between the first voltage and the input voltage, or the difference between the second voltage and the input voltage, is obtained, and the difference is divided by the sum of the preset current and the preset compensation current to obtain the resistance value.

[0034] This application also provides a power supply device, including a control circuit, a constant current circuit, a first interface, and a second interface. The control circuit is electrically connected to the constant current circuit, the first interface, and the second interface, respectively. A cable is electrically connected between the first interface and the second interface. The control circuit is used for:

[0035] The constant current circuit is electrically connected to the first interface and the second interface respectively, and the constant current circuit outputs the preset current between the first interface and the second interface through the cable;

[0036] Obtain the first voltage of the first interface, and obtain the second voltage of the second interface;

[0037] The resistance value of the cable is obtained based on the first voltage, the second voltage, and the preset current.

[0038] The control circuit is used to obtain the absolute value of the difference between the first voltage and the second voltage, and divide the absolute value by the preset current to obtain the resistance value.

[0039] The power supply device further includes a trigger, a first switching circuit, a second switching circuit, a third switching circuit, a fourth switching circuit, a power supply circuit, and a protocol chip. The constant current circuit is electrically connected to the first interface through the first switching circuit, the constant current circuit is electrically connected to the second interface through the second switching circuit, the power supply circuit is electrically connected to the first interface through the third switching circuit, and the power supply circuit is electrically connected to the second interface through the fourth switching circuit. The protocol chip is electrically connected to both the third and fourth switching circuits. The control circuit is electrically connected to the first switching circuit, the second switching circuit, and the protocol chip. The control circuit is used for:

[0040] In response to receiving a first trigger signal from the trigger element, the system enters detection mode;

[0041] Based on the first trigger signal, the first and second switching circuits are turned on, and the third and fourth switching circuits are turned off by the protocol chip.

[0042] After obtaining the resistance value, the first and second switching circuits are disconnected, and the third and fourth switching circuits are turned on by the protocol chip, so that the power supply circuit supplies power to the first and second interfaces.

[0043] Upon receiving a second trigger signal from the trigger element, the detection mode is exited.

[0044] The beneficial effects of this application are as follows: The power supply device of this application includes a first interface and a second interface. When the first interface is electrically connected to the second interface through the cable, the power supply device is controlled to output a preset current between the first interface and the second interface through the cable; a first voltage of the first interface and a second voltage of the second interface are acquired; and the resistance value of the cable is obtained based on the first voltage, the second voltage, and the preset current. Obtaining the cable resistance value through the first voltage, the second voltage, and the preset current facilitates the user's understanding of the cable impedance, allowing for the determination of cable quality based on the cable impedance, reducing the impact of cable impedance on the power supply device, and improving the efficiency of the power supply device. Attached Figure Description

[0045] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort. Wherein:

[0046] Figure 1 This is a schematic diagram of the framework of the first embodiment of the power supply device provided in this application;

[0047] Figure 2 yes Figure 1 A flowchart illustrating the first embodiment of the detection method for power supply equipment;

[0048] Figure 3 yes Figure 2 A flowchart illustrating the first embodiment of step S101;

[0049] Figure 4 This is a schematic diagram of the framework of the second embodiment of the power supply device provided in this application;

[0050] Figure 5 yes Figure 4 A flowchart illustrating the second embodiment of the detection method for power supply equipment;

[0051] Figure 6 This is a schematic diagram of the framework of the third embodiment of the power supply device provided in this application;

[0052] Figure 7 yes Figure 6 A flowchart illustrating the third embodiment of the detection method for power supply equipment;

[0053] Figure 8 yes Figure 7 A flowchart illustrating the first embodiment of step S301;

[0054] Figure 9 yes Figure 7 A flowchart illustrating the first embodiment of step S302;

[0055] Figure 10 yes Figure 6 A flowchart illustrating the third embodiment of the detection method for power supply equipment. Detailed Implementation

[0056] The embodiments of the technical solution of this application will now be described in detail with reference to the accompanying drawings. These embodiments are only used to more clearly illustrate the technical solution of this application and are therefore merely examples, and should not be used to limit the scope of protection of this application.

[0057] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application pertains; the terminology used herein is for the purpose of describing particular embodiments only and is not intended to limit the application; the terms “comprising” and “having”, and any variations thereof, in the specification, claims, and foregoing description of the drawings are intended to cover non-exclusive inclusion.

[0058] In the description of the embodiments of this application, technical terms such as "first" and "second" are used only to distinguish different objects and should not be construed as indicating or implying relative importance or implicitly indicating the number, specific order, or primary and secondary relationship of the indicated technical features.

[0059] In this document, the term "embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of this application. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a separate or alternative embodiment mutually exclusive with other embodiments. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein can be combined with other embodiments.

[0060] In the description of the embodiments in this application, the term "and / or" is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, and B existing alone. Additionally, the character " / " in this document generally indicates that the preceding and following related objects have an "or" relationship.

[0061] In the description of the embodiments of this application, the term "multiple" refers to two or more (including two), similarly, "multiple sets" refers to two or more (including two sets), and "multiple pieces" refers to two or more (including two pieces).

[0062] In the description of the embodiments of this application, unless otherwise expressly specified and limited, the technical terms such as "installation," "connection," "joining," and "fixing" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral part; they can refer to a mechanical connection or an electrical connection; they can refer to a connection between two components or an indirect connection through an intermediate medium; they can refer to the internal communication of two components or the interaction between two components. For those skilled in the art, the specific meaning of the above terms in the embodiments of this application can be understood according to the specific circumstances.

[0063] This application provides a power supply device; please refer to [link / reference]. Figure 1 and Figure 2 As shown, Figure 1 This is a schematic diagram of the framework of the first embodiment of the power supply device provided in this application; Figure 2 yes Figure 1 A flowchart illustrating the first embodiment of the detection method for power supply devices. The power supply device 1 in this embodiment includes, but is not limited to, adapters, power banks, desktop chargers, or hubs; for example, the power supply device 1 is an adapter used to charge electronic devices, including but not limited to smartphones and tablets.

[0064] The power supply device 1 in this embodiment includes a first interface 11 and a second interface 12. The first interface 11 and the second interface 12 can be a USB Type-C interface. In other embodiments, the first interface 11 and the second interface 12 can be other types of interfaces, such as USB Type-A.

[0065] The detection method in this embodiment includes the following steps.

[0066] S101: When the first interface 11 is electrically connected to the second interface 12 via cable 2, the control power supply device 1 outputs the acquired preset current between the first interface 11 and the second interface 12 via cable 2.

[0067] The power supply device 1 acquires a preset current, which includes, but is not limited to, 3A or 5A. In other embodiments, the preset current may also be greater than 0A and less than 3A, for example, the power supply device 1 acquires a preset current of 1A.

[0068] The first interface 11 is electrically connected to the second interface 12 via cable 2. The power supply device 1 outputs the preset current obtained between the first interface 11 and the second interface 12 via cable 2. Cable 2 includes, but is not limited to, a data cable.

[0069] In some embodiments, if the preset current obtained by the power supply device 1 is 3A, then the power supply device 1 is controlled to output 3A through the cable 2 between the first interface 11 and the second interface 12.

[0070] S102: Obtain the first voltage of the first interface 11 and the second voltage of the second interface 12.

[0071] Power supply device 1 acquires a first voltage from the first interface 11 and a second voltage from the second interface 12. For example, power supply device 1 samples the first voltage from the first interface 11 and samples the second voltage from the second interface 12.

[0072] S103: Based on the first voltage, the second voltage, and the preset current, obtain the resistance value of cable 2.

[0073] The power supply device 1 obtains the resistance value of the cable 2 based on the first voltage, the second voltage, and the preset current.

[0074] In some embodiments, after obtaining the resistance value of the cable 2, the power supply device 1 displays the resistance value of the cable 2 through a display unit, so that the user can easily know the resistance value of the cable 2.

[0075] In this embodiment, when the first interface 11 is electrically connected to the second interface 12 via cable 2, the power supply device 1 outputs a preset current between the first interface 11 and the second interface 12 via cable 2; it acquires a first voltage at the first interface 11 and a second voltage at the second interface 12; and based on the first voltage, the second voltage, and the preset current, it obtains the resistance value of cable 2. Obtaining the resistance value through the first voltage, the second voltage, and the preset current allows the user to easily determine the resistance value of cable 2, thereby assessing the quality of cable 2, reducing the impact of cable 2 impedance on the power supply device 1, and improving the efficiency of the power supply device 1.

[0076] According to some embodiments of this application, please refer to Figure 1 As shown, the power supply device 1 in this embodiment also includes a constant current circuit 20, and the cable 2 is electrically connected between the first interface 11 and the second interface 12.

[0077] Step S101 includes: controlling the constant current circuit 20 to be electrically connected to the first interface 11 and the second interface 12 respectively, and controlling the constant current circuit 20 to output the acquired preset current between the first interface 11 and the second interface 12 through the cable 2.

[0078] The constant current circuit 20 is electrically connected to the first interface 11 and the second interface 12. The constant current circuit 20 includes, but is not limited to, a constant current source, which is used to output a preset current. For example, the constant current circuit 20 outputs 3A to both the first interface 11 and the second interface 12.

[0079] Step S102 includes: at preset time intervals, acquiring the first voltage of the first interface 11 and the second voltage of the second interface 12.

[0080] After the constant current circuit 20 is electrically connected to the first interface 11 and the second interface 12 respectively, the power supply device 1 acquires the first voltage of the first interface 11 and the second voltage of the second interface 12 at preset intervals. For example, the preset time is 50ms; in other embodiments, the preset time can be other values, such as 30ms.

[0081] Step S103 includes: obtaining the absolute value of the difference between the first voltage and the second voltage, and dividing the absolute value by a preset current to obtain the resistance value.

[0082] In this process, power supply device 1 obtains the absolute value of the difference between the first voltage and the second voltage, divides the absolute value by a preset current, and obtains the resistance value. Therefore, the resistance value satisfies the following formula:

[0083] R = |V1 - V2| / I (1)

[0084] Where R is the resistance of cable 2, V1 is the first voltage, and V2 is the second voltage.

[0085] In some embodiments, the higher the resistance of cable 2, the worse cable 2 is; the lower the resistance of cable 2, the better cable 2 is, in order to determine the quality of cable 2.

[0086] In this embodiment, a constant current circuit 20 is electrically connected to the first interface 11 and the second interface 12 respectively. The constant current circuit 20 outputs a preset current between the first interface 11 and the second interface 12 through the cable 2. A first voltage of the first interface 11 and a second voltage of the second interface 12 are obtained. The absolute value of the difference between the first voltage and the second voltage is obtained, and the absolute value is divided by the preset current to obtain the resistance value. By obtaining the resistance value through the first voltage, the second voltage, and the preset current, the user can easily know the resistance value of the cable 2, determine the quality of the cable 2 by its impedance, reduce the impact of the cable 2 impedance on the power supply device 1, and improve the efficiency of the power supply device 1.

[0087] According to some embodiments of this application, please refer to Figure 1 As shown, the power supply device 1 in this embodiment further includes a trigger 30, a first switching circuit 31, a second switching circuit 32, a third switching circuit 33, a fourth switching circuit 34, a power supply circuit 40, and a protocol chip 50. The constant current circuit 20 is electrically connected to the first interface 11 through the first switching circuit 31, and to the second interface 12 through the second switching circuit 32. The power supply circuit 40 is electrically connected to the first interface 11 through the third switching circuit 33, and to the second interface 12 through the fourth switching circuit 34. The protocol chip 50 is electrically connected to both the third switching circuit 33 and the fourth switching circuit 34.

[0088] Among them, the trigger 30 includes, but is not limited to, a button. When the button is pressed, the first trigger signal is received from the trigger 30, and the power supply device 1 enters the detection mode to detect the resistance of the cable 2 through the power supply device 1.

[0089] Please see Figure 3 As shown, Figure 3 yes Figure 2 A flowchart illustrating the first embodiment of step S101. The constant current control circuit 20 is electrically connected to the first interface 11 and the second interface 12, and includes the following steps:

[0090] S201: In response to the first trigger signal received from the trigger 30, enter the detection mode.

[0091] When the trigger 30 is pressed once, the power supply device 1 responds to receiving the first trigger signal from the trigger 30 and enters the detection mode to detect the resistance of the cable 2.

[0092] S202: Based on the first trigger signal, control the first switch circuit 31 and the second switch circuit 32 to be turned on, and control the third switch circuit 33 and the fourth switch circuit 34 to be turned off through the protocol chip 50.

[0093] When power supply device 1 receives the first trigger signal, it controls the first switching circuit 31 and the second switching circuit 32 to turn on, and controls the third switching circuit 33 and the fourth switching circuit 34 to turn off through the protocol chip 50. At this time, the constant current circuit 20 is electrically connected to the first interface 11 through the first switching circuit 31, and the constant current circuit 20 is electrically connected to the second interface 12 through the second switching circuit 32.

[0094] In some embodiments, the protocol chip 50 may also be electrically connected to the first interface 11 and the second interface 12 respectively. The protocol chip 50 is used to identify the fast charging protocol of the first interface 11 and the fast charging protocol of the second interface 12.

[0095] The detection method of this embodiment further includes: after obtaining the resistance value, that is, after obtaining the resistance value of the cable 2, controlling the first switch circuit 31 and the second switch circuit 32 to disconnect, and controlling the third switch circuit 33 and the fourth switch circuit 34 to conduct through the protocol chip 50, so that the power supply circuit 40 supplies power to the first interface 11 and the second interface 12; in response to receiving the second trigger signal from the trigger 30, exiting the detection mode.

[0096] After checking the resistance value of cable 2, cable 2 is electrically connected to the first interface 11 or the second interface 12, meaning cable 2 is not electrically connected between the first interface 11 and the second interface 12. The power supply device 1 controls the first switching circuit 31 and the second switching circuit 32 to disconnect, meaning the constant current circuit 20 is disconnected from both the first and second interfaces 11 and 12. The protocol chip 50 controls the third switching circuit 33 and the fourth switching circuit 34 to conduct. At this time, the power supply circuit 40 is electrically connected to the first interface 11 and the second interface 12 respectively to supply power to the first and second interfaces 11 and 12, thereby charging the corresponding electronic devices through the first and second interfaces 11 and 12.

[0097] When the trigger 30 is pressed again, the detection mode is exited in response to receiving the second trigger signal from the trigger 30. The first switch circuit 31, the second switch circuit 32, the third switch circuit 33, and the fourth switch circuit 34 can all be switching transistors, such as MOSFETs.

[0098] This embodiment controls the first switch circuit 31 and the second switch circuit 32 to conduct based on the first trigger signal, and controls the third switch circuit 33 and the fourth switch circuit 34 to disconnect through the protocol chip 50; it can realize the constant current circuit 20 to output a preset current to the first interface 11 and the second interface 12, which is easy to implement and reduces costs.

[0099] This application also provides a power supply device 1, please refer to [link to application]. Figure 4 As shown, Figure 4 This is a schematic diagram of the framework of a second embodiment of the power supply device provided in this application. The power supply device 1 in this embodiment includes a control circuit 60, a constant current circuit 20, a first interface 11, and a second interface 12. The control circuit 60 is electrically connected to the constant current circuit 20, the first interface 11, and the second interface 12, respectively, and a cable 2 is electrically connected between the first interface 11 and the second interface 12. The control circuit 60 includes, but is not limited to, an MCU (Microcontroller Unit).

[0100] The control circuit 60 is used to control the constant current circuit 20 to be electrically connected to the first interface 11 and the second interface 12 respectively, and to control the constant current circuit 20 to output the preset current obtained between the first interface 11 and the second interface 12 through the cable 2.

[0101] The control circuit 60 is used to obtain the first voltage of the first interface 11 and the second voltage of the second interface 12; based on the first voltage, the second voltage and the preset current, the resistance value of the cable 2 is obtained.

[0102] In this embodiment, the control circuit 60 controls the constant current circuit 20 to be electrically connected to the first interface 11 and the second interface 12 respectively; it acquires the first voltage of the first interface 11 and the second voltage of the second interface 12; and based on the first voltage, the second voltage, and a preset current, it obtains the resistance value of the cable 2. This method allows the user to easily obtain the resistance value of the cable 2, enabling them to determine the quality of the cable 2 by its impedance, reducing the impact of the cable 2's impedance on the power supply device 1, and improving the efficiency of the power supply device 1.

[0103] According to some embodiments of this application, the control circuit 60 is used to obtain the absolute value of the difference between the first voltage and the second voltage, divide the absolute value by the preset current, and obtain the resistance value, which satisfies the above formula (1).

[0104] Please see Figure 4 As shown, the control circuit 60 also includes a trigger 30, a first switch circuit 31, a second switch circuit 32, a third switch circuit 33, a fourth switch circuit 34, a power supply circuit 40, and a protocol chip 50.

[0105] The constant current circuit 20 is electrically connected to the first interface 11 through the first switching circuit 31, and the constant current circuit 20 is electrically connected to the second interface 12 through the second switching circuit 32. The power supply circuit 40 is electrically connected to the first interface 11 through the third switching circuit 33, and the power supply circuit 40 is electrically connected to the second interface 12 through the fourth switching circuit 34. The protocol chip 50 is electrically connected to the third switching circuit 33 and the fourth switching circuit 34 respectively. The control circuit 60 is electrically connected to the trigger 30, the first switching circuit 31, the second switching circuit 32 and the protocol chip 50 respectively.

[0106] The control circuit 60 is also used to enter the detection mode in response to receiving a first trigger signal from the trigger element 30; control the first switch circuit 31 and the second switch circuit 32 to disconnect based on the first trigger signal, and control the third switch circuit 33 and the fourth switch circuit 34 to disconnect through the protocol chip 50; after obtaining the resistance value, control the first switch circuit 31 and the second switch circuit 32 to disconnect, and control the third switch circuit 33 and the fourth switch circuit 34 to conduct through the protocol chip 50, so that the power supply circuit 40 supplies power to the first interface 11 and the second interface 12; and exit the detection mode in response to receiving a second trigger signal from the trigger element 30.

[0107] Among them, the control circuit 60 controls the third switch circuit 33 and the fourth switch circuit 34 to be turned on or off through the protocol chip 50.

[0108] In some embodiments, see Figure 4 and Figure 5 As shown, Figure 5 yes Figure 4 A flowchart illustrating a second embodiment of the detection method for a power supply device. The power supply device 1 in this embodiment further includes a conversion circuit 70, which is electrically connected to the control circuit 60, the first interface 11, and the second interface 12. The conversion circuit 70 can be an ADC conversion circuit. The detection method includes the following steps.

[0109] S401: The trigger 30 is pressed, and the control circuit 60 receives the first trigger signal.

[0110] When the user presses the trigger 30, the control circuit 60 receives the first trigger signal and enters the detection mode.

[0111] S402: Control circuit 60 controls constant current circuit 20 to output preset current.

[0112] The control circuit 60 controls the constant current circuit 20 to output a preset current, so as to control the constant current circuit 20 to output the preset current obtained through the cable 2 between the first interface 11 and the second interface 12, for example, the preset current is 3A.

[0113] S403: Control circuit 60 controls the first switch circuit 31 to conduct.

[0114] S404: Protocol chip 50 controls the third switch circuit 33 to disconnect.

[0115] The control circuit 60 sends a control command to the protocol chip 50 so that the protocol chip 50 controls the third switch circuit 33 to disconnect.

[0116] S405: Control circuit 60 controls the second switch circuit 32 to conduct.

[0117] S406: Protocol chip 50 controls the fourth switch circuit 34 to disconnect.

[0118] The control circuit 60 sends a control command to the protocol chip 50 so that the protocol chip 50 controls the second switch circuit 32 to disconnect.

[0119] S407: Control circuit 60 obtains the first voltage from first interface 11 through conversion circuit 70.

[0120] S408: Control circuit 60 obtains the second voltage from second interface 12 through conversion circuit 70.

[0121] S409: Control circuit 60 obtains the absolute value of the difference between the first voltage and the second voltage, divides the difference by the preset current, and obtains the resistance value.

[0122] S410: Control circuit 60 controls the first switch circuit 31 to disconnect.

[0123] S411: Protocol chip 50 controls the third switch circuit 33 to conduct.

[0124] S412: Control circuit 60 controls the second switch circuit 32 to disconnect.

[0125] S413: Protocol chip 50 controls the fourth switch circuit 34 to conduct.

[0126] S414: The trigger 30 is pressed, and the control circuit 60 receives the second trigger signal.

[0127] When the user presses the trigger 30, the control circuit 60 receives the second trigger signal and exits the detection mode.

[0128] Please refer to the figures according to some embodiments of this application. Figure 6 and Figure 7 As shown, Figure 6 This is a schematic diagram of the framework of the third embodiment of the power supply device provided in this application. Figure 7 yes Figure 6 A flowchart illustrating a third embodiment of a method for testing power supply equipment. The testing method in this embodiment includes the following steps.

[0129] S301: When the first interface 11 or the second interface 12 is electrically connected to the receiving device 3 via the cable 2, the power supply device 1 is controlled to output a preset current to the first interface 11 or the second interface 12.

[0130] When the first interface 11 is electrically connected to the receiving device 3 via cable 2, such as Figure 6 As shown, the power supply device 1 outputs a preset current to the first interface 11. The preset current includes, but is not limited to, 3A or 5A, for example, the preset current is 0A-3A.

[0131] When the second interface 12 is electrically connected to the receiving device 3 via cable 2, the control power supply device 1 outputs a preset current to the second interface 12.

[0132] S302: Obtain the first voltage of the first interface 11 or the second voltage of the second interface 12, and obtain the resistance value of the cable 2 based on the first voltage or the second voltage and the preset current.

[0133] The power supply device 1 obtains the first voltage of the first interface 11 or the second voltage of the second interface 12, and obtains the resistance value of the cable 2 based on the first voltage or the second voltage and the preset current.

[0134] When the first interface 11 is electrically connected to the receiving device 3 via the cable 2, the power supply device 1 obtains the first voltage of the first interface 11 and obtains the resistance value of the cable 2 based on the first voltage and the preset current.

[0135] When the second interface 12 is electrically connected to the receiving device 3 via the cable 2, the power supply device 1 obtains the second voltage of the second interface 12 and obtains the resistance value of the cable 2 based on the second voltage and the preset current.

[0136] This embodiment obtains the first voltage of the first interface 11 or the second voltage of the second interface 12, and then obtains the resistance value of the cable 2 based on the first voltage or the second voltage and a preset current. This allows the user to know the resistance value of the cable 2, determine the quality of the cable 2 by its impedance, reduce the impact of the cable 2's impedance on the power supply device 1, and improve the efficiency of the power supply device 1.

[0137] According to some embodiments of this application, please refer to Figure 8 As shown, Figure 8 yes Figure 7 A flowchart illustrating the first embodiment of step S301. The power supply device 1 in this embodiment... Figure 6 The description is based on the disclosed power supply device 1, and the receiving device 3 can be the aforementioned electronic device.

[0138] Step S301 of this embodiment includes the following steps.

[0139] S501: Receive request information from receiving device 3 through first interface 11 or second interface 12, and obtain preset current and preset voltage from the request information.

[0140] Power supply device 1 receives request information from receiving device 3 via cable 2. The request information includes the preset current and preset voltage required by receiving device 3. For example, power supply device 1 receives a Request from receiving device 3 with a preset current of 3A and a preset voltage of 9V. In this case, power supply device 1 obtains the preset current and preset voltage from the Request.

[0141] When the first interface 11 is electrically connected to the receiving device 3 via cable 2, the power supply device 1 receives request information from the receiving device 3 through the first interface 11. When the second interface 12 is electrically connected to the receiving device 3 via cable 2, the power supply device 1 receives request information from the receiving device 3 through the second interface 12.

[0142] S502: Control power supply device 1 to output preset current and preset voltage to the first interface 11 or the second interface 12.

[0143] Power supply device 1 outputs a preset current and a preset voltage to the first interface 11 or the second interface 12; for example, power supply device 1 outputs 3A and 9V to the first interface 11 or the second interface 12.

[0144] When the first interface 11 is electrically connected to the receiving device 3 via cable 2, the power supply device 1 outputs a preset current and a preset voltage to the first interface 11. When the second interface 12 is electrically connected to the receiving device 3 via cable 2, the power supply device 1 outputs a preset current and a preset voltage to the second interface 12.

[0145] In this embodiment, the receiving device 3 receives request information and obtains preset current and preset voltage from the request information; it then controls the power supply device 1 to output the preset current and preset voltage to the first interface 11 or the second interface 12. The output of preset current and preset voltage by the power supply device 1 to the first interface 11 or the second interface 12 satisfies the requirements of the receiving device 3.

[0146] Please see Figure 9 As shown, Figure 9 yes Figure 7 A flowchart illustrating step S302 of the first embodiment. Step S302 of this embodiment includes the following steps.

[0147] S601: Obtain a status data packet from the receiving device 3 through the first interface 11 or the second interface 12. The status data packet includes the input voltage of the receiving device 3.

[0148] Power supply device 1 obtains status data packets from receiving device 3 through the first interface 11 or the second interface 12. The status data packets include the input voltage of receiving device 3. The input voltage of receiving device 3 is the voltage input by power supply device 1 to receiving device 3 through cable 2.

[0149] For example, power supply device 1 sends a Status Message (acquire status information) to receiving device 3 through the first interface 11 or the second interface 12, and receiving device 3 acquires the actual input voltage; receiving device 3 sends a status data packet to power supply device 1, and power supply device 1 acquires the input voltage from the status data packet.

[0150] When the first interface 11 is electrically connected to the receiving device 3 via cable 2, the power supply device 1 obtains status data packets from the receiving device 3 through the first interface 11. When the second interface 12 is electrically connected to the receiving device 3 via cable 2, the power supply device 1 obtains status data packets from the receiving device 3 through the second interface 12.

[0151] S602: Obtain the input voltage of receiving device 3.

[0152] Power supply device 1 parses the status data packet to obtain the input voltage of receiving device 3.

[0153] S603: Obtain the difference between the first voltage and the input voltage, or the difference between the second voltage and the input voltage, and divide the difference by the preset current to obtain the resistance value.

[0154] Power supply device 1 obtains the difference between the first voltage and the input voltage, or the difference between the second voltage and the input voltage, and divides the difference by a preset current to obtain the resistance value. That is, the resistance value satisfies the following formula:

[0155] R=(Vout-Vin) / I (2)

[0156] Where R is the resistance of cable 2, Vout is the first voltage or the second voltage, Vin is the input voltage, and I is the preset current. In other embodiments, I can be the current sampled by the power supply device 1 through the ADC conversion circuit.

[0157] This embodiment obtains the resistance value by acquiring the difference between the first voltage and the input voltage, or the difference between the second voltage and the input voltage, and dividing the difference by a preset current. This allows the user to know the resistance value of the cable 2, thereby determining the quality of the cable 2 through its impedance, reducing the impact of the cable 2's impedance on the power supply device 1, and improving the efficiency of the power supply device 1.

[0158] According to some embodiments of this application, step S302 of this embodiment further includes the following steps: when the cable 2 includes an electronic marker chip, obtain the difference between the first voltage and the input voltage, or the difference between the second voltage and the input voltage, and divide the difference by the sum of the preset current and the preset compensation current to obtain the resistance value.

[0159] When the power supply device 1 has an electronic marker chip in the cable 2, it obtains the difference between the first voltage and the input voltage, or the difference between the second voltage and the input voltage. It then divides this difference by the sum of a preset current and a preset compensation current to obtain the resistance value. The resistance value satisfies the following formula:

[0160] R=(Vout-Vin) / (I+I1) (3)

[0161] Where R is the resistance of cable 2, Vout is the first voltage or the second voltage, Vin is the input voltage, I is the preset current, and I1 is the compensation current.

[0162] In this embodiment, when cable 2 includes an electronic marker chip, the difference between the first voltage and the input voltage, or the difference between the second voltage and the input voltage, is obtained. This difference is then divided by the sum of a preset current and a preset compensation current to obtain the resistance value. The preset compensation current compensates for the current loss of the electronic marker chip, improving the accuracy of the resistance value. This allows users to easily determine the resistance value of cable 2, enabling them to assess the quality of cable 2 based on its impedance. This also reduces the impact of cable 2's impedance on power supply device 1, thereby improving the efficiency of power supply device 1.

[0163] In some embodiments, before step S301, the detection method of this embodiment further includes: the power supply device 1 broadcasts a first message (e.g., Source cap) to the receiving device 3 within a first preset time period, the first preset time period being 150ms; the power supply device 1 waits for the receiving device 3 to send a request message (e.g., Request) within a second preset time period, the second preset time period being 27ms; after the receiving device 3 sends the request message, it waits for the power supply device 1 to send a receiving message (e.g., Accept) within a second preset time period; after the receiving device 3 receives the receiving message, it waits for the receiving device 3 to send a second message (e.g., PS_RDY) within a third preset time period, then proceeds to step S301; the third preset time period being 500ms.

[0164] According to some embodiments of this application, Figure 10 yes Figure 6 A flowchart illustrating a third embodiment of a method for testing power supply equipment. The testing method in this embodiment includes the following steps.

[0165] S701: Power supply device 1 has detected that receiver device 3 has been inserted.

[0166] The power supply device 1 can detect the voltage of the CC line (Configuration Channel) of the first interface 11 or the second interface 12. The receiving device 3 can detect this voltage by connecting the cable 2 to the first interface 11 or the second interface 12. For example, the voltage of the CC line may drop from 3V to 1V.

[0167] S702: Power supply device 1 determines whether receiving device 3 requests PPS level.

[0168] Power supply device 1 determines whether receiving device 3 requests the PPS setting; if yes, proceed to step S703; if no, proceed to step S708. The PPS setting refers to the voltage and current combination in the PPS (Programmable Power Supply) fast charging protocol, used to adjust the voltage and current during the charging process to achieve the best charging effect.

[0169] S703: Power supply device 1 reads the request information from receiving device 3, and power supply device 1 outputs preset current and preset voltage to the first interface 11 or the second interface 12.

[0170] S704: Power supply device 1 sends status information to receiving device 3.

[0171] Power supply device 1 sends status information to receiving device 3 to obtain the input voltage of receiving device 3.

[0172] S705: Power supply device 1 receives status data packets from receiving device 3 and parses the status data packets to obtain the input voltage.

[0173] S706: Power supply device 1 acquires the current of the first interface 11 or the second interface 12 through the ADC conversion circuit, and the current of the first interface 11 or the second interface 12 is equal to the preset current.

[0174] S707: Power supply device 1 obtains the difference between the first voltage and the input voltage, or the difference between the second voltage and the input voltage, and divides the difference by the sum of the preset current and the preset compensation current to obtain the resistance value.

[0175] Wherein, the first voltage is equal to the preset voltage, or the second voltage is equal to the preset voltage. Power supply device 1 obtains the resistance value and returns to S703.

[0176] S708: Power supply device 1 fixed PD position.

[0177] Power device 1 has a fixed PD level, which refers to the level of the USB PD (USB Power Delivery) protocol. PD levels include 5V, 9V, 15V, or 20V; for example, power device 1 has a fixed PD level of 9V.

[0178] S709: Power supply device 1 reads the request information from receiving device 3, and power supply device 1 outputs preset current and preset voltage to the first interface 11 or the second interface 12.

[0179] S710: Power supply device 1 sends status information to receiving device 3.

[0180] S711: Power supply device 1 receives status data packets from receiving device 3 and parses the status data packets to obtain the input voltage.

[0181] S712: Power supply device 1 acquires the current of the first interface 11 or the second interface 12 through the ADC conversion circuit, and the current of the first interface 11 or the second interface 12 is equal to the preset current.

[0182] S713: Power supply device 1 obtains the difference between the first voltage and the input voltage, or the difference between the second voltage and the input voltage, and divides the difference by the preset current to obtain the resistance value.

[0183] Wherein, the first voltage is equal to the preset voltage, or the second voltage is equal to the preset voltage.

[0184] In summary, when the first interface 11 is electrically connected to the second interface 12 via cable 2, the power supply device 1 outputs a preset current between the first interface 11 and the second interface 12 via cable 2; acquires a first voltage of the first interface 11 and a second voltage of the second interface 12; and obtains the resistance value of cable 2 based on the first voltage, the second voltage, and the preset current. Obtaining the resistance value through the first voltage, the second voltage, and the preset current allows the user to easily determine the resistance value of cable 2, thereby assessing the quality of cable 2, reducing the impact of cable 2 impedance on the power supply device 1, and improving the efficiency of the power supply device 1.

[0185] The above description is merely an embodiment of this application and does not limit the patent scope of this application. Any equivalent structural or procedural transformations made using the content of this application's specification and drawings, or direct or indirect applications in other related technical fields, are similarly included within the patent protection scope of this application.

Claims

1. A method for testing power supply equipment, characterized in that, The power supply device includes a first interface and a second interface, and the detection method includes: When the first interface is electrically connected to the second interface via a cable, the power supply device is controlled to output a preset current between the first interface and the second interface via the cable; Obtain the first voltage of the first interface and the second voltage of the second interface; The resistance value of the cable is obtained based on the first voltage, the second voltage, and the preset current.

2. The detection method according to claim 1, characterized in that, The power supply device includes a constant current circuit, and controlling the power supply device to output a preset current between the first interface and the second interface via the cable includes: The constant current circuit is electrically connected to the first interface and the second interface respectively, and the constant current circuit outputs the preset current between the first interface and the second interface through the cable; At preset time intervals, acquire the first voltage of the first interface and the second voltage of the second interface.

3. The detection method according to claim 2, characterized in that, The step of obtaining the resistance value of the cable based on the first voltage, the second voltage, and the preset current includes: Obtain the absolute value of the difference between the first voltage and the second voltage, and divide the absolute value by the preset current to obtain the resistance value.

4. The detection method according to claim 3, characterized in that, The power supply device further includes a trigger, a first switching circuit, a second switching circuit, a third switching circuit, a fourth switching circuit, a power supply circuit, and a protocol chip. The constant current circuit is electrically connected to the first interface through the first switching circuit, the constant current circuit is electrically connected to the second interface through the second switching circuit, the power supply circuit is electrically connected to the first interface through the third switching circuit, the power supply circuit is electrically connected to the second interface through the fourth switching circuit, and the protocol chip is electrically connected to the third switching circuit and the fourth switching circuit respectively. The constant current circuit that controls the electrical connection to the first interface and the second interface respectively includes: In response to receiving a first trigger signal from the trigger element, the system enters detection mode; The first and second switching circuits are turned on based on the first trigger signal, and the third and fourth switching circuits are turned off based on the protocol chip.

5. The detection method according to claim 4, characterized in that, The detection method further includes: After obtaining the resistance value, the first and second switching circuits are disconnected, and the third and fourth switching circuits are turned on by the protocol chip, so that the power supply circuit supplies power to the first and second interfaces. Upon receiving a second trigger signal from the trigger element, the detection mode is exited.

6. The detection method according to claim 1, characterized in that, The detection method further includes: When the first interface or the second interface is electrically connected to the receiving device via the cable, the power supply device is controlled to output the preset current to the first interface or the second interface. Obtain the first voltage of the first interface or the second voltage of the second interface, and obtain the resistance value of the cable based on the first voltage or the second voltage and the preset current.

7. The detection method according to claim 6, characterized in that, The control of the power supply device to output the preset current to the first interface or the second interface includes: Receive request information from the receiving device through the first interface or the second interface, and obtain the preset current and preset voltage from the request information; Control the power supply device to output the preset current and the preset voltage to the first interface or the second interface; The step of obtaining the first voltage of the first interface or the second voltage of the second interface includes: A status data packet is obtained from the receiving device through the first interface or the second interface, the status data packet including the input voltage of the receiving device; Obtain the input voltage of the receiving device.

8. The detection method according to claim 7, characterized in that, The step of obtaining the resistance value of the cable based on the first voltage or the second voltage and the preset current includes: Obtain the difference between the first voltage and the input voltage, or the difference between the second voltage and the input voltage, and divide the difference by the preset current to obtain the resistance value.

9. The detection method according to claim 7, characterized in that, The step of obtaining the resistance value of the cable based on the first voltage or the second voltage and the preset current includes: When the cable includes an electronic marker chip, the difference between the first voltage and the input voltage, or the difference between the second voltage and the input voltage, is obtained, and the difference is divided by the sum of the preset current and the preset compensation current to obtain the resistance value.

10. A power supply device, characterized in that, The system includes a control circuit, a constant current circuit, a first interface, and a second interface. The control circuit is electrically connected to the constant current circuit, the first interface, and the second interface, respectively. A cable is electrically connected between the first interface and the second interface. The control circuit is used for: The constant current circuit is electrically connected to the first interface and the second interface respectively, and the constant current circuit outputs the preset current between the first interface and the second interface through the cable; Obtain the first voltage of the first interface, and obtain the second voltage of the second interface; The resistance value of the cable is obtained based on the first voltage, the second voltage, and the preset current.

11. The power supply device according to claim 10, characterized in that, The control circuit is used to obtain the absolute value of the difference between the first voltage and the second voltage, and divide the absolute value by the preset current to obtain the resistance value.

12. The power supply device according to claim 10 or 11, characterized in that, The power supply device further includes a trigger, a first switching circuit, a second switching circuit, a third switching circuit, a fourth switching circuit, a power supply circuit, and a protocol chip. The constant current circuit is electrically connected to the first interface through the first switching circuit, the constant current circuit is electrically connected to the second interface through the second switching circuit, the power supply circuit is electrically connected to the first interface through the third switching circuit, and the power supply circuit is electrically connected to the second interface through the fourth switching circuit. The protocol chip is electrically connected to both the third and fourth switching circuits. The control circuit is electrically connected to the first switching circuit, the second switching circuit, and the protocol chip. The control circuit is used for: In response to receiving a first trigger signal from the trigger element, the system enters detection mode; Based on the first trigger signal, the first and second switching circuits are turned on, and the third and fourth switching circuits are turned off by the protocol chip. After obtaining the resistance value, the first and second switching circuits are disconnected, and the third and fourth switching circuits are turned on by the protocol chip, so that the power supply circuit supplies power to the first and second interfaces. Upon receiving a second trigger signal from the trigger element, the detection mode is exited.