Factor out motor step