EYE on NPI - Analog Devices / Maxim MAX31329 Real-Time Clock (RTC) #EYEonNPI @ADI_News @digikey
Channel: Adafruit Industries
Date: 2022-05-26

This week's EYE ON NPI is right on time with the MAX31329 Low Current Real-Time Clock RTC (https://www.digikey.com/en/product-highlight/a/analog-devices/max31329-low-current-real-time-clock), which will fit wonderfully into your power, board size and materials budget no matter how small. We are digging this fully-integrated RTC, with a lot of li'l extras that make it an excellent choice for compact products.

A Real Time Clock a.k.a. RTC (https://en.wikipedia.org/wiki/Real-time_clock) is a specialty chip that is designed to be ultra low power, so even when everything else in the circuit is turned off, it can still sip power from a super capacitor or tiny battery and keep track of time. It's how your computer and devices can go all the way down to 0% power and yet still know what time it is when recharged/re-powered. Note this is different than storage memory because details like your WiFi password don't need updating every second whereas an RTC has to keep ticking second after second until main power comes back up. Just about everything you own has an RTC in it because timekeeping is so essential to functionality.

There are some chips that have built in RTCs but often these are just counters and are not as low power as a true RTC chip. The MAX31329 for example, has a "240nA Timekeeping Current", whereas only the most power-optimized microcontrollers can get below 1uA. Compare it to the DS1307 which has twice the current, ~500nA! With such low currents, you can even use a super cap (https://www.digikey.com/en/products/detail/elna-america/DSK-3R3H703T414-HRL/2171199) instead of a lithium battery to keep time, meaning no special shipping management or battery replacements. Wondering how big a capacitor you'd need? Maxim's got ya covered with their handy super-cap calculator (https://www.maximintegrated.com/en/design/design-tools/calculators/product-design-calculators/supercap.html)

OK, so it's low power. What else is so great about it? We also really like that the crystal is in-package integrated! Every RTC needs a crystal oscillator, the thing that actually does the counting of time. The crystals are almost always 32.768KHz crystals (https://www.digikey.com/en/products/detail/abracon-llc/ABS25-32-768KHZ-T/675361?s=N4IgTCBcDaIIYCMBOcDGB7AdgAgIICEBlMAVgFoBmMAOgHYA2ADgGkAJALTIBUQBdAXyA) so the chips count the vibrations into a 16-bit counter. When the counter overflows, a second has passed. Often the crystal is the same size as the chip, or if it's integrated, the chip is pretty large. like in the case of the DS3231.(https://www.adafruit.com/product/3013) In this case, we keep the nice smol size. A nice side effect of having a crystal integrated is improved tuning! Having a precise crystal, say +-5ppm like the Citizen CM315D32768 (https://www.digikey.com/en/products/detail/citizen-finedevice-co-ltd/CM315D32768HZFT/5970266) adds another 50 cents to the bill of materials. Not needed here, it's inside and tuned to that fancy 5ppm. Ideally they'd have a temperature-compensated version in the future, since that can get the precision down to 2ppm but 5ppm is still four times better than most low cost 32khz crystals.

Finally, a few small but kind details we caught in the datasheet (https://www.maximintegrated.com/en/products/analog/MAX31329.html): the RTC is 1.6V thru 5V logic friendly, so you can use it with any kit you've got. There's 64 bytes of battery-backed SRAM. I2C has a timeout feature in case of I2C bus jitters which happen at low power dips. Automatic power-switchover to battery when main power droops. Trickle charging with built-in diode and various internal resistors. External clock source select, such as GPS 1pps or line power 50/60hz.

This is a nice RTC, at a nice price, and you can book your order for the Maxim MAX31329 at Digi-Key right now (https://www.digikey.com/short/vqrcfdw3) for shipment the moment they come in stock. According to the lead time estimates, this part will be shipping in about 3 weeks / mid-June so you can start designing it into your PCB and chips will come in right when the prototype PCB is complete. While you're waiting you can also pick up one of the MAX31329 shield evaluation boards (https://www.digikey.com/short/ztdw8wfj) which can be plugged into any Arduino-Uno-like microcontroller and also comes with a development board if you just want to use the built in firmware/software.