Trying a bit more intelligently to get the motor port