Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Clk_GetTS_NTP()

...

Get current Clock timestamp as an NTP timestamp. Anchor10511581051158

Files

...

clk.h/clk.c

...

Prototype

...

classCode_Listing

...

...

rowspan5

...

Arguments

...

...

p_ts_ntp_sec Pointer to variable that will receive the NTP timestamp:

Anchor10672661067266 In seconds UTC+00, if no errors;
CLK_TS_SEC_NONE, otherwise. Anchor10511741051174

Returned Values

...

...

DEF_OK, if current timestamp is successfully converted.

...

...

DEF_FAIL, otherwise.

...

Required Configuration

Anchor10511771051177Available only if CLK_CFG_NTP_EN is DEF_ENABLED in clk_cfg.h (see section 3-1-1). Anchor10511781051178

Notes / Warnings

Anchor10684271068427NTP timestamp does not include any time zone offset. Thus any local time zone offset must be applied after calling Clk_GetTS_NTP(). Anchor

10684561068456NTP timestamp will eventually overflow, thus it's not possible to get NTP timestamp for years on or after CLK_NTP_EPOCH_YR_END. Anchor10511971051197

Example Usage

...

classCode_Listing

...

rowspan8

...