The content of the invention
The technical problem to be solved in the present invention is, for the drawbacks described above of prior art, there is provided a kind of charging voltage control
Device processed, mobile terminal and control method, it is intended to solve the charging voltage of the output voltage of existing charger and mobile terminal not
Matching causes charging exception, there is a problem of potential safety hazard.
The technical proposal for solving the technical problem of the invention is as follows:
A kind of charging voltage control device, is connected with the charging module of mobile terminal, and it includes inserting detection module, voltage
Control module and voltage comparison module, the voltage control module connection insertion detection module, voltage comparison module and charging mould
Block, the voltage comparison module connects charging module;
When the insertion detection module detection charger is inserted, voltage control module is by the output voltage of charger according to drop
Charging voltage is generated after pressure multiple blood pressure lowering;Voltage comparison module compares the size of charging voltage and setting voltage, in charging voltage
Less than the size that voltage control module adjusts blood pressure lowering multiple is controlled during setting voltage scope, until voltage comparison module judges to charge
Voltage stops adjustment when reaching setting voltage scope, starts charging module and charges.
In described charging voltage control device, the voltage control module includes:
Pressure unit, for output voltage to be exported according to after current blood pressure lowering multiple blood pressure lowering;
Blood pressure lowering control unit, for adjusting the blood pressure lowering multiple of pressure unit according to the comparative result of voltage comparison module;
The pressure unit connection charger, blood pressure lowering control unit, voltage comparison module and charging module, blood pressure lowering control is single
Rhizoma Coptidis are patched into detection module and voltage comparison module.
In described charging voltage control device, the pressure unit includes adjustable resistance and divider resistance, described adjustable
One end connection charger of resistance, the other end of adjustable resistance is connected charging module, is also grounded by divider resistance, adjustable resistance
Sliding end connection blood pressure lowering control unit.
In described charging voltage control device, the adjustable extent of the resistance of the adjustable resistance is 0 ohm ~ 100k
Ohm, the resistance of divider resistance is 10k ohm.
A kind of mobile terminal, including charging module and battery, it also includes described charging voltage control device, described to fill
Electric module connection charging voltage control device and battery;
The charging voltage control device judges whether charger inserts, when judging that charger is inserted, by charger
After output voltage is according to blood pressure lowering multiple blood pressure lowering, the charging voltage of acquisition minimal pressure value;According to charging voltage and setting voltage scope
Comparative result adjustment blood pressure lowering multiple, until charging voltage reach after setting voltage scope stop adjustment;Charging voltage control dress
Startup charging module is put, battery is charged with the charging voltage after currently adjusted.
A kind of charging voltage control method of mobile terminal, it includes:
A, charging voltage control device judge whether charger inserts, when judging that charger is inserted, by the defeated of charger
Go out voltage according to blood pressure lowering multiple blood pressure lowering, the charging voltage of acquisition minimal pressure value;
B, according to the comparative result of charging voltage and setting voltage scope adjust blood pressure lowering multiple, until charging voltage reaches setting
Determine to stop adjustment after voltage range;
C, charging voltage control device start charging module, and battery is charged with current charging voltage.
In described charging voltage control method, in step A, judge that the step of whether charger inserts includes:
Judge rising edge interrupt signal whether is produced on the CHGIN pins of mobile terminal:If having, judge that charger is inserted;No, then
Judge to be inserted without charger.
In described charging voltage control method, step B is specifically included:
Charging voltage and setting voltage scope after B1, voltage comparison module collection adjustment is compared;
If B2, judging charging voltage less than setting voltage scope, blood pressure lowering control unit exports the adjustment of the first control signal
The position of the slide plate makes the resistance of adjustable resistance diminish, so that charging voltage rises;Return to step B1;
If judging charging voltage in the range of setting voltage, blood pressure lowering control unit stops the position of adjustment slide plate;
If judging charging voltage more than setting voltage scope, it is described that blood pressure lowering control unit exports the adjustment of the second control signal
The position of slide plate makes the resistance of adjustable resistance become big, reduces charging voltage;Return to step B1.
In described charging voltage control method, first control signal adjusts the position of the slide plate, makes adjustable electric
The resistance of resistance reduces the first preset resistive value;Second control signal adjusts the position of the slide plate, makes the resistance of adjustable resistance
Increase the second preset resistive value;First preset resistive value is more than the second preset resistive value.
In described charging voltage control method, step B is specifically included:
Charging voltage and setting voltage scope after B11, voltage comparison module collection adjustment is compared;
If B12, judging charging voltage less than setting voltage scope, it is right to be called according to charging voltage and the difference of setting voltage
The adjustment grade answered, the ascending threshold in the adjustment grade rises charging voltage;Return to step B11;
If judging charging voltage in the range of setting voltage, blood pressure lowering control unit stops the position of adjustment slide plate;
If judging charging voltage more than setting voltage scope, it is described that blood pressure lowering control unit exports the adjustment of the second control signal
The position of slide plate makes the resistance of adjustable resistance become big, reduces charging voltage;Return to step B11.
Compared to prior art, charging voltage control device, mobile terminal and control method that the present invention is provided, insertion
When detection module detection charger is inserted, voltage control module generates the output voltage of charger according to after blood pressure lowering multiple blood pressure lowering
Charging voltage;Voltage comparison module compares the size of charging voltage and setting voltage, and in charging voltage setting voltage scope is less than
When control voltage control module adjust blood pressure lowering multiple size, until voltage comparison module judges that charging voltage reaches setting voltage
Stop adjustment during scope, start charging module and charge;The output voltage of different types of charger can be adjusted to mobile whole
The charging voltage that end needs, it is to avoid using during various non-standard chargers due to the peace that charges caused by the inconsistent institute of output voltage
Full hidden danger, it is ensured that the safety of charging.
Specific embodiment
The present invention provides a kind of charging voltage control device, mobile terminal and control method, for make the purpose of the present invention,
Technical scheme and advantage are clearer, clear and definite, and the present invention is described in more detail for the embodiment that develops simultaneously referring to the drawings.Should
Understand, specific embodiment described herein only to explain the present invention, is not intended to limit the present invention.
Fig. 1 is referred to, the mobile terminal 1 that the present invention is provided is connected with charger 2 using USB modes, the output of charger 2
Pin connects the CHGIN pins of mobile terminal(The pin is prior art).The mobile terminal 1 includes what the present embodiment was provided
Charging voltage control device 10, charging module 20 and battery 30.The He of the connection charging voltage of the charging module 20 control device 10
Battery 30.Charging voltage control device 10 judges to charge by whether producing rising edge interrupt signal on detection CHGIN pins
Whether device 2 inserts.When judging that charger 2 is inserted, the charging voltage control device 10 first presses the output voltage of charger 2
According to blood pressure lowering multiple blood pressure lowering, the charging voltage of acquisition minimal pressure value, tied according to the comparison of charging voltage and setting voltage scope afterwards
Fruit adjusts blood pressure lowering multiple, charging voltage is gradually risen or is declined, until charging voltage reaches setting voltage scope(Meet and move
The setting voltage that dynamic terminal standard charges)Stop adjustment afterwards.Afterwards, charging voltage control device 10 starts charging module 20, with
Current charging voltage charges to battery 30.The mobile terminal that the present embodiment is provided is not at once right when charger 2 is inserted
Battery charges;But charging voltage is adjusted by charging voltage control device 10, make charging voltage meet the setting
Just start to charge up after voltage, the output voltage of different types of charger so can be adjusted to the charging of mobile terminal needs
Voltage, due to charging potential safety hazard caused by the inconsistent institute of output voltage when can avoid using various non-standard chargers, it is ensured that
The safety charged.
Please continue to refer to Fig. 1, the charging voltage control device 10 be applied to the mobile terminal of charging in need, such as handss
Machine, panel computer, photographing unit etc..The charging voltage control device 10 includes insertion detection module 100, voltage control module
200 and voltage comparison module 300, the connection insertion detection module 100 of the voltage control module 200, the and of voltage comparison module 300
Charging module 20, the connection charging module 20 of the voltage comparison module 300.The insertion detection module 100 is used to detect movement
The interface that terminal 1 is connected with charger 2(Not shown in figure, it is existing interface)The voltage of upper CHGIN pins, so as to judge to be
It is no to have charger 2 to insert:Specifically, generate a rising edge interrupt signal on CHGIN pins when insertion detection module is detected
Shi Ze thinks have charger to insert.
After the insertion detection charger insertion of detection module 100, the output voltage of charger 2 by CHGIN pins transmit to
In voltage control module 200.Voltage control module 200 is electric according to charging is generated after blood pressure lowering multiple blood pressure lowering by the output voltage
Pressure and(By VCHG pins)It is transferred to charging module 20.It is big with setting voltage that voltage comparison module 300 compares charging voltage
It is little, the size that voltage control module 200 adjusts blood pressure lowering multiple is controlled when charging voltage is less than setting voltage scope(Turn down drop
Pressure multiple)Charging voltage is set to increase, until voltage comparison module 300 judges that charging voltage stops adjusting when reaching setting voltage scope
It is whole, start charging module and charge.The setting voltage is the output voltage of standard configuration charger, and its pressure value is equal to the mobile terminal
Standard charge voltage value, is provided and written in voltage comparison module 300 before dispatching from the factory by manufacturer.The setting voltage scope is i.e. etc.
It is in standard charge voltage or more bigger than standard charge voltage, 0.1V ~ 0.5V such as big than standard charge voltage.
In the present embodiment, the voltage control module 200 is very low using being first depressurized to, after the mode gradually boosted adjusting
Charging voltage.When being embodied as, the voltage control module 200 includes pressure unit 201 and blood pressure lowering control unit 202, described
The connection charger 2 of pressure unit 201, blood pressure lowering control unit 202, voltage comparison module 300 and charging module 20.The blood pressure lowering control
The connection of unit processed 202 insertion detection module 100 and voltage comparison module 300.The pressure unit 201 by output voltage according to work as
Export to charging module 20 after front blood pressure lowering multiple blood pressure lowering, its blood pressure lowering adjustable magnification.The blood pressure lowering control unit 202 is according to voltage
The comparative result of comparison module 300 adjusts the blood pressure lowering multiple of pressure unit 201.
Fig. 2 is seen also, the pressure unit 201 includes adjustable resistance R1 and divider resistance R2, the adjustable resistance
One end of R1 connects the CHGIN pins of mobile terminal(Equivalent to connection charger), the other end connection charging of adjustable resistance R1
The VCHG pins of module 20, also it is grounded by divider resistance R2, the control of the sliding end connection blood pressure lowering control unit 202 of adjustable resistance
Pin CTL processed.
The adjustable extent of the resistance of the adjustable resistance R1 is 0 ohm ~ 100k ohm.The resistance of divider resistance R2 is 10k
ohm.Then first voltage V1 on CHGIN pins(It is output voltage, magnitude of voltage is fixed)With the second voltage on VCHG pins
V2(It is charging voltage)Meet following relation:
V2 = V1 * R2 / ( R1 + R2 ) 。
Blood pressure lowering control unit 202 changes the resistance of adjustable resistance R1 by the position of adjustment adjustable resistance R1 slide plates, from
And have adjusted the size of charging voltage.
Voltage comparison module 300 gathers the charging voltage after adjustment every time and is compared with setting voltage scope.
If voltage comparison module 300 judges charging voltage less than setting voltage scope, notify that blood pressure lowering control unit 202 is needed
Continue adjustment, blood pressure lowering control unit 202 exports the position of the first control signal adjustment slide plate and makes the resistance of adjustable resistance R1
Value diminishes, so that charging voltage rises;Now need the position for continuing to adjust slide plate.
If judging charging voltage in the range of setting voltage, notify that blood pressure lowering control unit 202 stops adjustment, the position of slide plate
Fixation is put, charging module 20 starts, and battery 30 is charged with current charging voltage.
If judging charging voltage more than setting voltage scope, notify that blood pressure lowering control unit 202 exports the second control signal
Adjusting the position of the slide plate makes the resistance of adjustable resistance R1 become big, reduces charging voltage.
The present embodiment is when charging voltage is too low, and charge efficiency is low, and improves the scheme of charging voltage by transformation;Most
Realize eventually large and small adjustable.
The output voltage of different types of charger can be adjusted to by above-mentioned adjustment for the charging of mobile terminal needs
Voltage, due to charging potential safety hazard caused by the inconsistent institute of output voltage when can avoid using various non-standard chargers, it is to avoid
Damage of the high pressure to mobile terminal, it is ensured that the safety of charging.
Based on above-mentioned mobile terminal, the present invention also provides a kind of charging voltage control method, refers to Fig. 3, described to fill
Voltage conrol method includes:
S100, charging voltage control device judge whether charger inserts, when judging that charger is inserted, by charger
Output voltage is according to blood pressure lowering multiple blood pressure lowering, the charging voltage of acquisition minimal pressure value;
S200, according to the comparative result of charging voltage and setting voltage scope adjust blood pressure lowering multiple, until charging voltage reaches
Stop adjustment to after setting voltage scope;
S300, charging voltage control device start charging module, and battery is charged with current charging voltage.
In step S100, judge that the method whether charger inserts is:Judge whether produced on CHGIN pins
Rise along interrupt signal, if having, then it is assumed that charger is inserted;It is no then without charger insertion.
After charger insertion, charging voltage control device first by the output voltage of charger according to blood pressure lowering multiple blood pressure lowering, i.e.,
The position of the slide plate of adjustable resistance in adjustment pressure unit, makes the resistance of adjustable resistance maximum(Such as it is 100k ohm), so i.e.
The charging voltage of minimal pressure value can be obtained.The damage of high pressure or high voltage pulse to mobile terminal can so be avoided.Then need
Adjust the position of slide plate to gradually rise charging voltage.
In the present embodiment, step S200 is specifically included:
Charging voltage and setting voltage scope after step 201, each adjustment of voltage comparison module collection is compared;
If step 202, judging charging voltage less than setting voltage scope, blood pressure lowering control unit exports the first control signal
Adjusting the position of the slide plate makes the resistance of adjustable resistance diminish, so that charging voltage rises;Return to step 201.
If judging charging voltage in the range of setting voltage, blood pressure lowering control unit stops the position of adjustment slide plate.
If judging charging voltage more than setting voltage scope, it is described that blood pressure lowering control unit exports the adjustment of the second control signal
The position of slide plate makes the resistance of adjustable resistance become big, reduces charging voltage;Return to step 201.
In the specific implementation, voltage comparison module can change adjustable electric using ladder adjustment mode or classification adjustment mode
The resistance of resistance rises or falls charging voltage.
Ladder adjustment mode:
Step 1, voltage comparison module judge current charging voltage(That is the charging voltage of minimal pressure value)Whether it is less than and sets
Determine voltage range:If being less than, control blood pressure lowering control unit and export the position that the first control signal adjusts the slide plate, by adjustable electric
The resistance of resistance reduces the first preset resistive value Rx.
Now V2=V1 * R2/(R1_bak-Rx1+R2), V2 are the charging voltage after adjustment, and V1 is output
Voltage, R1_bak-Rx1 is the resistance of the adjustable resistance after this adjustment, and R1_bak is the adjustable resistance after last time adjustment
Resistance.Setting voltage scope is setting voltage ~ setting voltage+deviation(0.1V~ 0.5V).
It is to be appreciated that because the resistance of adjustable resistance is first adjusted to 100k ohm, then it is minimum when judging for the first time
The charging voltage of pressure value is typically smaller than setting voltage scope.
Step 2, voltage comparison module judge current charging voltage(Charging voltage after adjusting)Whether less than setting
Voltage range:
If step 3, being less than, control blood pressure lowering control unit and export the position that the first control signal adjusts the slide plate, making can
The resistance for adjusting resistance reduces the first preset resistive value Rx1;Return to step 2 continues the resistance for judging adjustment adjustable resistance.
If in the range of setting voltage, notifying that blood pressure lowering control unit stops adjustment, the position of the slide plate of adjustable resistance is consolidated
Fixed, charging module starts, and battery is charged with current charging voltage.
If being more than setting voltage scope, notify that blood pressure lowering control unit exports the position that the second control signal adjusts the slide plate
Put, the resistance for making adjustable resistance increases the second preset resistive value Rx2, reduces current charging voltage;Return to step 2 continues to sentence
It is disconnected.
Now V2=V1 * R2/(R1_bak+Rx2+R2), R1_bak+Rx2 are adjustable after this adjustment
The resistance of resistance, R1_bak is the resistance of the adjustable resistance after last time adjustment
Wherein, the first preset resistive value Rx1 is more than the second preset resistive value Rx2.First preset resistive value Rx1 is made after adjustment every time
Charging voltage is stepped up in equivalent, and the regulation stepping of the first preset resistive value Rx1 is larger, and charging voltage can be made to increase every time
1V or 0.5V, can accelerate the rate of climb of charging voltage.If charging voltage after the adjustment is more than the situation of setting voltage scope
Under, still adjusted with the first preset resistive value Rx1, it is possible that charging voltage is in two kinds less than or greater than setting voltage scope
Situation about moving in circles under state.For this purpose, the present embodiment arranges the second preset resistive value Rx2 to finely tune adjustable resistance, after making adjustment
Charging voltage try one's best with less adjustment stepping(As charging voltage can be made every time to reduce 0.1V or 0.2V)Near setting voltage
Scope, to avoid the occurrence of regulation stepping the situation that ambassador's charging voltage is unable to reach setting voltage scope is crossed.
Classification adjustment mode:
Whether step 11, voltage comparison module judge current charging voltage less than setting voltage scope:
If step 12, being less than, corresponding adjustment grade is called according to charging voltage and the difference of setting voltage.
In order to accelerate the charging voltage rate of climb, the present embodiment is different from the setting of the difference of setting voltage according to charging voltage
Adjustment grade, difference adjustment grades regulation steppings(That is the ascending threshold of charging voltage)It is different.The difference, adjustment etc.
Level, the relation of regulation stepping are as follows:
Difference is more than or equal to first voltage(Such as 2V), the first adjustment grade, resistance the 3rd pre- handicapping of reduction of adjustable resistance
Value Rx3(Charging voltage can be made to rise 2V).
Difference is less than first voltage and more than or equal to second voltage(Such as 1V), the second adjustment grade, the resistance of adjustable resistance
Reduce the 4th preset resistive value Rx4(Charging voltage can be made to rise 1V).
Difference is less than second voltage and more than or equal to tertiary voltage(Such as 0.1V), the 3rd adjustment grade, the resistance of adjustable resistance
Value reduces the 5th preset resistive value Rx5(Charging voltage can be made to rise 0.1V).
Correspondence adjustment stepping is selected according to difference(That is ascending threshold)Make after charging voltage rising, return to step 11 continues to sentence
It is disconnected.
If in the range of setting voltage, notifying that blood pressure lowering control unit stops adjustment, the position of the slide plate of adjustable resistance is consolidated
Fixed, charging module starts, and battery is charged with current charging voltage.
If being more than setting voltage scope, notify that blood pressure lowering control unit exports the position that the second control signal adjusts the slide plate
Put, the resistance for making adjustable resistance increases the second preset resistive value Rx2, reduces current charging voltage;Rear return to step is adjusted
11。
In sum, the present invention when charger is inserted, first by the output voltage of charger according to blood pressure lowering multiple blood pressure lowering, obtain
The charging voltage of minimal pressure value is obtained, changing blood pressure lowering multiple by adjusting the resistance of adjustable resistance afterwards makes charging voltage progressively go up
Rise or decline, until charging voltage reaches setting voltage scope(Meet the setting voltage of mobile terminal standard charging)After stop
Adjustment, is charged with current charging voltage;It is just started to charge up after charging voltage meets setting voltage, can be by difference
The output voltage of the charger of type is adjusted to the charging voltage of mobile terminal needs, can avoid using various non-standard chargers
When due to charging potential safety hazard caused by the inconsistent institute of output voltage, it is to avoid damage of the high pressure to mobile terminal, it is ensured that charge
Safety.
It should be appreciated that the application of the present invention is not limited to above-mentioned citing, and for those of ordinary skills, can
To be improved according to the above description or be converted, all these modifications and variations should all belong to the guarantor of claims of the present invention
Shield scope.