[Gambas-user] UDP-Socket-Client

T Lee Davidson t.lee.davidson at ...626...
Sun Aug 6 02:07:37 CEST 2017


On 08/04/2017 11:33 AM, Hans Lehmann wrote:
> Hello.
> 
> Does anyone have any experience how to query with a UDP socket client on port 123 the time from a time server? A socket client 
> on port 37 will work correctly, but only the seconds since 1.1.1900 will be returned. This accuracy is not enough.
> 
> Sincerely
> 
> Hans

I assume you mean that you need (not necessarily greater accuracy which is dependent upon the server, but) greater precision by 
retrieving also the fractional part of the seconds since the NTP epoch?

No real-world, production experience here, but have a look at the attached example.


-- 
Lee
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ntpexample-0.0.1.tar.gz
Type: application/gzip
Size: 12414 bytes
Desc: not available
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20170805/25a4faa0/attachment.gz>


More information about the User mailing list