axis = self.piezo.axis_by_name(self.axis_name)
- zero = _convert_volts_to_bits(axis.axis_channel_config, 0)
- target_def = _convert_volts_to_bits(axis.axis_channel_config, setpoint)
+ zero = _convert_volts_to_bits(axis.config['channel'], 0)
+ target_def = _convert_volts_to_bits(axis.config['channel'], setpoint)
_LOG.debug('zero the %s piezo output' % self.axis_name)
self.piezo.jump(axis_name=self.axis_name, position=zero)
pos = self._stepper_approach_again(
target_deflection=target_def, far=far)
- pos_m = _convert_bits_to_meters(
- axis.axis_channel_config, axis.axis_config, pos)
+ pos_m = _convert_bits_to_meters(axis.config, pos)
_LOG.debug('located surface at stepper %d, piezo %d (%g m)'
% (self.stepper.position, pos, pos_m))
except _FlatFit, e:
_LOG.debug(e)
continue
- pos_m = _convert_bits_to_meters(
- axis.axis_channel_config, axis.axis_config, pos)
+ pos_m = _convert_bits_to_meters(axis.config, pos)
_LOG.debug('located surface at stepper %d, piezo %d (%g m)'
% (self.stepper.position, pos, pos_m))
while pos_m > stepper_tolerance: # step forward if we need to
except _FlatFit, e:
_LOG.debug(e)
continue
- pos_m = _convert_bits_to_meters(
- axis.axis_channel_config, axis.axis_config, pos)
+ pos_m = _convert_bits_to_meters(axis.config, pos)
_LOG.debug('located surface at stepper %d, piezo %d (%g m)'
% (self.stepper.position, pos, pos_m))
_LOG.debug('adjust the %s piezo to place us just onto the surface'
% self.axis_name)
target_m = pos_m + depth
- target = _convert_meters_to_bits(
- axis.axis_channel_config, axis.axis_config, target_m)
+ target = _convert_meters_to_bits(axis.config, target_m)
self.piezo.jump(self.axis_name, target)
_LOG.debug(