building a cheap stratum 1 gps ntp timeserver

goal:
have a reliable local ntp timesource

motivation:

  • be independant of a internet connection
  • study the possibilities of cheap GPS devices

deliverables:

  • running ntp timeserver with GPS time
  • source code for ESP8266 for arduino IDE

approach:

  • find a ebook with code samples
  • play with the technology
  • implement
  • test

notes:

Progress

  • GPS sync for local clock implemented, setting local clock fails on some devices
  • ntp server prototype without GPS implemented
  • Do not use the standard softwareserial library with wifi, as it may crash the system. Use espsoftwareserial instead. I had to pay hard to find out…
  • Code is working now:

findings:

  • the esp9266 has a high resolution clock, but I can not set it on all devices
  • a PPS signal on the GPS device is the key to a high precision time source
  • atom with platformio ide is a nice development environment

open items:

  • build a nice 3d printed enclosure

source code:

 

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.