CN106026258B - A kind of mobile terminal - Google Patents

A kind of mobile terminal Download PDF

Info

Publication number
CN106026258B
CN106026258B CN201610468005.6A CN201610468005A CN106026258B CN 106026258 B CN106026258 B CN 106026258B CN 201610468005 A CN201610468005 A CN 201610468005A CN 106026258 B CN106026258 B CN 106026258B
Authority
CN
China
Prior art keywords
battery
charging
voltage
charger
current
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201610468005.6A
Other languages
Chinese (zh)
Other versions
CN106026258A (en
Inventor
李春乾
俞茂学
黄亚玲
杜文娟
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hisense Mobile Communications Technology Co Ltd
Original Assignee
Hisense Mobile Communications Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hisense Mobile Communications Technology Co Ltd filed Critical Hisense Mobile Communications Technology Co Ltd
Priority to CN201610468005.6A priority Critical patent/CN106026258B/en
Publication of CN106026258A publication Critical patent/CN106026258A/en
Application granted granted Critical
Publication of CN106026258B publication Critical patent/CN106026258B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H02GENERATION; CONVERSION OR DISTRIBUTION OF ELECTRIC POWER
    • H02JCIRCUIT ARRANGEMENTS OR SYSTEMS FOR SUPPLYING OR DISTRIBUTING ELECTRIC POWER; SYSTEMS FOR STORING ELECTRIC ENERGY
    • H02J7/00Circuit arrangements for charging or depolarising batteries or for supplying loads from batteries
    • H02J7/0029Circuit arrangements for charging or depolarising batteries or for supplying loads from batteries with safety or protection devices or circuits
    • H02J7/0036Circuit arrangements for charging or depolarising batteries or for supplying loads from batteries with safety or protection devices or circuits using connection detecting circuits
    • HELECTRICITY
    • H02GENERATION; CONVERSION OR DISTRIBUTION OF ELECTRIC POWER
    • H02JCIRCUIT ARRANGEMENTS OR SYSTEMS FOR SUPPLYING OR DISTRIBUTING ELECTRIC POWER; SYSTEMS FOR STORING ELECTRIC ENERGY
    • H02J7/00Circuit arrangements for charging or depolarising batteries or for supplying loads from batteries
    • H02J7/0029Circuit arrangements for charging or depolarising batteries or for supplying loads from batteries with safety or protection devices or circuits
    • H02J7/0031Circuit arrangements for charging or depolarising batteries or for supplying loads from batteries with safety or protection devices or circuits using battery or load disconnect circuits
    • HELECTRICITY
    • H02GENERATION; CONVERSION OR DISTRIBUTION OF ELECTRIC POWER
    • H02JCIRCUIT ARRANGEMENTS OR SYSTEMS FOR SUPPLYING OR DISTRIBUTING ELECTRIC POWER; SYSTEMS FOR STORING ELECTRIC ENERGY
    • H02J7/00Circuit arrangements for charging or depolarising batteries or for supplying loads from batteries
    • H02J7/0047Circuit arrangements for charging or depolarising batteries or for supplying loads from batteries with monitoring or indicating devices or circuits
    • HELECTRICITY
    • H02GENERATION; CONVERSION OR DISTRIBUTION OF ELECTRIC POWER
    • H02JCIRCUIT ARRANGEMENTS OR SYSTEMS FOR SUPPLYING OR DISTRIBUTING ELECTRIC POWER; SYSTEMS FOR STORING ELECTRIC ENERGY
    • H02J7/00Circuit arrangements for charging or depolarising batteries or for supplying loads from batteries
    • H02J7/007Regulation of charging or discharging current or voltage
    • HELECTRICITY
    • H02GENERATION; CONVERSION OR DISTRIBUTION OF ELECTRIC POWER
    • H02JCIRCUIT ARRANGEMENTS OR SYSTEMS FOR SUPPLYING OR DISTRIBUTING ELECTRIC POWER; SYSTEMS FOR STORING ELECTRIC ENERGY
    • H02J7/00Circuit arrangements for charging or depolarising batteries or for supplying loads from batteries
    • H02J7/0029Circuit arrangements for charging or depolarising batteries or for supplying loads from batteries with safety or protection devices or circuits
    • H02J7/00304Overcurrent protection

Abstract

The invention discloses a kind of mobile terminal, the metering chip of the current direction including battery, for detecting battery, charging interface, the load switch for directly filling access for being connected to or cutting off battery, current monitoring unit and processor for detecting total input current.The present invention enters total input current of mobile terminal and the current direction of battery by detection, tentatively judged with the plug state to charger, when mobile terminal detects that total input current is less than a certain preset value and battery discharge during directly filling, access is directly filled by cutting battery, it is influenced with eliminating cell voltage to the current potential of power pins on charging interface, then use traditional charger plug testing mechanism that can accurately judge whether charger is pulled out during directly filling, and then system is allow to be transferred to correct process flow, while improving charger plug accuracy in detection, it may also be ensured that the safety of battery charging, improve mobile terminal system reliability of operation.

Description

A kind of mobile terminal
Technical field
The invention belongs to DC charging technical fields, specifically, be related to one kind can be right during battery directly fills The extraction state of charger realizes the mobile terminal accurately detected.
Background technique
Currently, portable mobile termianl product (such as mobile phone, PAD, laptop etc.) has been deep into people's life Every aspect, become lead semiconductor industry advance leading force.Existing mobile terminal product mostly uses greatly chargeable Battery is that the circuit system of interiors of products is powered.As the function that mobile terminal is supported is increasing, the consumption of circuit system Electricity also increases with it, and in the case where limited battery capacity, the cruise duration after product charging is gradually shortened, and charging is caused to be grasped Work becomes more and more frequently, to bring great inconvenience to the routine use of people.
In order to accelerate charging rate, reduces user and charge the time waited, it is straight to carry out high current to battery using charger Filling is primary solutions that current charging field proposes.That is, the design connection charging interface in the charging circuit of mobile terminal Straight with battery fills access, directly fills access by connection, the output voltage of charger is directly transferred to battery, to realize to electricity The high current in pond is directly filled.
During battery directly fills, it sometimes appear that the case where charger is surprisingly extracted or powered off, at this time due to directly filling Access is also maintained at connected state, therefore the voltage on charging interface is substantially equal to the terminal voltage of battery, then leads to system It can not identify that charger has been pulled out, also rest in the process using charger charging, such as also shown in user interface There is charger icon etc., this can not only allow user to generate puzzlement, while also reduce the safety of running of mobile terminal.
Summary of the invention
The purpose of the present invention is to provide a kind of can accurately to detect what whether charger was extracted during directly filling Mobile terminal, to improve system reliability of operation.
In order to solve the above technical problems, the present invention is achieved by the following scheme:
A kind of mobile terminal is provided with battery, metering chip, charging interface, load switch, current monitoring unit and processing Device;The battery is for storing electric energy;The metering chip is used to detect the battery core voltage and charging current of the battery;It is described Charging interface is used for external charger, and is provided with power pins;The load switch be connected to the power pins with it is described Between battery, access is filled for being connected to or cutting off the straight of battery;The current monitoring unit is drawn for detecting by the power supply Total input current of foot;It is provided with communication interface on the processor, connects the metering chip;The processor is used for Meet directly control that the load switch is connected to the battery when filling condition directly fill access, and according to the meter during directly filling The current direction of the battery is flowed through in the charging current judgement that amount chip detects, and the current monitoring unit is detected Total input current is compared with a preset value;If total input current is lower than the preset value and the electric current stream of the battery To being flowed outwardly by battery, then controls the load switch and disconnect.
Compared with prior art, the advantages and positive effects of the present invention are: the present invention enters mobile terminal by detection The current direction of total input current and battery, is tentatively judged with the plug state to charger, when mobile terminal is straight It is logical by directly filling for cutting battery when detecting that total input current is less than a certain preset value and battery discharge during filling Road is influenced with eliminating cell voltage to the current potential of power pins on charging interface, then plugs detection using traditional charger Mechanism can accurately judge whether charger is pulled out during directly filling, and then system is allow to be transferred to correct processing Process can also further ensure that the safety of battery charging, improve and move while improving charger plug accuracy in detection Dynamic terminal system reliability of operation.
After the detailed description of embodiment of the present invention is read in conjunction with the figure, the other features and advantages of the invention will become more Add clear.
Detailed description of the invention
It to describe the technical solutions in the embodiments of the present invention more clearly, below will be to needed in the embodiment Attached drawing is briefly described, it should be apparent that, drawings in the following description are some embodiments of the invention, for this field For those of ordinary skill, without creative efforts, it is also possible to obtain other drawings based on these drawings.
Fig. 1 is a kind of schematic block circuit diagram for embodiment that mobile terminal is connect with the adjustable charger of output voltage;
Fig. 2 is the circuit theory frame for another embodiment that mobile terminal is connect with the adjustable charger of output voltage Figure;
Fig. 3 is a kind of process flow of embodiment of the charging method proposed based on mobile terminal shown in fig. 1 or fig. 2 Figure;
Fig. 4 is a kind of process flow diagram for embodiment that battery directly fills process;
Fig. 5 is a kind of process flow diagram for embodiment that charger plugs detection method during battery directly fills.
Specific embodiment
A specific embodiment of the invention is described in more detail with reference to the accompanying drawing.
The present embodiment is in order to make full use of the adjustable characteristic of QC3.0 charger output voltage dynamic, to realize charging rate Be obviously improved, on the one hand to be built-in with rechargeable battery mobile terminal carry out hardware modification, support mobile terminal both can Normal charge, that is, charged the battery by the charging chip inside mobile terminal;It can support directly to fill again, that is, by charger Output voltage be fed directly to battery, to battery carry out high current directly fill;On the other hand, according to battery during the charging process its The real-time change of battery core voltage carries out dynamic regulation to the charging voltage of QC3.0 charger output, and controls mobile terminal entrance Different charging modes then realize the rational utilization of charge power supply, shorten the charging time of battery.
Certainly, the QC3.0 charger can also be replaced using the adjustable charger of other output voltages dynamic, together Sample can achieve identical technical effect, the present embodiment to the concrete type of the adjustable charger of output voltage be not limited in Upper citing.
Below with reference to Fig. 1, Fig. 2, the hardware configuration situation of the mobile terminal of the present embodiment is specifically addressed first.
As shown in Figure 1, in order to retain the existing traditional charge function of mobile terminal, guarantee mobile terminal can with it is existing Host and the normal grafting of regular charger, charging, the present embodiment keep the existing charging interface of mobile terminal constant, that is, are used for The multiplex interface of charging and transmission data, such as the USB interface J1 being widely used at present, with meet its with it is big absolutely on the market at present The conventional power adapter of most producer's productions and the grafting charging requirement of main frame.In the present embodiment, the USB connects Mouth J1 can be USB Type-C interface, be also possible to Micro USB interface etc..Since USB Type-C interface can support height Up to the electric current of 5A, therefore, the present embodiment preferably uses USB Type-C interface as the charging interface of the mobile terminal, with In external charger, charge to the battery U4 inside mobile terminal.
Load switch U1 and charging chip U2 is set in the inside of mobile terminal, to support directly to fill and charging chip charging two Kind mode.In the present embodiment, the load switch U1 can directly fill access to the battery U4 using an integrated chip On-off control is carried out, as shown in Figure 1;The load switch U1 can also be set up using discrete component, for example, by using a MOS Pipe Q2 is built with unification booster circuit U7, as shown in Fig. 2, the on-off control for directly filling access to battery U4 equally may be implemented System.
The present embodiment combines Fig. 1 to set to using integrated chip as the specific route of the charging circuit of load switch U1 first Meter and its working principle are described in detail.
It, can be by the input pin VIN of load switch U1 when the load switch U1 is a controllable switch chip It is connected to the power pins VBUS of USB interface J1, output pin VOUT is connected to the anode of battery U4.During directly filling, bear Load switch U1 is connected by being inputted pin VIN and its output pin VOUT, fills access to be connected to the straight of battery U4.
In order to realize the on-off control to the load switch U1, the present embodiment is additionally provided with place in the mobile terminal Device U3 is managed, effective or invalid enable signal is exported to the enabled pin EN of load switch U1 using processor U3, then controls Load switch U1 processed is enabled or hangs up (non-enabled), to realize the accurate switching of two kinds of charging modes.
In the present embodiment, in order to ensure battery U4 charging safety, the present embodiment in the mobile terminal also into One step is provided with cell voltage monitoring unit U5 and logical AND gate U6, as shown in Figure 1.Wherein, cell voltage monitoring unit U5 is used It, specifically can be using the input terminal of anode and cell voltage monitoring unit U5 in battery U4 in the terminal voltage of detection battery U4 Between connect bleeder circuit (such as the bleeder circuit being made of resistance R10, R11) mode, using bleeder circuit to battery U4 Terminal voltage divided after, be transmitted to the input terminal of the cell voltage monitoring unit U5, realize battery by converting Effective monitoring of the voltage monitoring unit U5 to the terminal voltage of battery U4.If the terminal voltage of battery U4 is not above default threshold It is worth (for the battery that maximum battery core voltage is 4.4V, the threshold value that terminal voltage can be set is 4.6V), then cell voltage Monitoring unit U5 exports high level signal by its output end, is transmitted to one of input pin of logical AND gate U6.It will patrol GPIO mouthfuls of the first via for being connected to processor U3 with another input pin of door U6, such as GPIO1 mouthfuls are collected, processor is received The enable signal of U3 output enabled for controlling load switch U1.When needing directly to fill battery U4, processor U3 is logical Cross its GPIO1 mouthfuls of effective enable signal of output high level.At this point, if the terminal voltage of battery U4 without departing from preset threshold, Then two input pins of logical AND gate U6 are high level.Logical AND gate U6 to the two-way high level signal that receives carry out with Operation, output high level signal are transmitted to the enabled pin EN of load switch U1, and control load switch U1 is enabled, connects its input Pin VIN and output pin VOUT is made battery U4's directly to fill access connection, is carried out using the output voltage of charger to battery U4 Directly fill.During directly filling, processor U3 exports the effective enable signal of high level by its GPIO1 mouthfuls always, when battery electricity When pressure monitoring unit U5 detects that the terminal voltage of battery U4 is more than preset threshold, setting its output end is low level, makes logical AND The output signal of door U6 becomes low level from high level, and then by load switch U1 hang-up, (i.e. control load switch U1 enters non- Enabled off position), disconnect the input pin VIN and output pin VOUT of load switch U1, cutting battery U4's is straight Access is filled, battery U4 is avoided to overcharge damage.
The output signal of cell voltage monitoring unit U5 is sent to the GPIO mouthfuls all the way other of processor U3 simultaneously, such as GPIO2 mouthfuls, processor U3 may be implemented to the real time monitoring of the terminal voltage of battery U4.
Cell voltage monitoring unit U5 and logical AND gate U6 is arranged in the present embodiment in the terminal, even if mobile terminal exists Situations such as crashing in charging process also can use the low level signal control logic of cell voltage monitoring unit U5 output It is low level with the door U6 enabled pin for setting load switch U1, and then enters non-enabled state, cutting battery U4's directly fills access, Realize hardware over-voltage defencive function.
Lead to not carry out load switch U6 shutdown control because logical AND gate U6 exception occurs in order to prevent, this implementation Example utilizes second road GPIO mouthfuls of processor U3, such as GPIO3 mouthfuls, is directly connected to the enabled pin EN of load switch U1.It is described Processor U3 sets its GPIO3 mouthfuls by default as input state, once break down cannot be according to by discovery logical AND gate U6 It is required that when control load switch U1 cutting directly fills access low level mode, control load can be set to using by its GPIO3 mouthfuls Switch U1 enters non-enabled state, and that then cuts off battery U4 directly fills access, executes the protection mechanism of hardware anomalies.
The load switch U1 of the present embodiment also has overvoltage protection and current-limiting function, is provided with overvoltage protection pin OVP and current limliting pin ILIM, as shown in Figure 1.The overvoltage protection pin OVP of the load switch U1 is passed through into resistance pressure-dividing network It is connected to the power pins VBUS of USB interface J1, to monitor the output voltage of charger.In the present embodiment, the resistance point Pressure network road can be connected in series by two divider resistances R4, R5, be connected to the power pins VBUS of USB interface J1 with systematically it Between, the intermediate node of divider resistance R4, R5 are connected to the overvoltage protection pin OVP of load switch U1, by configuring partial pressure electricity The resistance value for hindering R4, R5, it is being more than default for making the charging voltage (i.e. the output voltage of charger) accessed by power pins VBUS Straight charging voltage secure threshold VsafeWhen, triggering load switch U1 executes overvoltage protection movement, and cutting battery U4's directly fills access, Avoid battery U4 by overvoltage impact.
In the present embodiment, the straight charging voltage secure threshold VsafeIt is contemplated that the battery core voltage V of battery U4bat_real、 The pairs of maximum charging current values I that battery U4 is supportedmax_bat, battery U4 internal resistance and system in the line resistance directly filled in access Etc. factors specifically determine.Specifically, V can be setsafe= Vbat_real+Imax_bat*R+△V;Wherein, R is the interior of battery U4 Resistance and system are in the sum of the line resistance directly filled in access, and △ V is voltage deviation threshold value, and △ V >=1V.The present embodiment is preferably set △ V=1V is set, while playing the role of overvoltage protection to battery U4, improves the timeliness of overvoltage protection action response.
For the current limliting pin ILIM of load switch U1, it is preferably passed through resistance R8 all the way and is grounded by the present embodiment, another Road is grounded by the switch ways of a resistance R6 and switching tube Q1, and the control terminal of switching tube Q1 is connected to processor U3, such as On the GPIO5 mouth of processor U3, the selectivity access of resistance R6 is controlled by control switch pipe Q1 on-off.Specifically, institute A variety of switch elements such as transistor, power tube, silicon-controlled can be selected by stating switching tube Q1, and the present embodiment is with NPN type triode Example is illustrated.The base stage of NPN type triode Q1 is connected to the GPIO5 mouth of processor U3, emitter ground connection, collector passes through The resistance R6 of series connection with it is connected to the current limliting pin ILIM of load switch U1.The resistance value for configuring resistance R8, makes load switch U1 Current limliting 500mA by default.When needs, which enter, directly fills process, processor U3 passes through the high electricity of its GPIO1 mouthfuls of output first Flat, control load switch U1 conducting, connection battery U4's directly fills access;Then pass through its GPIO5 mouthfuls of output high level, control NPN type triode Q1 saturation conduction is connected to the resistance value of the equivalent resistance on the current limliting pin ILIM of load switch U1 at this time R(ILIM)For the resistance value in parallel of resistance R6 and resistance R8, the resistance value of resistance R6 is configured, the cut-off current of load switch is made.Wherein, the IsafeSecure threshold I is flowed for preset straight chargingsafe, the IsafeIt is contemplated that electricity The pairs of maximum charging current values I that pond U4 is supportedmax_batEtc. factors determine.It, can as a kind of preferred design of the present embodiment I is arrangedsafe=Imax_bat+ △ I, wherein △ I is current deviation threshold value, and △ I >=500mA.The present embodiment be preferably provided with △ I= 500mA improves the timeliness of current limliting response action while playing overcurrent protection to battery U4.
The power pins VBUS of USB interface J1 is connected to the power input of the charging chip U2 inside mobile terminal simultaneously VBUS is held, when needing to charge to battery U4 using charging chip U2, it is low that processor U3 passes through its GPIO1 mouthfuls of output first The invalid enable signal of level, control load switch U1 are disconnected;Then by its control port, such as its GPIO4 mouthfuls, output is high To the EN pin of charging chip U2, control charging chip U2 is enabled to be run level signal, and charging modes are switched to charging chip U2 charging is received the output voltage of charger using charging chip U2, and the output voltage of charger regulation power is switched to and is filled Electrical chip U2 carries out dynamic regulation using output voltage of the charging chip U2 to charger.Specifically, charging chip U2 can be with According to the battery core voltage change of battery U4, the output voltage of charger is adjusted, and the output end ChgOut of charging chip U2 is connected The anode of energization pond U4 is battery U4 charging using the power supply of charging chip U2 output.
In order to which the parameters such as battery core voltage, charging current to battery U4 detect, the present embodiment is preferably in the battery Built-in metering chip in U4, using parameters such as the battery core voltage of metering chip detection battery U4, charging current, battery temperature rises, and (such as pass through I by bus communication mode2C bus) it is transmitted to the communication interface of the processor U3, such as I2C interface.Institute Charging chip U2 can be sent to for parameters such as the battery core voltage, the charging currents that receive by stating processor U3, such as pass through SPMI Bus sends charging chip U2 to, charging chip U2 determined according to the battery core voltage of battery U4 execute which kind of charge mode (such as Trickle charge mode or constant-voltage charge mode etc.).Furthermore, it is possible to which B+, B- pin of charging chip U2 is correspondingly connected to electricity The anode and cathode of pond U4, for detecting the terminal voltage of battery U4.In the output end ChgOut and battery U4 of charging chip U2 Anode between connect sampling resistor R9, such as the high-power precision resistance of 10 milliohms, and by C+, C- pin of charging chip U2 The both ends of the sampling resistor R9 are correspondingly connected to, by detecting the pressure drop at the both ends sampling resistor R9, in conjunction with sampling resistor R9's Resistance value can calculate the size of the output electric current of charging chip U2.
Acceptable further integrated current monitoring unit, enters mobile terminal for monitoring in the load switch U1 Total input current (that is, output electric current of charger), the current monitoring unit is according to ratios such as the output electric current of charger generations The monitoring current that example reduces passes through the current monitoring pin IMON output being arranged on load switch U1.The charging chip U2 can It with using it, ADC interface is connected to the current monitoring pin IMON of load switch U1 all the way, and is grounded by resistance R3, such as Shown in Fig. 1.The current monitoring pin IMON monitoring current exported is converted into voltage using resistance R3, and via ADC interface into After row analog-to-digital conversion, the output electric current of charger is calculated, realizes charging chip U2 to the real-time prison of the output electric current of charger It surveys.Certainly, the output current value for the charger that the charging chip U2 can also will test passes through SPMI bus transfer to place Device U3 is managed, to realize processor U3 to the overall monitor of system charging safety.
Certainly, the current monitoring unit can also be separately configured independently of the load switch U1, and the present embodiment is to this Without concrete restriction.
In order to which the output voltage of the QC3.0 charger to external USB interface J1 carries out dynamic regulation, the present embodiment will be handled Third driving pin (such as differential pin D+) of device U3 and the 4th driving pin (such as differential pin D-) are respectively connected to USB The differential pin of interface J1, i.e. D+ pin and D- pin, and by the first of charging chip U2 the driving pin (such as differential pin D +) and the second driving pin (such as differential pin D-) the D+ pin of USB interface J1 is connected to by isolation resistance R1, R2 respectively With D- pin, signal being isolated between charging chip U2 and processor U3 on differential signal line is realized by resistance R1, R2. Specifically, when processor U3 or charging chip U2 detect that the charger being inserted on USB interface J1 is QC3.0 charger When, it can be adjusted by the way of sending pulse signal to QC3.0 charger by its differential pin D+ or differential pin D- The output voltage of QC3.0 charger.
Its interface chip of QC3.0 charger utilizing receives the letter sent by its differential pin D+, differential pin D- Number, as soon as whenever its differential pin D+ receives a pulse signal, interface chip control the AC-DC unit of charger internal by its Output voltage raises 0.2V;As soon as interface chip controls AC-DC unit will whenever its differential pin D- receives a pulse signal Its output voltage lowers 0.2V, thus can realize the dynamic regulation of the output voltage to QC3.0 charger.
It, can be in mobile terminal in order to whether be that standard configuration QC3.0 charger accurately identifies to external charger Detection pin ID is respectively set on USB interface J1 and on the USB interface J0 of standard configuration QC3.0 charger, is examined using processor U3 The level change of the ID pin is surveyed, to realize the identification to standard configuration QC3.0 charger.One kind as the present embodiment is preferably set Meter scheme, can using in such a way that pull-up circuit or earthed circuit is arranged in the inside of standard configuration QC3.0 charger to change State level state of the detection pin ID in the plug of standard configuration QC3.0 charger.For example, on the USB interface J1 of mobile terminal not When being inserted into standard configuration QC3.0 charger, the interface circuit inside mobile terminal is configured, makes the electricity of the detection pin ID of USB interface J1 Position is in second electrical level state (such as low level);When the QC3.0 charger for having standard configuration is inserted on the USB interface J1, benefit The current potential of the detection pin ID is transformed into the first level with the internal circuit (such as pull-up circuit) of standard configuration QC3.0 charger State (such as high level), processor U3 are the first level by second electrical level state transition in the current potential for detecting the ID pin When state, it is determined with the insertion of standard configuration QC3.0 charger, into Charge Management process.
For the grounding pin GND in USB interface J1, it is answered to connect with the systematically good of mobile terminal, mobile whole When end is with external equipment grafting, guarantee mobile terminal and external equipment altogether.
Below with reference to Fig. 2 to the load switch U1 built using discrete component and the charging set up by the load switch U1 The specific route of circuit designs and its working principle is described in detail.
As shown in Fig. 2, the load switch U1 of this embodiment can match unification booster circuit U7 to pipe Q2 using a MOS It builds.Specifically, switch ways of the MOS to pipe Q2 can be connected on to the power pins VBUS and electricity of USB interface J1 Between the anode of pond U4, grid of the MOS to pipe Q2 is connected to the output end of booster circuit U7, is exported by booster circuit U7 Driving voltage carries out on-off control to the access that directly fills of battery U4 to control the MOS to pipe Q2 on-off.
In order to realize overvoltage protection and overcurrent protection during battery directly fills, for the load built using discrete component Current monitoring unit (that is, current monitoring chip U9) and controller U8 can be further arranged in switch U1, as shown in Figure 2.It is described Controller U8 can use chip microcontroller, and the AD2 of ADC interface all the way of single-chip microcontroller is divided by what is be made of resistance R26, R27 Volt circuit is connected to the anode of battery U4, detects for the terminal voltage to battery U4.By controller U8 in addition all the way ADC interface AD3 is connected to the straight of battery U4 by the bleeder circuit being made of resistance R28, R29 and fills access, for charging The output voltage of device is detected.High-power accurate electricity is preferably used in the sampling resistor R23(that connects that directly fills in access of battery U4 Resistance is as the sampling resistor R23), and positive-negative input end+the NI ,-NI of the current monitoring chip U9 are correspondingly connected to The both ends of the sampling resistor R23, by acquiring the pressure drop at the both ends the sampling resistor R23, to calculate the output of charger Size of current, and then the monitoring for exporting size of current can reflect by the output end OUT of current monitoring chip U9 output Voltage is transmitted separately to the ADC interface AD1 and charging chip U2 of the controller U8 after divider resistance R24, R25 partial pressure ADC interface, to realize controller U8 and charging chip U2 to the accurate measurements of output current of charger size.
Threshold value (such as straight charging voltage secure threshold V can be protected with preset overpressure in controller U8safe), overcurrent protection threshold Value (such as straight charging stream secure threshold Isafe) and terminal voltage maximum value, during battery directly fills, controller U8 is according to inspection The output voltage of the charger measured exports electric current and the terminal voltage of battery U4, and it is pre- to judge whether each parameter has exceeded its If threshold value, and then the corresponding control signal of pin CTL output is controlled by it, booster circuit U7 is made can control to realize.
Specifically, the control pin CTL default output high level that controller U8 can be set, by the controller U8's Control pin CTL is connect with one of input pin of logical AND gate U6, by another input pin of logical AND gate U6 It is connect with the GPIO1 of processor U3 mouth, receives the enable signal that processor U3 passes through its GPIO1 mouthfuls of output.When needs switch to When directly filling mode, processor U3 is by its GPIO1 mouthfuls of effective enable signal of output high level, since the control of controller U8 is drawn Foot CTL default output high level, therefore high level signal is exported by the output end of logical AND gate U6, control booster circuit U7 makes It can run, output drive signal controls MOS and pipe Q2 is connected, and connection battery U4's directly fills access.Process is directly filled in battery U4 In, the output voltage of controller U8 real-time detection charger exports electric current and the terminal voltage of battery U4, as long as one of them Parameter exceeds preset threshold, then is controlled pin CTL immediately and be set to low level, keep booster circuit U7 out of service, and MOS is controlled Pipe Q2 is turned off, fills access to cut off the straight of battery U4, it is ensured that the charging safety of battery U4.Meanwhile controller U8 can will be examined The parameters such as terminal voltage for measuring the output voltage of charger, output electric current and battery U4 pass through bus (such as UART bus) It is transmitted to processor U3, to realize that processor U3 controls the overall situation of circuit system.
When needing the charging modes of battery U4 being switched to charging chip charging by directly filling, can be incited somebody to action by processor U3 Its GPIO1 mouthfuls is set to low level, and then control logic and door U6 export low level signal, and control booster circuit U7 is out of service, Cutting battery U4's directly fills access, and then processor U3 exports high level signal by its control port (such as its GPIO4 mouthfuls) To the EN pin of charging chip U2, the enabled operation of charging chip U2 is controlled, is charged using starting charging chip U2 as battery U4.
In Fig. 2, between charging chip U2, processor U3 and battery U4 line connecting relation and and charging The connection relationship of mouthful J1 can copy circuit design shown in FIG. 1, the present embodiment not reinflated explanation herein.
After carrying out above-mentioned hardware modification to mobile terminal, below with reference to Fig. 3, Fig. 4 to charging valve performed by mobile terminal Reason process is described in detail.
As shown in figure 3, the Charge Management process of the present embodiment relates generally to following steps:
S301, the insert state for detecting charger;
In the present embodiment, mobile terminal can use its charging chip U2 or processor U3 on its USB interface J1 Whether there is charger insertion to be detected, if charger is not detected, repeats the detection process of this step;If detecting There is charger insertion, then executes subsequent step.
S302, the type for identifying charger;
Mobile terminal can be according to traditional charger type recognition methods to the charger being inserted on its USB interface J1 It is identified, and keeps the access that directly fills of battery U4 to disconnect (that is, load switch U1 in control figure 1 is non-to be made in identification process Energy;Or booster circuit U7 is non-enabled in control figure 2, is held off MOS to pipe Q2), default is filled using charging chip Electricity.
When mobile terminal detects that the charger of insertion is the fixed charger of output voltage, such as common 5V charger, QC2.0 charger, USB PD charger or MTK PE+ charger etc. keep charging chip to fill then in entire charging process Electricity, that is, be always battery U4 charging using charging chip U2.If insertion is adjustable charger (this reality of output voltage dynamic Example is applied to be illustrated by taking QC3.0 charger as an example), then execute subsequent step.
It in the present embodiment, can also be according to the design needs to described when detect insertion is QC3.0 charger Whether QC3.0 charger is that standard configuration charger makees further identification, specifically can use processor U3 according on USB interface J1 Whether be standard configuration charger, if so, executing subsequent step if detecting the level state of pin ID come the QC3.0 charger for judging insertion Suddenly;Otherwise, even if insertion is QC3.0 charger, for the charging safety for ensuring mobile terminal, also use charging chip for battery U4 charging.That is, mobile terminal is only detecting that the charger of insertion its USB interface J1 is the QC3.0 charging of standard configuration It when device, is just selectively entered and directly fills mode, otherwise, use charging chip U2 for battery U4 charging without exception.
In the present embodiment, standard configuration QC3.0 charger can be set and export 5V voltage by default, the voltage and master Machine, the charging voltage of conventional power adapter output are identical, to meet the charging chip U2 in mobile terminal to input power It is required that.
S303, the battery core voltage for detecting battery select to enter different charging modes according to the battery core voltage of battery;
In the present embodiment, processor U3 can be by being communicated, to obtain with the metering chip being built in battery U4 Take the battery core voltage V of battery U4bat_real;If the battery core voltage V of batterybat_realIn the preset range [S1, S2] for directly filling threshold value Within, then execute subsequent step;Otherwise, the S305 that gos to step is executed.
In the present embodiment, it is described directly fill threshold value (low pressure threshold S1, HVT high voltage threshold S2) can be according to the practical feelings of battery Condition specifically determines, preferably with the perseverance under standard DCP charging modes (the tradition charging carried out using regular charger to battery) Battery voltage range corresponding to the current charge stage is consistent.For example, for one piece of 4.4V battery, (i.e. battery core voltage max is The rechargeable battery of 4.4V), its low pressure threshold S1=3.2V, HVT high voltage threshold S2=4.2V can be set.
S304, process is directly filled into battery;
When processor U3 detects the battery core voltage V of battery U4bat_realIn it is preset directly fill threshold value range [3.2, When within 4.2], control charging chip U2 first is hung up, that is, enters non-enabled off position, by charging modes by charging core Piece charging, which is switched to, directly fills, and the output voltage of charger is regulated and controled to weigh to be switched to by charging chip execution and is held by processor U3 Row.Then, the preset initial relation table of comparisons is searched, according to the battery core voltage V of batterybat_realLocating segment obtains the area Between output voltage target value V corresponding to sectiontargWith charging current target value Itarg
It illustrates, threshold range [S1, S2] directly can be filled according to setting, if the battery core voltage division for battery goes out Dry segment, such as using 100mV as span, mark off N number of segment, N=(S2-S1)/100mV.For each segment Output voltage target value V corresponding to the battery core voltage of each segment is determined in advance outtargWith charging current target value Itarg, to form the initial relation table of comparisons, be stored in processor U3, or save in the terminal with processor In the memory of U3 connection, called for processor U3.
In the present embodiment, two segments preferably are marked off in the range [3.2,4.2] for directly filling threshold value:
The corresponding battery core voltage V of first interval sectionbat_realBetween 3.2V ~ 4V, the output voltage target value of charger Vtarg=Vmax-1, charging current target value Itarg=Imax_bat.I.e., it is possible to the pairs of maximum charging current values supported according to battery U4 Imax_batTo determine charging current target value I corresponding to first interval sectiontarg, such as I can be settarg=4.5A.It is described Vmax-1It can be according to the battery core voltage V of battery U4bat_real, the Imax_batAnd battery U4 internal resistance and system directly filling access In line resistance determine, such as V can be setmax-1=Imax_bat*R+Vbat_real, the R is that the internal resistance of battery U4 and system exist Directly fill the sum of the line resistance in access;
The corresponding battery core voltage of second interval section is between 4V ~ 4.2V, the output voltage target value V of chargertarg= Vmax-2, charging current target value Itarg=Imax_IC.I.e., it is possible to the maximum output current value supported according to charging chip U2 Imax_ICTo determine charging current target value I corresponding to second interval sectiontarg, such as I can be settarg=3A, in charging side When formula is excessively charged to charging chip by directly filling, it is steady to be able to maintain charging current.The Vmax-2It can be according to the electricity of battery U4 Core voltage Vbat_real, the Imax_ICAnd battery U4 internal resistance and system determined in the line resistance that directly fills in access, such as can V is arrangedmax-2=Imax_IC*R+Vbat_real
Below with reference to Fig. 4, the straight process of filling is described in detail.
S401, processor U3 are according to the battery core voltage V of the battery U4 detectedbat_realIt is searched in the initial relation table of comparisons In locating segment, according to output voltage target value V corresponding to the segmenttargAdjust the output electricity of QC3.0 charger Press Vout, until Vout=Vtarg
Specifically, processor U3 can be by output voltage target value VtargWith the 5V electricity of QC3.0 charger default output Pressure is compared, and the pulse number for needing to export by its differential pin D+ or D- is calculated, then to the difference of QC3.0 charger The pulse for separating foot D+ or D- output respective numbers, by the output voltage V of QC3.0 chargeroutIt is adjusted to Vtarg
S402, the straight of connection battery U4 fill access, and the output voltage using charger is directly battery U4 charging;
Specifically, for directly filling access (as shown in Figure 1) using load switch U1 design, it can use processor U3 The enabled operation of load switch U1 is controlled, fills access to be connected to the straight of battery U4;For directly filling access to what pipe Q1 was designed using MOS (as shown in Figure 2) can use the enabled operation of processor U3 control booster circuit U7, then drive MOS that pipe Q2 is connected, connection Battery U4's directly fills access, to realize directly filling to battery U4.
The charging current I of S403, real-time detection battery U4, by by the charging current mesh of charging current I and the segment Scale value ItargIt compares, to determine up-regulation or lower the output voltage V of chargerout, so that the charging current I of battery U4 Reach or close to the charging current target value Itarg
Specifically, during directly being filled to battery U4, the charging current I of real-time detection battery U4, if I < Itarg, then the output voltage V of charger is gradually raisedout, until charging current I=Itarg;If I > Itarg, then charging is gradually lowered The output voltage V of deviceout, until charging current I=Itarg.Hereafter, the charging current I of battery U4 is continued to test, as long as charging electricity I is flowed close to Itarg, such as charging current I is in [Itarg- △ I, Itarg] section in, be maintained for the current output voltage of charger VoutIt is constant, the constant current of high current class is carried out to battery U4 and is directly filled.The △ I is current deviation threshold value, and value is preferably not less than 500mA.In the present embodiment, it is preferably provided with △ I=500mA, to avoid there is the output voltage V of chargeroutIt adjusts repeatedly Situation.
S404, the battery core voltage V in battery U4bat_realThe higher leveled area of voltage is entered from the segment of the low level-one of voltage Between section when, search the initial relation table of comparisons, obtain the charging current target value I of the segmenttarg, and adjust charger Output voltage Vout, make the charging current I of battery U4 reach or close to the segment charging current target value Itarg
Specifically, during directly being filled to battery U4, the battery core voltage V of battery U4bat_realConstantly rise, when Battery core voltage Vbat_realWhen entering the higher leveled segment of voltage from the segment of the low level-one of voltage, processor U3 by searching for The initial relation table of comparisons obtains charging current target value I corresponding to the higher leveled segmenttarg;Then, lead to Crossing processor U3 dynamic reduces the output voltage V of the chargerout, until the charging current I of the battery U4 is equal to the section The charging current target value I of sectiontarg
For example, working as the battery core voltage V of battery U4bat_realWhen rising to the second interval section from the first interval section, Only read charging current target value I corresponding to second interval sectiontarg=Imax_IC=3A, according to the charging of second interval section Current target value ItargAdjust the output voltage V of chargerout, without the output voltage target according to corresponding to second interval section Value VtargTo adjust the output voltage V of chargerout, to guarantee charging current smooth change.In the present embodiment, second interval Output voltage target value V corresponding to sectiontargOnly when mobile terminal is inserted into standard configuration charger, the battery core voltage of battery U4 Vbat_realIt is read when just at the second interval section, using the basis initially adjusted as charger output voltage.
In the battery core voltage V of the battery U4bat_realThe higher leveled area of voltage is entered from the segment of the low level-one of voltage Between section, and close to when the critical point of two segments (for example, for setting two segments the case where, when the battery core of battery U4 Voltage Vbat_realWhen just beyond 4V), the charging current target value as corresponding to voltage higher leveled segment is lower than voltage Charging current target value corresponding to the segment of low level-one, it is therefore desirable to by the output voltage V of chargeroutIt lowers.In dynamic Reduce the output voltage V of the chargeroutWhen, it is possible that the battery core voltage V of battery U4bat_realIt is high by one from the voltage The case where segment of grade drops to the segment of the low level-one of the voltage is (for example, battery core voltage Vbat_realBecome smaller than 4V), This is because the presence of battery core internal resistance leads to battery core voltage V after charging current I is reducedbat_realMoment reduces, and returns A upper segment.In this case, in order to guarantee the stationarity for directly filling process, as long as detecting the charging current of battery U4 I is not zero, and does not just return to a upper segment, and being to continue with dynamic reduces the output voltage V of the chargerout, until described The charging current I of battery reaches charging current target value I corresponding to the higher leveled segmenttarg(for example, being directed to this reality The case where applying two segments of example design continues the output voltage V for lowering chargerout, until I=3A).Hereafter, in order to keep away Exempt from output voltage VoutIt adjusts repeatedly, as long as processor U3 detects charging current I close to Itarg, for example, I 2.5A ~ 3A it Between, it is maintained for the current output voltage V of chargeroutIt is constant, the constant current of high current class is carried out to battery U4 and is directly filled.The present embodiment exists Here preferably by current deviation threshold design at 500mA, it is of course also possible to need to select to set according to the actual design of mobile terminal Other numerical value are set to, the present embodiment is to this without concrete restriction.
S405, the battery core voltage V as battery U4bat_realIncreasing is more than preset directly when filling threshold range [S1, S2], will be filled Electric mode is switched to charging chip charging by directly filling;
Specifically, as the battery core voltage V for detecting battery U4bat_realIt is constantly increased with directly process is filled, is more than high pressure threshold When value S2, then that cuts off battery U4 directly fills access.It, can for directly filling access (as shown in Figure 1) using load switch U1 design To be hung up using processor U3 control load switch U1, i.e., control load switch U1 is non-enabled, into not operating status, with cutting Battery U4's directly fills access;For directly filling access (as shown in Figure 2) to what pipe Q1 was designed using MOS, processor U3 can use It is non-enabled to control booster circuit U7, then controls MOS and pipe Q2 is turned off, fills access to cut off the straight of battery U4.Battery U4's After directly filling access cutting, charging chip U2 is controlled by processor U3 and is enabled, switched to charging chip charging, utilize charging chip The output voltage V of U2 reception chargerout, charge for battery U4, and the S306 execution that gos to step.
S305, the battery core voltage V for judging batterybat_realWhether low pressure threshold S1 is less than, if so, passing through charging chip U2 Trickle charge is carried out to battery U4, until the battery core voltage V of batterybat_real=S1, return step S304 were directly filled into battery Journey;If the battery core voltage V of batterybat_realGreater than HVT high voltage threshold S2, S306 is thened follow the steps;
In the present embodiment, the processor U3 is in the battery core voltage V for detecting battery U4bat_realThreshold is directly filled preset When being worth other than range [S1, S2], control load switch U1 first is disconnected, and cutting battery U4's directly fills access, and charging modes are cut Charging chip charging is changed to, is battery U4 charging using charging chip U2, and the output voltage of charger regulation power is switched to Charging chip U2 adjusts the output voltage of charger using charging chip U2.
Charging chip U2 can obtain the battery core voltage V of battery U4 by communicating with processor U3bat_real.When charging core Piece U2 detects the battery core voltage V of battery U4bat_realWhen lower than S1, the output voltage V of QC3.0 charger is adjustedout=5V, to fill Electrical chip U2 power supply.At this point, charging chip U2 can export the low current of 200mA, trickle charge is carried out to the battery U4, directly To the battery core voltage V of battery U4bat_real=S1。
S306, the battery core voltage V for detecting battery U4bat_realWhether S2 is higher than and lower than maximum battery core corresponding to battery U4 Voltage S3, if so, thening follow the steps S307;Otherwise, step S308 is executed;
In the present embodiment, for selecting 4.4V battery the case where, the S3 is 4.4V.
The output voltage V of S307, dynamic regulation chargerout, the output electric current for finding out charging chip U2 meeting its expection Export electric current IthIn the case where charger minimum output voltage, using the minimum output voltage be charging chip U2 power, Until the battery core voltage V of battery U4bat_realReach its maximum battery core voltage;
In the present embodiment, it is contemplated that in identical charging current, the input voltage of charging chip (namely fills The output voltage of electric appliance) it is higher, the efficiency of charging chip is lower, and thermal losses is also bigger, so being using charging chip U2 When battery U4 charges, the output voltage V of chargeroutThe basic principle of adjustment is exactly in the case where meeting charge power, as far as possible Reduce the output voltage V of chargerout, improve input current Iin, to keep the input power of charging chip U2 and output power to keep It is permanent.
Specifically, as S2 < Vbat_realWhen≤S3, charging chip U2 adjusts it and exports electric current (that is, the charging electricity of battery U4 Stream I) reach its anticipated output electric current Ith.In the present embodiment, it is preferably provided with the anticipated output electric current IthEqual to the charging The maximum output current that chip U2 is supported, such as setting Ith=3A, further to shorten the charging time.
During charging chip U2 is that battery U4 charges, charging chip U2 can be controlled by processor U3 and gradually adjusted The output voltage V of whole chargerout, while the output electric current of charging chip U2 is detected, it finds out and is meeting anticipated output electric current IthFeelings Minimum input voltage under condition is (that is, meeting charging chip U2 anticipated output electric current IthIn the case of charger minimum output electricity Pressure), input voltage at this time is exactly the optimum efficiency in the case of current battery level.Hereafter, with the battery core voltage of battery U4 Vbat_realIt gradually rises, the output voltage V of synchronous adjustment chargerout, to maintain described in the charging current I satisfaction of battery U4 Ith, until the battery core voltage V of battery U4bat_realReach the turning point of constant-voltage charge, i.e. Vbat_real=S3, into subsequent constant pressure Charging stage.
S308, keep the output voltage of charging chip U2 constant equal to the maximum battery core voltage S3 of battery U4, to battery U4 Constant-voltage charge is carried out, and in the every reduction 500mA of charging current I, adjusts the output voltage V of chargeroutLower 200mV and most The low 5V that is adjusted to just is not adjusted still further below, until charging complete;
In the present embodiment, when charging process enters constant voltage charging phase, the charging current I of battery U4 will gradually drop Low, in order to still maintain higher charge efficiency during constant-voltage charge, the present embodiment is designed in constant voltage charging phase and is charged Electric current I is every to reduce by 500 milliamperes, controls the output voltage V of chargeroutLowering 200 millivolts, (this value can be according to mobile terminal Concrete condition measuring and calculating), when charging complete, by the output voltage V of chargeroutIt is adjusted to the 5V of default.
Entire charging process is completed as a result,.
In order to guarantee the safety of mobile terminal charging, the present embodiment also proposes the following exception handling that charges:
(1) for the mobile terminal designed using integrated chip as load switch U1, as shown in Figure 1, the present embodiment is excellent Choosing uses following safety protecting mechanism:
1. utilizing the current-limiting function of load switch U1, system is defaulted when powering on 500mA current limliting (by configuring resistance R8 Resistance value realize), guarantee abnormal conditions under charging current will not damage mobile terminal;
2. entering the total of mobile terminal during directly filling using the current monitoring pin IMON real-time monitoring of load switch U1 Input current Iin(i.e. the output electric current of charger), if total input current IinSecure threshold is flowed more than preset straight charging Isafe(resistance value in parallel by configuring resistance R6 and resistance R8 is realized, I is preferably provided withsafe=5A), then reduce the charger Output voltage Vout, so that reducing it exports electric current (i.e. total input current Iin), until Iin<Isafe
3. utilizing the over-voltage protecting function of load switch U1, make to enter total input voltage of mobile terminal not during directly filling More than given threshold.That is, the output voltage V of real-time detection chargeroutIf the output voltage V of the chargeroutMore than default Straight charging voltage secure threshold Vsafe, then that cuts off battery U4 directly fills access, and battery U4 is avoided to receive overvoltage impact.In this implementation In example, for 4.4V battery, it is preferably provided with Vsafe=6V;
4. using metering chip built-in in battery U4, the battery core voltage V of real-time detection battery U4bat_realAnd charging current I, if one of them be more than battery specifications book in defined max-thresholds (i.e. in battery specifications book defined maximum charge electricity Pressure value and pairs of maximum charging current values), then reduce the output voltage V of the chargerout, and cut off the straight of battery U4 and fill access;
5. the terminal voltage of battery U4 is monitored, once being more than max-thresholds (can be according to defined in battery specifications book most Large terminal voltage determines that it is 4.6V that the present embodiment, which is preferably provided with the max-thresholds for 4.4V battery U4), then it is filled described in reduction The output voltage V of electric applianceout, and cut off the straight of battery U4 and fill access;
6. hardware protection mechanism: when the logical AND gate U6 in Fig. 1 occur it is abnormal cause not can control load switch U1 it is normal When disconnection, the GPIO3 mouth for setting processor U3 is low level, and control load switch U1 is disconnected, and cutting battery U4's directly fills access, is kept away Exempt to damage battery.
(2) for the load switch U1 using MOS to pipe Q2 cooperation booster circuit U7 design, as shown in Fig. 2, this implementation Example preferably uses following safety protecting mechanism:
1. entering total input current I of mobile terminal by current monitoring chip U9 detectionin(that is, the output electricity of charger Stream), and the total input current I that will testinIt is sent to charging chip U2 and controller U8 simultaneously, processor U3 passes through charging core Piece U2 obtains the total input current I for directly filling and entering mobile terminal in the processin, when processor U3 or controller U8 detect IinIt is super Cross preset threshold (such as straight charging stream secure threshold Isafe, it is preferably provided with Isafe=5A) when, low level is exported to logical AND gate U6 Signal, cutting directly fill access, play the role of duplicate protection;
2. using metering chip built-in in battery U4, the battery core voltage V of real-time detection battery U4bat_realAnd charging current I, if one of them be more than battery specifications book in defined max-thresholds (i.e. in battery specifications book defined maximum charge electricity Pressure value and pairs of maximum charging current values), then reduce the output voltage V of the chargerout, and cut off the straight of battery U4 and fill access;
3. the terminal voltage of battery U4 is monitored, once being more than max-thresholds (can be according to defined in battery specifications book most Large terminal voltage determines that it is 4.6V that the present embodiment, which is preferably provided with the max-thresholds for 4.4V battery U4), then it is filled described in reduction The output voltage V of electric applianceout, and cut off the straight of battery U4 and fill access;
4. controller U8 detects the terminal voltage of battery U4 by its ADC interface AD2 simultaneously, once it is more than max-thresholds, Then by its UART interface notifier processes device U3, to reduce the output voltage V of the chargerout, even shut off the straight of battery U4 Fill access;
5. controller U8 and processor U3 use timing handshake mechanism during directly filling, once one side of discovery is not fixed Shi Jinhang signal is shaken hands, then that cuts off battery U4 directly fills access;
6. controller U8 enters total input electricity of mobile terminal by its ADC interface AD3 real-time detection during directly filling Press Vin, i.e. the output voltage V of chargeroutOnce VinMore than given threshold, such as more than preset straight charging voltage secure threshold Vsafe(V is preferably provided with for 4.4V batterysafe=6V), then notifier processes device U3 reduces the output voltage V of chargerout, or even cut Power-off pond U4's directly fills access.
By using processor U3 and controller U8 dual protection mechanism, the peace of mobile terminal charging may further ensure that Quan Xing.
The above-mentioned design scheme proposed using the present embodiment, if charger is unplugged or powers off during directly filling, Since the input pin VIN and output pin VOUT of load switch U1 are in channel status (for what is designed using MOS pipe Q2 Access directly is filled, then since source electrode and drain electrode of the MOS to pipe Q1 is connected to), then battery U4 voltage can be by directly filling path effect in USB The power pins VBUS of interface J1 causes the voltage of the power pins VBUS of USB interface J1 to maintain high potential, so that system is examined It does not measure charger to have extracted, the charger icon in user interface can also retain.
In order to guarantee that system can accurately detect the extraction state of charger during directly filling, directly filled with control logical Road is accurately cut off, and the present embodiment also proposed plug detection method of following charger during directly filling.
Detect total current (the i.e. total input current I inputted by charging interface J1in) and disengaging battery U4 electric current Ibat, according to IinAnd IbatVariation judge charger whether directly fill during be pulled out.
In conjunction with Fig. 5, detailed process includes:
The total current that S501, detection are inputted by charging interface J1, i.e., total input current Iin
In the present embodiment, for the load switch U1 using integrated chip design, as shown in Figure 1, detection can be passed through The monitoring current of the current monitoring pin IMON output of load switch U1 calculates total input current Iin.For using MOS to pipe Q2 cooperates the load switch of booster circuit U7 design, as shown in Fig. 2, can detect total input current by current monitoring chip U9 Iin, and according to total input current IinSize export corresponding voltage, after divider resistance R24, R25 partial pressure, by controlling Device U8 acquisition processed, to calculate total input current IinSize, and notify the processor U3.
If S502, IinLess than preset value, then subsequent step is executed;Otherwise it is assumed that charger is not extracted, keep current straight Fill process;
In the present embodiment, being preferably provided with the preset value is 100mA.
S503, the electric current I for detecting battery U4batThe flow direction of (i.e. charging current I), if being flowed out from battery U4, then it represents that battery U4 electric discharge, preliminary judgement charger may be pulled out, and execute subsequent step;Otherwise it is assumed that charger is not extracted, keep current Directly fill process;
In the present embodiment, it can use the electric current I of the metering chip detection battery U4 built in battery U4batIf electric current IbatFor positive value, then it represents that battery U4 electric discharge executes subsequent step and makees further judgement to the plug state of charger;If electric current IbatFor negative value, then it represents that battery U4 charging, it is believed that charger is not extracted, is kept current and is directly filled process.
S504, the straight of cutting battery U4 fill access;
Specifically, defeated by its GPIO1 mouthfuls when processor U3 determines that charger may be pulled out during directly filling The output level of low level out, control logic and door U6 become low level from high level, then control load switch U1(such as Fig. 1) Or booster circuit U7(such as Fig. 2) non-enabled, it is achieved in the cutting for directly filling access.It is cut off due to directly filling access, electricity Cell voltage will not the current potential on the power pins VBUS to charging interface J1 have an impact.
S505, the plug state of conventional charger plug state testing mechanism detection charger is utilized;
It is had been turned off due to directly filling access, if charger is extracted, the voltage on the power pins VBUS of charging interface J1 will It is reduced to zero, the current potential on power pins VBUS can be detected by processor U3 and then determine that charger has been extracted if zero, tied Beam charging process, and controlled by processor U3 and eliminate charger icon in user interface;If not zero, then determine charger not It extracts.
The plug detection method of charging method and charger proposed by the invention during directly filling can be widely applied In the various mobile terminal products such as mobile phone, tablet computer, laptop, mobile power source, to meet the different charging of user Demand.
Finally, it should be noted that the above embodiments are merely illustrative of the technical solutions of the present invention, rather than its limitations;Although Present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that: it still may be used To modify the technical solutions described in the foregoing embodiments or equivalent replacement of some of the technical features; And these are modified or replaceed, technical solution of various embodiments of the present invention that it does not separate the essence of the corresponding technical solution spirit and Range.

Claims (9)

1. a kind of mobile terminal, is provided with
Battery, for storing electric energy;
Metering chip, for detecting the battery core voltage and charging current of the battery;
Charging interface is provided with power pins, is used for external charger;
Load switch is connected between the power pins and the battery, fills access for being connected to or cutting off the straight of battery;
Current monitoring unit is used to detect total input current by the power pins;
Processor is provided with communication interface, connects the metering chip;The processor is on detecting the charging interface When thering is the adjustable charger of output voltage to be inserted into, is communicated with the metering chip, obtain the battery core voltage of the battery;When described The battery core voltage of battery is in preset when directly filling within the scope of threshold value, controls the load switch and is connected to the straight of the battery Access is filled, and searches its preset initial relation table of comparisons, which is obtained according to segment locating for the battery core voltage of battery Output voltage target value and charging current target value corresponding to section, and the charging is adjusted according to the output voltage target value The output voltage of device is to the output voltage target value;The processor battery battery core voltage from the area of the low level-one of voltage Between section enter the higher leveled segment of voltage, and close to when the critical point of two segments, if dynamic reduces the charger Output voltage cause the battery core voltage of battery to drop to the area of the low level-one of the voltage from the higher leveled segment of the voltage Between section, then detect the charging current of the battery, if charging current is not zero, continuing dynamic reduces the output of the charger Voltage, until the charging current of the battery reaches or close to charging current target corresponding to the higher leveled segment Value;During directly filling, the battery is flowed through in the charging current judgement that the processor is detected according to the metering chip Current direction, and total input current that the current monitoring unit detects is compared with a preset value;If described total defeated The current direction for entering electric current lower than the preset value and the battery is flowed outwardly by battery, then controls the load switch It disconnects.
2. mobile terminal according to claim 1, which is characterized in that the load switch is an integrated chip, the electricity Flow monitoring unit is built in the load switch, and the load switch generates equal proportion according to total input current of access The monitoring current of diminution exports, and is converted into voltage via ground resistance and is supplied to the processor, described total to calculate The value of input current.
3. mobile terminal according to claim 1, which is characterized in that the load switch is a MOS to pipe, the MOS The switch ways of pipe are connected between the power pins of the charging interface and the battery, MOS connects the control terminal of pipe One booster circuit controls the MOS to pipe on-off using the driving voltage of booster circuit output;In the power supply of the charging interface Pin and the MOS are a current monitoring to a sampling resistor, the current monitoring unit is in series between the switch ways of pipe Chip, the pressure drop by detecting the sampling resistor both ends calculate total input current, then generate with it is described always defeated Enter the corresponding voltage output of electric current to a bleeder circuit;
It is additionally provided with controller in the mobile terminal, connects the divider node of the bleeder circuit, is saved according to the partial pressure The partial pressure value of point calculates total input current, and is sent to the processor.
4. mobile terminal according to any one of claim 1 to 3, which is characterized in that be additionally provided with:
Charging chip is connected between the charging interface and battery, for receiving the charge power supply of charger output, and is institute State battery charging;
The processor is during directly filling, if detecting total input current lower than the preset value and the electricity of the battery Stream flow direction is to be flowed outwardly by battery, and after controlling the load switch and disconnecting, the VBUS for detecting the charging interface draws Current potential on foot notifies the charging chip to detect the current potential on the VBUS pin, if low level, then sentences Determine charger extraction;Otherwise, it is determined that charger is not extracted.
5. mobile terminal according to claim 4, which is characterized in that be additionally provided on the charging interface D+ pin and D- pin;
It is additionally provided with the first driving pin being connected with the D+ pin on the charging chip, is connected with the D- pin Second driving pin, when the battery core voltage of the battery is in other than the preset range for directly filling threshold value, the charging chip The output voltage of the charger is adjusted by the first driving pin and the second driving pin;
Be additionally provided on the processor the third being connected with the D+ pin driving pin, be connected with the D- pin the Four driving pins;The processor is when the battery core voltage of battery is in other than the preset range for directly filling threshold value, described in control Load switch disconnects, and starts the charging chip as battery charging;It is in preset in the battery core voltage of battery and directly fills threshold value Within the scope of when, close the charging chip, and control the load switch and be connected to the battery and the VBUS pin, and Drive pin and the 4th driving pin that the output voltage of the charger is adjusted by the third.
6. mobile terminal according to claim 5, which is characterized in that be provided on the processor a control port and One GPIO mouthfuls;
The processor passes through the control when the battery core voltage of the battery is in other than the preset range for directly filling threshold value The starting of charging chip described in port controlling, and the enable signal invalid by described GPIO mouthfuls output, control the load switch It disconnects;
The processor the battery core voltage of the battery be in it is preset directly fill threshold value within the scope of when, pass through the control Charging chip described in port controlling is closed, and by the described GPIO mouthfuls effective enable signal of output, controls the load switch Conducting.
7. mobile terminal according to claim 5, which is characterized in that the processor is at the battery core voltage of the battery In it is preset directly fill within the scope of threshold value when, according to the output voltage target value determine by the third drive pin with The pulse signal of the 4th driving pin output, adjusts the output voltage of the charger to the output voltage target Value, and the charging current of the battery is detected, the output voltage of charger described in dynamic regulation makes the charging current of the battery Reach or close to the charging current target value.
8. mobile terminal according to claim 7, which is characterized in that the processor is led in the control load switch It is logical, when directly being filled to battery, if detect the battery core voltage of battery it is described directly fill threshold value within the scope of and from the low level-one of voltage Segment enter the higher leveled segment of voltage, then the higher leveled area is found out by the initial relation table of comparisons Between charging current target value corresponding to section, and dynamic reduces the output voltage of the charger, until the charging of the battery Electric current reaches or close to charging current target value corresponding to the higher leveled segment.
9. mobile terminal according to claim 5, which is characterized in that
The charging chip the battery core voltage for detecting battery lower than it is preset directly fill the range of threshold value when, adjust charger Output voltage is powered to 5V for charging chip, carries out trickle charge to the battery by charging chip;
The charging chip is higher than the preset range for directly filling threshold value in the battery core voltage for detecting battery and is propped up lower than battery When the maximum battery core voltage held, the output voltage of dynamic regulation charger finds out the output electric current of charging chip to meet its pre- The minimum output voltage of charger in the case where phase output electric current, is charging chip power supply using the minimum output voltage, directly Battery core voltage to battery reaches the maximum battery core voltage;
The charging chip adjusts its output voltage when the battery core voltage for detecting battery reaches the maximum battery core voltage To the maximum battery core voltage, constant-voltage charge is carried out to the battery, and detects the charging current of the battery, and the electricity that charges Flow every reduction 500mA, control charger output voltage lower 200mV and it is minimum adjust to 5V, until charging complete.
CN201610468005.6A 2016-06-24 2016-06-24 A kind of mobile terminal Active CN106026258B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610468005.6A CN106026258B (en) 2016-06-24 2016-06-24 A kind of mobile terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610468005.6A CN106026258B (en) 2016-06-24 2016-06-24 A kind of mobile terminal

Publications (2)

Publication Number Publication Date
CN106026258A CN106026258A (en) 2016-10-12
CN106026258B true CN106026258B (en) 2018-12-28

Family

ID=57086989

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610468005.6A Active CN106026258B (en) 2016-06-24 2016-06-24 A kind of mobile terminal

Country Status (1)

Country Link
CN (1) CN106026258B (en)

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107942260A (en) * 2017-12-11 2018-04-20 上海木爷机器人技术有限公司 A kind of control method and system of battery charging and discharging test
CN109066874A (en) * 2018-08-30 2018-12-21 北京小米移动软件有限公司 Fast charge method and device, electronic equipment, computer readable storage medium
CN111327087B (en) * 2018-12-14 2023-03-21 青岛海信移动通信技术股份有限公司 Electronic equipment and charging method thereof
CN110277814B (en) * 2019-06-18 2023-06-13 Oppo广东移动通信有限公司 Equipment to be charged and charging method
CN110676898B (en) * 2019-09-16 2023-06-02 Oppo广东移动通信有限公司 Equipment to be charged
CN110797950A (en) * 2020-01-06 2020-02-14 深圳微步信息股份有限公司 Automatic switching method based on Type-C and AC charging and mobile terminal thereof
CN114336814A (en) * 2020-09-30 2022-04-12 深圳英集芯科技股份有限公司 Multi-port charging control circuit, charging chip and power supply equipment
CN112865225A (en) * 2021-01-07 2021-05-28 惠州拓邦电气技术有限公司 Battery output power control method and device and battery power supply system
CN113489079B (en) * 2021-05-25 2022-07-22 荣耀终端有限公司 Terminal device and charging system

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5477128A (en) * 1993-07-30 1995-12-19 Technical Associates Co., Ltd. Automatic charging apparatus
CN104578243A (en) * 2013-10-24 2015-04-29 罗伯特·博世有限公司 A method for monitoring the DC voltage charge and a battery management system
CN104993182A (en) * 2015-08-05 2015-10-21 青岛海信移动通信技术股份有限公司 Mobile terminal, direct charging power adapter and charging method

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5477128A (en) * 1993-07-30 1995-12-19 Technical Associates Co., Ltd. Automatic charging apparatus
CN104578243A (en) * 2013-10-24 2015-04-29 罗伯特·博世有限公司 A method for monitoring the DC voltage charge and a battery management system
CN104993182A (en) * 2015-08-05 2015-10-21 青岛海信移动通信技术股份有限公司 Mobile terminal, direct charging power adapter and charging method

Also Published As

Publication number Publication date
CN106026258A (en) 2016-10-12

Similar Documents

Publication Publication Date Title
CN106026257B (en) A kind of mobile terminal
CN106026258B (en) A kind of mobile terminal
CN105978093B (en) A kind of mobile terminal
CN1316710C (en) Accumulator, super capacitor charge-discharge equalizing method and equipment
CN104348215B (en) Charger, battery module, and systems and methods for identifying and monitoring a battery charger
EP3327892B1 (en) Charging and discharging control circuit and battery pack
CN203398772U (en) Multi-section lithium battery protection system
CN201789318U (en) Mobile phone power supply device with leather case battery for power supply
CN103475054A (en) Intelligently-controlled lithium battery charger and charging control method
CN105553030A (en) Uninterruptable power supply management system of lithium battery
CN108988412A (en) A kind of accumulator charging and discharging control method
CN102222942A (en) Power supply circuit and charging method for electronic equipment
CN206650467U (en) A kind of management of charging and discharging circuit of lithium battery
CN103683266B (en) Rechargeable battery protection circuit
CN202153645U (en) Electric device based on OTG interface charging
CN203151186U (en) Intelligent charging and discharging system for lithium battery and computer
CN102709979B (en) Integrated autonomous control system for power battery
CN201222661Y (en) Lithium battery protection device with zero discharging function during storage period
CN204144993U (en) A kind of electric automobile lithium battery charge balancing control circuit
CN203933057U (en) A kind of portable multi-function portable power source
CN207664703U (en) A kind of standby power alarm power supply circuit
Linlin et al. Research on dynamic equalization for lithium battery management system
CN106571496B (en) Scalable modularization power battery system
CN206041534U (en) Balanced battery charge and discharge of battery
CN209016730U (en) A kind of means for anti-jamming of electromyographic signal collection instrument

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant