bugfix for motor driver