Patent attributes
A motor driving device includes a brake mode control section for starting, when a brake instruction for a motor, braking of the motor in a reverse brake mode and then switching the reverse brake mode to a short brake mode; a cycle start detection section for receiving a rotation signal and detecting a start of a cycle of the rotation signal for each cycle; and a counter for performing, when the start of the cycle of the rotation signal is detected by the cycle start detection section, a count operation from an initial value. In the motor driving device, the brake mode control section detects that a value of the counter exceeds a threshold and performs switching from the reverse brake mode to the short brake mode with a delay from the detection.