utils/inc/qshTimeUtil.h
Structures
qshTimeUtil
Sensors time utilities.
Members
std::atomic< std::int64_t >
Functions
getInstance
get singleton instance of the timeutil class
qtimerGetTicks
reads the current QTimer count value
qtimerGetFreq
get QTimer frequency in Hz
qtimerGetTimeNs
get time in nanoseconds since boot-up
qtimerTicksToNs
convert the qtimer tick value of nanoseconds
uint64_t
qtimerNsToElapsedRealtimeNano
convert qtimer timestamp (in ns) to android system time (in ns)
elapsedRealtimeNanoToQtimerNs
convert android system time (in ns) to qtimer timestamp (in ns)
int64_t
qtimerTicksToElapsedRealtimeNano
convert qtimer timestamp (in ticks) to android timestamp (in ns)
getElapsedRealtimeNanoOffset
get offset between sensor time system and Android time system (in ns)
recalculateOffset
kick in the logic to recalculate offset for drift
if true, always update the offset (even if the previous update was more recent than the last update)

