From 4f5c59c0611deb17e73575de806ed747f7f2a2f4 Mon Sep 17 00:00:00 2001 From: Romain Bazile Date: Fri, 27 Nov 2020 11:31:18 +0100 Subject: [PATCH] imager: remove minimum volume check (done in Node-Red now) --- scripts/planktoscope/imager.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/planktoscope/imager.py b/scripts/planktoscope/imager.py index c228eff..e65bac5 100644 --- a/scripts/planktoscope/imager.py +++ b/scripts/planktoscope/imager.py @@ -304,8 +304,7 @@ class ImagerProcess(multiprocessing.Process): # Get duration to wait before an image from the different received arguments self.__sleep_before = float(last_message["sleep"]) # Get volume in between two images from the different received arguments - # Minimal volume is 0.1mL - self.__pump_volume = max(float(last_message["volume"]), 0.1) + self.__pump_volume = float(last_message["volume"]) # Get the pump direction message self.__pump_direction = last_message["pump_direction"] @@ -680,6 +679,7 @@ class ImagerProcess(multiprocessing.Process): while not self.stop_event.is_set(): self.treat_message() self.state_machine() + time.sleep(0.0001) logger.info("Shutting down the imager process") self.imager_client.client.publish("status/imager", '{"status":"Dead"}')