SparkFun Forums 

Where electronics enthusiasts find answers.

Have questions about a SparkFun product or board? This is the place to be.
By eejake52
I am working on a project using a PIC 18F6621 as the core of a multi-zone, programmable thermostat. My house has a custom HVAC system, so off-the-shelf thermostats just don't work well. A description of the project (so far) is here: ... el/thermo/

I plan to use the I2C bus to talk to a DS1307 RTC and a DS2482 1 Wire master. At this point, I am stuck trying to get either the DS1307 or the DS2482 to answer on the I2C bus. I had to lower the I2C baud rate to 100 kHz because of the DS parts. I send the I2C address byte, I verify on my scope (which is just a PC based Optascope), that the SCL and SDA lines are doing what they should, but neither chip sends the ACK; instead the SDA line is released and is seen as a NACK. If any of you have any ideas, please advise.


** Update later that day **
Have you ever noticed how the time required to solve a problem is inversely proportional to the number of forums where you asked for help? I posted this message in 3 places, then within an hour I figured it out for myself.

I now have the DS1307 working. There were 2 problems:
1) The DS1307 absolutely MUST have a battery connected or else tie that pin to ground
2) The very last read of the device must be NAKed by the Master