0
\$\begingroup\$

I am considering doing some recreational timing. I have few OCXO's, GPSDO, Rb source - but no way to compare their stability / jitter. Majority of sources are around 10Mhz.

Is there any DIY-friendly way via some publicly available / open source hardware & software to measure jitter / Allan deviation?

For example, I think it should be possible to compare clock1 vs clock2 (OCXO) using phase comparator feed into soundcard or ADC. Then some software might analyze it and build a graph. Maybe signal could be compared to 2 independent OCXO and even better measurement extracted with very simple measurement setup. Or some DDS-based approach could be used.

Is it possible? Can you suggest where too look for previous DIY-friendly developments in the area?

Example image by @LeoBodnar: Image by @LeoBodnar

\$\endgroup\$
2
  • \$\begingroup\$ This site is not really set up for pointing to external references. The timenuts mailing list has moved to leapsecond.com. You can find a lot of info there, eg. pointer to AllanTools.py. \$\endgroup\$ Nov 13, 2020 at 7:51
  • 1
    \$\begingroup\$ @BarsMonster low cost suggestions, mostly for Tau>1 second: 1) Join the time-nuts mailing list if you haven't already, and browse the archives. 2) Download Timelab to plot things, unless you like chasing math errors. 3) Burn a PicDIV to divide down your clocks. 4) Even the cheapest ebay uBlox GPSs have an external Int pin which they can timestamp at a 20 ns granuarity (plus gps error), a few times a second. 5) The TDC7200 chip can measure time intervals with a few 10s of accuracy, hundreds of times per second. Available as a $20 TDC-Click board. \$\endgroup\$
    – tomnexus
    Nov 29, 2022 at 20:04

3 Answers 3

2
\$\begingroup\$

It depends at what level you want to do 'recreational'. Do you enjoy wrestling the software, or reaching the noise floors? What do you want to tackle first, close to carrier, 1 kHz offset, far out noise floors, long term stability, Allan Variance, they will all need different tweaks to the acquisition hardware.

This is not the sort of project that numerous participants will write reams for on 'Instructables'. So you will be more or less on your own.

The PN3048 software used for your picture does appear to be available, in what's described as an incomplete (no Allan Variance), buggy, no-source version for windows (a few googles will find it), which might be able to process files without needing the original GPIB instruments to run. I would personally recommend writing your own in python/scipy/matplotlib, you will know what you've got, be able to hook up to modern scopes and SDRs, and be in total control of it.

If you rely on PC audio hardware with a simple mixer, then you're limited to the order of 10 kHz offset, and needing sources offset by a small amount, which is not what you get with OCXOs and GPSDOs. You might want to build your own 10.01 MHz source, to mix all your inputs down to audio, if you want to go this route. With standard PC hardware, you'll only be able to compare them pair-wise, though you can get external multi-channel audio inputs.

Although they have a poor noise performance, a multi-channel oscilloscope will be fine for capturing measurements for close to carrier and long term stability work, and at least getting your feet wet further from carrier. Digitise at 40 MHz, one 10 MHz source into each channel, downconvert and compare.

Software Defined Radios (SDRs) are a relatively inexpensive and (some) open source way of getting integrated RF and high quality fast ADCs into the hands of amateurs. You will find a large community of users online, though probably few pushing the low noise envelope.

Maybe signal could be compared to 2 independent OCXO and even better measurement extracted with very simple measurement setup.

Yes, it's possible to do two reference correlation measurements, though it only works spectrally, not for time based measurements. As you do multiple averages, the device under test noise grows as power, the self noise of the references grows as sqrt(power), so you get a 1.5 dB improvement in noise floor per doubling of measurement time, which means for any practical factor, it rapidly becomes time limited. I'd leave that facility until last, it's not a panacea for noisy references or hardware.

\$\endgroup\$
2
\$\begingroup\$

I've done this with a soundcard to estimate phase noise of some cheap crystal oscillators without a low phase noise reference.

So I just took a piece of copperclad and put two identical oscillators there, each using either some AA batteries or a 18650 LiIon as power supply. LiIons are convenient, you can get 3.3V out of them. Then I used a logic gate as a mixer, also powered by its own battery. I don't remember which type of gate exactly, but pretty much any AND/NAND/NOR etc will output a "something" at the frequency difference between oscillators.

This "ghetto" setup has several issues.

The output signal is f1-f2 and the soundcard doesn't have that much bandwidth, which means it is limited to oscillators of identical frequency spec, unless you want to test VCOs or some other form of adjustable oscillators. But of course, with VCOs, they are only as good as the noise on the control pin, so that's another way to screw up the test setup, and I wanted to keep it simple.

This means f1-f2 is going to be pretty small. Additionally, the logic gate mixer generates a ton of harmonics, which means the signal between 0Hz and 2(f1-f2) is clean, but above that it's just harmonics. So it's only suitable for measuring phase noise close to carrier, or frequency drift. For this specific application, it works nicely. So it can be used to compare one pair of oscillators to another pair of oscillators, and even that can give useful information. Basically you get the leftmost portion of the phase noise graph, so at least you can see where the slope is.

But it won't give a clean, calibrated output of course, and nothing above a few hundred Hz.

Variations in phase noise and drift due to temperature are easily detected. For example, this crude setup shows that putting a ball of cotton on top of the oscillators to reduce temperature variations due to air currents works wonders on short term drift.

Measurement bandwidth (ie, f1-f2) can be extended a bit by pulling the oscillators via changing the power supply voltage (ie, using more or less charged batteries).

\$\endgroup\$
1
\$\begingroup\$

You could just use a mixer (NE602) for nearly-identical oscillators.

Use your scope to digitize the difference output (have to high-pass reject the sum).

Use the FFT behavior of the scope, to examine the spectrum of the deterministic and random noise of the jitter (phase noise).

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.