def METHOD_NAME(self, z_stage_fn):
    self.z_stage_fn = z_stage_fn
    self.z_stage_fn.zStagePosition.connect(self.handleZStagePosition)
    self.ui.goSpinBox.setMinimum(self.z_stage_fn.getMinimum())
    self.ui.goSpinBox.setMaximum(self.z_stage_fn.getMaximum())
    self.setEnabled(True)