_LOG.error(('requested setpoint ({} bits) is larger than the '
'maximum deflection value of {} bits'
).format(deflection, max_def))
- raise ValueError(setpoint)
+ raise ValueError(deflection)
elif deflection < 0:
_LOG.error(('requested setpoint ({} bits) is less than the '
'minimum deflection value of 0 bits'
).format(deflection))
- raise ValueError(setpoint)
+ raise ValueError(deflection)
def _stepper_approach_again(self, target_deflection, min_slope_ratio, far):
_LOG.info('back off %d half steps and approach until deflection > %g'