Shop OBEX P1 Docs P2 Docs Learn Events
Random question: How do online clocks compensate for slow internet / page loadi — Parallax Forums

Random question: How do online clocks compensate for slow internet / page loadi

FlyingFishFingerFlyingFishFinger Posts: 461
edited 2010-02-21 04:20 in General Discussion
I was looking for an accurate clock source to adjust my nixie clock to and watch its deviation over time. Since I don't have a GPS or anything, I looked at online clocks (NIST etc), but how accurate are these given page loading times / internet speeds / whatever other factors?

Rafael

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
UC Berkeley '12 EECS
CalSol: UC Berkeley Solar Car
http://calsol.berkeley.edu
KJ6AWU

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2010-02-17 05:40
    The transit time of an internet packet is very variable. Normally the internet backbone routers will pick the shortest path to the message's destination, but might reroute a packet over a long path if there's a lot of congestion on the shorter circuit. A packet originating in Los Angeles might be routed through Chicago to Seattle for example. The ISP adds additional overhead to the delays in the final link to your computer. Each hop causes the packet to be queued up in a buffer for transmission. Your best bet for a clock source would be a receiver for one of the broadcast clock standards like WWV. The signal propagation time is well understood and the signal is easily decoded.

    If you use the Network Time Protocol (NTP), you can get much better accuracy. The Wikipedia indicates that you can get time latencies on the order of tens of milliseconds with NTP (en.wikipedia.org/wiki/Network_Time_Protocol).

    Post Edited (Mike Green) : 2/17/2010 5:46:13 AM GMT
  • mctriviamctrivia Posts: 3,772
    edited 2010-02-18 05:00
    try this:

    open cmd.exe(start->run on windows xp)
    type in:

    ping google.com

    look at the time value. I get 101ms, 117ms, 101ms, 52ms

    now try

    ping propmodule.com

    I get 73,73,97,100

    as you can see the ms delay can be fairly large and can very a lot even from packet to packet(52ms vs 117ms)


    if you need a very accurate time source pick up a cheap gps or use WWV. Personally I like GPS I have several GPS units and they will give you a rock solid time.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    24 bit LCD Breakout Board now in. $24.99 has backlight driver and touch sensitive decoder.

    If you have not already. Add yourself to the prophead map
  • ManetherenManetheren Posts: 117
    edited 2010-02-18 21:42
    There is also a phone number that you can call and receive WWV over also. This has been more accurate for me in the past. I just cannot remember the number and have switched phones since then.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Tia'Shar Manetheren
  • kf4ixmkf4ixm Posts: 529
    edited 2010-02-18 22:01
    (303) 499-7111 for WWV (Colorado), and (808) 335-4363 for WWVH (Hawaii). Callers are disconnected after 2 minutes.
    Manetheren said...
    There is also a phone number that you can call and receive WWV over also. This has been more accurate for me in the past. I just cannot remember the number and have switched phones since then.

  • Spiral_72Spiral_72 Posts: 791
    edited 2010-02-18 22:26
    You can also tune in on WWV if you have that option. It takes a known (calculated) amount of time to for the signal to reach you from near Denver Colorado.

    "The station radiates 10,000 W on 5, 10, and 15 MHz; and 2500 W on 2.5 and 20 MHz"

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    "puff"...... Smile, there went another one.
  • Martin HodgeMartin Hodge Posts: 1,246
    edited 2010-02-19 00:12
    Also don't forget WWVB, which is at 60 KHz. Antennas for this station can be ripped out of one of these $12.99 movements
    http://www.klockit.com/products/dept-159__sku-10144.html

    The antenna has three wires, Vcc, GND and 1bps time data.
    http://tf.nist.gov/stations/wwvbtimecode.htm

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Martin Hodge
    "I like Pie"
  • David BDavid B Posts: 592
    edited 2010-02-19 17:55
    When I pull up the NIST website at http://www.time.gov/timezone.cgi?Pacific/d/-8/java, it starts a java applet on my local machine, then I assume it does some round-trip measurement time adjustment, then displays right there on the screen "Accurate to within 0.2 seconds".

    Doesn't that answer your question right there?

    How are you checking the accuracy of your nixie clock?

    If you're only checking it by looking at the visible nixie display, watching the NIST time at a particular nixie digit transition, over several days, then probably the NIST website with no extra compensation would be perfectly fine. 0.2 seconds seems like it would be quite close to the errors you'll get in swinging your eyeballs between displays.

    I'm guessing that if you don't have access to a GPS receiver, then you probably don't have access to a receiver than can pick up WWV either.

    In fact, the power line 60 Hz frequency is supposed to be maintained to the correct cycle transition counts over the long run to keep power-line wall clocks accurate, so if all you want to do is a rough accuracy check, why not start by using a plugged-in clock?
  • FlyingFishFingerFlyingFishFinger Posts: 461
    edited 2010-02-20 02:01
    David-
    Yes, I looked at the site. I was wondering how they keep it that accurate for display on anyone's browser [noparse]:)[/noparse]
    And, what's your definition of *rough* ? I've been running it for over a week now and it still agrees with my cell phone. So in theory it's fine, but being an engineer I want to know exactly [noparse]:)[/noparse]

    Rafael

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    UC Berkeley '12 EECS
    CalSol: UC Berkeley Solar Car
    http://calsol.berkeley.edu
    KJ6AWU
  • David BDavid B Posts: 592
    edited 2010-02-20 19:17
    Time-keeping is one of those things that can be addicting; some people make life-long hobbies out of collecting and calibrating their collection of clocks.

    I say that because there can be any number of answers to what "rough" accuracy is, all depending on how far you'd like to go into the hobby. A cell phone comparison may be a perfectly fine measure for some people, but others might want to get into making a much more detailed measurement.

    If you were to get a GPS receiver with a one pulse per second digital output, which is fairly common, and you use the propeller's ability to detect pulse edges, I think you could quite easily measure the clock's performance (rate) down to an accuracy in the tens to hundreds of nanoseconds range, if you wanted to. (But I've heard that the time displayed on GPS screens is not necessarily kept particularly accurate, maybe being as much as a second or two off the actual time.)
  • mctriviamctrivia Posts: 3,772
    edited 2010-02-21 01:14
    GPS time should be perfectly acurate to a known error factor.

    Error Factors:
    1) GPS do not use day light savings time. accounts for 0 or 3600 second depending on time of year and region you live in.
    2) GPS do not use leap seconds. This error changes in a non predictive way and is based on the speeding up and slowing down of the earths rotation. I believe at this moment the error is 19 seconds ahead of the correct time.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    24 bit LCD Breakout Board now in. $24.99 has backlight driver and touch sensitive decoder.

    If you have not already. Add yourself to the prophead map
  • Martin HodgeMartin Hodge Posts: 1,246
    edited 2010-02-21 03:48
    I don't understand the 19 seconds thing. I have a GPS clock I made sitting next to a store bought WWVB clock -- which does do leap seconds -- and they are both dead on. Are you talking about the raw data coming from the sats before the receiver processes it?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Martin Hodge
    "Mmmmm, Biscuits"
  • mctriviamctrivia Posts: 3,772
    edited 2010-02-21 04:20
    yes. i am talking about the raw data.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    24 bit LCD Breakout Board now in. $24.99 has backlight driver and touch sensitive decoder.

    If you have not already. Add yourself to the prophead map
Sign In or Register to comment.