Using RTC and Analog Pins on Arduino Uno

I've been struggling with getting my RTC readings correct and then learned that you can use A4 and A5 as SDA and SCL instead of the Uno's built in SDA and SCL pins that I have my RTC hooked up to.

Is there any way to free up those Analog pins while using an RTC or are SDA and SCL hardwired to A4 and A5?

Why give the extra SDA and SCL pins if A4 and A5 are tied up to them anyway?

Is there any way to free up those Analog pins while using an RTC or are SDA and SCL hardwired to A4 and A5?

No.
The SDA and SCL pins by pin 13 and ground are directly connected to A4 and A5. They are not separate.

Why give the extra SDA and SCL pins if A4 and A5 are tied up to them anyway?

Why is there more than one ground pin?

A very quick DMM continuity check shows that my clone UNO has the SCL/SDA points hard connected to A4 & A5, my guess as to why have both on the board? is for ease of identification or connection.

Please define "I've been struggling with getting my RTC readings correct" what is incorrect about them? why do you need to free up THOSE two pins?

Kiwi_Bloke:
Please define "I've been struggling with getting my RTC readings correct" what is incorrect about them? why do you need to free up THOSE two pins?

I would get either 2165/165/165 as the date or have no serial output at all.

My project is pretty pin-intensive so they are the only two pins I currently have free.

My next thought is to get a multiplexer and just get more pins unless someone has better advice

Now is a good time to read up on how to post code and post the entire code so we can all see what is going on. The values you are showing suggest a coding error.

Please also post a link to the RTC you are using and a wiring diagram of the whole setup.

I am learning to use RTC’s for a data logging project and found the only way to resolve issues was to just code for the RTC with Serial Print to see what was happening, once that worked I then did the same process with the LCD display and the Data logger then merged the 4 sketches together.

Hi,
Can you please post your code?

Please read the first post in any forum entitled how to use this forum.
http://forum.arduino.cc/index.php/topic,148850.0.html then look down to item #7 about how to post your code.
It will be formatted in a scrolling window that makes it easier to read.

Do you have anything other than the RTC connected to A4 and A5?

Thanks.. Tom.. :slight_smile:

Easy way to add pins is to jump up to a '1284P processor. 32 IO, two hardware serial ports, 16K SRAM.
I offer 1284P boards in a few form factors.
http://www.crossroadsfencing.com/BobuinoRev17/#ATMega1284P

Hi all,

Thanks for the advice. I do actually know how to post code. I just happened to know that wasn't the issue since I was using the RTClib example file.

I ended up freeing up pins elsewhere and not using A4 and A5