From 8e0e8d75868590bf3656ad761018fd32426ac7bf Mon Sep 17 00:00:00 2001 From: Andrej Babic Date: Thu, 23 Apr 2020 19:37:43 +0200 Subject: [PATCH] Base pulse id instead of start Since we stream from the start of the file and not from the specific pulse --- sf-buffer/src/sf_replay.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/sf-buffer/src/sf_replay.cpp b/sf-buffer/src/sf_replay.cpp index 059f3ba..816b51a 100644 --- a/sf-buffer/src/sf_replay.cpp +++ b/sf-buffer/src/sf_replay.cpp @@ -142,7 +142,10 @@ int main (int argc, char *argv[]) { auto path_suffixes = BufferUtils::get_path_suffixes(start_pulse_id, stop_pulse_id); - size_t current_pulse_id = start_pulse_id; + uint64_t base_pulse_id = start_pulse_id / core_buffer::FILE_MOD; + base_pulse_id *= core_buffer::FILE_MOD; + + size_t current_pulse_id = base_pulse_id; string filename_base = device + "/" + channel_name + "/"; for (const auto& suffix:path_suffixes) {