Notes About Working with Various Arduino & Netduino Microcontroller Boards

Thursday, December 27, 2012

Sparkfun DeadOn RTC DS3234 Breakout & Arduino Due

The DeadOn real-time clock on a breakout board from Sparkfun connects to the Arduino using SPI (rather than I2C like the Chronodot).  If you look at the documentation for the SPI library on the Arduino site, it talks in the "Connections" section about using the ICSP pins. On the Arduino Due, though, you need to use the SPI header (with the SPI label).

Here is the layout of the SPI header:

(1)  MISO      (2)  +Vcc
(3)  SCK/CLK   (4)  MOSI
(5)  RESET/RST (6)  GND

Using the correct header for the SPI connections, the sample Arduino code for the DeadOn RTC works just fine. If you connect to the ICSP pins the way the Arduino SPI documentation might lead you to believe, the sample sketch runs but the date and time are nonsense (and the time does not increase as the sketch runs). Of course, this is not a surprise, since you've connected to the wrong pins.

When using SPI, be sure to use the VCC and GND power connections on the SPI header, not the "regular" 3V3 and GND pins.

The Sparkfun DeadOn RTC and breakout definitely is an easier fit on a breadboard than the Chronodot from Adafruit. 

1 comment:

  1. Every person has the passion in any aspects or things.
    If you love something and it came in front of you it completes your day and your mood turns into something you won't expected.
    I love your work and I want to read more about it. Visit my site if you have time . Thank you.