Calibration of the Si570 Via WWV/WWVHbroadcast power of 10 KW, it has been estimated that their...

10
Calibration of the Si570 Via WWV/WWVH ©2014, Mac A. Cody, AE5PH Introduction The Silicon Labs Si570 Programmable Crystal Oscillator (XO)[1] has proven to be a very capable and reasonably priced variable frequency oscillator (VFO) for amateur radio low-power (QRP) and software-defined radio (SDR) applications. Various versions of the device are specified to operate from 10 MHz to 1.4 GHz, with frequency programming resolution below 0.1 parts per billion (ppb), total phase jitter better than 1 picosecond, and total stability (accuracy, aging, and temperature) of well below 100 parts per million (ppm) over a twenty-year operational life. The CMOS variant of the Si570 (570CAC), most often used by amateur radio home brewers, can be obtained for less than twenty dollars (U.S.) in single-piece quantities. Exploiting the excellent performance of the Si570 is achieved by properly programming the internal registers of the device to cause it to generate the desired clock frequency. This requires knowledge of the internal crystal frequency of the device. Given that the crystal's frequency can have a maximum variation of 2000 ppm from the nominal value of 114.285 MHz, it is necessary to derive that value as accurately as possible. The common approach is to calculate the value based on the Si570's start up frequency and corresponding register settings. These register settings, programmed into each device at the Silicon Labs factory, are unique and are as accurate as possible, based upon the measurement equipment used at the factory. According to the Si570 datasheet, though, the initial accuracy is typically 1.5 ppm. Component aging will contribute a maximum frequency drift of ±3 ppm over the first year and a maximum of ±10 ppm over a 20-year life. Temperature stability for the Si570CAC contributes ±50 ppm to the total device stability. Consequently, component aging and ambient temperature will cause the actual start-up frequency to deviate a small amount from that specified. Therefore, some form of compensation is necessary to achieve more accurate frequency generation. The purpose of this paper is to present a method to compensate for an Si570's internal crystal frequency using the radio transmissions of the time service radio stations WWV or WWVH. These stations provide very accurate reference transmissions (less than one part in 10 -12 )[2]. The schematic for a simple direct conversion (DC) receiver and the procedure used to determine the amount of frequency compensation will be described. An example application will be presented using an Si570 interfaced to a Radiono [3,4], an Arduino-based controller board designed for radio applications. The Arduino sketch for controlling the Si570 will be provided. Theory The end goal of receiving a radio signal is the conversion of the signal, modulated at the transmission frequency, into a signal at a frequency where it can be appropriately interpreted. In the case of audio transmissions, the signal is converted so that a human listener can hear it, which is known as the baseband audio frequency range (typically 100 Hz – 18,000 Hz). A direct conversion (DC) receiver accomplishes this by mixing the transmitted signal with a local oscillator (LO) possessing a frequency (f LO ) equal to the carrier frequency (f C ) of the modulated signal. The difference frequency obtained from the mixing operation places the center frequency of the modulated signal at zero Hertz. Although a summed frequency component of the mixing operation is also generated (at two times f C ), it will be ignored for the remainder of this discussion. If the transmitted signal employs amplitude modulation (AM), the double sideband modulation envelope, centered on the transmission frequency f C , is shifted down so that the sidebands are

Transcript of Calibration of the Si570 Via WWV/WWVHbroadcast power of 10 KW, it has been estimated that their...

Page 1: Calibration of the Si570 Via WWV/WWVHbroadcast power of 10 KW, it has been estimated that their signals can be received essentially world wide. Reports of reception of WWV and WWVH

Calibration of the Si570 Via WWV/WWVH

©2014, Mac A. Cody, AE5PH

IntroductionThe Silicon Labs Si570 Programmable Crystal Oscillator (XO)[1] has proven to be a very capable and reasonably priced variable frequency oscillator (VFO) for amateur radio low-power (QRP) and software-defined radio (SDR) applications. Various versions of the device are specified to operate from 10 MHz to 1.4 GHz, with frequency programming resolution below 0.1 parts per billion (ppb),total phase jitter better than 1 picosecond, and total stability (accuracy, aging, and temperature) of well below 100 parts per million (ppm) over a twenty-year operational life. The CMOS variant of the Si570 (570CAC), most often used by amateur radio home brewers, can be obtained for less thantwenty dollars (U.S.) in single-piece quantities.

