I2C - Chip not responding

I have an I2C bus with a PIC6621 master and a 24LC512 EEPROM slave. It is working. I am trying to add a DS1307 and a DS2482 to the I2C bus, but I can't get any response from either of the latter. I can see the SCL and SDA lines on my Optascope (and admittedly, the Optascope just barely has the power to see a

100 kHz signal). When I send the I2C address, I can verify the 8 bit pattern of SDA, but when the slave is supposed to send an ACK by holding SDA low, all I see is a high NACK pulse instead. It appears that the slave is not responding, or choosing to send a NACK. I have verified the addressing of the DS1307 (0xD0) and the DS2482 (0x30), so I'm stuck. Any suggestions are welcome.
Reply to
Gavin Jacobs
Loading thread data ...

What clock speed as this device can go up to 400KHz?

So I wonder what clock speed you are trying to run at as DS1307 at least is 100KHz MAX I2C clock rate (SCL).

--
Paul Carpenter          | paul@pcserviceselectronics.co.uk
    PC Services
              GNU H8 & mailing list info
             For those web sites you hate
Reply to
Paul Carpenter

It was initially set at 400 kHz, but now it is running at 100kHz; which I did manage to verify on the Optascope.

Reply to
Jake

see

and

I now have it working. I had two problems:

1) The DS1307 absolutely MUST have a battery connected 2) The very last read of the device must be NACKed by the Master
Reply to
Gavin Jacobs

Darn. I almost suggested this [1], but it didn't seem to fit the symptoms you described. Sorry.

[1] I also wasted a day or so staring at 'scope traces due to having missed this point in the specs...

Steve

formatting link

Reply to
Steve at fivetrees

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.