diff options
author | Matthias P. Braendli <matthias.braendli@mpb.li> | 2019-02-18 11:57:54 +0100 |
---|---|---|
committer | Matthias P. Braendli <matthias.braendli@mpb.li> | 2019-02-18 11:57:54 +0100 |
commit | bbf0c1d07370190830a6f14b8458e29544062c1b (patch) | |
tree | c9b8d77457a1e38b85c89941fd45b572627953c8 /src | |
parent | fd33dd4329b591cc72ef30f1cefd9eb05cb1e560 (diff) | |
download | dabmux-bbf0c1d07370190830a6f14b8458e29544062c1b.tar.gz dabmux-bbf0c1d07370190830a6f14b8458e29544062c1b.tar.bz2 dabmux-bbf0c1d07370190830a6f14b8458e29544062c1b.zip |
Apply UTCO in odr-zmq2edi wait time calculation
Diffstat (limited to 'src')
-rw-r--r-- | src/zmq2edi/EDISender.cpp | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/src/zmq2edi/EDISender.cpp b/src/zmq2edi/EDISender.cpp index 236222c..b3a89ff 100644 --- a/src/zmq2edi/EDISender.cpp +++ b/src/zmq2edi/EDISender.cpp @@ -229,20 +229,13 @@ void EDISender::send_eti_frame(uint8_t* p, metadata_t metadata) using namespace std::chrono; - const auto seconds = metadata.edi_time; const auto pps_offset = milliseconds(std::lrint((tist & 0xFFFFFF) / 16384.0)); const auto t_frame = system_clock::from_time_t( - seconds + posix_timestamp_1_jan_2000) + pps_offset; + metadata.edi_time + posix_timestamp_1_jan_2000 - metadata.utc_offset) + pps_offset; const auto t_release = t_frame + milliseconds(tist_delay_ms); const auto t_now = system_clock::now(); - /* - etiLog.level(debug) << "seconds " << seconds + posix_timestamp_1_jan_2000; - etiLog.level(debug) << "now " << system_clock::to_time_t(t_now); - etiLog.level(debug) << "wait " << wait_time.count(); - */ - const auto wait_time = t_release - t_now; wait_times.push_back(duration_cast<microseconds>(wait_time).count()); |