From 9dcde4d65b93f96e6b828fb2957bb7022a2b3437 Mon Sep 17 00:00:00 2001 From: jupfi Date: Thu, 8 Feb 2024 17:49:10 +0100 Subject: [PATCH] Added stuff from argument parsing to the run experiment function --- src/limedriver.cpp | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/src/limedriver.cpp b/src/limedriver.cpp index 64167cb..44e5977 100644 --- a/src/limedriver.cpp +++ b/src/limedriver.cpp @@ -604,12 +604,6 @@ int parseArguments(int argc, char **argv, LimeConfig_t &LimeCfg, std::vector &HDFattrV Config2HDFattr_t HDFattr[no_of_attr]; std::copy(HDFattrVector.begin(), HDFattrVector.end(), HDFattr); + // convert input in seconds/Hz to samples + for (int ii = 0; ii < LimeCfg.Npulses; ii++) { + LimeCfg.p_dur_smp[ii] = round(LimeCfg.p_dur[ii] * LimeCfg.srate); + LimeCfg.p_frq_smp[ii] = LimeCfg.p_frq[ii] / LimeCfg.srate; + } // check directory first if (makePath(LimeCfg.save_path) == 0) {