Commit 249edebe authored by bliss administrator's avatar bliss administrator
Browse files

Add workaround to avoid tango timeout in case of windows detector

parent 3a945e0f
......@@ -569,6 +569,15 @@ class TomoCcd(TomoParameters):
)
self.det_proxy.image_roi = np.array(self.detector.image.roi)
#fix to avoid timeout during restore ccd config for windows pco
if len(self.detector.directories_mapping_names) > 0 and self.det_proxy.saving_directory != "":
dirsplit = self.det_proxy.saving_directory.split('/')
if 'inhouse' in self.det_proxy.saving_directory:
self.det_proxy.saving_directory = '/'.join(dirsplit[:dirsplit.index('inhouse')+1])
if 'visitor' in self.det_proxy.saving_directory:
self.det_proxy.saving_directory = '/'.join(dirsplit[:dirsplit.index('visitor')+1])
print(self.det_proxy.saving_directory)
# save the detector state
self.save_ccd_config(config_name)
......@@ -747,7 +756,9 @@ class TomoCcd(TomoParameters):
self.det_proxy.acq_trigger_mode = "INTERNAL_TRIGGER"
self.det_proxy.acq_expo_time = expo_time
self.det_proxy.acq_nb_frames = nimg
self.det_proxy.set_timeout_millis(10000)
self.det_proxy.prepareAcq()
self.det_proxy.set_timeout_millis(3000)
# start image acquisition
runtime = time.time()
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment