diff --git a/csaxs_bec/bec_ipython_client/plugins/flomni/flomni.py b/csaxs_bec/bec_ipython_client/plugins/flomni/flomni.py index 374ec61..87f3680 100644 --- a/csaxs_bec/bec_ipython_client/plugins/flomni/flomni.py +++ b/csaxs_bec/bec_ipython_client/plugins/flomni/flomni.py @@ -468,7 +468,7 @@ class FlomniSampleTransferMixin: def ftransfer_flomni_stage_out(self): self.flomnigui_show_cameras() - + self.flomnigui_raise() target_pos = -162 if np.isclose(dev.fsamx.readback.get(), target_pos, 0.01): @@ -924,7 +924,20 @@ class FlomniSampleTransferMixin: class FlomniAlignmentMixin: - default_correction_file = "correction_flomni_20210300_360deg.txt" + import csaxs_bec + import os + from pathlib import Path + + # Ensure this is a Path object, not a string + csaxs_bec_basepath = Path(csaxs_bec.__file__) + + default_correction_file_rel = "correction_flomni_20210300_360deg.txt" + + # Build the absolute path correctly + default_correction_file = ( + csaxs_bec_basepath.parent / 'bec_ipython_client' / 'plugins' / 'flomni' / default_correction_file_rel + ).resolve() + def reset_correction(self, use_default_correction=True): """ @@ -1186,8 +1199,8 @@ class Flomni( umv(dev.fsamx, fsamx_in) raise exc - def xrayeye_update_frame(self): - self.align.update_frame() + def xrayeye_update_frame(self,keep_shutter_open=False): + self.align.update_frame(keep_shutter_open) def xrayeye_alignment_start(self, keep_shutter_open=False): self.start_x_ray_eye_alignment(keep_shutter_open) diff --git a/csaxs_bec/bec_ipython_client/plugins/flomni/x_ray_eye_align.py b/csaxs_bec/bec_ipython_client/plugins/flomni/x_ray_eye_align.py index 893e5ad..f156aad 100644 --- a/csaxs_bec/bec_ipython_client/plugins/flomni/x_ray_eye_align.py +++ b/csaxs_bec/bec_ipython_client/plugins/flomni/x_ray_eye_align.py @@ -105,6 +105,10 @@ class XrayEyeAlign: print("This routine can be called with paramter keep_shutter_open=True to keep the shutter always open") self.send_message("Getting things ready. Please wait...") + #potential unresolved movement requests to zero + epics_put("XOMNYI-XEYE-MVX:0", 0) + epics_put("XOMNYI-XEYE-MVY:0", 0) + # reset shift xy and fov params self._reset_init_values()