| 1 |
#ifndef RIST_TIME_H |
| 2 |
#define RIST_TIME_H |
| 3 |
|
| 4 |
#include "common/attributes.h" |
| 5 |
|
| 6 |
#include <stdint.h> |
| 7 |
|
| 8 |
|
| 9 |
#define RIST_CLOCK (4294967LL) |
| 10 |
#define ONE_SECOND (1000 * RIST_CLOCK) |
| 11 |
#define RIST_LOG_QUIESCE_TIMER ONE_SECOND |
| 12 |
#define SEVENTY_YEARS_OFFSET (2208988800ULL) |
| 13 |
|
| 14 |
RIST_PRIV uint64_t timestampNTP_u64(void); |
| 15 |
RIST_PRIV uint64_t timestampNTP_RTC_u64(void); |
| 16 |
RIST_PRIV uint32_t timestampRTP_u32(int advanced, uint64_t i_ntp); |
| 17 |
RIST_PRIV uint64_t convertRTPtoNTP(uint8_t ptype, uint32_t time_extension, uint32_t i_rtp); |
| 18 |
RIST_PRIV uint64_t calculate_rtt_delay(uint64_t request, uint64_t response, uint32_t delay); |
| 19 |
|
| 20 |
#endif |