Skip to content

Struct SYN_SNTP

ClassList > SYN_SNTP

SNTP client context — caller-owned.

  • #include <syn_sntp.h>

Public Attributes

Type Name
SYN_Backoff backoff
SYN_FilterEMA drift_filter
int32_t drift_ppm
uint32_t epoch_frac
uint32_t epoch_s
uint32_t prev_sync_epoch
uint32_t prev_sync_tick_ms
uint32_t recv_deadline
SYN_SockAddr server
uint32_t sync_interval_s
uint32_t sync_tick_ms
bool synced
SYN_Socket udp_sock

Public Attributes Documentation

variable backoff

SYN_Backoff SYN_SNTP::backoff;

Retry backoff state


variable drift_filter

SYN_FilterEMA SYN_SNTP::drift_filter;

EMA filter for clock drift PPM smoothing


variable drift_ppm

int32_t SYN_SNTP::drift_ppm;

Calculated & filtered clock drift in PPM (+ = fast, - = slow)


variable epoch_frac

uint32_t SYN_SNTP::epoch_frac;

Fractional seconds (NTP format)


variable epoch_s

uint32_t SYN_SNTP::epoch_s;

Last synced UTC epoch (seconds)


variable prev_sync_epoch

uint32_t SYN_SNTP::prev_sync_epoch;

Epoch at previous sync for PPM calculation


variable prev_sync_tick_ms

uint32_t SYN_SNTP::prev_sync_tick_ms;

Local tick at previous sync for PPM calculation


variable recv_deadline

uint32_t SYN_SNTP::recv_deadline;

Tick deadline for non-blocking recv


variable server

SYN_SockAddr SYN_SNTP::server;

NTP server address (IP + port)


variable sync_interval_s

uint32_t SYN_SNTP::sync_interval_s;

Re-sync interval in seconds


variable sync_tick_ms

uint32_t SYN_SNTP::sync_tick_ms;

Local tick at time of last sync


variable synced

bool SYN_SNTP::synced;

true after first successful sync


variable udp_sock

SYN_Socket SYN_SNTP::udp_sock;

UDP socket handle



The documentation for this class was generated from the following file src/syntropic/net/syn_sntp.h