ST AN2640 Application note

AN2640
Application note
Intelligent multipower digital ballast for
fluorescent lamps
Introduction
Fluorescent lamps are highly popular due to their luminous efficiency, long life and color rendering. These lamps need external circuitry to compensate for their negative resistance characteristic. This circuitry is called "ballast". The simplest ballast is a magnetic inductor connected in series at the lamp. The electronic ballast with respect to the magnetic one offers the following advantages:
Better efficiency
Increased lamp life
Lightweight with smaller dimensions
Better lamp power control
For these reasons, in the last years there has been a shift in the market towards the use of electronic ballasts with dedicated drivers and controllers. Today, thanks to microcontrollers, it is possible to add intelligence into the circuit. Instead of having a dedicated circuit for each lamp with a single ballast it is possible to drive many different lamp groups. This application note describes an electronic ballast that is able to recognize lamps within the T5 fluorescent family such as 24 W, 39 W, 54 W and 80 W. It consists of two main blocks:
A boost converter (Power Factor Controller PFC) working in transition mode (fixed T
and variable frequency)
An inverter in half-bridge configuration working in zero voltage switching
ON
Both ballast and PFC stages are controlled by the ST7FLIT19B that offers its entire signal to the L6382D5 which provides the right voltage and current levels for the Power MOSFET. This system after tube recognition sets the right parameter and drives the lamp correctly.
Figure 1 shows the ballast block diagram.

Figure 1. Ballast block diagram

January 2008 Rev 1 1/36
www.st.com
Contents AN2640
Contents
1 PFC section design criteria . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
1.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
1.2 Boost inductor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
1.3 PFC devices selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
1.3.1 Power switch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
1.3.2 Rectifier . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
2 Half-bridge design criteria . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
3 ST7LIT19BF1 - 8-bit MCU . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
3.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
3.2 Use of the pins . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
4 L6382D5 - power management units for microcontrolled ballast . . . . 18
4.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
4.2 Use of the pins . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
5 Recognition technique . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
5.1 Code implementation on microcontroller . . . . . . . . . . . . . . . . . . . . . . . . . 23
6 Board description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
6.1 Electrical schematic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
6.2 Bill of materials . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
6.3 Experimental results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
6.3.1 From system switch on to ballast run . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
6.3.2 PF, THD and ballast efficiency . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
6.3.3 Electromagnetic compatibility . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
7 Conclusion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
8 References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34
9 Revision history . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35
2/36
AN2640 List of figures
List of figures
Figure 1. Ballast block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
Figure 2. The step-up "Boost" regulator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
Figure 3. Inductor current waveform and MOSFET timing. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
Figure 4. 24 W lamp power . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
Figure 5. 39 W lamp power . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
Figure 6. 54 W lamp power . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
Figure 7. 80 W lamp power . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
Figure 8. ST7LITE1xB general block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
Figure 9. ST7LITE1xB 20-pin SO and DIP package pinout . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
Figure 10. PFC overcurrent detection circuit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
Figure 11. PFC V Figure 12. PFC V
Figure 13. Average current circuit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
Figure 14. Lamp type detection circuit (a) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
Figure 15. Lamp type detection circuit (b) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
Figure 16. Peak lamp voltage circuit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
Figure 17. Average lamp voltage circuit. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
Figure 18. Lamp detection circuit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
Figure 19. Zero-current detection circuit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
Figure 20. L6385Dx block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
Figure 21. Typical L6385Dx use . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
Figure 22. Circuit connected at CSI pin . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
Figure 23. Ballast operation sequence flowchart . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
Figure 24. STEVAL-ILB004V1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
Figure 25. Electrical schematic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
Figure 26. L6382 startup sequence and ballast start . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
Figure 27. 24 W lamp power . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29
Figure 28. 39 W lamp power . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29
Figure 29. 54 W lamp power . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30
Figure 30. 80 W lamp power . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30
Figure 31. Test equipment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
Figure 32. 24 W . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
Figure 33. 39 W . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
Figure 34. 54 W . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
Figure 35. 80 W . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
sense circuit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
out
waveform circuit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
in
3/36
PFC section design criteria AN2640

1 PFC section design criteria

1.1 Introduction

The following data are needed to calculate the input and output capacitors and the boost inductance:
Mains range (V
Regulated DC output voltage (V
Rated output power (P
Minimum switching frequency (f
Maximum output voltage ripple (V
Expected efficiency (η)
Maximum mains RMS current (I
Rated output current I
irms(min)

Input capacitor

The input capacitor that has been chosen is 470 nF. Using this value good performances in terms of power factor and current distortion have been obtained with the lamps that can be driven.
and V
)
o
o
irms(max)
)
o
swmin
o
)
rms
)
)
)

Output capacitor

The output bulk capacitor (Co) selection depends on the DC output voltage and the ripple on it. For lighting applications the ripple, 2*∆V
The output bulk capacitor has been calculated using the following formula:
Equation 1
----------------------------------------
C
o
4 π f V
⋅⋅⋅
Where:
f= 50 Hz (mains frequency)
V
V
I
P
= is the output voltage (420V)
o
= (½ ripple peak-to-peak value at 5%) is 10.5 V
o
= is the output peak current capacitor
o
= (lamp specifications)
o(max)
therefore
Co 30.7 µF
C
was selected as 47 µF
o
, is typically 5% of the output voltage.
o
I
o
------------------------------------------------------=
4 π fVo∆V
o
P
o
⋅⋅⋅ ⋅
o
4/36
AN2640 PFC section design criteria

1.2 Boost inductor

