From 2c38a7dc43d13882f0452abfcc69c47b84e6e35b Mon Sep 17 00:00:00 2001 From: Joel Collins Date: Mon, 6 Jul 2020 13:33:17 +0100 Subject: [PATCH] Delegate starting stream worker --- openflexure_microscope/camera/base.py | 5 ----- openflexure_microscope/camera/pi.py | 4 +++- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/openflexure_microscope/camera/base.py b/openflexure_microscope/camera/base.py index 8dc59dad..8cce8d22 100644 --- a/openflexure_microscope/camera/base.py +++ b/openflexure_microscope/camera/base.py @@ -30,15 +30,10 @@ class BaseCamera(metaclass=ABCMeta): self.event = ClientEvent() self.stop = False # Used to indicate that the stream loop should break - self.stream_timeout = 20 - self.stream_active = False self.record_active = False self.preview_active = False - # Start the stream worker on init - self.start_worker() - @property @abstractmethod def configuration(self): diff --git a/openflexure_microscope/camera/pi.py b/openflexure_microscope/camera/pi.py index d24ac186..55d74dd6 100644 --- a/openflexure_microscope/camera/pi.py +++ b/openflexure_microscope/camera/pi.py @@ -115,7 +115,9 @@ class PiCameraStreamer(BaseCamera): self.picamera_lst_path = settings_file_path( "picamera_lst.npy" ) #: str: Path of .npy lens shading table file - + + # Start the stream worker on init + self.start_worker() @property def configuration(self):