A system and method for generating a test signal used in measuring the
speed of a rotating device, such as a fan in a computer system is
disclosed. A pulse width modulated (PWM) signal may power the fan with
the duty cycle of the PWM signal controlling the speed of the fan. The
fan may generate tachometer pulses used for monitoring RPM of the fan.
The frequency of the test signal may be selected to be at least twice the
frequency of the tachometer pulses. The test signal may be generated from
a base frequency signal using two cascaded frequency dividers. The first
divider may output a scaled base frequency signal obtained by dividing
the base frequency signal by a user programmable scale frequency
coefficient corresponding to a maximum test signal frequency for the fan.
The second divider may output the test signal by dividing the scaled base
frequency signal by a fraction frequency coefficient obtained from and
proportional to the current PWM duty cycle value. The test signal may be
multiplexed with the PWM signal to obtain existing tachometer pulses even
when the PWM signal is not asserted. The scale frequency coefficient may
only need to be programmed once for each fan.