Invention content
Present invention solves the technical problem that how being reduced when being illuminated when filling to filling in charge type portable lamp
The influence in the service life of battery.
In order to solve the above technical problems, the embodiment of the present invention provides a kind of control method of portable lamp, it is described portable
Formula lamps and lanterns include rechargeable battery and lighting circuit, and the lighting circuit is coupled with the rechargeable battery, and the power for illumination
Road and the rechargeable battery can adapt to external power supply, and the control method includes:Whether detect the portable lamp
External power supply;When the portable lamp external power supply and detect Lighting control instruction when, adjust the work of the lighting circuit
Make electric current, and detect the current state of the rechargeable battery simultaneously, to keep the rechargeable battery to be in charging shape always
State.
Optionally, the current state of the detection rechargeable battery, including:It is detected using test circuit for cell status
The charging current and discharge current of the rechargeable battery, and according to obtained charging current and discharge current is detected, determine institute
State the current state of rechargeable battery.
Optionally, the operating current for adjusting the lighting circuit includes:Reduce the operating current of the lighting circuit.
Optionally, the Lighting control is inputted using any one following mode to instruct:The mode of touch interface;Button side
Formula;The mode of voice;The mode of remote control.
The embodiment of the present invention additionally provides a kind of portable lamp, and the portable lamp includes:Rechargeable battery;Illumination
Circuit;Input circuit is suitable for input Lighting control instruction;Current regulating circuit is suitable for adjusting the work electricity of the lighting circuit
Stream;Test circuit for cell status is adapted to detect for the current state of the rechargeable battery;Control circuit, with the input circuit,
Current regulating circuit and test circuit for cell status coupling, suitable for working as the portable lamp external power supply and detecting illumination control
When system instruction, the operating current that the current regulating circuit adjusts the lighting circuit is controlled, and control the battery shape simultaneously
State detection circuit detects the current state of the rechargeable battery, to keep the rechargeable battery to be in charged state always.
Optionally, the test circuit for cell status is adapted to detect for the charging current and electric discharge electricity of the rechargeable battery
Stream, and testing result is input to the control circuit.
Optionally, the test circuit for cell status includes:It is adapted to detect for the of the charging current of the rechargeable battery
One detection sub-circuit, and it is adapted to detect for the second detection sub-circuit of the discharge current of the rechargeable battery.
Optionally, the first detection sub-circuit and the second detection sub-circuit structure are identical, and include:First resistor,
Second resistance, amplifier, PMOS tube and 3rd resistor, wherein:The negative-phase input of the first resistor and amplifier and described
The source electrode of PMOS tube couples;The second resistance and the normal phase input end of the amplifier couple;The output end of the amplifier
It is coupled with the grid of the PMOS tube;The source electrode of the PMOS tube is coupled with substrate, and drain electrode is grounded through the 3rd resistor;It is described
First resistor is identical as second resistance resistance value.
Optionally, the portable lamp further includes:First voltage conversion circuit and second voltage conversion circuit, wherein:
The first voltage conversion circuit, input terminal are coupled with charge port, and output end is coupled with the rechargeable battery and control circuit,
Voltage suitable for being inputted to the charge port carries out voltage conversion, obtains being suitable for being input to rechargeable battery and the electricity of control circuit
Pressure;The second voltage conversion circuit, input terminal are coupled with the first voltage conversion circuit, output end and the current regulation
Circuit couples, and the work to work suitable for the lighting circuit is converted to suitable for carrying out voltage to the first voltage conversion circuit
Voltage, and maintain preset second voltage value.
Optionally, the current regulating circuit is suitable for being in charged state when the rechargeable battery and receives illumination control
When system instruction, reduce the operating current of the lighting circuit.
Optionally, the portable lamp further includes:Crossing detector circuit couples with the current regulating circuit, is suitable for
The operating current of the lighting circuit is detected, and feeds back to the control circuit.
Optionally, input circuit described in the portable lamp be it is following any one:Touch interface;Voice unit;It presses
Keypad;Teleinstruction receiving unit.
Compared with prior art, the technical solution of the embodiment of the present invention has the advantages that:
Using the above scheme, by the electric current inputted when portable lamp external power supply, a part is used as portable lamp
The operating current of tool, charging current of the another part as rechargeable battery, therefore, in portable lamp external power supply and detection
When being instructed to Lighting control, the operating current of the portable lamp is adjusted so that the rechargeable battery is always in charging shape
State reduces the charge and discharge number of rechargeable battery so as to avoid the switching repeatedly of rechargeable battery charging and discharging state, therefore can
To improve the service life of rechargeable battery.
Specific implementation mode
Existing portable lamp, usually using a certain fixed current value as operating current.Portable lamp is external
Power supply, operating current of the electric current one side that external power supply inputs as portable lamp, is on the one hand used as in portable lamp
Rechargeable battery charging current.In order to ensure that portable lamp is worked with the fixed current value, rechargeable battery is frequent
It needs to switch to discharge condition by current charged state, to provide enough operating currents for portable lamp, so usually
The charge and discharge number that rechargeable battery can be increased, influences the service life of rechargeable battery.
In view of the above-mentioned problems, an embodiment of the present invention provides a kind of control methods of portable lamp, by portable
Lamps and lanterns external power supply and detect Lighting control instruction when, adjust the operating current of the portable lamp so that described to fill
Battery reduces chargeable electricity in charged state so as to avoid the switching repeatedly of rechargeable battery charging and discharging state always
The charge and discharge number in pond, therefore the service life of rechargeable battery can be improved.
It is understandable to enable above-mentioned purpose, feature and the advantageous effect of the present invention to become apparent, below in conjunction with the accompanying drawings to this
The specific embodiment of invention explains in detail.
Referring to Fig.1, an embodiment of the present invention provides a kind of control methods of portable lamp.
First, in order to make those skilled in the art more fully understand the control method, the portable lamp is carried out
It is described as follows:It is provided with rechargeable battery in the portable lamp.By the way that the charging on the portable lamp surface is arranged
Mouth external power supply, on the one hand can provide operating current for portable lamp, on the other hand can be that the rechargeable battery fill
Electricity.
In specific implementation, the control method may include steps of:
Step 11, detect the portable lamp whether external power supply.
In specific implementation, may be used a variety of methods detect the portable lamp whether external power supply, for example, can be with
Whether the electric current for detecting the portable lamp charge port input is more than 0.When the electric current of portable lamp charge port input
When more than 0, portable lamp external power supply is determined, otherwise determine the non-external power supply of portable lamp.
Wherein, the external power supply can be charger baby, alternating current etc., and the charge port on the portable lamp surface can be
USB port etc..
Step 12, when the portable lamp external power supply and detect Lighting control instruction when, adjust the power for illumination
The operating current on road, and the current state of the rechargeable battery is detected simultaneously, to keep the rechargeable battery to be in always
Charged state.
In specific implementation, various ways input may be used in the Lighting control instruction, is not restricted specifically.For example,
Touch interface can be provided on the portable lamp, inputting the Lighting control by the touch interface instructs.It is described
Corresponding keypad can also be set on portable lamp, referred to by Lighting control described in the key-press input on the keypad
It enables.Corresponding radio reception device, such as microphone can also be set on the portable lamp, voice shape is inputted by the radio reception device
The Lighting control of formula instructs.The control terminals such as the portable lamp and mobile phone can also be bound, pass through the side of remote control
Formula inputs the Lighting control instruction.
In specific implementation, when the portable lamp external power supply and detect Lighting control instruction when, can reduce
The operating current of the portable lamp.By the electric current inputted when portable lamp external power supply, a part is as portable
The operating current of formula lamps and lanterns, charging current of the another part as rechargeable battery, therefore in external power input to portable lamp
In the case that the electric current of tool is certain, the charging electricity of rechargeable battery can be increased by reducing the operating current of the portable lamp
Stream avoids the switching of rechargeable battery charging and discharging state, reduction can it is possible thereby to so that rechargeable battery maintains charged state
The charge and discharge number of rechargeable battery, therefore the service life of rechargeable battery can be improved.Certainly, it is reached in the charging current of rechargeable battery
When to pre-set current value, the operating current of the portable lamp can also be increased, as long as so that rechargeable battery maintains fills
Electricity condition.
In specific implementation, the current state that various ways detect the rechargeable battery may be used.The present invention's
In one embodiment, the current state that test circuit for cell status detects the rechargeable battery may be used.
Further, in order to more accurately detect the current state of the rechargeable battery, battery status may be used
Detection circuit detects the charging current and discharge current of the rechargeable battery, and then the charging current that is obtained according to detection and puts
Electric current determines the current state of the rechargeable battery.
For example, when the charging current of the rechargeable battery is more than 0, determine that the rechargeable battery is in charging shape
State.When the discharge current of the rechargeable battery is more than 0, determine that the rechargeable battery is in discharge condition.
In specific implementation, the rechargeable battery can be nickel-cadmium cell, or Ni-MH battery, lithium-ion electric
Pond, lead accumulator or lithium iron battery etc. can be specifically configured according to the actual needs of the portable lamp.
In specific implementation, the portable lamp can be any one lamps and lanterns such as flashlight, desk lamp, not limit specifically
System.It is understood which kind of lamps and lanterns the specific portable lamp is, it is not construed as limiting the invention, and at this
Within the protection domain of invention.
As shown in the above, the control method of the portable lamp in the embodiment of the present invention, by portable lamp
External power supply and when detecting Lighting control instruction, adjusts the operating current of the portable lamp, can described can fill
Battery maintains charged state, so as to improve the service life of rechargeable battery.
In order to enable those skilled in the art are better understood from and realize the present invention, below to the control of above-mentioned portable lamp
Portable lamp corresponding to method processed is described in detail.
With reference to the electrical block diagram of Fig. 2~portable lamp shown in Fig. 4, the circuit structure of the portable lamp
It can specifically include following component part:
Rechargeable battery 21;
Lighting circuit 22;
Input circuit SW1 is suitable for input Lighting control instruction;
Current regulating circuit 23 is suitable for adjusting the operating current of the lighting circuit 22;
Test circuit for cell status 24 is adapted to detect for the current state of the rechargeable battery 21;
Control circuit U3, suitable for when the portable lamp external power supply and detect Lighting control instruction when, control institute
The operating current that current regulating circuit 23 adjusts the lighting circuit is stated, and controls the inspection of the test circuit for cell status 24 simultaneously
The current state for surveying the rechargeable battery, to keep the rechargeable battery to be in charged state always.
In specific implementation, the charge port of portable lamp can be USB interface, or other types of interface.
For using USB interface as the charge port of portable lamp, control circuit U3 can be coupled by resistance R14 and USB interface, be led to
Whether the voltage value for crossing detection resistance R14 and resistance R15 intermediate node USB sense reaches preset the first voltage value, can be with
Determine portable lamp whether external power supply.
In specific implementation, the portable lamp can also include that first voltage conversion circuit U1 and second voltage turn
Change circuit.
Wherein, the input terminal of the first voltage conversion circuit U1 can be coupled with USB interface, output end and triode Q3
And sampling resistor Rcs coupling, the supply voltage for being suitable for input USB interface carry out voltage conversion, obtain suitable for triode Q3 and
The voltage that rechargeable battery 21 works.For example, the supply voltage of USB interface input can be 5V, converted through the first voltage
After the voltage conversion of circuit U 1, the voltage between 3.7V~4.2V can be obtained.Mono- sides of first voltage conversion circuit U1
Face is that rechargeable battery 21 provides charging voltage through resistance Rcs, on the one hand through triode Q3 circuit U 3 and lighting circuit in order to control
22 provide supply voltage VCC.
The input terminal of the second voltage conversion circuit and the output end of the first voltage conversion circuit U1 couple, output
End is coupled with current regulating circuit 23, is suitable under the control of the enable signal EN of control circuit U3 outputs, is converted to first voltage
1 transformed voltage of circuit U carries out further voltage conversion, obtains being suitable for the operating voltage that lighting circuit 22 works, and tie up
It holds in preset second voltage value.For example, when the output voltage of the first voltage conversion circuit U1 is 3.7V, through the second electricity
After voltage conversion circuit U2 conversions, stable 6V voltages can be obtained.
Specifically, the second voltage conversion circuit may include:Voltage conversion sub-circuit U2 and voltage stabilizing sub-circuit.It is described
Voltage stabilizing sub-circuit may include:Inductance L1, diode D3, resistance R3, resistance R4, capacitance C3 and capacitance C4.Wherein, inductance L1 with
Voltage conversion sub-circuit U2 is in parallel, and resistance R3 is in parallel with capacitance C, and resistance R3 is in parallel with capacitance C4 after connecting with resistance R4.Two poles
Pipe D3 is coupled between inductance L1 and resistance R3.The FB of the intermediate node FB and voltage conversion sub-circuit U2 of resistance R3 and resistance R4
Pin connects, suitable for feeding back to voltage conversion sub-circuit U2 to voltage conversion sub-circuit U2 and by voltage stabilizing result.
In specific implementation, current regulating circuit 23 may include:With lighting circuit 22 and second voltage conversion circuit coupling
The NMOS tube Q1 connect, the NMOS tube Q2 with the coupling of second voltage conversion circuit are coupled to the grid and NMOS tube Q2 of NMOS tube Q1
Drain electrode between resistance R6, the capacitance C2 being coupled between the grid and ground wire of NMOS tube Q1, the grid of NMOS tube Q2 and control
Circuit U 3 processed couples, and the source electrode of NMOS tube Q1 is grounded by resistance RS.The drive signal that control circuit U3 is exported through resistance R5
DRV, and by the pulsewidth of drive signal DRV adjustment NMOS tubes Q2, and then change the drain current of NMOS tube Q1.Due to power for illumination
Road 22 is connected with NMOS tube Q1, therefore changes the drain current of NMOS tube Q1, is equivalent to the operating current for changing lighting circuit 22, into
And it can achieve the purpose that adjust 22 operating current of lighting circuit.
In specific implementation, the portable lamp can also include:Current detection circuit 25, is adapted to detect for lighting circuit
22 operating current and the pin CC that testing result is input to control circuit U3.Specifically, the current detection circuit 25 can
To include:Operational amplifier U4, resistance R7, resistance R8 and resistance R9.Wherein, the normal phase input end of operational amplifier U4 is logical
The source electrode for crossing resistance R7 and NMOS tube Q1 couples, and negative-phase input is coupled by resistance R8 and ground wire.Resistance R9 is coupled to described
Between the negative-phase input and output end of operational amplifier U4.It is amplified, is amplified by the voltage difference at the both ends detection resistance RS
Result afterwards is input to control circuit U3, and control circuit U3 is it is possible thereby to know the operating current of lighting circuit 22.
In specific implementation, lighting circuit 22 is by two four feet electric wire connecting junction CON3 and CON4 can coupling, with second
Voltage conversion circuit U2, current detection circuit 25 and control circuit U3 couplings.In one embodiment of this invention, four foot wiring
The 4th pin of device CON3 and the 3rd pin can be in series with thermo-sensitive resistor NTC, the 1st pin and the control electricity of four foot electric wire connecting junction CON4
The NTC_AD pins of road U3 couple, and the operating temperature of lighting circuit 22 can be detected by the quick resistance NTC.
In one embodiment of this invention, lighting circuit 22 is made of four LED light groups in parallel, each LED light group packet
Two concatenated LED light are included, LED light D2~D4, D8~D12 are specifically included.
In specific implementation, input circuit SW1 passes through the two five foot electric wire connecting junction CON1 and CON2 that can be coupled and control
Circuit U 3 couples.Wherein, the input circuit SW1 can be touch interface, and the photograph is inputted by the touch interface unit
Bright control instruction;May be corresponding keypad, user can input different photographs by modes such as touch potential, intensity
Bright control instruction;It can also be corresponding voice unit, such as microphone, the photograph of speech form is inputted by institute's speech units
Bright control instruction.In specific implementation, the input circuit SW1 can also be for teleinstruction receiving unit, by described remote
Journey instruction reception unit binds the control terminals such as the portable lamp and mobile phone, is inputted by way of remote control described
Lighting control instructs.
In one embodiment of this invention, the portable lamp can also include:Indicating circuit 26, being used to indicate can fill
The current state of battery 21.For example, two LED light R (Red LED) and Y can be arranged in the indicating circuit on keypad
(Yellow LED) couples described LED etc. by five foot electric wire connecting junction CON1 and CON2 and control circuit U3.In control circuit U3
After knowing the current state of rechargeable battery 21, it can be indicated by controlling LED light.
In one embodiment of this invention, the test circuit for cell status 24 is adapted to detect for the rechargeable battery 21
Charging current Charge AD and discharge current Discharge AD, and testing result is input to the corresponding of control circuit U3 and is drawn
Foot is determined the current state of the rechargeable battery 21 by control circuit U3 according to testing result.
In specific implementation, with reference to Fig. 2, the test circuit for cell status 24 may include:First detection sub-circuit U5
And the second detection sub-circuit U6.Wherein, the first detection sub-circuit U5 is adapted to detect for the charging electricity of the rechargeable battery 21
Stream, the second detection sub-circuit U6 are adapted to detect for the discharge current of the rechargeable battery 21.
The control circuit U3 determines chargeable electricity in the charging current Charge AD > 0 of the rechargeable battery 21
Pond 21 is in charged state, in the discharge current Discharge AD < 0 of the rechargeable battery 21, determines rechargeable battery
21 are in discharge condition.
In specific implementation, may exist with reference to Fig. 2 and Fig. 5, the first detection sub-circuit U5 and the second detection sub-circuit U6
A variety of circuit structures, are not restricted specifically.In one embodiment of this invention, the first detection sub-circuit U5 and the second detection son electricity
Road U6 structures are identical, and may each comprise:First resistor R1, second resistance R2, amplifier AP, PMOS tube P1 and 3rd resistor
R3, wherein:
The negative-phase input of the first resistor R1 and amplifier AP and the source electrode of the PMOS tube P1 couple.Described second
The normal phase input end of the resistance R2 and amplifier AP couples.The grid of the output end of the amplifier AP and the PMOS tube P1
Coupling.The source electrode of the PMOS tube P1 is coupled with substrate, and drain electrode is grounded through the 3rd resistor R3.The first resistor R1 and
Two resistance R2 resistance values are identical.
In specific implementation, with reference to Fig. 2 and Fig. 5, the charging current of the rechargeable battery 21 is through the sampling resistor Rcs
It is input to the rechargeable battery 21, the discharge current of the rechargeable battery 21 is the illumination through the sampling resistor Rcs
22 power supplies.
Specifically, in the first detection sub-circuit U5, the ends RS- of first resistor R1 and the first end k of sampling resistor Rcs
Coupling, the ends RS+ of second resistance R2 are coupled with the second end m of sampling resistor Rcs.In the second detection sub-circuit 252, first
The ends RS+ of resistance R1 and the second end m of sampling resistor Rcs are coupled, the ends RS- of second resistance R2 and the first of sampling resistor Rcs
Hold k couplings.
The first detection sub-circuit U5 and the second detection sub-circuit U6 can put the voltage difference at the both ends sampling resistor Rcs
Greatly.When rechargeable battery 21 discharges, the PMOS tube P1 conductings of the first detection sub-circuit U5, output discharge current Discharge
AD=(V1*R1)/(Rcs*R3), wherein V1 is the voltage of the first 251 output end out of detection sub-circuit.When to rechargeable battery
When 21 charging, the PMOS tube P1 conductings of the second detection sub-circuit U6, output charging current stream Charge AD=(V2*R1)/
(Rcs*R3), wherein V2 is the voltage of the second 252 output end out of detection sub-circuit.
In specific implementation, the first detection sub-circuit U5 and the second detection son electricity can be selected according to actual conditions
The resistance value of the gain of amplifier and first resistor R1 and 3rd resistor R3 in the U6 of road.For example, the gain of amplifier can be
The resistance value of 25, first resistor R1 are 400 ohm, and the resistance value of 3rd resistor R3 is 10 ohm.The gain of amplifier may be
The resistance value of 100, first resistor R1 are 100 ohm, and the resistance value of 3rd resistor R3 is 10 ohm.The gain of amplifier can also be
The resistance value of 200, first resistor R1 are 100 ohm, and the resistance value of 3rd resistor R3 is 20 ohm.
In specific implementation, the pin MCLR and PGC of control circuit U3 accordingly controls program for burning, pin DGND and
PGD is grounding pin.
In specific implementation, with reference to Fig. 2, after portable lamp external power supply, first voltage conversion circuit U1 is to external electricity
After the voltage of source input carries out voltage conversion, supply voltage is provided for other circuits of portable lamp.When user passes through input
When circuit SW1 input Lighting control instructions, control circuit U3 is after detecting Lighting control instruction, to second voltage conversion circuit
U2 sends enable signal EN, and sends drive signal DRV to current regulating circuit 23.On the one hand control circuit U3 passes through battery
State detection circuit 24 monitors the current state of rechargeable battery 21 in real time, on the one hand passes through current regulating circuit 23 and adjusts illumination
The operating current of circuit 22 so that the rechargeable battery 21 maintains charged state, so as to improve rechargeable battery
Service life.
One of ordinary skill in the art will appreciate that all or part of step in the various methods of above-described embodiment is can
It is completed with instructing relevant hardware by program, which can be stored in a computer readable storage medium, storage
Medium may include:ROM, RAM, disk or CD etc..
Although present disclosure is as above, present invention is not limited to this.Any those skilled in the art are not departing from this
It in the spirit and scope of invention, can make various changes or modifications, therefore protection scope of the present invention should be with claim institute
Subject to the range of restriction.