From 6519205775ea075f93c9b49a8cfeb3b21edd9cc9 Mon Sep 17 00:00:00 2001 From: fusEngineers <148349859+fusEngineers@users.noreply.github.com> Date: Tue, 17 Dec 2024 11:32:59 +0100 Subject: [PATCH] set pulse_train_rep param to pulse_train_dur if wait for trigger --- fus_ds_package/fus_driving_systems/sequence.py | 6 ++++++ .../interleaved_example/standalone_igt_interleaved.py | 1 + 2 files changed, 7 insertions(+) diff --git a/fus_ds_package/fus_driving_systems/sequence.py b/fus_ds_package/fus_driving_systems/sequence.py index dc52659..4e6cf1d 100644 --- a/fus_ds_package/fus_driving_systems/sequence.py +++ b/fus_ds_package/fus_driving_systems/sequence.py @@ -498,6 +498,12 @@ def n_triggers(self, n_triggers): True, True, True, False) if is_validated: self._n_triggers = n_triggers + + # set temporarily the pulse train repetition parameters equal to + # the pulse train duration to prevent default being lower than + # pulse train duration + self.pulse_train_rep_int = self.pulse_train_dur + self.pulse_train_rep_dur = self.pulse_train_dur @property def transducer(self): diff --git a/standalone_driving_system_software/interleaved_example/standalone_igt_interleaved.py b/standalone_driving_system_software/interleaved_example/standalone_igt_interleaved.py index fda3ee0..1627dc8 100644 --- a/standalone_driving_system_software/interleaved_example/standalone_igt_interleaved.py +++ b/standalone_driving_system_software/interleaved_example/standalone_igt_interleaved.py @@ -75,6 +75,7 @@ one_interleaved_session_ms = seq1.pulse_train_rep_dur + seq3.pulse_train_rep_dur n_sessions = round(total_duration_s / (one_interleaved_session_ms/1000)) for i in range(n_sessions): + print(f'\n session {i} of {n_sessions} \n') igt_driving_sys.execute_sequence(seq1, seq2) igt_driving_sys.execute_sequence(seq3, seq4)