LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to synchronize clocks on two PCs?

Been tangling with this problem: I have two PC-based data sources whose clocks I'd like to keep synchronized within ~25ms.  They share an ethernet x-over connection on static IPs.  Machine A is my deployment target, Machine B is a device controller that I have essentially user access to.  Both are Windows XP PCs.  No net connection exists. The two machines are only connected when my software is in use.  Tests run ~1hr max.

 

I tried using the Windows Time Service ( w32tm and W32Time ) to synchronize two XP machines.  I followed this MS article on how to configure xp as an NTP time server, and set the client up to sync from it. http://support.microsoft.com/kb/314054/.  I  got it working and got it to correct a 16second difference between the machines, but it doesn't seem to do anything if there's an offset under 1sec.  in http://support.microsoft.com/kb/939322best , MS claims that 1-2sec is the limit of the software.

 

 

Has anyone used a different NTP setup?  I see a few posts involving NTP and cRIO, is there any application of that here?

-Barrett
CLD
0 Kudos
Message 1 of 4
(5,161 Views)

Do you need to sync them WITHOUT a network connection?

 

If you have a network, you could use UDP to transmit sync packets after you benchmark the transport time.

 

Otherwsie IRIG-B interfaces (don't remeber the NI borad that supports it) will let you sync to the GPS clocks.

 

Ben

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 2 of 4
(5,156 Views)

Hi blawson,

 

Have a look at www.arachnoid.com/abouttime/

It has a program that can be a network time server or client. That may do what you need

 

Rod.

 

0 Kudos
Message 3 of 4
(5,138 Views)

-sorry if it wasn't clear enough: computers are networked peer-to-peer with no internet connection.

 

though W32Time is trying to *keep* computers synchronized, all I want to do is force one computer to sync off another on command.

 

I've discovered that with the proper network sharing setup, "net time \\computername /set /yes" on a command line will do what I want. 

-Barrett
CLD
0 Kudos
Message 4 of 4
(5,127 Views)