From 2707a4ddaea183f30924a9d615a103881512bbf0 Mon Sep 17 00:00:00 2001 From: James Souter Date: Thu, 16 Nov 2023 09:02:20 +0000 Subject: [PATCH 1/2] base frame timestamp off epicsTS --- pslApp/src/PSL.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/pslApp/src/PSL.cpp b/pslApp/src/PSL.cpp index cf91c3e..0d93ae6 100755 --- a/pslApp/src/PSL.cpp +++ b/pslApp/src/PSL.cpp @@ -524,7 +524,6 @@ asynStatus PSL::getImage() NDDataType_t dataType=NDUInt8; NDArray *pImage=NULL; NDColorMode_t colorMode; - epicsTimeStamp now; asynStatus status; NDArrayInfo arrayInfo; char *pOut=NULL; @@ -603,10 +602,9 @@ asynStatus PSL::getImage() getIntegerParam(NDArrayCounter, &imageCounter); /* Put the frame number and time stamp into the NDArray */ - epicsTimeGetCurrent(&now); pImage->uniqueId = imageCounter; - pImage->timeStamp = now.secPastEpoch + now.nsec / 1.e9; updateTimeStamp(&pImage->epicsTS); + pImage->timeStamp = pImage->epicsTS.secPastEpoch + pImage->epicsTS.nsec / 1.e9; pImage->pAttributeList->add("ColorMode", "Color Mode", NDAttrInt32, &colorMode); From 043c524aa409dc81f5d9fbed033ec5c2fe57c2de Mon Sep 17 00:00:00 2001 From: James Souter Date: Fri, 17 Nov 2023 09:05:18 +0000 Subject: [PATCH 2/2] use new updateTimeStamps method --- pslApp/src/PSL.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pslApp/src/PSL.cpp b/pslApp/src/PSL.cpp index 0d93ae6..4c8087f 100755 --- a/pslApp/src/PSL.cpp +++ b/pslApp/src/PSL.cpp @@ -603,8 +603,7 @@ asynStatus PSL::getImage() /* Put the frame number and time stamp into the NDArray */ pImage->uniqueId = imageCounter; - updateTimeStamp(&pImage->epicsTS); - pImage->timeStamp = pImage->epicsTS.secPastEpoch + pImage->epicsTS.nsec / 1.e9; + updateTimeStamps(pImage); pImage->pAttributeList->add("ColorMode", "Color Mode", NDAttrInt32, &colorMode);