LED constant-current driver and LED constant current driving method
Technical field
The present invention relates to circuit protection, particularly relate to a kind of LED constant-current driver and a kind of LED constant current is driven
Dynamic method.
Background technology
Need when LED normally works to provide a constant DC current to it, so needing a LED perseverance
Line voltage is converted into unidirectional current and is supplied to LED by stream driver.As it is shown in figure 1, LED constant-current driver
Structurally generally comprise by semiconductor diode D, inductance L, electric capacity C, resistance R and master power switch S.
In order to realize the accurate control to the electric current being supplied to LED load, general LED constant-current driver all needs
A sampling resistor is wanted to be connected in main loop of power circuit, by the voltage signal at sampling resistor two ends is adopted
Sample can obtain the information of output electric current, the most again by the way of changing the ON time of master power switch S
Realize the accurate control to output electric current.As in figure 2 it is shown, sampling resistor Rsen is connected to main loop of power circuit
In, LED constant current driving chip IC obtains the electric current of sampling resistor Rsen, and master power switch S1 is by LED
Constant-current driven chip IC controls according to certain dutycycle turn-on and turn-off, thus controls output voltage.
It addition, to the harmonic pollution of electrical network and reduce driving in order to reduce the input current of LED constant-current driver
The volume of device, general LED constant-current driver also needs to use APFC control technology, the most logical
Crossing control master power switch S1 allows the waveform of input current follow input voltage waveform.
The potential danger that traditional LED constant-current driver exists is, after once sampling resistor is short-circuited,
Owing to the voltage signal at sampling resistor two ends is much smaller than output current reference, cause the ON time of power switch
Become big the most therewith, thus cause the peak value of inductive current also to become larger.At the inductive current being gradually increased
Under effect, output voltage can increase, and in circuit, the current stress of device is consequently increased.If defeated
Before going out the over-voltage protection point that voltage is not reaching to output voltage, inductive current has exceeded some device energy in circuit
During the maximum current born, device can damaged or blast.The output capacitance that particularly circuit uses is bigger
Time.
Summary of the invention
Based on this, it is necessary to provide a kind of it can be avoided that sampling resistor short circuit and cause device in circuit damaged
Or the LED constant-current driver of blast.
Additionally, also provide for a kind of LED constant current driving method.
A kind of LED constant-current driver, including: output electric current measure module, it is used for obtaining power switch and resets
Signal;Inductive current zero passage detection module, connects the inductance of external circuit, obtains inductive current;RS triggers
Device, set end connects described inductive current zero passage detection module, carries out set when receiving zero cross signal;
Reset terminal connects the outfan of described output electric current measure module, is receiving low level to high level transition
Reset during signal;Power switch driver, the outfan being connected to rest-set flip-flop is opened with outside power
Between pass, drive described external power switch for the output signal according to rest-set flip-flop;Also include: circulation
Timer, is connected with the set end of described rest-set flip-flop and receives the defeated of described inductive current zero passage detection module
Go out, start timing when receiving zero cross signal and arrive reset timer after Preset Time in timing;Short circuit
Protection module, input connects described chronocyclograph, and outfan connects the clear terminal of described rest-set flip-flop,
Judge that sampling resistor is the most short-circuit, if so, provide signal and turn off master power switch, otherwise, holding circuit is just
Often work, described chronocyclograph enters next cycle period;Wherein, described Preset Time is more than or equal to
Line voltage the most macrocyclic 1/2nd.
Wherein in an embodiment, described output electric current measure module includes: current sample module, connects
The sampling resistor of external circuit, obtains sample rate current;Operational amplifier, inverting input connects described electric current
Sampling module also receives sample rate current input, and in-phase input end is connected with reference current source and receives reference current
Input;Resistance-capacitance network outside outfan connection;First comparator, inverting input connects described computing and puts
The outfan of big device, outfan connects the reset terminal of described rest-set flip-flop;Waveform generator, with described first
Comparator in-phase input end connects, and transmits the ripple signal of output.
Wherein in an embodiment, described short circuit protection module includes: voltage sample module, connects outside
The sampling resistor of circuit, obtains sampled voltage;Second comparator, in-phase input end connects described voltage sample
Module also receives sampled voltage input;Inverting input linker reference voltage source also receives reference voltage input,
Described reference voltage is to judge the short-circuit voltage that sampling resistor is the most short-circuit;Short-circuit protection unit, follows with described
The outfan of ring timer and the second comparator connects respectively, judges when described chronocyclograph timing arrives
Whether the sampled voltage of described sampling resistor was consistently less than or equal to described benchmark electricity within a time-count cycle
Pressure, the most then output reset signal makes described rest-set flip-flop reset.
Wherein in an embodiment, the ripple letter of the waveform generator output in described output electric current measure module
Number being fixing, its peak value is equal with external resistor-capacitor network output end voltage value during normal circuit operation, its week
Phase is consistent with inductive current period of change.
Wherein in an embodiment, described waveform generator is triangular-wave generator.
A kind of LED constant current driving method, comprises the steps:
The inductance detecting the external circuit being connected with LED constant-current driver the zero passage obtaining inductive current letter
Number;
Detect the resistance-capacitance network of the external circuit being connected with LED constant-current driver and obtain its output end voltage letter
Number;
Detect the sampling resistor in the external circuit being connected with LED constant-current driver and obtain sample rate current;
Using described zero cross signal as the set signal of the rest-set flip-flop in described LED constant-current driver, incite somebody to action
Described sample rate current carries out processing the reset signal as described rest-set flip-flop;
Described rest-set flip-flop is according to described set signal and reset signal output drive signal;
Also include:
Utilize described zero cross signal to trigger chronocyclograph, carry out the timing of Preset Time;
In described Preset Time, persistently judge that described sampling resistor is the most short-circuit, at described chronocyclograph
If sampling resistor is the most short-circuit when timing arrives, then output reset signal makes described rest-set flip-flop reset.
Wherein in an embodiment, the described step judging sampling resistor whether short circuit specifically includes:
Being compared with reference voltage by the sampled voltage of sampling resistor, both result of the comparisons compare by second
Relatively device exports to short-circuit protection unit;
When chronocyclograph timing arrives, described short-circuit protection unit judges sampling resistor voltage is at a meter
Time the cycle in whether be consistently less than or equal to reference voltage, the most then sampling resistor short circuit.
Wherein in an embodiment, described carry out processing the reset as described rest-set flip-flop using sample rate current
The step of signal specifically includes:
Being compared with reference current by sample rate current, the error signal that both produce is defeated by operational amplifier
Go out the outfan of the resistance-capacitance network to external circuit and be converted into voltage signal;
Being compared by the ripple signal of described voltage signal with waveform generator, both result of the comparisons are by the
One comparator exports the reset terminal to rest-set flip-flop: enter when receiving low level to high level signals that transition
Horizontal reset.
Above-mentioned LED constant-current driver and LED constant current driving method, can automatically identify band active power factor
The single-stage LED constant-current driver of calibration function normally works and the situation of sampling resistor short circuit, avoids well
The inductive current of the superelevation occurred in circuit after sampling resistor short circuit causes blast or the damage of device.
Accompanying drawing explanation
Fig. 1 is the topology diagram of LED constant-current driver;
Fig. 2 is the main loop of power circuit circuit diagram of LED constant-current driver;
Fig. 3 is the LED constant-current driver function structure chart of an embodiment;
Fig. 4 is the schematic diagram of the LED constant-current driver of an embodiment;
Fig. 5 be embodiment illustrated in fig. 4 LED constant-current driver in relevant conducting waveform corresponding to inductive current
Figure;
Fig. 6 is the waveform correlation figure that the constant current driver circuit for LED of embodiment illustrated in fig. 4 normally works;
Fig. 7 is the waveform correlation figure of sampling resistor short circuit in tradition LED constant-current driver;
Fig. 8 is the waveform correlation figure of sampling resistor short circuit in the present invention;
Fig. 9 is the LED constant current driving method flow chart of an embodiment.
Detailed description of the invention
As it is shown on figure 3, be the LED constant-current driver function structure chart of an embodiment.This LED constant current drives
Device includes output electric current measure module 110, inductive current zero passage detection module 120, rest-set flip-flop 130, merit
Rate switch driver 140, chronocyclograph 150 and short circuit protection module 160.Wherein output electric current measure mould
Block 110 is connected with the reset terminal of rest-set flip-flop 130, for obtaining the sample rate current of external sampling resistance, and
Reset signal is exported according to described sample rate current.Outside the input of inductive current zero passage detection module 120 connects
The inductance of portion's circuit, obtains inductive current, and the set end of its output termination rest-set flip-flop 130, when inductance electricity
After stream is completely discharged, inductive current zero passage detection module 120 sends set signal to rest-set flip-flop 130.
Power switch driver 140 be connected to the outfan of rest-set flip-flop 130 and external circuit power switch it
Between, drive described power switch, i.e. rest-set flip-flop 130 for the output signal according to rest-set flip-flop 130
Drive power switch conducting during set, drive when rest-set flip-flop 130 resets power switch to be turned off.Circulation
Timer 150 is connected with the set end of described rest-set flip-flop 130 and receives described inductive current zero passage detection mould
The output of block 120, starts timing the meter that resets after timing arrives Preset Time when receiving zero cross signal
Time device.Short circuit protection module 160 is used for judging that sampling resistor is the most short-circuit.Concrete, when sampling resistor two
When terminal voltage is more than sampling resistor short reference voltage, holding circuit normally works;When sampling resistor two ends electricity
When pressure is less than sampling resistor short reference voltage, illustrate that sampling resistor is short-circuit, provide signal and turn off main power and open
Close.
As shown in Figure 4, it is the schematic diagram of LED constant-current driver of an embodiment.Output electric current measure module
110 include: current sample module 111, operational amplifier U1, the first comparator U2 and triangular wave occur
Device 114.Current sample module 111 connects the sampling resistor (D, E pin by figure) of external circuit,
Obtain sample rate current and be input to the inverting input (-) of operational amplifier U1.Operational amplifier U1's is anti-
Phase input (-) connects current sample module 111 and receives sample rate current input, in-phase input end (+) with
Reference current source connects and receives reference current input;The capacitance-resistance outside outfan connection of operational amplifier U1
Network (the C pin by figure).First comparator U2 inverting input (-) concatenation operation amplifier
The outfan of U1, in-phase input end (+) be connected with triangular-wave generator 114 and receive triangular wave input.
The outfan of the first comparator U2 connects the reset terminal of rest-set flip-flop 130.
The input of inductive current zero passage detection module 120 connects the inductance of external circuit (by the B in figure
Pin), obtain inductive current, the set end of its output termination rest-set flip-flop 130, when inductive current is complete
After full electric discharge, inductive current zero passage detection module 120 sends set signal to rest-set flip-flop 130.Power is opened
Close between outfan and the power switch of outside that driver U4 is connected to rest-set flip-flop 130, for basis
The output signal of rest-set flip-flop 130 drives described power switch, i.e. drives merit during rest-set flip-flop 130 set
Rate switch conduction, drives power switch to be turned off when rest-set flip-flop 130 resets.Chronocyclograph 150 with
The set end of described rest-set flip-flop 130 connects and receives the defeated of described inductive current zero passage detection module 120
Go out, start timing when receiving zero cross signal and arrive reset timer after Preset Time in timing.
Short circuit protection module 160 includes: voltage sample module the 161, second comparator U3, short-circuit protection list
Unit 163.Voltage sample module 161 connects the sampling resistor (D, E pin by figure) of external circuit,
Obtain sampled voltage;Second comparator U3 in-phase input end (+) connect described voltage sample module 161 also
Reception sampled voltage inputs;Inverting input (-) linker reference voltage source also receives reference voltage input, institute
Stating reference voltage is to judge the short-circuit voltage that sampling resistor is the most short-circuit.Short-circuit protection unit 163 one of them
Input is connected with described chronocyclograph 150, and the outfan of another input and the second comparator U3 is even
Connect, judge that when described chronocyclograph 150 timing arrives the sampled voltage of described non-essential resistance is at a meter
Time the cycle in whether be consistently less than or equal to described short-circuit voltage, the most then output reset signal makes described RS
Trigger 130 resets.
The operation principle of circuit is described with the circuit diagram shown in Fig. 4 below.
Current sample module 111 is connected with external circuit port pinout E and D, obtains external circuit sampling electricity
The voltage signal at resistance two ends, then exports current sample result through current sample module 111, this result conduct
The homophase input of operational amplifier U1.Electric current on the basis of the anti-phase input of operational amplifier U1, both produce
Error signal by operational amplifier U1 output to C end connect external resistor-capacitor network, be then converted into
Voltage signal, by controlling the time constant of the resistance-capacitance network that C end connects so that C terminal voltage signal becomes
Change the least.C terminal voltage signal is as the anti-phase input of the first comparator U2, with the triangular wave of fixed slope
Signal inputs as the positive of the first comparator U2, and both are more afterwards by the first comparator U2 output to RS
The reset terminal of trigger can obtain fixing ON time Ton.When the ON time in each switch periods reaches
After Ton, the master power switch change that A end connects is turned off.Inductive current zero passage detection module 120 is passed through
Outside port pin B obtains external circuit inductive current, and its outfan is connected with the set end of rest-set flip-flop,
After the inductive current in external circuit is completely discharged, sends signal by rest-set flip-flop set, then connect
Power switch driver U4 between the outfan and the power switch pin A of outside of rest-set flip-flop drives
Master power switch makes it again turn on.In the LED constant-current driver of embodiment illustrated in fig. 4, inductive current is corresponding
Relevant conducting oscillogram as shown in Figure 5.
Fig. 6 show the waveform correlation figure that the LED constant-current driver of embodiment illustrated in fig. 4 normally works, because of
Time cycle for the master power switch conducting of the external main loop of power circuit of LED constant-current driver is fixing,
So the electric current of inductive current, sampling resistor two ends can realize following the line voltage sinusoidal variations of input.
Traditional LED constant-current driver does not has short block, after once sampling resistor is short-circuited, will go out
Situation the most as shown in Figure 7, sampling resistor both end voltage signal can be much smaller than reference current, at feedback circuit
Effect under, C pin voltage will gradually rise, then rest-set flip-flop can make because can not get reset signal
Master power switch ON time is elongated, thus causes the peak value of inductive current followed by and become larger, eventually
Because inductive current exceedes electric current that in circuit, some device can bear and cause device failure or blast.So this
Invention adds short circuit protection module and chronocyclograph on the basis of previous circuit, specific as follows:
The voltage sample module being connected with external circuit port pinout E and D is by sampling resistor voltage sample result
Positive as the second comparator U3 inputs, and short-circuit voltage connects second as sampling resistor short reference and compares
The inverting input of device U3, both through the second comparator U3 relatively after export to short-circuit protection unit.
After inductive current zero crossing is detected, after i.e. the inductive current in external circuit is completely discharged,
Circulation timing module starts to start timing, and after timing time reaches, timing module automatically resets timer.Often
After secondary timing terminates, whether the voltage at short-circuit protection unit judges sampling resistor two ends is more than before timing terminates
Over-sampling resistive short reference voltage: if the voltage at sampling resistor two ends was more than this reference voltage, then say
Bright circuit is working properly;Otherwise explanation sampling resistor is the most short-circuit, forces immediately to reset rest-set flip-flop so that
The master power switch that A end connects stops conducting.Owing to during normal work, the voltage at sampling resistor two ends is likely to
Sampling resistor short reference can be less than, so the time-count cycle of chronocyclograph is the longest more than or equal to line voltage
/ 2nd of cycle.The present invention concrete sampling resistor short circuit waveform correlation figure as shown in Figure 8, once
Sampling resistor is short-circuited, and will start short-circuit protection unit at the end of chronocyclograph current period timing,
Thus force rest-set flip-flop to reset and stop the conducting of master power switch in time.
As it is shown in figure 9, be the LED constant current driving method flow chart of an embodiment, the method specifically include as
Lower step.
Step S101: respectively detection be connected with LED constant-current driver the inductance of external circuit, resistance-capacitance network,
Sampling resistor.
In the present embodiment, detection is connected with LED constant-current driver the inductance of external circuit primarily to
Obtain the zero cross signal of inductive current, the resistance-capacitance network of the external circuit that detection is connected with LED constant-current driver
Primarily to obtain its output end voltage signal, in the external circuit that detection is connected with LED constant-current driver
Sampling resistor primarily to obtain sample rate current.
The trigger set of step S102:RS or reset also trigger chronocyclograph in set simultaneously.
In the present embodiment, the zero cross signal obtained is triggered as the RS in described LED constant-current driver
The set signal of device, carries out processing the reset signal as rest-set flip-flop using the sample rate current of acquisition.So
Rest-set flip-flop will be according to described set signal and reset signal output drive signal.And utilize described zero passage to believe
Number trigger chronocyclograph, carry out the timing of Preset Time.
Step S103: chronocyclograph timing judges that described sampling resistor is the most short-circuit when arriving.
In the present embodiment, in Preset Time, can persistently judge that described sampling resistor is the most short-circuit.If
When chronocyclograph timing arrives, sampling resistor does not has short circuit, then return to step S101.Otherwise perform step
S104。
Step S104: output reset signal makes described rest-set flip-flop reset.
Wherein, the step judging sampling resistor whether short circuit of step S103 specifically includes:
Being compared with reference voltage by the sampled voltage of sampling resistor, both result of the comparisons compare by second
Relatively device exports to short-circuit protection unit.When chronocyclograph timing arrives, described short-circuit protection unit judges
Whether sampling resistor voltage is consistently less than in a cycle period or equal to reference voltage, the most then samples
Resistive short.
It addition, step S101 sample rate current is carried out process the reset signal as described rest-set flip-flop
Step specifically includes:
Being compared with reference current by sample rate current, the error signal that both produce is defeated by operational amplifier
Go out the outfan of the resistance-capacitance network to external circuit and be converted into voltage signal.Then by described voltage signal with
The ripple signal of waveform generator compares, and both result of the comparisons are triggered to RS by the first comparator output
The reset terminal of device: reset when receiving low level to high level signals that transition, do not reset.
Embodiment described above only have expressed the several embodiments of the present invention, and it describes more concrete and detailed,
But therefore can not be interpreted as the restriction to the scope of the claims of the present invention.It should be pointed out that, for this area
Those of ordinary skill for, without departing from the inventive concept of the premise, it is also possible to make some deformation and
Improving, these broadly fall into protection scope of the present invention.Therefore, the protection domain of patent of the present invention should be with appended
Claim is as the criterion.