Loading...
Searching...
No Matches
Time.h File Reference
`#include <SoapySDR/Config.h>`

Go to the source code of this file.

## Functions

SOAPY_SDR_API long long | SoapySDR_ticksToTimeNs (const long long ticks, const double rate)
SOAPY_SDR_API long long | SoapySDR_timeNsToTicks (const long long timeNs, const double rate)

## Detailed Description

Utility functions to convert time and ticks.

Copyright
  Copyright (c) 2015-2015 Josh Blum SPDX-License-Identifier: BSL-1.0

## Function Documentation

## SoapySDR_ticksToTimeNs()

SOAPY_SDR_API long long SoapySDR_ticksToTimeNs | ( | const long long | ticks,
|  | const double | rate )

Convert a tick count into a time in nanoseconds using the tick rate.

Parameters

  ticks | a integer tick count
  rate | the ticks per second

Returns
  the time in nanoseconds

## SoapySDR_timeNsToTicks()

SOAPY_SDR_API long long SoapySDR_timeNsToTicks | ( | const long long | timeNs,
|  | const double | rate )

Convert a time in nanoseconds into a tick count using the tick rate.

Parameters

  timeNs | time in nanoseconds
  rate | the ticks per second

Returns
  the integer tick count