DS3231 is an accurate I2C real-time clock. Arduinos cannot keep good time on their own, so an RTC module or Internet clock is needed for reliable timekeeping. These modules include a coin cell holder for a CR2032; the coin cell allows the unit to keep time when the Arduino is reset or otherwise loses power.
32K (32KHz square wave output)
SQW (Square wave or interrupt output)
SCL - A5
SDA - A4
VCC - 5V
GND - GND
Investigating this IC, the datasheet shows some interesting features:
- Real-Time Clock Counts Seconds, Minutes, Hours, Date of the Month, Month, Day of the Week, and Year, with Leap-Year Compensation Valid Up to 2100
- Accuracy ±2ppm from 0°C to +40°C
- Accuracy ±3.5ppm from -40°C to +85°C
- Digital temperature sensor with ±3ºC accuracy
- Two Time-of-day alarms
This is a really cool chip. My module has a 32K AT24C32 memory chip as well as a few analog pads, A0, A1, and A2. According to manufacturuer, the 24C32 addresses can be shorted A0/A1/A2 modify default address is 0x57.
Many libraries available. NeiroNx’s RTCLib provides the usual as well as a getTemp method for the DS3231 RTC object, though this is not documented in the examples.