From 3fac5ff9e30dc39905df3ced5d2b92f729f55e42 Mon Sep 17 00:00:00 2001 From: Holler Date: Fri, 5 Sep 2025 11:04:07 +0200 Subject: [PATCH] fixed issue with move_to_start --- csaxs_bec/scans/flomni_fermat_scan.py | 5 +++-- csaxs_bec/scans/omny_fermat_scan.py | 5 +++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/csaxs_bec/scans/flomni_fermat_scan.py b/csaxs_bec/scans/flomni_fermat_scan.py index aefd2f3..651f8f0 100644 --- a/csaxs_bec/scans/flomni_fermat_scan.py +++ b/csaxs_bec/scans/flomni_fermat_scan.py @@ -295,9 +295,10 @@ class FlomniFermatScan(SyncFlyScanBase): logger.debug("reading monitors") # yield from self.device_rpc("rtx", "controller.kickoff") - def return_to_start(self): + def move_to_start(self): """return to the start position""" - # in flomni, we need to move to the start position of the next scan + # in flomni, we need to move to the start position of the next scan, which is the end position of the current scan + # this method is called in finalize and overwrites the default move_to_start() if isinstance(self.positions, np.ndarray) and len(self.positions[-1]) == 3: yield from self.stubs.set(device=["rtx", "rty", "rtz"], value=self.positions[-1]) return diff --git a/csaxs_bec/scans/omny_fermat_scan.py b/csaxs_bec/scans/omny_fermat_scan.py index 4529ee8..9cb902b 100644 --- a/csaxs_bec/scans/omny_fermat_scan.py +++ b/csaxs_bec/scans/omny_fermat_scan.py @@ -280,9 +280,10 @@ class OMNYFermatScan(SyncFlyScanBase): logger.debug("reading monitors") # yield from self.device_rpc("rtx", "controller.kickoff") - def return_to_start(self): + def move_to_start(self): """return to the start position""" - # in omny, we need to move to the start position of the next scan + # in omny, we need to move to the start position of the next scan, which is the end position of the current scan + # this method is called in finalize and overwrites the default move_to_start() if isinstance(self.positions, np.ndarray) and len(self.positions[-1]) == 3: yield from self.stubs.set(device=["rtx", "rty", "rtz"], value=self.positions[-1]) return