Detailed Description
The present invention will be further explained in detail with reference to the accompanying drawings.
Referring to fig. 1a, 1b and 1c, fig. 1a, 1b and 1c are block diagram illustrations of a USB power supply, a USB cable and a USB device of the present invention, respectively. The invention provides a method for realizing a multi-power supply USB interface, and relates to a method for realizing a USB power supply 100, a USB cable 120 and USB equipment 140. The method can enable the USB power supply 100, the USB cable 120 and the USB equipment 140 to mutually detect and identify, and enable the USB power supply 100 to output a plurality of paths of power supplies with different voltages to supply power to the USB equipment 140 under the condition of meeting the conditions. The USB power supply 100 may be a USB host such as a computer or a USB power adapter as a power output terminal. The USB device 140 may be connected to the USB power source 100 through the USB cable 120 as a power input terminal, or may be directly connected to the USB power source 100 without a cable. The USB power supply 100 and the USB cable 120 of the present invention are compatible with the conventional single-channel USB devices.
Referring to fig. 1a, the USB power supply 100 includes: a power input 101, a power conversion module 102, a power path management module 103, a USB interface 104, and a control module 105.
Power input 101: the input power supply providing the USB power supply differs according to the type of the USB power supply 100. For example: the USB interface of the PC inputs Direct Current (DC) power; and the input of the power adapter is Alternating Current (AC) power.
The power conversion module 102: for converting the input power of the USB power supply 100 to provide the output power of the USB power supply. According to different USB power types, the power conversion modules are different: when the USB power supply input is an AC power supply, the power supply conversion module is an AC/DC rectification filter and a DC step-down transformer; when the USB power supply input is a direct current power supply, the power supply conversion module is used for converting a DC-DC power supply. The power conversion module 102 supports multiple dc outputs and has adjustable voltage. In this embodiment, the first DC supply output by the power conversion module 102 is 5V DC, and when the input power is normal, the first DC supply is the default output to supply the power requirements of other modules of the USB power supply 100 itself; the second DC supply output by the power conversion module 102 is 20V DC, and is off by default. It is worth mentioning that the second direct current supply can be adjusted within a certain range, for example: 3V-30V to meet the personalized requirements of the USB equipment.
Power path management module 103: is located between the output of the power conversion module 102 and the power port of the USB interface 104, and performs path control on the connection between the two. Firstly, when the USB device 140 is not plugged in, the output of the power conversion module 102 and the power path of the USB interface 104 are disconnected to meet the USB protocol requirement; secondly, since the USB Type-C interface supports two insertion directions, different outputs of the power conversion module 102 need to be controlled to be connected to the power ports of the corresponding USB interfaces 104 according to the insertion directions.
It is understood that the power path management module 103 includes a first set of interfaces 1031 and a second set of interfaces 1032, and a switch array connected between the two sets of interfaces 1031, 1032, the first set of interfaces 1031 being connected to the power supply ports of the USB interface 104, the second set of interfaces 1032 including: interface connected with first direct current supply and interface connected with second direct current supply
The USB interface 104: for connecting the USB cable 120 or the USB device 140, the USB interface of the present invention adopts a Type-C interface. In this embodiment, the USB interface 104 is a Type-C socket.
According to the USB protocol, the standard Type-C socket interface signal is defined as shown in FIG. 2a, wherein the A4, A9, B4 and B9 ports are all USB interface single power VBUS. The USB interface of the USB power supply 100 provided by the present invention modifies the standard Type-C interface definition, and splits the VBUS power supply port into multiple power supply ports. As shown in fig. 2B, in the present embodiment, a4 and B4 define VBUS1 (e.g., corresponding to the first dc supply), and a9 and B9 define VBUS2 (e.g., corresponding to the second dc supply), so that the dual power supply can be realized. In other embodiments, the four ports a4, a9, B4, and B9 may be defined as VBUS1, VBUS2, VBUS3, and VBUS4, respectively, to implement four-way power supply. The definitions and functions of the rest ports of the Type-C interface of the invention are consistent with those of the traditional USB Type-C interface, and are not described in detail herein.
It is worth mentioning that referring to the Type-C plug definition of fig. 2C and 2d, when the USB device 140 is connected in a plug-and-play manner, the USB power source 100 still uses the Type-C socket.
The control module 105: for controlling the power conversion module 102 and the power path management module 103 so that the USB interface 104 can provide the power supply required by the USB device 140. The control module 105 is connected to the control port of the USB interface 104, and can control the output voltage of the power conversion module 102 and the switch array of the power path management module 103 according to the information obtained from the control port, so that the USB power supply 100 can support the forward and backward insertion for outputting the first dc supply and/or the second dc supply.
Specifically, the main functions of the control module 105 include: firstly, completing the USB device 140 insertion identification process specified by the USB protocol, and establishing the normal identification of the USB power supply 100, the USB cable 120 and the USB device 140. And secondly, detecting the identification information of the USB cable 120, and reading cable parameters including the number of power supplies supported by the cable, rated current and the like. And thirdly, detecting the identification information of the USB equipment 140 and identifying the parameters of the equipment, including the quantity and voltage of the power supply required by the equipment. And fourthly, controlling the power conversion module 102 according to the identified identification information of the USB cable 120 and the USB equipment 140, and outputting a power supply meeting the requirement (mainly aiming at the personalized requirement of the USB equipment, and adjusting the second direct current supply to meet the requirement). Detecting the insertion direction of the USB interface 104, and controlling the power path management module 103 to output the power conversion module 102 to different VBUS ports according to different insertion directions. Sixthly, identifying the device parameters of the USB power supply 100, including the information of the number of the output-supported power supplies, the voltage range and the like, for the USB device 140 to detect.
Referring to fig. 1b, the USB cable 120 is an electronic identification (EMCA) cable, which includes: a first USB interface 121, a second USB interface 123 and an identification module 125.
First and second USB interfaces 121 and 123: USB Type-C plug is used, the standard USB Type-C plug interface definition is shown in fig. 2C, the USB Type-C plug interface definition of the present invention is shown in fig. 2d, and the power port definition is consistent with the USB interface VBUS port definition of the USB power supply 100 shown in fig. 2 b. VBUS of the two USB interfaces 121 and 123 at the two ends of the USB cable 120 correspond to each other, and are connected by independent power lines. The other port definitions of the USB interfaces 121, 123 are consistent with the standard USB type-C interface plug definition.
The identification module 125: for identifying the type and parameters of USB cable 120, including the number of power supplies supported by USB cable 120, the current rating of each power supply, etc.
Referring to fig. 1c, the USB device 140 includes: a USB interface 141, a power path management module 142, a power conversion module 143, and a control module 144.
The USB interface 141: the USB Type-C Type interface is adopted, and the Type of the interface is different according to the different types of USB equipment. For the direct-plug USB device without cable connection, the USB interface uses USB Type-C plug, and the interface definition is consistent with the interface definition of the USB cable 120, as shown in fig. 2 d; for the USB device requiring cable connection, the USB interface uses USB type-C socket, and the interface definition is consistent with that of the USB power supply 100, as shown in fig. 2 b.
Power path management module 142: the multi-path power supply input by the USB interface 141 is subjected to access control, and when positive and negative insertion directions of the USB Type-C interface are ensured, each path can be controlled to be accurately switched to the corresponding loads 160 and 180. For cable-connected USB devices, a power path management module 142 is necessary; for a plug-in type USB device, the power path management module 142 is not necessary.
The power conversion module 143: the USB power supply conversion device is used for carrying out power supply conversion on a USB input power supply and converting the input power supply into other required power supplies to supply power to a load; the module is an optional module, and if the USB multi-path power supply meets the requirement of equipment, the module is not needed.
The control module 144: for implementing the following functions: firstly, completing the USB interface identification process specified by the USB protocol, and establishing the normal connection of the USB power supply 100, the USB cable 120 and the USB equipment 140. And secondly, communicating with the control module 105 of the USB power supply 100 to acquire information of the USB power supply 100 and the USB cable 120. Thirdly, according to the acquired information of the USB power source 100 and the USB cable 120 and the detected insertion direction of the USB interface, the power path management module 142 is controlled to switch the input power of the USB interface 141 to the respective loads 160 and 180. And fourthly, identifying the equipment parameters of the USB equipment 140, including the information such as the number, the voltage and the like of the power supplies required by the support, and detecting the USB power supply 100.
Referring to fig. 3, fig. 3 is a schematic flow chart of an implementation method of the multi-power-supply USB interface of the present invention. The method for realizing the multi-power supply USB interface of the invention roughly comprises the following steps:
s301, corresponding four power supply ports defined by the USB interface standard to multiple paths of power supplies.
And S303, setting a power supply conversion module in the USB power supply, wherein the power supply conversion module is used for providing first direct current supply and second direct current supply.
S305, a power supply path management module is arranged in the USB power supply and used for switching a link between the power supply conversion module and the USB interface.
S307, setting a control module in the USB power supply, wherein the control module is used for controlling the power supply path management module and the power supply conversion module.
Referring to fig. 4, fig. 4 is a detailed flow schematic of a method for implementing a multi-power-supply USB interface of the present invention, and is suitable for a situation where a USB device is connected to a USB power supply via a USB cable. In this case, the method of the present invention comprises:
s401, the device is connected to a power supply through a cable, and the power supply identifies the device to be plugged in.
S403, identifying the cable insertion direction, and controlling the path management to output the first direct current supply to the equipment.
S405, starting an equipment detection module, and identifying the USB power access by equipment.
S407, if the cable is identified as the electronic identification cable?, the step is switched to S409, otherwise, the step is switched to S421.
And S409, supplying power to the cable by the power supply, and starting the identification module on the cable.
S411, the power supply/cable/equipment establishes communication, and the power supply reads information of the cable and the equipment.
S413, if it is determined whether the second dc supply satisfies the device power supply requirement?, go to step S415, otherwise go to step S423.
And S415, adjusting the second direct current supply, and outputting the multi-path power supply to the equipment through path management.
S417, the device detects the USB inserting direction and adjusts the circuit path management module to switch to different loads.
And S419, enabling the USB equipment to work normally.
S421, common passive cable, not support the multi-path power supply.
And S423, turning off the USB power supply, wherein the USB device does not work.
Referring to fig. 5, fig. 5 is a detailed flow chart illustrating a method for implementing a multi-power-supply USB interface of the present invention, which is suitable for a situation where a USB device is directly connected to a USB power supply. In this case, the method of the present invention comprises:
s501, the device is directly connected to a power supply, and the power supply identifies the insertion of the device.
S503, the power supply identifies the insertion direction of the equipment, and controls the path management to output first direct current supply to the equipment.
And S505, starting an equipment detection module, and identifying the USB power access by equipment.
And S507, the power supply/equipment establishes communication, and the power supply reads equipment information.
S509, if it is determined whether the second dc supply satisfies the device power supply requirement?, go to step S511, otherwise go to step S517.
And S511, adjusting the second direct current supply, and outputting the multi-path power supply to the equipment through path management.
S513, the device detects the direction of the power supply USB, and the circuit path management module is adjusted to switch to different loads.
And S515, the USB device works normally.
And S517, turning off the USB power supply, wherein the USB equipment does not work.
Referring to fig. 6, fig. 6 is an electrical schematic of the USB power supply of the present invention. The USB power supply 600 inputs 220V commercial power through the plug 601, and the power conversion module 602 converts the 220V AC power into a high-voltage DC power of about 300V by using an AC/DC rectification change module, and then steps down the high-voltage DC power through a DC step-down transformer. Wherein the DC step-down transformer supports two outputs OUT1, OUT2, and the output voltage is adjustable, wherein the output OUT1 (i.e. the first DC supply) defaults to 5V and the output OUT2 (i.e. the second DC supply) is turned off by default. The 5V power supply of output OUT1 simultaneously powers the control module 605 within the USB power supply 600.
The power path management module 603 of the USB power supply 600 employs 4-way power switches S1, S2, S3, S4, all of which are turned off by default. The power switches S1, S2, S3, S4 are controlled by the control module 605 in accordance with the USB Type-C protocol and the detected USB cable and device identification information.
The control module 605 selects a USB Type-C control chip, which supports the USB Power Delivery 2.0 protocol, and the working principle thereof is as follows.
Firstly, when the USB equipment is accessed through a USB cable, the USB Type-C control chip detects the access of the USB equipment and identifies the insertion direction of the USB interface. If the USB Cable is plugged, namely VBUS1(Cable) of the USB Cable corresponds to VBUS1(Host) of the USB power supply, the power switch S1 is controlled to be switched on, and first direct current is supplied to VBUS1(Host) and VBUS1 (Cable); if the USB Cable is reversely plugged, namely VBUS1(Cable) of the USB Cable corresponds to VBUS2(Host) of the USB power supply, the control power switch S3 is switched on, and the first direct current supply is provided for VBUS2(Host) and VBUS1(Cable), so that the first direct current supply is ensured to be provided for the USB device through VBUS1(Cable) of the Cable, and power is firstly supplied for a control module of the USB device.
And secondly, recognizing the insertion of the USB cable by the USB Type-C control chip, controlling the internal switch of the USB Type-C control chip to be switched on, and transmitting the first direct current supply provided by the output OUT1 to VCONN to supply power to the identification module of the USB cable.
The USBType-C control chip establishes USB Power Delivery protocol communication with the identification module of the USB cable and the control module of the USB device through the CC signal of the USB interface 604, reads identification information in the USB cable and the USB device, identifies whether the Type of the USB cable supports a plurality of Power supplies, and identifies Power supply voltage demand information of the USB device.
And fourthly, the USB Type-C control chip controls the output OUT2 of the power conversion module 602 to generate a second direct current supply required by the USB device according to the identified information of the USB device, and simultaneously turns on the power switch S2 or S4 corresponding to the forward insertion or the reverse insertion of the USB Cable respectively to input the second direct current supply to the VBUS2(Host) or the VBUS1(Host) and ensure that the second direct current supply is supplied to the USB device through the VBUS2(Cable) of the USB Cable.
As can be seen, the switch array of the power path management module 603 is composed of four power switches S1, S2, S3, S4, wherein the power switches S1, S3 are used to establish the supply link of the first dc supply (5V), and the power switches S2, S4 are used to establish the supply link of the second dc supply (20V). Specifically, the four power switches S1, S2, S3, S4 are all open by default, and when the USB power source is connected to the USB device, the control module 605 first closes the power switch S1 or S3 according to the insertion direction of the USB device, and keeps the other three power switches open, so that the USB power source outputs a first direct current to the USB device to establish communication; further, the control module 605 determines whether the second dc supply can meet the personalized requirements of the USB device, and if so, closes the power switch S2 or S4 according to the connection direction, and if not, opens all of the four power switches S1, S2, S3, and S4 again. In this embodiment, the power switches S1, S2, S3, and S4 are implemented by MOS transistors.
Referring to fig. 7, fig. 7 is an electrical schematic of the USB cable of the present invention. The USB cable 700 can be coupled to the USB power supply 600 of the present invention. The USB cable 700 supports dual power supply, and a dual VBUS cable is used therein to connect VBUS1 and VBUS2 of USB connectors 721 and 723 at both ends of the cable, respectively, to form two power transmission paths. The identification module 725 selects a USB Type-C electronic identification chip, is powered by the VCONN power provided by the USB power supply 600, and can identify parameters of the USB cable, such as supporting a dual power supply, a rated current and voltage of the power supply, a data rate of the cable, and the like.
Referring to fig. 8, fig. 8 is an electrical schematic diagram of a USB device with multiple power USB interfaces of the present invention. The USB device 800 may be connected to the USB power supply 600 of the present invention through the USB cable 700, and the USB power supply 600 provides power supply. The power path management module 842 of the USB device 800 employs four power switches S1, S2, S3, S4, wherein the power switches S1, S3 are turned on by default, and the power switches S2, S4 are turned off by default, to connect the 5V load path 860. When the USB device 800 is connected to the USB power source 600 through the USB Cable 700, the USB power source 600 outputs 5V power after detecting the USB device 800, and the 5V power is provided to the USB device 800 through VBUS1(Cable) of the USB Cable. Since the USB interface 841 of the USB Device 800 also supports a positive and negative insertion operation, the VBUS1(Cable) of the USB Cable 700 corresponds to VBUS1(Device) of the USB Device 800 at the time of the positive insertion; when unplugged, the VBUS1(Cable) of the USB Cable 700 corresponds to the VBUS2(Device) of the USB Device 800. Since power switches S1, S3 are turned on by default, there will be a first DC supply provided to control module 844 of USB device 800 whether it is plugged in or plugged in backwards.
The control module 844 selects a USB Type-C control chip to support the USB Power Delivery function. After recognizing the first dc supply provided by the USB power source 600, the interface recognition process at the USB device side is started to control the power path management module 842.
First, the control module 844 of the USB device 800 establishes USB Power Delivery protocol communication with the control module 605 of the USB Power supply 600 through the CC signal of the USB interface 841, may obtain identification information in the USB cable 700 and the USB Power supply 600, identify whether the type of the USB cable 700 supports multiple Power supplies, and identify Power supply voltage information that the USB Power supply 600 can provide.
Secondly, if the USB power supply 600 can meet the requirements of the equipment, the USB Type-C control chip identifies the insertion direction of the USB interface. If the USB Cable 700 is plugged, that is, VBUS1(Cable) of the USB Cable 700 corresponds to VBUS1(Device) of the USB Device, the power switch S3 is controlled to be turned off, the switch S4 is controlled to be turned on, and VBUS2(Device) is switched to the 20V load path 880; if the USB Cable 700 is reversely plugged, i.e. VBUS1(Cable) of the USB Cable 700 corresponds to VBUS2(Device) of the USB Device 800, the power switch S1 is controlled to be turned off, the switch S2 is controlled to be turned on, and VBUS1(Device) is switched to the 20V load path 880;
and thirdly, if the USB power supply 600 cannot meet the requirement of the device, the USB power supply 600 is informed to turn off the power supply output, and the USB device 800 does not work.
Compared with the prior art, the power path management module 103 and the control module 105 are skillfully arranged, so that the USB power supply 100 can support positive and negative insertion output of the first direct current supply and/or the second direct current supply, and can support multiple paths of different voltage outputs, thereby simplifying the power supply of the USB equipment, improving the utilization efficiency of the power supply, reducing energy loss and heat dissipation measures, and being beneficial to miniaturization of electronic equipment.
The above-mentioned embodiments are merely preferred examples of the present invention, and not intended to limit the present invention, and those skilled in the art can easily make various changes and modifications according to the main concept and spirit of the present invention, so that the protection scope of the present invention shall be subject to the protection scope of the claims.