Specialist Supplier of Crystals & Frequency Control Componentssales@mecxtal.com.cn0755-26500570
MERLIN home / Rednote / Low-Frequency Timing and System Power

Why does a PCF8523 run fast after reset with a 12.5 pF, 32.768 kHz crystal?

Read CAP_SEL before blaming startup

When replacing a 7 pF crystal with a 12.5 pF passive 32.768 kHz crystal, change the PCF8523 load setting too. CAP_SEL is bit 7 in Control_1: 0 selects 7 pF, while 1 selects 12.5 pF. Reset defaults to 7 pF. Firmware may fail to restore the bit on one boot path or overwrite it with another register write. The clock can then keep time acceptably until a complete loss of power or a software reset. A host-only reset does not prove the RTC reset; read the register.

The crystal's purchasing specification, the firmware's intended configuration and the RTC's actual state are different evidence. A stable divided output confirms oscillation but not the correct calibrated load. Save the initial register state before testing or adding capacitance. A startup routine that corrects the time immediately can erase the most useful evidence.

How to handle 7, 12.5 and 9 pF crystals

Crystal load specificationNative PCF8523 settingEngineering action
7 pFCAP_SEL=0Verify the board and startup at that setting
12.5 pFCAP_SEL=1Verify the firmware paths following RTC reset
9 pFNo corresponding settingAn intermediate value is not a drop-in option
Unclear on labelDo not select yetCheck full ordering code and manufacturer documentation

The same FC-135R family can contain different specifications

Epson lists 7 pF, 9 pF and 12.5 pF options in the FC-135R brief. They can share a 32.768 kHz marking and the same package. A family name and frequency cannot identify the load on an assembly. This is an example of reading purchase specifications, not manufacturer validation of every combination with the PCF8523. Confirm full code, ESR, drive and temperature against oscillator requirements, then check startup and timekeeping on the board.

The two settings describe the intended crystal load, not external capacitors to fit at the two oscillator pins. Nor does dividing the difference between 7 and 12.5 pF across the pins create a known intermediate load. Routing, inputs and probes affect the actual circuit. Treat a 9 pF part as a separate design change or return to a matched option.

Why can the clock run fast, but by no fixed amount?

For an ordinary parallel-load tuning-fork crystal, lower actual load capacitance than its specified load generally raises oscillation frequency, all else equal. Higher load generally pulls it lower. The direction helps troubleshooting, but the nominal capacitance difference does not give ppm or seconds per day. The crystal parameters, actual load, temperature and parasitics determine the magnitude. Do not assume separate lots or layouts exhibit the same offset.

For example, a measured +20 ppm that persists across the interval corresponds to a gain of about 1.728 seconds per day: 86,400 seconds multiplied by 20 and divided by one million. That converts a measured error; it is not a calculation from the two capacitor settings. When comparing clock outputs, verify both the selected output rate and the calibration state.

Test reset, oscillator stop and parts independently

Run three cases. First reset only the host with main and backup power normal and record whether the RTC retained CAP_SEL. Next test main-power loss with backup maintained and record the host's first actual read on recovery. Finally, on a test board, remove all power or intentionally issue the documented RTC software reset. Read the default before confirming that initialization restored the correct setting. Separate the interval the RTC actually counted from when the product reset the time.

Do not overwrite unrelated control bits

Update Control_1 according to its register rules so changing CAP_SEL does not inadvertently change STOP, hour format or interrupt configuration. If initialization writes an entire defined configuration, read it back and record the result. Also check the oscillator-stop status; a readable old time is not proof of continuous timekeeping. Measure sustained error, not whether one read hit a second boundary.

Prefer a configured buffered clock output or an elapsed-time comparison using a traceable reference. An ordinary scope probe across the crystal pins can change the load. Record the counter reference, gate time and connection if using a frequency counter. With software time comparisons, record the full observation duration and beginning and ending references. An online log can miss an outage and subsequent restoration. Keeping both kinds of evidence helps separate drift and time reinitialization.

Give purchasing and firmware a shared acceptance rule

Specify 32.768 kHz, the exact load, full manufacturer code and which board revision takes it. For firmware, record the CAP_SEL mapping, when the default might return and which code sets and verifies it. Link the two records by board reference designator. A mechanically identical part still needs a load check. For upgrades in the field, do not hard-code a common setting across hardware lots with different loads unless they can be identified reliably.

Software offset can make a mismatched assembly appear accurate for a while. It does not prove the load was corrected or that low-voltage and cold startup have adequate margin. Match the setting and validate oscillation and retention first; then consider any frequency trim. The combination of cold-start readback and measured time error is more informative than simply checking the time displayed after startup.

For a first article, use two documented board revisions to check 7 pF and 12.5 pF in the same stable-temperature environment. Change one variable at a time and keep the measurement interval and trim constant. Save correct-setting records first, then reproduce the mismatch on a designated test unit and verify that register and frequency evidence reveal it. Do not write unknown states to customer units or overwrite earlier records with a later trim. If the matched setup still drifts, check the actual part number, flux residue and leakage around the crystal. Finish by restoring and retesting the correct configuration.

WeChat

MERLIN · TIMING COMPONENTS

Scan with WeChat to contact Sales

Add our WeCom contacts from your usual WeChat app.

On desktop, scan with your phone. On mobile, save the QR image and select it from your album in WeChat Scan.