added forward and backward fail safe to moveTo