To define the PFC inductor several parameters are involved. The formula used to obtain the inductance value is:
Equation 2
2
V
irms min()
---------------------------------------------------------------------------------------------- -=
L
Where
f
V
P
P
η is the estimated efficiency (0.9)
= 35 kHz
sw(min)
irms(min)
= Po/η
i
o
= 185 V
is the lamp power
For multipower ballast the inductance calculation must be performed adopting the maximum lamp power (85 W).
Using these parameters L = 1.95 mH.
An inductance value of 2 mH ± 5% is chosen.
Vo2V
2f
⋅⋅
sw min()PiVo
()
irms min()
The switching frequency of PFC power transistor can be obtained using the following formula:
Equation 3
sw
⋅⋅
2LP
1
--------------------------
f
Notice that increasing the inductance value L decreases the PFC switching frequency.

1.3 PFC devices selection

The PFC is a step-up "Boost" regulator, therefore in normal operation the energy is fed from the inductor to the load and then stored in the output capacitor

Figure 2. The step-up "Boost" regulator

2
V
----------------------------------------------------------------------------------------- -
=
i
irms
Vo2V
irms
V
o
Θsin⋅⋅()
5/36
PFC section design criteria AN2640

Figure 3. Inductor current waveform and MOSFET timing

1.3.1 Power switch

It must be:
V
DSS
ID > I
> V
T(pk)
out
Equation 4
Equation 5
Equation 6
Equation 7
Equation 8
Equation 9
Equation 10
P
imax
V
I
Lmax rms()
I
Lpk()
22I
V
P
out
omax
420 V=
η 0.9=
P
omax
----------------
η
imin rms()
P
imax
------------------------- -
V
imin rms()
Lmax rms()
85 W=
95 W=
185 V=
510 mA=
1.5 A⋅⋅=
6/36
AN2640 PFC section design criteria
For safety reasons we must choose a device with:
V
I
20% more V
RRM
3 times more I
F(av)
, that is, 504 V
out
, that is, 4.5 A (to be considered transient current)
out
The STP6NK60Z, a Zener-Protected SuperMESH™ MOSFET, satisfies these specifications.
Table 1. STP6NK60Z general features

1.3.2 Rectifier

It must be:
Equation 11
Equation 12
For safety reasons we must choose a device with:
V
RRM
I
F(av)
The STTH1L06, a turbo 2 ultrafast, high-voltage rectifier, was selected because it is especially suitable as a boost diode in discontinuous or critical mode power factor corrections.
Table 2. STTH1L06 general features
V
DSS
R
DS(on)
600 V < 1.2 6 A
20% more V
3 times more I
I
Fav()Iout
, that is, 504 V
out
, that, is 600 mA
out
V
RRMVout
P
omax
----------------
V
out
420 V=>
200m A=>
I
D
I
F(AV)
V
RRM
V
F(typ)
t
rr(max)
1 A 600 V 1.05 V 80 ns
7/36
Half-bridge design criteria AN2640

2 Half-bridge design criteria

The design of the half-bridge section involves dimensioning the resonant components: ballast inductor and startup capacitor. The component design is not an easy matter and several parameters must be considered, especially when different lamps must be driven with the same resonant components. The main parameters to be considered are preheating current and voltage, maximum preheating voltage, maximum ignition voltage and run lamp voltage. For each lamp the transfer function was plotted in order to evaluate the operating point in terms of preheating and run frequency. The resonant inductor has been chosen as
1.2 mH and the startup capacitor has been chosen as 10 nF.

Figure 4. 24 W lamp power

Figure 5. 39 W lamp power

8/36
AN2640 Half-bridge design criteria

Figure 6. 54 W lamp power

Figure 7. 80 W lamp power

During the preheating phase in this system the half-bridge works at fixed frequency and the selected preheating frequency is the best choice according to the selected lamp specifications.
This working frequency guarantees the right preheating current for all lamps that can be driven by this system.
After tube recognition the microcontroller sets the right run frequency for the connected lamp.
9/36
ST7LIT19BF1 - 8-bit MCU AN2640

3 ST7LIT19BF1 - 8-bit MCU

3.1 Introduction

The ST7LIT19BF1 is a member of the ST7 microcontroller family.
All ST7 devices are based on a common industry-standard 8-bit core, featuring an enhanced instruction set.

Figure 8. ST7LITE1xB general block diagram

The ST7LIT19BF1, moreover, is a microcontroller designed for lighting applications.
10/36
AN2640 ST7LIT19BF1 - 8-bit MCU
The following are a few main features that make this microcontroller suitable for this scope:
Internal RC oscillator with 1% precision at 8 MHz CPU frequency
32 MHz timer counter clock with two independent counters for half-bridge and PFC
management
Analog PFC zero-current detection and half-bridge dead time generation
Analog comparator
10-bit A/D Converter with 7 channels and the possibility to use an amplifier (fixed gain
8) between the input and converter
2 timers with 1 ms or 2 ms time base to provide timing to the system management

Figure 9. ST7LITE1xB 20-pin SO and DIP package pinout

3.2 Use of the pins

Pin 1: GND
Pin 2: V
generated by the L6382D5 device. To prevent noise in this pin a 100 nF capacitor must be soldered as close as possible between this pin and GND.
Pin 3: reset (not used). It is advisable to connect a small capacitor to avoid undesired
reset of the micro between this pin and GND.
Pin 4: COMPIN+. This pin is used to protect against overcurrent on the PFC Power
MOSFET and inductor. When the current exceeds 2 A, the comparator inside the MCU stops the ballast without using the MCU core. Figure 10 shows the detection circuit.
. The microcontroller is supplied by means of this pin. The voltage is
CC
11/36
Loading...
+ 25 hidden pages