Another demo for interfacing an Arduino with the DS1307 Real Time Clock. The board I used (see here) also has an integrated 24C32 32K EEPROM which we won’t worry about in this demo.
Here’s a picture of my setup:
- Arduino Uno R3
- 16×2 LCD Shield
- DS1307 board (I used this one) but you could use this one too
- CR2032 button cell
(NOTE: If you’re using the same board as me then wire to the side of the board with the pins SQ, DS, SCL, SDA, VCC, GND & BAT)
- Uno’s 5V (via LCD Shield) to RTC’s 5V
- Uno’s GND (via LCD Shield) to RTC’s GND
- Uno’s Analog Pin 4 (via LCD Shield) to RTC’s SDA
- Uno’s Analog Pin 5 (via LCD Shield) to RTC’s SCL
- Leave the other pins unconnected
- Put the button cell in!
You can find the code here. And voila! 🙂