Skip to content

supasillyass/TimeSync

Repository files navigation

TimeSync

A Simple Network Time Protocol (SNTP) client based on RFC 4330.

Initially based on the RFC 2030 implementations of Valer Bocan (here and here), the code was updated to RFC 4330 with an option for the user to specify a NTP/SNTP server.

Help

Time Synchronizer (SNTP Client)
(C)2001-2019 Valer BOCAN, PhD <[email protected]>
Modified by Miguel GARCIA-BLANCO [2021/11/05 16:29Z]

Set the system date and time from a remote NTP time server.

Usage: TimeSync [-q] [SERVER]
  -q, --query   Query only - do not set the clock
  -?, --help    Display this help and exit

If SERVER is not specified, the default server 'pool.ntp.org' will be used.

Examples:
  TimeSync -q
  TimeSync time.nist.gov
  TimeSync 128.138.141.172

Example

Time Synchronizer (SNTP Client)
(C)2001-2019 Valer BOCAN, PhD <[email protected]>
Modified by Miguel GARCIA-BLANCO [2021/11/05 16:29Z]

Connecting to pool.ntp.org...

 Leap Indicator: 0 (no warning)
 NTP Version: 4
 Stratum: 2 (secondary reference - synchronized by NTP or SNTP)
 Poll Interval: 3 (8 s)
 Precision: -24 (59.605 ns)
 Root Delay: 4.364 ms
 Root Dispersion: 38.864 ms
 Reference ID: 192.33.96.101
 Local Time: 2023/01/01 19:13:40.753+10:30
 Round Trip Delay: 351.26 ms
 System Clock Offset: -66.16 ms

SYSTEM TIME NOT UPDATED

References

About

A Simple Network Time Protocol (SNTP) client.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages