Adafruit PCF8523 Shield

Overview

The Adafruit PCF8523 Real Time Clock Shield features an NXP PCF8523 Real-Time clock and two Qwiic connectors. It has a CR1220 3 Volt back-up coin-cell battery.

Adafruit PCF8523 Shield

Adafruit PCF8523 Shield (Credit: Adafruit)

Requirements

This shield can be used with boards which provide an I2C connector, for example STEMMA QT or Qwiic connectors. The target board must define a zephyr_i2c node label. See Shields for more details.

Pin Assignments

Shield Pin

Function

SDA

PCF8523 I2C SDA. Also connected to the Qwiic connector.

SCL

PCF8523 I2C SCL. Also connected to the Qwiic connector.

SQW

PCF8523 INT/CLK interrupt output or square wave output

To use the interrupt output from the PCF8523, you need to connect a wire from the shield SQW output to a suitable GPIO on your microcontroller board, and to modify the devicetree settings. See nxp,pcf8523 for options.

Programming

Set --shield adafruit_pcf8523 when you invoke west build. For example when running the Real-Time Clock (RTC) sample:

# From the root of the zephyr repository
west build -b adafruit_qt_py_rp2040 --shield adafruit_pcf8523 samples/drivers/rtc