Changes in motor.c