cancel
Showing results for 
Search instead for 
Did you mean: 

RTC Temperature Calibration -- 20ppm all temperatures feasible?

chostetler
Associate II

Good morning,
I'm developing a device with these requirements:

  • STM32F446RET6
  • No internet (NTP) or GPS connection
  • Real-Time clock, set manually (so, the less often a user has to set it, the better)
  • Outdoor -20°C~70°C temperature range (most installations in continental USA)

Ideally, we would like to get our total clock drift under 10 minutes/year (20 ppm) if possible.

I created one prototype using an Abracon 32.768kHz crystal for the LSE, with two C0G 6pF load capacitors. To test the prototype, I routed the LSE to the MCO1 and measured the clock frequency as we swept the temperature from -20°C to 70°C in our temperature chamber. I measured that and compared the ppm deviation to the expected deviation given by abracon (ppm = (T-25°C)^2 * (-0.035ppm)):

Time [wall clock time] Ambient Temperature [°C] measured MCO frequency [kHz] ppm deviation Predicted deviation (per abracon datasheet equation)
10:10 -20.9 32.76681 -36.3 -73.74
10:13 -20.6 32.76672 -39.1 -72.78
10:24 -11.9 32.76712 -26.9 -47.66
10:34 -3.9 32.76750 -15.3 -29.23
10:45 4.2 32.76785 -4.6 -15.14
10:56 12.6 32.76809 2.7 -5.38
11:06 19.8 32.76818 5.5 -0.95
11:17 28.5 32.76820 6.1 -0.43
11:28 36.2 32.76810 3.1 -4.39
11:38 44.1 32.76785 -4.6 -12.77
11:49 52.2 32.76750 -15.3 -25.89
12:02 62.3 32.76685 -35.1 -48.70
12:14 70.5 32.76620 -54.9 -72.46
12:25 70.1 32.76598 -61.6 -71.19
12:54 70 32.76590 -64.1

-70.88

So, my next steps that I was planning was to:

  1. Test various load capacitances to try to bring the room-temperature error as close to 0ppm as possible
  2. Use software calibration to modify `CALP` and `CALM` on-the-fly according to the ADC temperature, to counteract (1) the room-temperature ppm offset of the crystal and (2) the offset incurred by high and low temperatures (abracon equation).

However after doing some research, I'm a bit less confident about my approach

  • The temperature slope I measured was different from the one given by the Abracon datasheet
  • The measurement period for the RTC after calibration (32 seconds) is very wide, and I'm unsure if our equipment is suited for it
  • I don't know how I will tune each device if the temperature slope differs for every crystal.

Is it feasible to tune a RTC like this to achieve 20ppm accuracy over a wide range of temperatures using only software? Or am I better off getting something like a temperature-controlled oscillator?

Thanks!

 

1 ACCEPTED SOLUTION

Accepted Solutions
TDK
Super User

From the crystal datasheet, the range in accuracy varies by more than 20ppm over the 20-70 temperature range. Note the delta from the blue and yellow lines.

So that's not a viable solution unless you have the tools and time to calibrate each crystal independently.

TDK_0-1769005872772.png

You're better off with a TCXO.

If you feel a post has answered your question, please click "Accept as Solution".

View solution in original post

4 REPLIES 4
TDK
Super User

From the crystal datasheet, the range in accuracy varies by more than 20ppm over the 20-70 temperature range. Note the delta from the blue and yellow lines.

So that's not a viable solution unless you have the tools and time to calibrate each crystal independently.

TDK_0-1769005872772.png

You're better off with a TCXO.

If you feel a post has answered your question, please click "Accept as Solution".
Ozone
Principal III

In commercial RF transceivers, they used to keep the oscillator section at a constant temperature for this purpose.
And for the ease of control, this was usually a temperature at the higher end of the ambient spectrum.

Ah, yep. That's a good point, I should have noticed that.

In general, is this a viable strategy, assuming a wider ppm accuracy is acceptable?

Thanks

It's an okay strategy if the temperature is stable. It's not going to give you the accuracy of a TXCO though.

Your code will be more complicated, and you will use more power, it will be less accurate (compared to TXCO), but it will be cheaper in parts cost.

If you feel a post has answered your question, please click "Accept as Solution".