One Technology Way • P.O. Box 9106 • Norwood, MA 02062-9106 • Tel: 781/329-4700 • Fax: 781/326-8703 • www.analog.com
Programming the Automatic Fan Speed Control Loop
By Mary Burke
AUTOMATIC FAN SPEED CONTROL
The ADT7460/ADT7463 have a local temperature sensor
and two remote temperature channels that may be connected to an on-chip diode-connected transistor on a
CPU. These three temperature channels may be used as
the basis for automatic fan speed control to drive fans
using pulsewidth modulation (PWM). In general, the
greater the number of fans in a system, the better the
cooling, but this is to the detriment of system acoustics.
Automatic fan speed control reduces acoustic noise
by optimizing fan speed according to measured temperature. Reducing fan speed can also decrease system
current consumption. The automatic fan speed control
mode is very flexible owing to the number of programmable parameters, including T
discussed in detail later. The T
MIN
MIN
and T
and T
values for a
RANGE
RANGE
, as
temperature channel and thus for a given fan are critical
since these define the thermal characteristics of the system. The thermal validation of the system is one of the
most important steps of the design process, so these
values should be carefully selected.
AIM OF THIS SECTION
The aim of this application note is not only to provide
the system designer with an understanding of the automatic fan control loop, but to also provide step-by-step
guidance as to how to most effectively evaluate and
select the critical system parameters. To optimize the
system characteristics, the designer needs to give some
forethought to how the system will be configured, i.e.,
the number of fans, where they are located, and what
temperatures are being measured in the particular
REMOTE 1
TEMP
LOCAL
TEMP
REMOTE 2
TEMP
THERMAL CALIBRATION
T
MIN
THERMAL CALIBRATION
T
MIN
THERMAL CALIBRATION
T
MIN
T
T
T
RANGE
RANGE
RANGE
100%
0%
100%
0%
100%
0%
MUX
PWM
MIN
PWM
MIN
PWM
MIN
RAMP
CONTROL
(ACOUSTIC
ENHANCEMENT
TACHOMETER 1
MEASUREMENT
RAMP
CONTROL
(ACOUSTIC
ENHANCEMENT
TACHOMETER 2
MEASUREMENT
RAMP
CONTROL
(ACOUSTIC
ENHANCEMENT
TACHOMETER 3
AND 4
MEASUREMENT
PWM
CONFIG
PWM
GENERATOR
PWM
CONFIG
PWM
GENERATOR
PWM
CONFIG
PWM
GENERATOR
PWM1
PWM2
PWM3
REV. 0
Figure 1. Automatic Fan Control Block Diagram
AN-613
system. The mechanical or thermal engineer who is
tasked with the actual system evaluation should also be
involved at the beginning of the process.
AUTOMATIC FAN CONTROL OVERVIEW
Figure 1 gives a top-level overview of the automatic fan
control circuitry on the ADT7460/ADT7463. From a systems level perspective, up to three system temperatures
can be monitored and used to control three PWM outputs. The three PWM outputs can be used to control up
to four fans. The ADT7460/ADT7463 allow the speed of
four fans to be monitored. Each temperature channel
has a thermal calibration block. This allows the
designer to individually configure the thermal characteristics of each temperature channel. For example, one
may decide to run the CPU fan when CPU temperature
increases above 60°C, and a chassis fan when the local
temperature increases above 45°C. Note that at this
stage, you have not assigned these thermal calibration
settings to a particular fan drive (PWM) channel. The
right side of the Block Diagram (Figure 1) shows controls
that are fan-specific. The designer has individual control
over parameters such as minimum PWM duty cycle, fan
speed failure thresholds, and even ramp control of the
PWM outputs. This ultimately allows graceful fan speed
changes that are less perceptible to the system user.
STEP 1: DETERMINING THE HARDWARE CONFIGURATION
During system design, the motherboard sensing and
control capabilities should not be an afterthought, but
addressed early in the design stages. Decisions about
how these capabilities are used should involve the system thermal/mechanical engineer. Ask the following
questions:
1. What ADT7460/ADT7463 functionality will be used?
• PWM2 or SMBALERT?
• 2.5 V voltage monitoring or SMBALERT?
• 2.5 V voltage monitoring or processor power
monitoring?
• TACH4 fan speed measurement or over-
temperature THERM function?
• 5 V voltage monitoring or overtemperature
THERM function?
• 12 V voltage monitoring or VID5 input?
The ADT7460/ADT7463 offers multifunctional pins that
can be reconfigured to suit different system requirements and physical layouts. These multifunction pins
are software programmable. Various pinout options
are discussed in a separate application note.
2. How many fans will be supported in system, three or
four? This will influence the choice of whether to use
the TACH4 pin or to reconfigure it for the THERM
function.
3. Is the CPU fan to be controlled using the ADT7460/
ADT7463 or will it run at full speed 100% of the time?
If run at 100%, it will free up a PWM output, but the
system will be louder.
REMOTE 1 =
AMBIENT TEMP
LOCAL =
VRM TEMP
REMOTE 2 =
CPU TEMP
THERMAL CALIBRATION
T
MIN
THERMAL CALIBRATION
T
MIN
THERMAL CALIBRATION
T
MIN
T
RANGE
T
RANGE
T
RANGE
Figure 2. Hardware Configuration Example
100%
0%
100%
0%
100%
0%
MUX
PWM
MIN
PWM
–2–
MIN
PWM
MIN
RAMP CONTROL
(ACOUSTIC
ENHANCEMENT)
TACHOMETER 1
MEASUREMENT
RAMP CONTROL
(ACOUSTIC
ENHANCEMENT)
TACHOMETER 2
MEASUREMENT
RAMP CONTROL
(ACOUSTIC
ENHANCEMENT)
TACHOMETER 3
AND 4
MEASUREMENT
PWM
CONFIG
PWM
GENERATOR
PWM
CONFIG
PWM
GENERATOR
PWM
CONFIG
PWM
GENERATOR
PWM1
TACH1
PWM2
TACH2
PWM3
TACH3
CPU
FAN SINK
FRONT
CHASSIS
REAR
CHASSIS
REV. 0
FRONT
CHASSIS
FAN
TACH2
AN-613
PWM1
TACH1
COMP
PWM3
TACH3
D1+
D1–
3.3VSB
5V
12V/VID5
CURRENT
V
CORE
REAR
CHASSIS
FAN
AMBIENT
TEMPERATURE
ADP316x
VRM
CONTROLLER
V
Figure 3. Recommended Implementation 1
4. Where will the ADT7460/ADT7463 be physically
located in the system?
This influences the assignment of the temperature
measurement channels to particular system thermal
zones. For example, locating the ADT7460/ADT7463
close to the VRM controller circuitry allows the VRM
temperature to be monitored using the local temperature channel.
RECOMMENDED IMPLEMENTATION 1
Configuring the ADT7460/ADT7463 as in Figure 3 provides the systems designer with the following features:
1.Six VID Inputs (VID0 to VID5) for VRM10 Support.
2.Two PWM Outputs for Fan Control of up to Three
Fans. (The front and rear chassis fans are connected
in parallel.)
3.Three TACH Fan Speed Measurement Inputs.
4.V
5.CPU Core Voltage Measurement (V
Measured Internally through Pin 4.
CC
CORE
).
VID[0:4]/VID[0.5]
ADT7463
GND
5(VRM9)/6(VRM10)
D2+
D2–
THERM
SMBALERT
PROCHOT
SDA
SCL
6.2.5 V Measurement Input Used to Monitor CPU Current (connected to V
output of ADP316x VRM
COMP
controller). This is used to determine CPU power
consumption.
7.5 V Measurement Input.
8.VRM temperature uses local temperature sensor.
9.CPU Temperature Measured Using Remote 1 Temperature Channel.
10. Ambient Temperature Measured through Remote 2
Temperature Channel.
11. If not using VID5, this pin can be reconfigured as the
12 V monitoring input.
12. Bidirectional THERM Pin. Allows monitoring of
PROCHOT output from Intel
®
P4 processor, for
example, or can be used as an overtemperature
THERM output.
13. SMBALERT System Interrupt Output.
REV. 0
–3–
AN-613
FRONT
CHASSIS
FAN
TACH2
PWM2
PWM1
TACH1
COMP
PWM3
TACH3
D1+
D1–
3.3VSB
5V
12V/VID5
CURRENT
V
CORE
REAR
CHASSIS
FAN
AMBIENT
TEMPERATURE
ADP316x
VRM
CONTROLLER
V
Figure 4. Recommended Implementation 2
RECOMMENDED IMPLEMENTATION 2
Configuring the ADT7460/ADT7463 as in Figure 4 provides the systems designer with the following features:
1.Six VID Inputs (VID0 to VID5) for VRM10 Support.
2.Three PWM Outputs for Fan Control of up to Three
Fans. (All three fans can be individually controlled.)
3.Three TACH Fan Speed Measurement Inputs.
4.V
5.CPU Core Voltage Measurement (V
Measured Internally through Pin 4.
CC
CORE
).
6.2.5 V Measurement Input Used to Monitor CPU Current (connected to V
output of ADP316x VRM
COMP
Controller). This is used to determine CPU power
consumption.
VID[0:4]/VID[0.5]
ADT7463
GND
5(VRM9)/6(VRM10)
D2+
D2–
THERM
PROCHOT
SDA
SCL
7.5 V Measurement Input.
8.VRM Temperature Uses Local Temperature Sensor.
9.CPU Temperature Measured Using Remote 1 Temperature Channel.
10. Ambient Temperature Measured through Remote 2
Temperature Channel.
11. If not using VID5, this pin can be reconfigured as the
12 V monitoring input.
12. BIDIRECTIONAL THERM Pin. Allows monitoring
of PROCHOT output from Intel P4 processor, for
example, or can be used as an overtemperature
THERM output.
–4–
REV. 0
AN-613
STEP 2: CONFIGURING THE MUX—WHICH
TEMPERATURE CONTROLS WHICH FAN?
After the system hardware configuration is determined,
the fans can be assigned to particular temperature channels. Not only can fans be assigned to individual
channels, but the behavior of fans is also configurable.
For example, fans can be run under automatic fan control, can run manually (under software control), or can
run at the fastest speed calculated by multiple temperature channels. The MUX is the bridge between
temperature measurement channels and the three PWM
outputs.
Bits <7:5> (BHVR bits) of registers 0x5C, 0x5D, and 0x5E
(PWM configuration registers) control the behavior of
the fans connected to the PWM1, PWM2, and PWM3 outputs. The values selected for these bits determine how
the MUX connects a temperature measurement channel
to a PWM output.
AUTOMATIC FAN CONTROL MUX OPTIONS
<7:5> (BHVR) REGISTERS 0x5C, 0x5D, 0x5E
000 = Remote 1 Temp controls PWMx
001 = Local Temp controls PWMx
010 = Remote 2 Temp controls PWMx
101 = Fastest Speed calculated by Local and Remote 2
Temp controls PWMx
110 = Fastest Speed calculated by all three temperature
channels controls PWMx
The "Fastest Speed Calculated" options pertain to the
ability to control one PWM output based on multiple
temperature channels. The thermal characteristics of
the three temperature zones can be set to drive a
single fan. An example would be if the fan turns on
when Remote 1 temperature exceeds 60°C or if the local
temperature exceeds 45°C.
OTHER MUX OPTIONS
<7:5> (BHVR) REGISTERS 0x5C, 0x5D, 0x5E
011 = PWMx runs full speed (default)
100 = PWMx disabled
111 = Manual Mode. PWMx is run under software control.
In this mode, PWM duty cycle registers (registers 0x30 to
0x32) are writable and control the PWM outputs.
REMOTE 1 =
AMBIENT TEMP
LOCAL =
VRM TEMP
REMOTE 2 =
CPU TEMP
THERMAL CALIBRATION
T
MIN
THERMAL CALIBRATION
T
MIN
THERMAL CALIBRATION
T
MIN
T
RANGE
T
RANGE
T
RANGE
100%
0%
100%
0%
100%
0%
MUX
MUX
PWM
MIN
PWM
MIN
PWM
MIN
RAMP CONTROL
(ACOUSTIC
ENHANCEMENT)
TACHOMETER 1
MEASUREMENT
RAMP CONTROL
(ACOUSTIC
ENHANCEMENT)
TACHOMETER 2
MEASUREMENT
RAMP CONTROL
(ACOUSTIC
ENHANCEMENT)
TACHOMETER 3
AND 4
MEASUREMENT
PWM
CONFIG
PWM
GENERATOR
PWM
CONFIG
PWM
GENERATOR
PWM
CONFIG
PWM
GENERATOR
PWM1
TACH1
PWM2
TACH2
PWM3
TACH3
CPU
FAN SINK
FRONT
CHASSIS
REAR
CHASSIS
REV. 0
Figure 5. Assigning Temperature Channels to Fan Channels
–5–
AN-613
MUX CONFIGURATION EXAMPLE
This is an example of how to configure the MUX in a
system using the ADT7460/ADT7463 to control three
fans. The CPU fan sink is controlled by PWM1, the front
chassis fan is controlled by PWM 2, and the rear chassis
fan is controlled by PWM3. The MUX is configured for
the following fan control behavior:
PWM1 (CPU fan sink) is controlled by the fastest speed
calculated by the Local (VRM Temp) and Remote 2 (processor) temperature. In this case, the CPU fan sink is
also being used to cool the VRM.
PWM2 (front chassis fan) is controlled by the Remote 1
temperature (ambient).
PWM3 (rear chassis fan) is controlled by the Remote 1
temperature (ambient).
REMOTE 2 =
CPU TEMP
THERMAL CALIBRATION
T
MIN
THERMAL CALIBRATION
T
RANGE
100%
0%
100%
MUX
EXAMPLE MUX SETTINGS
<7:5> (BHVR) PWM1 CONFIGURATION REG 0x5C
101 = Fastest speed calculated by Local and Remote 2
Temp controls PWM1.
<7:5> (BHVR) PWM2 CONFIGURATION REG 0x5D
000 = Remote 1 Temp controls PWM2.
<7:5> (BHVR) PWM3 CONFIGURATION REG 0x5E
000 = Remote 1 Temp controls PWM3.
These settings configure the MUX, as shown in Figure 6.
PWM
MIN
PWM
MIN
RAMP CONTROL
(ACOUSTIC
ENHANCEMENT)
TACHOMETER 1
MEASUREMENT
RAMP CONTROL
(ACOUSTIC
ENHANCEMENT)
PWM
CONFIG
PWM
GENERATOR
PWM
CONFIG
PWM
GENERATOR
PWM1
TACH1
PWM2
CPU
FAN SINK
FRONT
CHASSIS
LOCAL =
VRM TEMP
REMOTE 1 =
AMBIENT TEMP
T
MIN
THERMAL CALIBRATION
T
MIN
T
RANGE
T
RANGE
TACHOMETER 2
PWM
MIN
MEASUREMENT
RAMP CONTROL
(ACOUSTIC
ENHANCEMENT)
TACHOMETER 3
AND 4
MEASUREMENT
0%
100%
0%
Figure 6. MUX Configuration Example
PWM
CONFIG
PWM
GENERATOR
TACH2
PWM3
TACH3
REAR
CHASSIS
–6–
REV. 0
AN-613
STEP 3: DETERMINING T
SETTING FOR EACH
MIN
THERMAL CALIBRATION CHANNEL
T
is the temperature at which the fans will start to
MIN
turn on under automatic fan control. The speed at which
the fan runs at T
is programmed later. The T
MIN
MIN
values
chosen will be temperature channel specific, e.g., 25°C
for ambient channel, 30°C for VRM temperature, and
40°C for processor temperature.
T
is an 8-bit twos complement value that can be pro-
MIN
grammed in 1°C increments. There is a T
register
MIN
associated with each temperature measurement channel:
Remote 1, Local, and Remote 2 Temp. Once the T
MIN
value is exceeded, the fan turns on and runs at minimum
PWM duty cycle. The fan will turn off once temperature
has dropped below T
MIN
– T
(detailed later).
HYST
To overcome fan inertia, the fan is spun up until two
valid tach rising edges are counted. See the Fan Startup
Timeout section of the ADT7460/ADT7463 data sheet
for more details. In some cases, primarily for psychoacoustic reasons, it is desirable that the fan never
switches off below T
. Bits <7:5> of enhance acoustics
MIN
Register 1 (Reg. 0x62), when set, keeps the fans running
at PWM minimum duty cycle if the temperature should
fall below T
T
REGISTERS
MIN
Reg. 0x67 Remote 1 Temp T
Reg. 0x68 Local Temp T
Reg. 0x69 Remote 2 Temp T
MIN
.
= 0x5A (90°C default)
MIN
= 0x5A (90°C default)
MIN
= 0x5A (90°C default)
MIN
ENHANCE ACOUSTICS REG 1 (REG. 0x62)
Bit 7 (MIN3) = 0, PWM3 is OFF (0% PWM duty cycle)
when Temp is below T
MIN
– T
HYST
.
Bit 7 (MIN3) = 1, PWM3 runs at PWM3 minimum duty
cycle below T
MIN
– T
HYST
.
Bit 6 (MIN2) = 0, PWM2 is OFF (0% PWM duty cycle)
when Temp is below T
MIN
– T
HYST
.
Bit 6 (MIN2) = 1, PWM2 runs at PWM2 minimum duty
cycle below T
MIN
– T
HYST
.
Bit 5 (MIN1) = 0, PWM1 is OFF (0% PWM duty cycle)
when Temp is below T
MIN
– T
HYST
.
Bit 5 (MIN1) = 1, PWM1 runs at PWM1 minimum duty
cycle below T
MIN
– T
HYST
.
REMOTE 2 =
CPU TEMP
LOCAL =
VRM TEMP
REMOTE 1 =
AMBIENT TEMP
100%
PWM DUTY CYCLE
0%
T
THERMAL CALIBRATION
T
MIN
THERMAL CALIBRATION
T
MIN
THERMAL CALIBRATION
T
MIN
MIN
T
RANGE
T
RANGE
T
RANGE
100%
0%
100%
0%
100%
0%
MUX
PWM
MIN
PWM
MIN
PWM
MIN
RAMP
CONTROL
(ACOUSTIC
ENHANCEMENT
TACHOMETER 1
MEASUREMENT
RAMP
CONTROL
(ACOUSTIC
ENHANCEMENT
TACHOMETER 2
MEASUREMENT
RAMP
CONTROL
(ACOUSTIC
ENHANCEMENT
TACHOMETER 3
AND 4
MEASUREMENT
PWM
CONFIG
PWM
GENERATOR
PWM
CONFIG
PWM
GENERATOR
PWM
CONFIG
PWM
GENERATOR
PWM1
TACH1
PWM2
TACH2
PWM3
TACH3
CPU
FAN SINK
FRONT
CHASSIS
REAR
CHASSIS
REV. 0
Figure 7. Understanding the T
–7–
Parameter
MIN
AN-613
STEP 4: DETERMINING PWM
FOR EACH PWM (FAN)
MIN
OUTPUT
PWM
is the minimum PWM duty cycle at which each
MIN
fan in the system will run. It is also the “start” speed for
each fan under automatic fan control once the temperature rises above T
benefit, PWM
MIN
. For maximum system acoustic
MIN
should be as low as possible. Starting
the fans at higher speeds than necessary will merely
make the system louder than necessary. Depending on
the fan used, the PWM
setting should be in the 20% to
MIN
33% duty cycle range. This value can be found through
fan validation.
100%
PWM DUTY CYCLE
PWM
MIN
0%
TEMPERATURE
Figure 8. PWM
T
MIN
Determines Minimum PWM
MIN
Duty Cycle
It is important to note that more than one PWM
output can be controlled from a single temperature
measurement channel. For example, Remote 1 Temp
can control PWM1 and PWM2 outputs. If two different
fans are used on PWM and PWM2, then the fan characteristics can be set up differently. As a result, Fan 1
driven by PWM1 can have a different PWM
value than
MIN
that of Fan 2 connected to PWM2. Figure 9 illustrates
this as PWM1
duty cycle of 20%, whereas PWM2
(front fan) is turned on at a minimum
MIN
(rear fan) turns
MIN
on at a minimum of 40% duty cycle. Note, however,
that both fans turn on at exactly the same temperature, defined by T
MIN
.
100%
PWM2
PWM2
MIN
PWM DUTY CYCLE
PWM1
MIN
0%
T
MIN
PWM1
TEMPERATURE
Figure 9. Operating Two Different Fans from a Single
Temperature Channel
PROGRAMMING THE PWM
The PWM
registers are 8-bit registers that allow the
MIN
REGISTERS
MIN
minimum PWM duty cycle for each output to be configured anywhere from 0% to 100%. This allows minimum
PWM duty cycle to be set in steps of 0.39%.
The value to be programmed into the PWM
register is
MIN
given by:
Value (decimal) = PWM
MIN
/0.39
Example 1: For a minimum PWM duty cycle of 50%,
Value (decimal) = 50/0.39 = 128 decimal
Value = 128 decimal or 80 hex
Example 2: For a minimum PWM duty cycle of 33%,
Value (decimal) = 33/0.39 = 85 decimal
Value = 85 decimal or 54 hex
PWM
REGISTERS
MIN
Reg. 0x64 PWM1 Min Duty Cycle = 0x80 (50% default)
Reg. 0x65 PWM2 Min Duty Cycle = 0x80 (50% default)
Reg. 0x66 PWM3 Min Duty Cycle = 0x80 (50% default)
FAN SPEED AND PWM DUTY CYCLE
It should be noted that PWM duty cycle does not
directly correlate to fan speed in RPM. Running a fan at
33% PWM duty cycle does not equate to running the fan
at 33% speed. Driving a fan at 33% PWM duty cycle
actually runs the fan at closer to 50% of its full speed.
This is because fan speed in %RPM relates to the square
root of PWM duty cycle. Given a PWM square wave as
the drive signal, fan speed in RPM equates to:
–8–
% fan speedPWM duty cycle 10=×
REV. 0
AN-613
STEP 5: DETERMINING T
FOR EACH TEMPERATURE
RANGE
CHANNEL
T
is the range of temperature over which automatic
RANGE
fan control occurs once the programmed T
ture has been exceeded. T
is actually a temperature
RANGE
slope and not an arbitrary value, i.e., a T
only holds true for PWM
creased or decreased, the effective T
= 33%. If PWM
MIN
RANGE
tempera-
MIN
of 40°C
RANGE
is in-
MIN
is changed, as
described later.
T
RANGE
100%
PWM DUTY CYCLE
PWM
MIN
0%
TEMPERATURE
Figure 10. T
The T
RANGE
T
MIN
Parameter Affects Cooling Slope
RANGE
or fan control slope is determined by the fol-
lowing procedure:
1. Determine the maximum operating temperature for
that channel, e.g., 70°C.
2. Determine experimentally the fan speed (PWM duty
cycle value) that will not exceed the temperature at
the worst-case operating points, e.g., 70°C is reached
when the fans are running at 50% PWM duty cycle.
3. Determine the slope of the required control loop to
meet these requirements.
4. Use best fit approximation to determine the most
suitable T
value. ADT7460/ADT7463 evaluation
RANGE
software is available to calculate the best fit value.
Ask your local Analog Devices representative for
more details.
100%
50%
PWM DUTY CYCLE
33%
0%
30C
T
MIN
Figure 11. Adjusting PWM
40C
MIN
Affects T
RANGE
T
is implemented as a slope, which means as
RANGE
PWM
is changed, T
MIN
changes but the actual slope
RANGE
remains the same. The higher the PWM
smaller the effective T
will be, i.e., the fan will reach
RANGE
full speed (100%) at a lower temperature.
100%
50%
33%
25%
PWM DUTY CYCLE
10%
0%
30C
40C
45C
54C
T
MIN
Figure 12. Increasing PWM
T
RANGE
For a given T
value, the temperature at which the
RANGE
Changes Effective
MIN
fan will run at full speed for different PWM
easily be calculated: