Sunday, February 19, 2017

Calibrating the Raduino

Don's discussion of the calibration problem is especially relevant for the "channelized" 60 meter band in the USA -- he has been working on a Module modified for that band.   But I think accurate calibration is also important on 40 SSB.  The vast majority of phone QSOs on 40 take place on whole integer kHz frequencies:  7164 kHz, NOT 7164.3 kHz!  If you call CQ on a non-integer frequency, people get confused and irritated. Often they will tell you that your signal is "distorted."  I have the Si5351 on my DigiTia well calibrated (thanks to Tom AK2B) and I keep the increment at 1 kHz.  This keeps people happy.   Bill N2CQR
Raduino Calibration
by  Don Cantrell, ND6T

The BITX and Raduino combination can be used as shipped without calibration as long as you do not operate right at the boundaries of the assigned frequency allocations. The old saw “Good 'nuff fer gum'mit work” applies for most use. Certainly it is more accurate (and stable) than the stuff we old geezers used “back in the day”. But what if you want all of the accuracy that the equipment is capable of producing? That digital readout is tempting.

Ashar Farhan composed a brilliant solution in his Raduino sketch. He included a software calibration that uses a push button press to enable the operator to tune a known frequency signal “by ear” to establish an offset to be applied to the VFO frequency. This puts it very close, much better than the uncalibrated result, since it accounts for both  BFO and Si5351 reference variations. There remains a small intrinsic error (insignificant in a single band application) in that the correction is frequency proportional. If you were to use the scheme for wide frequency ranges it could be a small problem.

When I converted my new BITX40 to 60m I realized that my channels were several kilohertz off frequency. In this country these channels are only 2.8 Khz wide. I couldn't even hear them. I measured the Beat Frequency Oscillator frequency at C106, the blocking capacitor to the balanced modulator/product detector, and found that it was 11.999045 MHz. Other BITXs will be significantly different since the crystals are carefully selected to match those in the crystal IF filter.

I wrote this value into my operating program file as the “BFO frequency” but found that I was still not on frequency. The only other reason for this discrepancy, aside from a math error, would be the reference oscillator for the Si5351 Phase Locked Loop.

I wrote my 60m operating system from scratch. It is simple since I am a novice at such things. No internal calibration routine. Instead I rely upon the accuracy of the Raduino reference oscillator value.

To find what that is, without disturbing the oscillator loading with a probe, I wrote a short and simple sketch for the Raduino.

/*

 Calibration program for Raduino

 Don Cantrell,ND6T  v 1.0           7 Feb 2017

 Compiles under etherkit Si5351 library v 2.0.1

 This source file is under General Public License version 3.

 Generates the reference clock frequency so that it can be

 measured and substituted as the corrected frequency of the

 particular oscillator.

 */

#include <si5351.h>

Si5351 si5351;



void setup() {

   

    si5351.init(SI5351_CRYSTAL_LOAD_8PF,25e6L,0);

    si5351.set_pll(SI5351_PLL_FIXED, SI5351_PLLA);

    si5351.output_enable(SI5351_CLK2, 1);

    si5351.set_freq(25e8 , SI5351_CLK2);

}

void loop() {

}

The crystal frequency is assumed to be exactly 25 MHz, at least that is what the Si5351 thinks. So we ask it to generate a 25 MHz signal and then read what it actually is. Simple.

If you are comfortable with re-loading the original Raduino sketch (or whatever sketch that you have been running) and are familiar with the different versions of the libraries and procedures that are needed to do this then, and only then, you are ready to continue. If you aren't comfortable with that then stop right here! You can easily “upgrade yourself out of service” as most of us have realized, much to our chagrin. If you find yourself in that corner then you may not have anyone to rescue you.

That said, the next step is to replace the operating system with the little calibration sketch and let it run for a few minutes so that the oscillator will stabilize (it can drift 10 Hz or so while warming up). There is no display routine for the Raduino so ignore the display (I told you this was a simple program). Measure the Raduino output frequency where it feeds the “DDS1”jack at pin number 1 there on the BITX board. Record your result from the frequency counter and use that value in the setup line for the Si5351 in place of the 25000000 value. Don't forget to add the “L” (for Long integer) if the old value had it.

In the original Raduino sketch v 1.0.1 this appears at line number 589.

“ si5351.init(SI5351_CRYSTAL_LOAD_8PF,25000000l); “

Reload your revised operating sketch and enjoy. It certainly solved my problem. My 60m BITX now seems to stay within 1 Hz, or so, of where it should be (after a few minutes “warm up”, of course).

Keep this value to use whenever you use this particular reference oscillator. Your frequencies will now be as accurate as your frequency counter and component drift will allow.

de ND6T

No comments:

Post a Comment