lib60870-C  2.3.2
C source code library for the IEC 60870-5-101/104 protocols
Typedefs | Functions
Collaboration diagram for Time related functions:

Typedefs

typedef uint64_t nsSinceEpoch
 
typedef uint64_t msSinceEpoch
 

Functions

PAL_API msSinceEpoch Hal_getTimeInMs (void)
 
PAL_API nsSinceEpoch Hal_getTimeInNs (void)
 
PAL_API bool Hal_setTimeInNs (nsSinceEpoch nsTime)
 

Detailed Description

Function Documentation

◆ Hal_getTimeInMs()

PAL_API msSinceEpoch Hal_getTimeInMs ( void  )

Get the system time in milliseconds.

The time value returned as 64-bit unsigned integer should represent the milliseconds since the UNIX epoch (1970/01/01 00:00 UTC).

Returns
the system time with millisecond resolution.

◆ Hal_getTimeInNs()

PAL_API nsSinceEpoch Hal_getTimeInNs ( void  )

Get the system time in nanoseconds.

The time value returned as 64-bit unsigned integer should represent the nanoseconds since the UNIX epoch (1970/01/01 00:00 UTC).

Returns
the system time with nanosecond resolution.

◆ Hal_setTimeInNs()

PAL_API bool Hal_setTimeInNs ( nsSinceEpoch  nsTime)

Set the system time from ns time

The time value returned as 64-bit unsigned integer should represent the nanoseconds since the UNIX epoch (1970/01/01 00:00 UTC).

Returns
true on success, otherwise false