Close

Firmware and other changes

A project log for GPS Disciplined xCXO

A DIY GPS disciplined 10 MHz reference clock

nick-sayerNick Sayer 08/23/2015 at 16:010 Comments

One of the members of the Time Nuts list offered to characterize the GPSDO with his extraordinarily accurate equipment. I'm extremely grateful to him for taking the time and going to the exhaustive lengths he did. He made such a kind offer to a complete stranger, and has earned my eternal gratitude. I'm not naming him here simply because I didn't ask him if I could. I'm also not going to share his exact results for the same reason, but I will summarize.

The oscillator by itself is running 20 dB above the manufacturer's noise curve. That's not good, and it's all on me. The most shocking thing is that the blinking of the LEDs is actually causing frequency modulation on the output! There are a raft of isolation and power supply changes that will hopefully help this.

That said, the system is indeed at or below 1e-9 (1 ppb) for all time periods examined. That's not to say it can't do better, but the version available in the store now is meeting the design goal, if only just.

In addition to the hardware changes, I'm considering making some changes to the firmware too. The present firmware implements a frequency locked loop as opposed to a PLL. The difference between the two in this case is that a PLL attempts to discipline to the total error over all time. That is, a PLL endeavors to correct for past inaccuracy with opposite inaccuracy in the short term so as to maximize long term precision. With a PLL, you can count on the number of cycles to be correct even if the immediate frequency has to change to get there. With an FLL, the short term frequency accuracy is paramount, and the sins of the past are ignored and forgotten. With an FLL, the Allan plot sort of flattens out as you go to the right. With a PLL, it dives downwards as the tau (the measurement period) increases.

I'm undecided whether short term frequency accuracy or long term accuracy is better. If this were a clock, there'd be no question, but it's a frequency standard with no timekeeping. If I do go with a PLL, however, I've decided that it will not attempt to keep history across periods where the GPS lock is lost. Whenever GPS is acquired, the error history will start at zero.

One change I am going to do is ditch the LED blinking. Even with a cleaned up power supply, there's no need to tempt fate. The new system renames the two software LEDs as 0 and 1. When GPS is unlocked, they will blink back and forth at 2 Hz. One will be on at all times, so the current draw should be fairly static. The FIX led will blink, but there's nothing we can do about that. When GPS is acquired, the binary value of the lock quality will be displayed by the two LEDs: 0=bad, 1=good, 2=better, 3=best. The LEDs would only ever change once every 100 seconds, which should mean that even if they do have an impact on the output frequency, it won't be nearly as much as the FM observable now. The original purpose to blinking them was to prove the controller was running, but that isn't nearly as important as the damn thing being accurate and stable. :)

The v1.3 board hasn't been ordered yet. I have a revision on its way that I want to test first. V1.3 is slated to include these changes:

1. A separate digital and analog power bus, separated by an inductor. The inductor will be an attempt to isolate voltage changes due to current fluctuations to the digital components, where it doesn't matter.

2. Changing the buffer amp into an inverting compression amp. The goal is to trade DAC excursion range for increased granularity. The tuning range will be reduced to ~6 ppm, but the granularity will be double - just under 0.2 ppb.

3. The LDO in place of the switcher supply. I still don't know what possessed me. Temporary insanity.

4. Moving the analog section down into the corner, further away from the digital stuff. Hopefully it will have a much clearer return path through the ground planes. Also, the analog section will have its own separate power rail coming from the opposite physical side of the LDO output pad.

5. Moving the clock fan-out to be much, much closer to the output pins.

6. Adding some additional bypass caps in the digital section to the fan-out and GPS module to try and add additional high frequency reactance to ground.

Will all of that be enough? We'll see. The good thing is that none of that appreciably impacts the BOM cost. And I don't mind doing as many little, cheap things as I can. But if this isn't enough, then we need to contemplate one or more of:

1. Separate LDOs for the analog and digital sections.

2. A separate, high precision regulator for the DAC reference voltage.

3. Going back to a 20 MHz clock rate. That would double our measurement granularity over the same timeframes, permitting us to get 0.5 ppb in a 100 second sample. This would require powering the micro at 5v, but option 1 requires separate LDOs anyway (and this would require a third LDO just for the GPS, since it must have 3.3V, but lives in the digital section).

I don't believe any of those three options are likely. The goal is not maximum accuracy at any cost (there are plenty of commercial alternatives and I don't intend to attempt to compete with them), it is maximum accuracy at *this* price point. We're at 1 ppb now. I just want to squeeze out as much from these parts as they have to offer.

Discussions