From 5ebfab9364d4315394a136732fd464ffe2229588 Mon Sep 17 00:00:00 2001 From: "Matthias P. Braendli" Date: Fri, 20 May 2016 16:14:33 +0200 Subject: Improve timestamp handling Replace PPS representation from double to integer, and analyse in OutputUHD if the timestamp is as expected. --- src/EtiReader.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'src/EtiReader.cpp') diff --git a/src/EtiReader.cpp b/src/EtiReader.cpp index 16272e3..067d6d0 100644 --- a/src/EtiReader.cpp +++ b/src/EtiReader.cpp @@ -287,7 +287,7 @@ bool EtiReader::sourceContainsTimestamp() /* See ETS 300 799, Annex C.2.2 */ } -double EtiReader::getPPSOffset() +uint32_t EtiReader::getPPSOffset() { if (!sourceContainsTimestamp()) { //fprintf(stderr, "****** SOURCE NO TS\n"); @@ -296,8 +296,7 @@ double EtiReader::getPPSOffset() uint32_t timestamp = ntohl(eti_tist.TIST) & 0xFFFFFF; //fprintf(stderr, "****** TIST 0x%x\n", timestamp); - double pps = timestamp / 16384000.0; // seconds - return pps; + return timestamp; } -- cgit v1.2.3