Exploiting the excellent performance of the Si570 is achieved by properly programming the internalregisters of the device to cause it to generate the desired clock frequency. This requires knowledge of the internal crystal frequency of the device. Given that the crystal's frequency can have a maximum variation of 2000 ppm from the nominal value of 114.285 MHz, it is necessary to derive that value as accurately as possible. The common approach is to calculate the value based on the Si570's start up frequency and corresponding register settings. These register settings, programmed into each device at the Silicon Labs factory, are unique and are as accurate as possible, based upon the measurement equipment used at the factory. According to the Si570 datasheet, though, the initialaccuracy is typically 1.5 ppm. Component aging will contribute a maximum frequency drift of ±3 ppm over the first year and a maximum of ±10 ppm over a 20-year life. Temperature stability for the Si570CAC contributes ±50 ppm to the total device stability. Consequently, component aging and ambient temperature will cause the actual start-up frequency to deviate a small amount from that specified. Therefore, some form of compensation is necessary to achieve more accurate frequency generation.

The purpose of this paper is to present a method to compensate for an Si570's internal crystal frequency using the radio transmissions of the time service radio stations WWV or WWVH. These stations provide very accurate reference transmissions (less than one part in 10-12)[2]. The schematicfor a simple direct conversion (DC) receiver and the procedure used to determine the amount of frequency compensation will be described. An example application will be presented using an Si570interfaced to a Radiono [3,4], an Arduino-based controller board designed for radio applications. The Arduino sketch for controlling the Si570 will be provided.

TheoryThe end goal of receiving a radio signal is the conversion of the signal, modulated at the transmission frequency, into a signal at a frequency where it can be appropriately interpreted. In the case of audio transmissions, the signal is converted so that a human listener can hear it, which is known as the baseband audio frequency range (typically 100 Hz – 18,000 Hz). A direct conversion (DC) receiver accomplishes this by mixing the transmitted signal with a local oscillator (LO) possessing a frequency (fLO) equal to the carrier frequency (fC) of the modulated signal. The difference frequency obtained from the mixing operation places the center frequency of the modulated signal at zero Hertz. Although a summed frequency component of the mixing operation is also generated (at two times fC), it will be ignored for the remainder of this discussion.

If the transmitted signal employs amplitude modulation (AM), the double sideband modulation envelope, centered on the transmission frequency fC, is shifted down so that the sidebands are

Page 2: Calibration of the Si570 Via WWV/WWVHbroadcast power of 10 KW, it has been estimated that their signals can be received essentially world wide. Reports of reception of WWV and WWVH

centered around zero Hertz. The sideband that is shifted to negative frequencies is mirrored to form positive frequencies. Ideally, the sidebands combine to form an audio signal identical to what was originally modulated, barring distortions added by the transmission channel, as shown in Illustration1a. If fLO is not identical to fC, the sidebands will be offset from zero Hertz and will not combine properly. The frequencies of one sideband will be shifted below what is nominal, while frequencies of the other sideband will be shifted above what is nominal, as shown in Illustration 1b. Depending upon the difference between fLO and fC, the resulting audio sound can be described as 'warbling' slowly or sounding 'raspy'.

A pure tone ft will be perceived as two tones at frequencies abs(fC – fLO–ft) and abs(fC – fLO+ft), i.e. offset from the frequency of the original tone by ±(fC – fLO), as shown in Illustration 2.

Illustration 1: Sideband frequency mirroring of amplitude modulated signal when the local oscillator frequency (fLO) and carrier frequency (fC) are (a) equal and (b) different.

Illustration 2: Sideband frequency mirroring of an amplitude modulated tone when the local oscillator frequency (fLO) and carrier frequency (fC) are (a) equal and (b) different.

Page 3: Calibration of the Si570 Via WWV/WWVHbroadcast power of 10 KW, it has been estimated that their signals can be received essentially world wide. Reports of reception of WWV and WWVH

Assume that fC is known to be very accurate and any pure tones ft modulated by fC are also known to be very accurate. It is then possible to determine the deviation between fC and fLO. This is done bycalculating the difference in frequency between each offset tone and the frequency of the pure tone. Due to the identical frequency content of the upper and lower sidebands, there will be ambiguity in the sign of the difference between fC and fLO. In other words, it will not be possible to discern whether fLO is offset from fC in either a positive or negative direction.

Utilizing WWV/WWVH and AlternativesAs mentioned in the Introduction, the transmission frequencies of of WWV and WWVH are accurate to better than one part in 10-12. This is due to their calibration against atomic clocks. The audio tones that are transmitted as part of the WWV/WWVH broadcast format are similarly accurate[Error: Reference source not found]. Dynamic ionospheric conditions at HF frequencies result in variations in signal propagation that degrade the quality of the transmitted signal and the accuracy of time measurements. Accuracy on the order of one part in 10-7 (1 Hertz at 10 MHz) can be expected[5].

With the placement of the broadcast antennas of WWV in Colorado and WWVH in Hawaii, and thebroadcast power of 10 KW, it has been estimated that their signals can be received essentially worldwide. Reports of reception of WWV and WWVH around the world have been reported. It is acknowledged, though, that the variablilities of shortwave band radio propagation can make signal reception problematic.

Fortunately, there are other radio stations around the world that provide time services with similar accuracies in transmission frequency and signal content. A partial list of stations, along with the accuracy of their transmission frequencies, is presented in Table 1.[6] Whether using WWV, WWVH, or an alternative source, it is possible to use time station radio transmissions to improve the frequency accuracy of an Si570 through calibration.

Table 1: Time service radio stations, their locations, frequencies, and performance.

Station Location Transmission Frequencies Accuracy

BPM Pucheng County, Shaanxi, China 2.5 MHz, 5 MHz, 10 MHz, 15 MHz Δf/f < 1 x 10-12

CHU Ottawa, Canada 3330 kHz, 7335 kHz, 14670 kHz Δf/f < 5 x 10-12

HLA Taejon, Korea 5 MHz Δf/f < 2 x 10-12

RWM Moskva, Russia 4.996 MHz, 9.996 MHz, 14.996 MHz Δf/f < 5 x 10-12

WWV Ft. Collins, Colorado, USA 2.5 MHz, 5 MHz, 10 MHz, 15 MHz Δf/f < 1 x 10-12

WWVH Kekaha, Hawaii, USA 2.5 MHz, 5 MHz, 10 MHz, 15 MHz Δf/f < 1 x 10-12

Time service station frequencies compatible with the WWV calibration receiver are emboldened.

