Detailed Description
The most key concept of the invention is as follows: the adapter outputs a first voltage to the host to be identified, the specific host is identified through a negotiation mechanism, if the host to be identified is the specific host, the specific host outputs a feedback signal to the adapter through the feedback circuit, and the adapter outputs a second voltage to charge the specific host.
Referring to fig. 1, a technical solution adopted by the present invention is:
a method for host-specific charging, comprising the steps of:
s1, presetting a parameter, storing the parameter in an adapter, connecting the adapter with a host to be identified and outputting a first voltage to the host to be identified;
s2, if the adapter receives the feedback signal sent by the host to be identified, preprocessing the feedback signal;
s3, judging whether the preprocessed feedback signal is matched with the parameter, if so, determining that the host to be identified is a specific host, and outputting a second voltage to charge the specific host by the adapter; the value of the second voltage is greater than the value of the first voltage.
From the above description, the beneficial effects of the present invention are: the adapter is connected with the host to be identified and outputs a first voltage to the host to be identified, the specific host is identified through a negotiation mechanism, if the host to be identified is the specific host, the specific host outputs a feedback signal to the adapter, the adapter outputs a second voltage to charge the specific host, and expensive TYPE-C protocol chips do not need to be added in the adapter and the host to be identified, so that the cost is low.
Further, step S3 includes extracting a dc level from the preprocessed feedback signal, calculating a difference between the dc level and the parameter, taking an absolute value of the difference, and if the absolute value is smaller than a preset value, determining that the preprocessed feedback signal matches the parameter.
As can be seen from the above description, if the preprocessed feedback signal matches the parameter, it indicates that the host to be identified is a specific host.
Further, step S3 includes if the preprocessed feedback signal does not match the parameter, determining that the host to be identified is a non-specific host, and the adapter keeps outputting the first voltage to charge the non-specific host.
From the above description, if the host to be identified is the non-specific host, the adapter keeps outputting the first voltage to charge the non-specific host, so as to ensure that the non-specific host is not damaged due to the voltage mismatch.
Further, the preprocessing of step S2 includes rectifying and filtering the feedback signal.
As can be seen from the above description, rectifying and filtering the feedback signal may eliminate noise interference.
Further, the feedback signal of step S2 is a periodic clock signal, the amplitude of the periodic clock signal ranges from 1V to 5V, and the frequency of the periodic clock signal ranges from 1Khz to 100Mhz, for example, the amplitude of the periodic clock signal is 3V, and the frequency of the periodic clock signal is 100 Khz.
As can be seen from the above description, the periodic clock signal with an output amplitude of 1V-5V and a frequency range of 1Khz-100Mhz is fed back to the control circuit as a characteristic signal of a specific host machine, so that the control circuit can identify the specific host machine.
Further, the value of the second voltage is 4-6 times of the value of the first voltage.
As can be seen from the above description, the value of the second voltage is 4-6 times the value of the first voltage to achieve fast charging of a particular host.
Referring to fig. 2 to fig. 3, another technical solution adopted by the present invention is:
an adapter for charging a specific host comprises an AC-DC conversion circuit, a DC-DC circuit, a control circuit and a feedback circuit, wherein the AC-DC conversion circuit is connected with the host to be identified through the DC-DC circuit, the DC-DC circuit is connected with the feedback circuit through the control circuit, and the feedback circuit is connected with the host to be identified.
The adapter is connected with a host to be identified, the adapter outputs first voltage to the DC-DC circuit through the AC-DC conversion circuit, the DC-DC circuit does not work at the moment, only the first voltage is transmitted to the host to be identified, the host to be identified obtains first voltage input, the power negotiation circuit of the host to be identified works, if the host to be identified is a specific host, the specific host outputs a feedback signal to the control circuit through the feedback circuit, and the control circuit controls the DC-DC circuit to output second voltage to charge the specific host.
According to the description, the adapter is connected with the host to be identified, the AC-DC conversion circuit outputs the first voltage to the host to be identified, if the host to be identified is the specific host, the specific host outputs the feedback signal to the control circuit through the feedback circuit, the control circuit controls the DC-DC circuit to output the second voltage to charge the specific host, and expensive TYPE-C protocol chips do not need to be added in the adapter and the host to be identified, so that the cost is low.
Further, the AC-DC conversion circuit comprises a bridge rectifier, a filter circuit and a transformation circuit which are sequentially connected, wherein the bridge rectifier is connected with a mains supply, the transformation circuit is connected with the DC-DC circuit, and the transformation circuit outputs a first voltage.
As can be seen from the above description, the adapter outputs the first voltage to the DC-DC circuit through the AC-DC conversion circuit, and the DC-DC circuit outputs the first voltage to the host to be identified.
Furthermore, the DC-DC circuit comprises a boost chip, an enable pin of the boost chip is connected with the control circuit, an input pin of the boost chip is connected with the AC-DC conversion circuit, and an output pin of the boost chip is connected with the host to be identified.
As can be seen from the above description, the control circuit controls the DC-DC circuit to output the second voltage to charge the specific host.
Further, the feedback circuit comprises a first crystal oscillator, a first phase inverter and a second phase inverter which are connected with each other, the first crystal oscillator and the first phase inverter are connected with the host to be identified, and the second phase inverter is connected with the control circuit; further, the feedback circuit is a microcontroller in the specific host and a clock output pin of the microcontroller, the microcontroller operates under the first voltage and the second voltage and generates periodic clock output, and the clock output pin is connected with the control circuit.
As can be seen from the above description, the feedback circuit is mainly used to generate a periodic clock signal.
Further, the adapter is equipped with the cable that links to each other with the host computer of treating discerning, the cable is 4 heart yearns, specifically includes power pin, first signal pin, second signal pin and ground connection pin, the both ends interface of cable is the TYPE-A interface that links to each other with the adapter respectively and treats the TYPE-C interface that the discernment host computer links to each other.
As can be seen from the above description, the adapter implements negotiation communication with the host to be identified through the first signal pin and the second signal pin.
Furthermore, the LED lamp comprises an indicating lamp circuit, the indicating lamp circuit comprises two LED lamps which are connected in parallel and are respectively connected with the control circuit, and the light colors of the two LED lamps are different.
As can be seen from the above description, the indicator light circuit is used to indicate the operating status of the adapter.
Referring to fig. 1, a first embodiment of the present invention is:
a method for host-specific charging, comprising the steps of:
s1, presetting a parameter and storing the parameter in an adapter, where the parameter is a voltage value in the embodiment, connecting the adapter with a host to be identified and outputting a first voltage to the host to be identified, where the first voltage is 5V in the embodiment;
s2, if the adapter receives the feedback signal sent by the host to be identified, preprocessing the feedback signal, wherein the preprocessing comprises rectifying and filtering the feedback signal, extracting a direct current level from the preprocessed feedback signal, calculating a difference value between the direct current level and a parameter, taking an absolute value of the difference value, if the absolute value is smaller than a preset value, determining that the preprocessed feedback signal is matched with the parameter, if the preprocessed feedback signal is not matched with the parameter, determining that the host to be identified is a non-specific host, and keeping the adapter outputting 5V voltage to charge the non-specific host;
the feedback signal of step S2 is a periodic clock signal, the amplitude range of the periodic clock signal is 1V-5V, and the frequency range of the periodic clock signal is 1Khz-100Mhz, wherein the amplitude of the periodic clock signal is preferably 3V, and the frequency of the periodic clock signal is preferably 100 Khz;
s3, judging whether the preprocessed feedback signal is matched with the parameter, if so, determining that the host to be identified is a specific host, and outputting a second voltage to charge the specific host by the adapter; the value of the second voltage is greater than the value of the first voltage, the value of the second voltage is 4-6 times of the value of the first voltage, and the second voltage is 20V in this embodiment.
Referring to fig. 2 to fig. 3, a second embodiment of the present invention is:
an adapter for charging a specific host comprises an AC-DC conversion circuit 1, a DC-DC circuit 2, a control circuit 3 and a feedback circuit 4, wherein the AC-DC conversion circuit 1 is connected with the host 3 to be identified through the DC-DC circuit 2, the DC-DC circuit 2 is connected with the feedback circuit 4 through the control circuit 3, and the feedback circuit 4 is connected with a host 5 to be identified.
The AC-DC conversion circuit comprises a bridge rectifier, a filter circuit and a transformation circuit which are sequentially connected, wherein the bridge rectifier is connected with a mains supply, the transformation circuit is connected with the DC-DC circuit, and the transformation circuit outputs 5V direct current voltage.
The DC-DC circuit comprises a boost chip, an enable pin of the boost chip is connected with the control circuit, an input pin of the boost chip is connected with the AC-DC conversion circuit, and an output pin of the boost chip is connected with the host to be identified.
As shown in fig. 3, the feedback circuit comprises a first crystal oscillator, a first inverter and a second inverter which are connected with each other, the first crystal oscillator and the first inverter are connected with the host to be identified, and the second inverter is connected with the control circuit; further, the feedback circuit is a microcontroller in the specific host and a clock output pin of the microcontroller, the microcontroller operates under the first voltage and the second voltage and generates periodic clock output, and the clock output pin is connected with the control circuit.
The adapter is connected with a host to be identified, the adapter outputs 5V voltage to the DC-DC circuit through the AC-DC conversion circuit, the DC-DC circuit does not work at the moment, only 5V voltage is transmitted to the host to be identified, the host to be identified obtains 5V voltage input, the power negotiation circuit of the host to be identified works, if the host to be identified is a specific host, the specific host outputs a feedback signal to the control circuit through the feedback circuit, and the control circuit controls the DC-DC circuit to output 20V voltage to charge the specific host.
The adapter is provided with a cable connected with a host to be identified, wherein the cable is a 4-core wire and specifically comprises a power supply pin, a first signal pin, a second signal pin and a grounding pin.
The two-end interface of the cable is a TYPE-A interface connected with the adapter and a TYPE-C interface connected with the host to be identified respectively.
For the USB2.0 communication protocol: one end of the USB needs to provide a pull-up resistor first, and after the other end of the USB recognizes the pull-up resistor, the other end of the USB starts enumeration actively, and the first signal pin and the second signal pin at one end of the USB have signals.
For the USB fast charge QC protocol: the adapter firstly provides 0.325V voltage, the host terminal recognizes the 0.325V voltage, the first signal pin and the second signal pin are firstly shorted for 1.25s and then the first signal pin and the second signal pin are disconnected, and the host terminal continuously provides 3.3V or 0.6V voltage for the adapter. The adapter of the invention does not follow the QC protocol, so other USB quick charging terminals can not continuously generate continuous alternating current signals on the first signal pin and the second signal pin, meanwhile, the QC protocol is to short-circuit the first signal pin and the second signal pin for 1.25s and then disconnect the first signal pin and the second signal pin, and respectively identify the fixed level of 3.3V or 0.6V.
For USB PD fast charge and MTK PEK fast charge protocols: the PD and PE standard quick charging adapters do not use the first signal pin and the second signal pin, so the first signal pin and the second signal pin do not generate signals and cannot be triggered by the alternating current signal of the specific host defined by the invention.
The adapter for charging the specific host further comprises an indicating lamp circuit for indicating the working state of the adapter, the indicating lamp circuit is connected with the control circuit and comprises two LED lamps connected in parallel, the two LED lamps are respectively connected with the control circuit, one LED lamp is red, the other LED lamp is green, if the host to be identified is the specific host, the green lamp is turned on, and if the host to be identified is the specific host, the red lamp is turned on.
Taking a cash register as an example, the power supply conditions of the cash register respectively cross-connected with other devices are as shown in table 1 below, so that the voltage matching between the specific adapter and the specific host is realized in a low-cost manner, and the risks that the specific adapter and the non-specific host are damaged due to the mixed insertion between the specific adapter and the non-specific host and between the non-specific adapter and the specific host are avoided.
TABLE 1
In summary, according to the method and the adapter for charging a specific host provided by the present invention, the adapter is connected to a host to be identified, the adapter outputs a first voltage to the DC-DC circuit through the AC-DC conversion circuit, at this time, the DC-DC circuit does not operate, only the first voltage is transmitted to the host to be identified, the host to be identified obtains the first voltage input, the power negotiation circuit of the host to be identified operates, if the host to be identified is the specific host, the specific host outputs a feedback signal to the control circuit through the feedback circuit, the control circuit controls the DC-DC circuit to output a second voltage to charge the specific host, and it is not necessary to add expensive TYPE-C protocol chips inside the adapter and the host to be identified, so that the cost is low.