Adding real time clock information to microcontroller driven systems is problematic. As time goes by, small errors in computing routines add up. Given that users hate entering system times, a real-time element is valuable.

NXP – once Philips Semiconductors – is an old hand in the space of real time clocks, making the PCF2127 a classic. Our figure shows a basic application circuit taken from the application note.

View Datasheet

The extra battery ensures timing continuity if system power is unavailable

Let us start out with the most important question: the part is pretty accurate. The small version PCF2127AT promises a three PPM accuracy from -15 to 60°C, while the PCF2127T achieves the same from -30 to 80°C.

A question of complication! RTC ICs work with some kind of serial interface. Given that NXP developed the I2C protocol, the chip makes for a great I2C real-time clock IC. Furthermore, the chip can also work as an SPI real-time clock – the figures show two operating modes.

The PCF2127 makes for a great SPI real time clock

Can also handle the I2C protocol perfectly

In addition to providing a simple incrementing time keeper, the chip also has a calendar system. It even takes care of leap year computations, thereby allowing you to use microcontroller space for other tasks.

Finally, a timestamp function emits a periodic signal. This is useful smart meters, where periodic wake up can be handled via an interrupt generated by the real-time clock IC.

Sadly, developers who still hand-prototype the circuits won’t be happy. The IC comes in SO16 and SO20 variants, both of which are priced similarly.

Given that NXP has a long tradition of designing sensors, the Dutch could not resist adding a temperature sensor and 512 bytes of static RAM. This allows you to store a small amount of information in a remanent fashion. Finally, the chip can also supervise the battery voltage – the circuit can inform the user if the backup battery runs low.

Author: Tam Hanna
Published: March 12, 2021