ST AN1320 Application note

AN1320
APPLICATION NOTE
L6574 & MICROCONTROLLER
IN BALLAST APPLICATIONS
by Francesca Sandrini and Luca Rodeschini
There is an increasing demand for flexibility in ballast applications. This means a request for having ballast that can be used for different tubes without changing the soldered components. The aim is to save money by using less parts (resistors, capacitors and so on) and less ballast models to be stored and managed.
A way that is going to be investigated is the use of micr ocontroller which can “supervise” the application in such a way that the key parameters of the application can be modi fied accordi ng to the tube char ac­teristics just by changing the micro-code.
In this application note we will exploit a way to interface a microcontroller with our integrated ballast controller: the L6574.
1.0 INTRODUCTION
Roughly speaking a HF-TL ballast converts the 50-60Hz input to a high frequency output, usually in the range of 25-125KHz.
A rectifier block and a DC to high frequency inverter usually make up a ballast. The half bridge of the inverter can be driven in different ways with different ICs.
We will focus on a specific driver: the L6574. We will see first how the L6574 can drive and control a ballast, then how it can communicate and be supervised by a
The aim of this paper is to examine if there are advantages in having a this “cooperation”, and a practical example.
2.0 L6574
L6574 is a BCD off line 16 pin IC specifically designed for ballast applications [r ef.1](see fig.1). It has both driver functions and controller functions on board.
The most useful characteristics to control the lamp are:
Preheat and frequency shifting timing
Cmos shut down input
Sense op-amp for closed loop control or protection failures
The parameters of the application are set by external components (resistors and capacitors) connected to the IC. L6574 allows the user to set all the parameters according to the lamp characteristics, and the ballast wi ll be a high performance one. There is a specific application note on this IC (ref. [2]) : here you find the description of 58W TL ballast with PFC section. Please refer to this application note and to the L6574 datasheet for the IC details. In the following paragraphs we will focus our attention on a way to interface the L6574 with the micro­controller rather than on “L6574 - stand alone” perfor mances. The aim of this “supervision” is to control the three points mentioned above.
µ
C.
µ
C work with L6574, the feasibility of
December 2000
1/20
AN1320 APPLICATION NOTE
Figure 1. L6574 Block Diagram
V
S
OP AMP
5
OPOUT
6
OPIN-
7
OPIN+
4
R
IGN
2
R
PRE
3
Cf
Imin
Imax
VCO
+
-
V
REF
V
REF
12
CONTROL
LOGIC
UV
DETECTION
DEAD
TIME
Ifs
+
Vthpre
-
+
-
Ipre
BOOTSTRAP
1
C
PRE
DRIVER
DRIVING
LOGIC
HVG
DRIVER
LEVEL
SHIFTER
LVG DRIVER
+
-
+
-
V
V
THE
V
THE
D97IN493B
V
16
BOOT
HVG
15
OUT
14
S
LVG
11
GND
10
8
EN1
9
EN2
H.V.
C
BOOT
LOAD
3.0 L6574: HOW TO SET FREQUENCIES, TIMING, FAULT SIGNALS IN AN “ANALOG APPLICATION”
In this paragraph we will have a snap shot of the L6574 working, just as far as the characteristics important for the micro interface are concerned. For further details please refer to [1] and [2].
The L6574 typical behavior is shown in fig. 2: there is a starting frequency (f set preheat time T
, than there is a frequency shift towards f
PRE
that last 0.1 of T
min
MAX
or f
PRE
) that is constant for a
PRE
and is called T
IGN
or TSH.
Figure 2. Frequency shift
freq
preheating phase
fmax
Tpre
ignition phase
normal operation
fmin
Tsh
time
Leads 1, 2, 3, 4 are used to set frequencies and timing. The capacitor connected to pin 1[CPRE] sets the preheat time: T
= K1 · C
PRE
The ignition time, or better, the time to let frequency shift from preheat value to the min. value is one tenth of T
PRE
PRE
.
The current that charges and discharges the capacitor connected to pin 3 (CF) sets the half bridge oscillating frequency.
The current that charges C
2/20
is set by the current that flows out from pin 2 and 4 during preheat and from pin 4
F
AN1320 APPLICATION NOTE
alone during the on phase. As pin 2 and 4 are at 2V, the currents that flow out of them is inversely proportional to the resistance connected between gnd and pin 2 (R
There are some useful formula:
1.41 R
ƒ
---------------------------------------------------=
min
ƒ
max
Choosing properly the resistor and the c apacitor values the designer can set the desired fr equencies and timing. When the designer has to do another application for another lamp type, he has to change the resistors and ca­pacitors in order to have another range of frequencies.
For protection in case of lamp failure two logic input are provided: pin8 [EN1] and pin9 [EN2]. Both are active high, but they have different functions: when EN2 is activated it forces the IC to start again the preheat se­quence. When EN1 is activated it shut down the IC until V
EN2 is usually used as “ignition fault”: if the lamp is not ignited, the preheat sequence starts again. EN1 can be used to sense lamp removal / replacement or disconnection.
) and between gnd and pin 4 (R
PRE
+()
preRign
⋅⋅
R
preRign
1.41
----------------------- -=
R
ign
is removed or until EN2 is pulled high.
CC
IGN
).
Figure 3. EN1
V
CC
LVG
HVG
EN1
V
SUVP
D97IN490
3/20
AN1320 APPLICATION NOTE
Figure 4. EN2
V
CC
V
SUVP
f
OUT
f
PRE
f
ING
EN2
D97IN491B
t
PRE
t
SH
t
PREtSH
L6574 has also a sense op-amp th at can be used to have a closed loop contr ol of the lam p. We can give a volt­age reference to the non-inverting input, a signal proportional to the load current to the inverting input, and we can connect the op amp output pin to pin #4. In this way if the current in the load exceeds the reference the op amp will sink from pin 4 an additional amount of current that has to be added to the current that flows through R
. So the current charging CF will increase, that means a higher half bridge osci llation frequency, that m eans
IGN
a lower current in the load. C hanging the reference v oltage on the non- in verting input of the op amp we change the frequency of the oscillator, that means we change the current in the load, and this allows lamp dimming.
Figure 5. Cl osed Loop
4/20
R25
0.68
Q3 STP4NB50/ STP6NB50
R33 9.1K
7+
C9 8.2nF
D3
1N4148
65
-
R18 100K R19 100K
RIGN 4
D98IN818A
Figure 6. AN993 Demo Application Circuit
47K
R16 47
R20
C12
100nF
C11
680pF 630V
C20
R21
100nF
22
15
1612
2
C18
C17
L1 2.1mH
STP6NB50
Q2 STP4NB50/
R22 22
14
7
R17 9.1K
100nF 250V
R28
750K
100nF 250V
R26
390K
STP6NB50
47K
R23
11
L6574
6
C9
8.2nF
C19
8.2nF
1500V
R29
750K
Q3 STP4NB50/
D4
9
8
5
D3
1N4148
AN1320 APPLICATION NOTE
R27
6.8K
LAMP
R30
3.9K
C16 1µF
R32 20K
1N4148
R25
0.68
C15
330nF
R24
R18
100K
C14
C13
R19
6.8K
1µF
R33 9.1K
470pF
100K
10
1
3
4
D1 BYT11600
R5
T1 1.24mH (E25*13*7)
10 Turns 1.3mm gapped
R1
Bridge
Fuse
C1
220nF
DZ1
68K
1.5M
630V
D2
14V
1N4148
4.7K
RSENSE
C4 680nF
C8
R15
R12
R9
R8
C3
R2
100nF
1.5K
9.53K
0.68
0.68
10nF
10.1K
D99IN1064
R13
100K
C6
25V
R4
R3
C5
4.7µF
120K
120K
NTC
100nF
Q1
R6 22
7
8
5
6
STP6NB50
R7
47K
L6561
C2
220nF
C7
R10
400V
22µF
750K
450V
4
3
R11
12
R14
750K
5/20
AN1320 APPLICATION NOTE
4.0 L6574: HOW TO SET FREQUENCIES, TIMING, FAULT SIGNALS IN A “MICROCONTROLLED APPLICATION”
We have seen that the frequencies in L6574 are set by fixing the current that flows out from pin 2 and 4 and fixing the value of the C
A microcontroller output pin can give us a high logic level (5V) a low logic one (0V) or a PWM output at fixed frequency and variable duty cycle.
capacitor.
F
We can not use the P WM to act directly on C
pin, because the rising edge on CF is the low side mosfet “on
F
time” and the falling edge is the high side mosfet one. The half bridge would oscillate in asymmetrical way at fixed frequency instead of at 50% duty cycle and variable frequency. So we have to interface the pins that set the current that charges C
. A push pull output that gives us just 0V or 5V can not be used to in-
F
µ
C with th e
terface pin 2 and 4 because they have a maximum voltage level up to 2V. We have to use the integrated value of a PWM signal to set a voltage level between 0V and 2V.
We can use a PWM output also to gi ve the op amp the vo ltage reference to c hange the load c urrent (and so the lamp power to perform dimming)
Acting on L6574 pin 4 and (or) on pin 7 (opamp+) we can control the inverter working frequency. If we want to control the preheat timing and frequency we have to act on pins 2 and 1. First we have to avoid
that the L6574 fixes the preheat time by itself. If we connect to pin 1 a ver y small cap (e.g. 1nF), the L6574 “an­alog T
” will be so small to be “invisible” to the lamp (i.e. less than 2ms). During these 2 ms, the oscillating
PRE
frequency has to be high enough to avoid lamp filaments preheat (> 150KHz). The resistor connected to pin 2 has to be sized properly.
After these 2 ms L6574 is in “working mode”: it means that pin 4 is no more involved in fixing the frequency. Only C
Now the effective preheat time can be decided by the
and R
F
(pin 3 and 4) set it.
IGN
µ
C just acting on the PWM that gives the voltage reference to pin 4. For example, it can have a certain duty cycle (appropriate for the preheat freq.) for a fixed time, than it can change the duty cycle (i.e. the voltage reference) to set the ignition profile and the final working frequency.
Now we are able to change all the frequencie s and the tim ing invo lved in lamp tur ning on a nd dimming with two connections between L6574 and the
µ
C.
The fault management can al so be d one by the
µ
C: all the fault si gnals will be br ought to it, and then it will react according to the code. A connection that can be useful is the one to pin 8 (shut down pin) that can be direct because the ICs levels are compatible. In this way the
µ
C can react to a signal either by stopping the inverter or by changing the frequency (i.e. r epeating a preheat sequ ence if there is the no-i gnition al arm, or brin ging the frequency to a very high value…).
Just with these 3 connection between the L6574 and the
µ
C we can set nearly all the parameters of the appli-
cation by software. The number of We need another input pin to give the
µ
C inputs we need for fault signals depends only on what we want to control.
µ
C the information about the dimming level: this is the interface between the ballast and the “final user”. We can use either switches or an AD input. The first solution is more expensive in terms of number of pin, the AD input requires some attention for the co de part but allows a much larger num­ber of levels.
5.0 HOW TO APPLY THIS INTERFACE TO A BALLAST
We started from AN993 demo boar d to build a µC application with the s ame performances and s ome additi onal degrees of freedom.
We will now apply all the concepts already discussed and put them into a working board.
6/20
Loading...
+ 14 hidden pages