Patent ID: 7504786

Claim:
A motor controller for controlling output of a motor by opening and closing a switching element arranged on a power supply line to said motor in accordance with a PWM control signal, comprising: a relation storage part for storing a predetermined relationship between a current, a terminal voltage, a speed electromotive force, and an impedance of a coil constituting an armature winding of said motor; a voltage determination part for determining the terminal voltage of said coil; a speed electromotive force determination part for determining the speed electromotive force of said coil; a current detector for detecting the current of said coil; a judgment part for judging whether or not a duty cycle of said PWM control signal is in a current detection permission region by comparing said duty cycle with a set reference value; an impedance calculation part for determining the impedance of said coil in time series via a calculation based on the stored relationship, the determined terminal voltage, the determined speed electromotive force, and the detected current when said duty cycle of the PWM control signal is in the current detection permission region; a latest impedance storage part for storing the latest impedance determined by said impedance calculation part; a current calculation part for determining the current of said coil via a calculation based on the stored relationship, the determined terminal voltage, the determined speed electromotive force, and the stored latest impedance; and a current target value calculation part for determining a current target value via a calculation, wherein, when said duty cycle of the PWM control signal is in the current detection permission region, the output of said motor is controlled so as to reduce the deviation between the current target value determined by said current target value calculation part and a value corresponding to the detected current, and when said duty cycle of the PWM control signal is not in the current detection permission region, the output of said motor is controlled so as to reduce the deviation between the current target value determined by said current target value calculation part and a value corresponding to the current determined by said current calculation part.