Loading openflexure_microscope/stage/openflexure.py +9 −2 Original line number Diff line number Diff line from openflexure_stage import OpenFlexureStage from serial import SerialException from openflexure_microscope.lock import StrictLock import logging # TODO: Implement lock on movement class Stage(OpenFlexureStage): def __init__(self, *args, **kwargs): Loading @@ -11,7 +14,11 @@ class Stage(OpenFlexureStage): """ self.lock = StrictLock(timeout=2) #: :py:class:`openflexure_microscope.lock.StrictLock`: Strict lock controlling thread access to camera hardware try: OpenFlexureStage.__init__(self, *args, **kwargs) except SerialException as e: logging.error("No stage found. Aborting stage.") logging.warning("Stage lock can be acquired, but any stage methods will fail and raise exceptions.") def _move_rel_nobacklash(self, *args, **kwargs): """ Loading Loading
openflexure_microscope/stage/openflexure.py +9 −2 Original line number Diff line number Diff line from openflexure_stage import OpenFlexureStage from serial import SerialException from openflexure_microscope.lock import StrictLock import logging # TODO: Implement lock on movement class Stage(OpenFlexureStage): def __init__(self, *args, **kwargs): Loading @@ -11,7 +14,11 @@ class Stage(OpenFlexureStage): """ self.lock = StrictLock(timeout=2) #: :py:class:`openflexure_microscope.lock.StrictLock`: Strict lock controlling thread access to camera hardware try: OpenFlexureStage.__init__(self, *args, **kwargs) except SerialException as e: logging.error("No stage found. Aborting stage.") logging.warning("Stage lock can be acquired, but any stage methods will fail and raise exceptions.") def _move_rel_nobacklash(self, *args, **kwargs): """ Loading