Method of Estimating Motor Speed and Motor Control System
A method of estimating motor speed includes: calculating a first estimate of rotor mechanical frequency of a motor based on measured time between successive counter pulses, each of the counter pulses corresponding to a fixed number of counts per revolution of the motor; calculating a second estimate of the rotor mechanical frequency based on the number of counter pulses over a fixed period of time; and dynamically revising an official estimate of the rotor mechanical frequency, by weighting the first and second estimates inversely proportional to one another based on the rotor mechanical frequency. A corresponding motor control system is also described.
1 . A method of estimating motor speed, comprising:
calculating a first estimate of rotor mechanical frequency of a motor based on measured time between successive counter pulses, wherein each of the counter pulses corresponds to a fixed number of counts per revolution of the motor;
calculating a second estimate of the rotor mechanical frequency based on the number of counter pulses over a fixed period of time; and
dynamically revising an official estimate of the rotor mechanical frequency, by weighting the first and second estimates inversely proportional to one another based on the rotor mechanical frequency.
2 . The method of claim 1 , wherein weighting the first and second estimates inversely proportional to one another based on the rotor mechanical frequency comprises:
applying a weighting factor of one to the first estimate of the rotor mechanical frequency and a weighting factor of zero to the second estimate of the rotor mechanical frequency, for rotor mechanical frequencies below a predetermined threshold; and
applying a weighting factor of one to the second estimate of the rotor mechanical frequency and a weighting factor of zero to the first estimate of the rotor mechanical frequency, for rotor mechanical frequencies above the predetermined threshold.
3 . The method of claim 1 , wherein weighting the first and second estimates inversely proportional to one another based on the rotor mechanical frequency comprises:
calculating a linear weighting factor based on the rotor mechanical frequency; and
applying the linear weighting factor to the first and second estimates of the rotor mechanical frequency.
4 . The method of claim 3 , wherein the linear weighting factor has a positive slope.
5 . The method of claim 3 , wherein the linear weighting factor has a slope that approximates change of a nonlinear weighting factor over a frequency range, and wherein the nonlinear weighting factor yields lower overall quantization error over the frequency range compared to the linear weighting factor.
6 . The method of claim 1 , wherein weighting the first and second estimates inversely proportional to one another based on the rotor mechanical frequency comprises:
calculating a nonlinear weighting factor over a frequency range; and
applying the nonlinear weighting factor to the first and second estimates of the rotor mechanical frequency, as a function of frequency.
7 . The method of claim 6 , wherein the nonlinear weighting factor is calculated as follows:
k
opt
=
(
N
0
f
*
)
2
(
N
0
f
*
)
2
+
f
ISR
(
f
clk
-
N
0
f
*
)
,
where k opt is the nonlinear weighting factor, N 0 is the fixed number of counts per revolution of the motor, f ISR is a frequency of the fixed period of time, f clk is a clock frequency of a timer/counter that measures time between the successive counter pulses, and f* is the rotor mechanical frequency.
8 . The method of claim 1 , wherein the counter pulses are derived from incremental encoder quadrature signals.
9 . The method of claim 1 , wherein the counter pulses are derived from hall sensor signals.
10 . The method of claim 1 , further comprising:
filtering the official estimate of the rotor mechanical frequency,
wherein the first and second estimates of the rotor mechanical frequency are weighted inversely proportional to one another based on the filtered official estimate of the rotor mechanical frequency.
11 . A motor control system, comprising:
a controller configured to:
calculate a first estimate of rotor mechanical frequency of a motor based on measured time between successive counter pulses, wherein each of the counter pulses corresponds to a fixed number of counts per revolution of the motor;
calculate a second estimate of the rotor mechanical frequency based on the number of counter pulses over a fixed period of time; and
dynamically revise an official estimate of the rotor mechanical frequency, by weighting the first and second estimates inversely proportional to one another based on the rotor mechanical frequency.
12 . The motor control system of claim 11 , wherein the controller is configured to:
apply a weighting factor of one to the first estimate of the rotor mechanical frequency and a weighting factor of zero to the second estimate of the rotor mechanical frequency, for rotor mechanical frequencies below a predetermined threshold; and
apply a weighting factor of one to the second estimate of the rotor mechanical frequency and a weighting factor of zero to the first estimate of the rotor mechanical frequency, for rotor mechanical frequencies above the predetermined threshold.
13 . The motor control system of claim 11 , wherein the controller is configured to:
calculate a linear weighting factor based on the rotor mechanical frequency; and
apply the linear weighting factor to the first and second estimates of the rotor mechanical frequency.
14 . The motor control system of claim 13 , wherein the linear weighting factor has a positive slope.
15 . The motor control system of claim 13 , wherein the linear weighting factor has a slope that approximates change of a nonlinear weighting factor over a frequency range, and wherein the nonlinear weighting factor yields lower overall quantization error over the frequency range compared to the linear weighting factor.
16 . The motor control system of claim 11 , wherein the controller is configured to:
calculate a nonlinear weighting factor over a frequency range; and
apply the nonlinear weighting factor to the first and second estimates of the rotor mechanical frequency, as a function of frequency.
17 . The motor control system of claim 16 , wherein the controller is configured to calculate the nonlinear weighting factor as follows:
k
opt
=
(
N
0
f
*
)
2
(
N
0
f
*
)
2
+
f
ISR
(
f
clk
-
N
0
f
*
)
,
where k opt is the nonlinear weighting factor, No is the fixed number of counts per revolution of the motor, f ISR is a frequency of the fixed period of time, f clk is a clock frequency of a timer/counter that measures time between the successive counter pulses, and f* is the rotor mechanical frequency.
18 . The motor control system of claim 11 , wherein the controller is configured to derive the counter pulses from incremental encoder quadrature signals.
19 . The motor control system of claim 11 , wherein the controller is configured to derive the counter pulses from hall sensor signals.
20 . The motor control system of claim 11 , wherein the controller is configured to:
filter the official estimate of the rotor mechanical frequency; and
weight the first and second estimates of the rotor mechanical frequency inversely proportional to one another based on the filtered official estimate of the rotor mechanical frequency.