A WWV 10 MHz Calibration RecieverAs mentioned in the Theory section, a DC receiver can be used to demodulate AM radio transmissions, such as those transmitted by WWV/WWVH and other time service radio stations. A basic DC receiver is probably one of the simplest receivers to construct and get to work, short of a crystal radio, especially if integrated circuit components are used. A schematic for a DC receiver for10 MHz WWV calibration is shown in Illustration 3. This design is a modification of one developedby Steve Weber, KD1JV (see http://kd1jv.qrpradio.com/WWVRX/WWV%20receiver.htm).

In this circuit, the Si570 provides the LO and is the local time base. The 10.7 IF transformers are adjusted to maximize RF input to the SA612. If necessary, they can be 'detuned' to attenuate the signal and prevent overdriving the LM386 or the input of a connected recording device.

Page 4: Calibration of the Si570 Via WWV/WWVHbroadcast power of 10 KW, it has been estimated that their signals can be received essentially world wide. Reports of reception of WWV and WWVH

Construction of this receiver is not critical. A printed circuit board is not needed. 'Ugly' style or Manhattan construction techniques are sufficient. An example implementationof the WWV Calibration Receiver, using the Manhattan construction technique, is shown in Illustration 4. The circuit has been placed in a ubiquitous Altoids® tin. BNC connectors allow connection to a long-wire antenna and the Si570 LO signal. Audio output is through an 3.5 mm stereo headphone jack. The receiver is powered with a nine-volt battery.

Illustration 4: WWV Calibration Receiver, assembled using the Manhattan construction technique and placed inside an Altoids® tin.

Illustration 3: Schematic of the WWV Calibration Receiver.

Page 5: Calibration of the Si570 Via WWV/WWVHbroadcast power of 10 KW, it has been estimated that their signals can be received essentially world wide. Reports of reception of WWV and WWVH

Calibration ProcedureThe following steps are performed to calibrate an Si570.

1. Prepare the Arduino calibration sketch by editing the following macros:

1. SI570_STARTUP_FREQUENCY lists the startup frequency of the Si570 in Hertz.

2. STATION_FREQUENCY lists the frequency of the time service radio station in Hertz.

3. PPTM_CORRECTION should set to zero.

2. Compile the sketch and load it into the Radiono.

3. Prepare the calibration test setup by first connect the output of the Si570 to the LO input of the WWV receiver. Second, connect the 12 Volt power supply to the Radiono, but do not turn it on yet. Third, connect an antenna to the RF input of the WWV receiver. Connect the audio output of the WWV receiver to the audio input of the computer, tablet, or smart phonethat will be running the audio spectrum analyzer software. The test setup should appear as shown in Illustration 5.

4. Apply power to the WWV receiver and the Radiono. Ensure that the time service radio station is being received. If necessary, temporarily connect the audio output of the WWV receiver to a pair of headphones to enable monitoring of the received signal. Let the test setup warm up for at least one hour prior to taking measurements. Doing this will allow the temperature of the Si570 to stabilize.

5. Start the audio spectrum analyzer software and determine the frequency of the 'seconds' tonefor each sideband. It is recommended that the spectrum analyzer software be set up such thatsampling rate and FFT size yeild a frequency bin spacing of less than one Hertz. It is expected that the frequecy initially generated will offset some number of Hertz from the WWV transmit frequency (10 MHz). Consequently, the spectrum display may be difficult tointerpret. The spectrum analyzer should display something similar to what is shown in the

Illustration 5: Si570 calibration setup using a smart phone with audio spectrum analyzer software to monitor the WWV time standard signal.

Page 6: Calibration of the Si570 Via WWV/WWVHbroadcast power of 10 KW, it has been estimated that their signals can be received essentially world wide. Reports of reception of WWV and WWVH

two spectrums displayed in Illustration 6. The top spectrum is what should occur with a 500 Hz 'seconds' tone. There two spectral peaks equally distant from the nominal frequency of 500 Hz. The bottom spectrum is what should occur with a 600 Hz 'seconds' tone. There two spectral peaks equally distant from the nominal frequency of 600 Hz. Note that the large spectral peak close to zero Hertz is the WWV AM carrier. The reduced peak near 200 Hz is the 100 Hz subcarrier for the WWV digital time code.

6. Determine the parts per ten million (pptm) frequency offset by finding the difference in frequency of each sideband's 'seconds' tone from the nominal tone frequency. Using the spectrum shown in Illustration 6, the offsets for the 500 Hz tone are 77.97 Hz (500 – 422.03)and 78.29 Hz (578.29 – 500). The offsets for the 600 Hz tone are 76.72 Hz (600 – 523.28) and 76.2 Hz (676.2 – 600). The average frequency offset is calculated to be 77.295 Hz [(77.97+78.29+76.72+76.2)/4]. This value is rounded to 77 Hz.

7. Change the value of the macro PPTM_CORRECTION in the Arduino sketch to state the estimated pptm value. Note that due to frequency ambiguity, the value may be either positive or negative. Both positive and negative values will have to tried. For example, usingthe values calculated above, the PPTM_CORRECTION value will be either -77 or 77.

8. Remove the Radiono from the test setup, recompile and load the modified sketch into the

Illustration 6: Initial measurement of WWV time standard signals with sidebands of the 500 Hz (top) and 600 Hz (bottom) 'seconds' tones offset from nominal.

Page 7: Calibration of the Si570 Via WWV/WWVHbroadcast power of 10 KW, it has been estimated that their signals can be received essentially world wide. Reports of reception of WWV and WWVH

Radiono, and reconnect it into the test setup.

9. Apply power to the Radiono as before and allow it to warm up again for at least one hour.

10. Using the audio spectrum analyzer software, to determine whether the correction value (bothmagnitude and sign) cause the frequencies of the 'seconds' tone to be at their nominal values.When the correction value's magnitude and sign are correct, the spectrum analyzer should display something similar to what is shown in the two spectrums displayed in Illustration 7. Note that the AM carrier is no longer visible and the subcarrier of the WV digitial time code is at 100 Hz.

11. If the correction does not result in the frequency of each sideband's 'seconds' tone to be at their nominal frequencies, repeat steps 7 through 10 with the sign changed for the PPTM_CORRECTION value. If this does not correct the frequencies, repeat the calibration procedure from the beginning, as the magnitude of the correction value is incorrect.

Illustration 7: Final measurement of WWV time standard signals with sidebands of the 500 Hz (top) and 600 Hz (bottom) 'seconds' tones close to nominal.

Page 8: Calibration of the Si570 Via WWV/WWVHbroadcast power of 10 KW, it has been estimated that their signals can be received essentially world wide. Reports of reception of WWV and WWVH

References1. Si570/Si571 10 MHz to 1.4 GHz I2C P rogrammable XO/VCXO, Rev. 1.4 4/13, Copyright ©

2013, Silicon Labs.2. Nelson, Glenn K., Michael A. Lombardi, and Dean T. Okayama, NIST Time and Frequency

Radio Stations: WWV, WWVH, and WWVB, NIST Special Publication 250-67, January 2005,Time and Frequency Division, Physics Laboratory, National Institute of Standards and Technology.

3. Radiono, http://www.hfsignals.org/index.php/Radiono.4. Minima - Arduino, http://www.hfsignals.org/index.php/Minima#Arduino.5. Lombardi, Michael A., NIST Time and Frequency Services, NIST Special Publication 432,

2002 Edition, National Institute of Standards and Technology.6. Time Signals, BIPM Annual Report on Time Activities, Volumn 8, 2013, Bureau International

des Poids et Mesures (BIPM).

Page 9: Calibration of the Si570 Via WWV/WWVHbroadcast power of 10 KW, it has been estimated that their signals can be received essentially world wide. Reports of reception of WWV and WWVH

Appendix A – Time Calibration Arduino SketchThis sketch is used to calibrate the frequency offset, in parts per million of a Silicon Labs Si570 device using signals received from a time service radio station, such as WWV. The frequency generated by an Si570 will not exactly match the frequency requested, due to component aging and temperature. The calibration method is to set the frequency of the Si570 being tested to the frequency of a time service radio station and feed the audio output into an audio spectrum display program running of a computer, tablet, or smart phone. The frequency analysis analysis software is used to determine the difference between the frequency generated by the Si570 and the carrier frequency of the time service radio station. This is done by measuring the frequency offset of the sideband images of the timing tones broadcast by the time service radio station and their nominal values (e.g. WWV/WWVH: 500 and 600 Hz 'seconds' tones). The measured frequency offset is converted to a ppm error value that is used to update the PPM_CORRECTION macro defined below. Frequency ambiguity in the sidebands requires that both a positive and negative ppm corrections be tried. Note that the Si570 should be run for at least one hour to achieve some measure of thermal equilibrium prior to estimating frequency offsets./* * Wire is only used from the Si570 module but we need to list it here so that * the Arduino environment knows we need it. */#include <Wire.h>#include <LiquidCrystal.h>

#include <avr/io.h>#include <stdlib.h>#include <math.h>#include "Si570.h"

/* The 16x2 LCD is connected as follows:    LCD's PIN   Raduino's PIN  PURPOSE      ATMEGA328's PIN    4           13             Reset LCD    19    6           12             Enable       18    11          10             D4           17    12          11             D5           16    13           9             D6           15    14           8             D7           14*/LiquidCrystal lcd(13, 12, 11, 10, 9, 8);

// Most Si570 come from the factory programmed with the following I2C// address.  Change it if the device has a different I2C address.#define SI570_I2C_ADDRESS 0x55

// Set the startup frequency below according to the a factory­supplied value.// Most Si570 devices used by hams have the following startup frequency in Hz,// e.g. #define SI570_STARTUP_FREQUENCY 56320000L// Some Si570 devices can have a startup frequency matching that of a time// standards station, e.g. #define SI570_STARTUP_FREQUENCY 10000000L#define SI570_STARTUP_FREQUENCY 10000000L

// This is the time service station frequency in Hz, (e.g. BPM, WWV, WWVH)#define STATION_FREQUENCY 10000000L

// The parts per ten million (pptm) correction value is initially unknown,// so set it to zero.  Once it is measured, the value can be changed.//#define PPTM_CORRECTION 0L#define PPTM_CORRECTION 77L

void setup() {  char c[20];  Si570 *vfo;  uint8_t hs_reg_value;  uint8_t n_reg_value;  uint64_t refFrequencyUint64;  uint64_t newFrequencyUint64;  

Page 10: Calibration of the Si570 Via WWV/WWVHbroadcast power of 10 KW, it has been estimated that their signals can be received essentially world wide. Reports of reception of WWV and WWVH

  // Initialize the LCD.  lcd.begin(16, 2);  lcd.clear();  lcd.setCursor(0, 0);  lcd.print("Si570 Calibrate");  lcd.setCursor(0, 1);  sprintf(c, "Startup %ld", SI570_STARTUP_FREQUENCY);  lcd.print(c);  delay(5000); // Adjust time delay as desired.

  // The library automatically reads the factory calibration settings of  // the Si570 but it needs to know what frequency it was calibrated for.  // If yours was calibrated for another frequency, you need to change  // that at the #define statement at the top of this sketch.  vfo = new Si570(SI570_I2C_ADDRESS, SI570_STARTUP_FREQUENCY);

  if (vfo­>status == SI570_ERROR) {    // The Si570 is unreachable. Show an error and return.    lcd.clear();    lcd.setCursor(0, 0);    lcd.print("Si570 comm error");    return;  }

  // Obtain the HSDEV, N1, and RFREQ values  hs_reg_value = vfo­>getHsDiv();  n_reg_value = vfo­>getN1();  refFrequencyUint64 = vfo­>getRfReq();  // Display the HSDEV, N1, and RFREQ values.  lcd.clear();  sprintf(c, "HS: %d  N1: %d", hs_reg_value, n_reg_value);  lcd.setCursor(0, 0);  lcd.print(c);  sprintf(c, "RFREQ:%lX%lX", (unsigned long) (refFrequencyUint64 >> 32), \    (unsigned long) (refFrequencyUint64 & 0x00000000ffffffff));  lcd.setCursor(0, 1);  lcd.print(c);  delay(5000); // Adjust time delay as desired.

  newFrequencyUint64 = STATION_FREQUENCY + \    ((STATION_FREQUENCY * PPTM_CORRECTION) / 10000000L);

  // Change to the time standards station frequency, if necessary.  if (SI570_STARTUP_FREQUENCY != newFrequencyUint64) {    vfo­>setFrequency(newFrequencyUint64);  }

  lcd.clear();  lcd.setCursor(0, 0);  lcd.print("Time Srv Station");  lcd.setCursor(4, 1);  sprintf(c, "%ld", newFrequencyUint64);  lcd.print(c);  delay(5000); // Adjust time delay as desired.

  // Obtain the new HSDEV, N1, and RFREQ values  hs_reg_value = vfo­>getHsDiv();  n_reg_value = vfo­>getN1();  refFrequencyUint64 = vfo­>getRfReq();  // Display the new HSDEV, N1, and RFREQ values.  lcd.clear();  sprintf(c, "HS: %d  N1: %d", hs_reg_value, n_reg_value);  lcd.setCursor(0, 0);  lcd.print(c);  sprintf(c, "RFREQ:%lX%lX", (unsigned long) (refFrequencyUint64 >> 32), \    (unsigned long) (refFrequencyUint64 & 0x00000000ffffffff));  lcd.setCursor(0, 1);  lcd.print(c);}

void loop(){}