I’ve been working on GPSD a lot recently – we’re heading towards a 3.10 release with a lot of new features. As part of this release I’ve decided to ship a HOWTO on setting up a high-quality NTP time server using GPSD. In the course of working on that, I’ve had an idea.
The idea has two antecedents. One is that if you start with any one of several inexpensive GPS modules (my favorite of which is the u-blox 6), and add GPSD to read it and feed an ntpd instance, it’s possible to build an NTP server that meets the usual standard for public Stratum 1 time servers – 10mSec or better accuracy to UTC.
The other is that there is a raft of inexpensive SBCs that run Linux out there – Arduino, Raspberry Pi and the current new hotness BeagleBone. So here’s my thought: why not build a low-power Stratum 1 timeserver on a credit-card-sized SBC?
A little googling tells me that someone has already mated a GPS to a BeagleBone Black. His design uses a u-blox, but has one serious drawback – he doesn’t wire up 1PPS from the receiver. This is a must if you want sub-second precision on your time service.
Now, to be fair, the D2523T he’s using might not bring 1PPS out from the u-blox5 to the module header. On the other hand, I looked up the D2523T’s data sheet on Sparkfun and their pinout for it has a lead labeled “GPS LED”.
Bingo! Boys and girls, the LED on your GPS is driven by 1PPS – the once-per-second flash it emits is top of GPS second accurate to 50 nanoseconds. It seems likely that we could take the right small variant of this design, add ntpd to it, do a little configuration, and stand back! Instant Stratum 1 in a smaller package than your smartphone, powered off its USB cable.
Well, that is, if the RS232 headers on the BeagleBone include any handshake line. Carrier Detect, Ring Indicator, even Clear To Send – any of these would be good enough. 1PPS has to travel over something that isn’t TX.
It would be a fun project. I wish I had time to do it.